
Space-time decompositions: CP and Tucker tensors, matrix factorisation, Haar wavelets, harmonic trends
Source:R/SpaceTimeDecomp.R
CpAls.RdCpAls: CP/PARAFAC of a three-way array by alternating least squares
from the HOSVD start, unit-norm columns with weights, ordered by weight,
largest entry of each A and B column positive. TuckerHooi: HOSVD
followed by higher-order orthogonal iteration. MatrixFactorizationAls:
ridge-regularised X ~ U t(V) over observed entries (NA missing) by
alternating ridge regressions. HaarDwt and HaarMra: Haar
pyramid algorithm with W_t = (V_(2t+1) - V_(2t)) / sqrt(2) and the
additive multiresolution analysis (as the wavelets package).
HaarDwt2d and HaarMra2d: separable two-dimensional versions
(subbands a, h, v, d). WaveletDetrend: x - S_J.
HarmonicRegression: least-squares Fourier trend with amplitudes and phases.
Usage
CpAls(tensor, rank, max_iter = 500, tol = 1e-12)
TuckerHooi(tensor, ranks, max_iter = 50, tol = 1e-12)
MatrixFactorizationAls(X, rank, l2 = 0.1, max_iter = 200, tol = 1e-12)
HaarDwt(x, levels)
HaarMra(x, levels)
HaarDwt2d(field, levels)
HaarMra2d(field, levels)
WaveletDetrend(x, levels)
HarmonicRegression(y, t, period, n_harmonics = 2, trend = TRUE)Arguments
- tensor
Three-way array (or nested list).
- rank
Number of components.
- max_iter, tol
Iteration limit and tolerance.
- ranks
Tucker ranks (length 3).
- X
Data matrix (NA for missing).
- l2
Ridge penalty.
- x
Series (length a multiple of
2^levels).- levels
Number of levels.
- field
Matrix (dimensions multiples of
2^levels).- y
Response series.
- t
Times.
- period
Fundamental period.
- n_harmonics
Number of harmonics.
- trend
Include a linear trend.
References
Kolda, T. G. and Bader, B. W. (2009). SIAM Review 51, 455-500. De Lathauwer, L., De Moor, B. and Vandewalle, J. (2000). SIAM J. Matrix Anal. Appl. 21, 1253-1278. Koren, Y., Bell, R. and Volinsky, C. (2009). Computer 42(8), 30-37. Percival, D. B. and Walden, A. T. (2000). Wavelet Methods for Time Series Analysis. Mallat, S. G. (1989). IEEE Trans. PAMI 11, 674-693. Bloomfield, P. (2000). Fourier Analysis of Time Series.