Analysis¶
Statistics of spike trains¶

brian.
firing_rate
(spikes)¶ Rate of the spike train.

brian.
CV
(spikes)¶ Coefficient of variation.

brian.
correlogram
(T1, T2, width=20.0 * msecond, bin=1.0 * msecond, T=None)¶ Returns a crosscorrelogram with lag in [width,width] and given bin size. T is the total duration (optional) and should be greater than the duration of T1 and T2. The result is in Hz (rate of coincidences in each bin).
N.B.: units are discarded. TODO: optimise?

brian.
autocorrelogram
(T0, width=20.0 * msecond, bin=1.0 * msecond, T=None)¶ Returns an autocorrelogram with lag in [width,width] and given bin size. T is the total duration (optional) and should be greater than the duration of T1 and T2. The result is in Hz (rate of coincidences in each bin).
N.B.: units are discarded.

brian.
CCF
(T1, T2, width=20.0 * msecond, bin=1.0 * msecond, T=None)¶ Returns the crosscorrelation function with lag in [width,width] and given bin size. T is the total duration (optional). The result is in Hz**2: CCF(T1,T2)=<T1(t)T2(t+s)>
N.B.: units are discarded.

brian.
ACF
(T0, width=20.0 * msecond, bin=1.0 * msecond, T=None)¶ Returns the autocorrelation function with lag in [width,width] and given bin size. T is the total duration (optional). The result is in Hz**2: ACF(T0)=<T0(t)T0(t+s)>
N.B.: units are discarded.

brian.
CCVF
(T1, T2, width=20.0 * msecond, bin=1.0 * msecond, T=None)¶ Returns the crosscovariance function with lag in [width,width] and given bin size. T is the total duration (optional). The result is in Hz**2: CCVF(T1,T2)=<T1(t)T2(t+s)><T1><T2>
N.B.: units are discarded.

brian.
ACVF
(T0, width=20.0 * msecond, bin=1.0 * msecond, T=None)¶ Returns the autocovariance function with lag in [width,width] and given bin size. T is the total duration (optional). The result is in Hz**2: ACVF(T0)=<T0(t)T0(t+s)><T0>**2
N.B.: units are discarded.

brian.
total_correlation
(T1, T2, width=20.0 * msecond, T=None)¶ Returns the total correlation coefficient with lag in [width,width]. T is the total duration (optional). The result is a real (typically in [0,1]): total_correlation(T1,T2)=int(CCVF(T1,T2))/rate(T1)

brian.
spike_triggered_average
(spikes, stimulus, max_interval, dt, onset=None, display=False)¶ Spike triggered average reverse correlation. spikes is an array containing spike times stimulus is an array containing the stimulus max_interval (second) is the duration of the averaging window dt (second) is the sampling period onset (second) before which the spikes are discarded. Note: it will be at least as long as max_interval display (default=False) display the number of spikes processed out of the total number output the spike triggered average and the corresponding time axis