tssdr {tsBSS} | R Documentation |
Supervised Dimension Reduction for Multivariate Time Series
Description
Supervised dimension reduction for multivariate time series data. There are three different algorithms to choose from. TSIR is a time series version of Sliced Inverse Regression (SIR), TSAVE is a time series version of Sliced Average Variance Estimate (TSAVE) and a hybrid of TSIR and TSAVE is TSSH (Time series SIR SAVE Hybrid). For summary of an object of class tssdr, see summary.tssdr
.
Usage
tssdr(y, X, ...)
## Default S3 method:
tssdr(y, X, algorithm = c("TSIR", "TSAVE", "TSSH"), k = 1:12, H = 10, weight = 0.5,
method = c("frjd", "rjd"), eps = 1e-06, maxiter = 1000, ...)
## S3 method for class 'ts'
tssdr(y, X, ...)
## S3 method for class 'xts'
tssdr(y, X, ...)
## S3 method for class 'zoo'
tssdr(y, X, ...)
## S3 method for class 'tssdr'
print(x, digits = 3, ...)
## S3 method for class 'tssdr'
components(x, ...)
## S3 method for class 'tssdr'
plot(x, main = "The response and the directions", ...)
Arguments
y |
A numeric vector or a time series object of class |
X |
A numeric matrix or a multivariate time series object of class |
algorithm |
Algorithm to be used. The options are |
k |
A vector of lags. It can be any non-zero positive integer, or a vector consisting of them. Default is |
H |
The number of slices. If |
weight |
Weight |
method |
The method to use for the joint diagonalization. The options are |
eps |
Convergence tolerance. |
maxiter |
The maximum number of iterations. |
... |
Further arguments to be passed to or from methods. |
In methods for class 'tssdr' only:
x |
An object of class tssdr |
digits |
The number of digits when printing an object of class tssdr. Default is 3 |
main |
A title for a plot when printing an object of class tssdr. |
Details
Assume that the -variate time series
with
observations is whitened, i.e.
, for
,
where
is a sample covariance matrix of
.
Divide
into
disjoint intervals (slices) by its empirical quantiles.
For each lag , denote
for a vector of the last
values of the sliced
. Also denote
for the first
observations of
. Then
are the disjoint slices of
according to the values of
.
Let be the number of observations in
.
Write
for
,
and
.
Then for algorithm
TSIR
matrix
Denote for a sample covariance matrix of
. Then for algorithm
TSAVE
matrix
.
For TSSH
then matrix
for a chosen . Note that the value of
can be different for TSIR and TSAVE parts.
The algorithms find an orthogonal matrix by maximizing, for
or
,
for and all lags
.
The final signal separation matrix is then
.
Write , where
is chosen in such way that
for
and all lags
.
Then the
:th element of the matrix
is
.
To make a choice on which lags and directions to keep, see summary.tssdr
. Note that when printing a tssdr object, all elements are printed, except the directions S.
Value
A list of class 'tssdr' containing the following components:
W |
The estimated signal separation matrix. |
k |
The vector of the used lags. |
S |
The estimated directions as time series object standardized to have mean 0 and unit variances. |
MU |
The mean vector of |
L |
The Lambda matrix for choosing lags and directions. |
H |
The used number of slices. |
yname |
The name for the response time series |
Xname |
The name for the predictor time series |
algorithm |
The used algorithm as a character string. |
Author(s)
Markus Matilainen
References
Matilainen, M., Croux, C., Nordhausen, K. and Oja, H. (2017), Supervised Dimension Reduction for Multivariate Time Series, Econometrics and Statistics, 4, 57–69.
Matilainen, M., Croux, C., Nordhausen, K. and Oja, H. (2019), Sliced Average Variance Estimation for Multivariate Time Series. Statistics: A Journal of Theoretical and Applied Statistics, 53, 630–655.
Li, K.C. (1991), Sliced Inverse Regression for Dimension Reduction, Journal of the American Statistical Association, 86, 316–327.
Cook, R. and Weisberg, S. (1991), Sliced Inverse Regression for Dimension Reduction, Comment. Journal of the American Statistical Association, 86, 328–332.
See Also
Examples
n <- 10000
A <- matrix(rnorm(9), 3, 3)
x1 <- arima.sim(n = n, list(ar = 0.2))
x2 <- arima.sim(n = n, list(ar = 0.8))
x3 <- arima.sim(n = n, list(ar = 0.3, ma = -0.4))
eps2 <- rnorm(n - 1)
y <- 2*x1[1:(n - 1)] + eps2
X <- ((cbind(x1, x2, x3))[2:n, ]) %*% t(A)
res1 <- tssdr(y, X, algorithm = "TSAVE")
res1
summ1 <- summary(res1, type = "alllag", thres = 0.8)
summ1
plot(summ1)
head(components(summ1))
coef(summ1)
# Hybrid of TSIR and TSAVE. For TSIR part H = 10 and for TSAVE part H = 2.
tssdr(y, X, algorithm = "TSSH", weight = 0.6, H = c(10, 2))