SSAsir | R Documentation |
SSAsir method for identifying non-stationarity in mean.
SSAsir(X, ...) ## Default S3 method: SSAsir(X, K, n.cuts = NULL, ...) ## S3 method for class 'ts' SSAsir(X, ...)
X |
A numeric matrix or a multivariate time series object of class |
K |
Number of intervals the time series is split into. |
n.cuts |
A K+1 vector of values that correspond to the breaks which are used for splitting the data. Default is intervals of equal length. |
... |
Further arguments to be passed to or from methods. |
Assume that a p-variate Y with T observations is whitened, i.e. Y = S^(-1/2)*(X_t - (1/T)*sum_t(X_t)), for t = 1, …, T, where S is the sample covariance matrix of X.
The values of Y are then split into K disjoint intervals T_i. Algorithm first calculates matrix
M = sum((T_i/(T)) m_Ti m_Ti'),
where i = 1, …, K, K is the number of breakpoints, and m_Ti is the average of values of Y which belong to a disjoint interval T_i.
The algorithm finds an orthogonal matrix U via eigendecomposition
M = UDU^T.
The final unmixing matrix is then W = U S^(-1/2). The first k rows of U are the eigenvectors corresponding to the non-zero eigenvalues and the rest correspond to the zero eigenvalues. In the same way, the first k rows of W project the observed time series to the subspace of components with non-stationary mean, and the last p-k rows to the subspace of components with stationary mean.
A list of class 'ssabss', inheriting from class 'bss', containing the following components:
W |
The estimated unmixing matrix. |
S |
The estimated sources as time series object standardized to have mean 0 and unit variances. |
M |
Used separation matrix. |
K |
Number of intervals the time series is split into. |
D |
Eigenvalues of M. |
MU |
The mean vector of |
n.cut |
Used K+1 vector of values that correspond to the breaks which are used for splitting the data. |
method |
Name of the method ("SSAsir"), to be used in e.g. screeplot. |
Markus Matilainen, Klaus Nordhausen
Flumian L., Matilainen M., Nordhausen K. and Taskinen S. (2021) Stationary subspace analysis based on second-order statistics. Submitted. Available on arXiv: https://arxiv.org/abs/2103.06148
JADE
n <- 5000 A <- rorth(4) z1 <- arima.sim(n, model = list(ar = 0.7)) + rep(c(-1.52, 1.38), c(floor(n*0.5), n - floor(n*0.5))) z2 <- arima.sim(n, model = list(ar = 0.5)) + rep(c(-0.75, 0.84, -0.45), c(floor(n/3), floor(n/3), n - 2*floor(n/3))) z3 <- arima.sim(n, model = list(ma = 0.72)) z4 <- arima.sim(n, model = list(ma = c(0.34))) Z <- cbind(z1, z2, z3, z4) X <- tcrossprod(Z, A) res <- SSAsir(X, K = 6) res$D # Two non-zero eigenvalues screeplot(res, type = "lines") # This can also be seen in screeplot # Plotting the components plot(res) # The first two are nonstationary in mean
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.