Description Usage Arguments Details Value Note Author(s) References See Also Examples
Computes w - correlations (Golyandina, et.al. 2001) from a matrix containing reconstructed components in its columns.
1 | ssa_w_cor(z, l, k)
|
z |
A matrix containing reconstructed components in its columns. |
l |
An integer for the window width |
k |
An integer defined by k=t-l+1 |
w-correlations can be used to assess how well reconstructed components can be separated from each other. See reference for more details.
A square matrix containing the w-correlations between components.
~~further notes~~
Patrick Crutcher
Golyandina, N.; Nekrutkin, V. & Zhiglkilavskifi, A. Analysis of Time Series Structure: SSA and Related Techniques. CRC Press, 2001
~~objects to See Also as help
, ~~~
1 2 3 4 5 6 7 8 9 10 11 12 13 | #x <- sin(seq(0,10*pi,len=200))
#x <- x + rnorm(x)/2
#x.wc <- w.cor(x.rc,40)
#image(x.wc,col=gray(100:0/100))
## The function is currently defined as
function(z,l,k) {
ls<-min(l,k); ks<-max(l,k)
n<-nrow(z); w<-rep(ls,n)
w[1:ls]<-1:ls; w[(ks+1):n]<-n-(ks:(n-1))
c<-crossprod(z,w*z); d<-diag(c)
return(c/sqrt(outer(d,d)))
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.