| stdWindowSlopeCast | R Documentation |
Calculates the variability of trends as a function of windowing length. The time-series data is split up into chunks of size w, and each chunk is fit to the equation
x(t) = A + Bt.
The function returns the standard deviation of the distribution of all the chunks Bs.
stdWindowSlopeCast(time, amplitude, windows)
time |
Times (spacings can be uniform or non-uniform), vector, float |
amplitude |
Amplitudes corresponding to times, vector, float |
windows |
Length of window(s) to calculate for, scalar or vector, float |
If 'windows' is a vector, the function will broadcast over it. Different calculation algorithms will be used depending on whether 'time' is uniformly or non-uniformly spaced.
## Broadcasting over a vector of windows
> time <- seq(0, 10, len=1000)
> amplitude <- sin(time)
stdWindowSlopeCast(time,amplitude,seq(0.1,0.8,len=5))
[1] 0.7243351 0.7299902 0.7294216 0.7379881 0.7297922
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.