Description Usage Arguments Value
View source: R/EstimateResponseDelayByMomentMatching.R
A function that detects the delay of a response relative to the odor onset by finding the delay with maximum cross correlation of the given response rate timecourse, with that of the odor onset convolved with a decaying exponential. The parameters of the exponential are found by moment matching.
1 2 | EstimateResponseDelayByMomentMatching(y, x0, verbose = FALSE, plot = FALSE,
minDelay = 0, fitOdorProfileOnError = TRUE)
|
y |
A length T vector of the mean firing rate of the neuron in a series of bins. |
x0 |
A binary length T vector indicating the odor window. |
verbose |
Whether to print out the results |
plot |
Whether to plot the delayed exponential on top of the firing rate. |
minDelay |
The minimum delay value that can be used. |
fitOdorProfileOnError |
Whether to fit the odor profile itself if learning the filter parameters failed. |
A list consisting of
a0 |
The amplitude of the exponential. |
a1 |
The autoregressive coefficient of the exponential |
tau |
The time constant of the exponential. a1 = exp(-1/tau). |
l0 |
The baseline firing rate. |
delay |
The delay with the highest correlation. |
status |
A string. "OK" if the parameters could be learned, "ERROR" if not. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.