Description Usage Arguments Details Value Note Author(s) References See Also Examples
Fourier SSA
1 | sincos(L)
|
L |
window length |
~~ If necessary, more details than the description above ~~
s |
matrix of Fourier coefficients |
~~further notes~~
~~who you are~~
~put references to the literature/web site here ~
~~objects to See Also as help
, ~~~
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | ##---- Should be DIRECTLY executable !! ----
##-- ==> Define data, use random,
##-- or do help(data=index) for the standard data sets.
## The function is currently defined as
function(L) {
x<-2*pi*(1:L)/L
M<-floor(L/2)
if (is.even(L)) N<-M-1 else N<-M
s<-matrix(0,L,N+M+1)
for (k in 1:N)
s[,k]<-sin(x*k)
for (k in 0:M)
s[,N+k+1]<-cos(x*k)
return(apply(s,2,function(z) z/sqrt(sum(z^2))))
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.