Spike
Loading...
Searching...
No Matches
statistics.h
1#ifndef SPIKE_STATISTICS_H
2#define SPIKE_STATISTICS_H
3
4#include <fftw3.h>
5
6#include <complex>
7#include <vector>
8
10#include "Spike/Signal/WhiteNoiseSignal.h"
11#include "Spike/SpikeTrain/SpikeTrain.h"
12#include "Spike/TimeFrame/TimeFrame.h"
13
14namespace Spike {
15
16double mean(const std::vector<double> &array);
17
18double standard_deviation(const std::vector<double> &array);
19
20std::vector<double> get_spike_times(const SpikeTrain &spike_train,
21 const TimeFrame &time);
22
23double calculate_cv(const std::vector<double> &spike_times);
24
25void cross_spectrum(const std::vector<double> &input_signal,
26 const std::vector<double> &output_signal,
27 const TimeFrame &time_frame,
28 std::complex<double> *spectrum);
29
30void power_spectrum(const std::vector<double> &signal,
31 const TimeFrame &time_frame, std::vector<double> &spectrum);
32
33void susceptibility(const std::vector<double> &input_signal,
34 const std::vector<double> &output_signal,
35 const TimeFrame &time_frame,
36 std::vector<std::complex<double>> &suscept);
37
38void susceptibility(const WhiteNoiseSignal &signal,
39 const std::vector<double> &output_signal,
40 const TimeFrame &time_frame,
41 std::vector<std::complex<double>> &suscept, size_t norm);
42
43void susceptibility_lin_nonlin(const WhiteNoiseSignal &signal,
44 const std::vector<double> &output_signal,
45 const TimeFrame &time_frame,
46 std::vector<std::complex<double>> &suscept_lin,
47 std::vector<std::complex<double>> &suscept_nonlin_diag,
48 std::vector<std::complex<double>> &suscept_nonlin_antidiag,
49 size_t norm);
50
51void susceptibility_nonlin(
52 const WhiteNoiseSignal &signal, const std::vector<double> &output_signal,
53 const TimeFrame &time_frame,
54 std::vector<std::vector<std::complex<double>>> &suscept_nonlin,
55 size_t norm);
56
57} // namespace Spike
58
59#endif // SPIKE_STATISTICS_H