acf.spikeTrain
computes (and by default plots) estimates of the
autocovariance or autocorrelation function of the inter-spike
intervals of a spike train.
acf.spikeTrain(spikeTrain, lag.max = NULL, type = c("correlation", "covariance", "partial"), plot = TRUE, na.action = na.fail, demean = TRUE, xlab = "Lag (in isi #)", ylab = "ISI acf", main, ...)
spikeTrain
object or a vector which can be
coerced to such an object."correlation"
(the default), "covariance"
or
"partial"
.TRUE
(the default) the acf is plotted.na.pass
can be used.plot.acf
."acf"
, which is a list with the following
elements:lag
containing
the estimated acf.type
argument).x
.k
value returned by ccf(x,y)
estimates the
correlation between x[t+k]
and y[t]
.The result is returned invisibly if plot
is TRUE
.
acf
function. The first argument,
spikeTrain
, is processed first to extract the inter-spike
intervals. acf.spikeTrain
is mainly used to plot what Perkel et
al (1967) call the serial correlation coefficient (Eq. 8) or
serial covariance coefficient (Eq. 7), p 400.
acf
,
varianceTime
,
renewalTestPlot
## Simulate a log normal train
train1 <- c(cumsum(rlnorm(301,log(0.01),0.25)))
train1 <- as.spikeTrain(train1)
## Get its isi acf
acf.spikeTrain(train1,lag.max=100)
Run the code above in your browser using DataLab