The function automatically applies a maximal overlap discrete wavelet
transform to a provided univariate time series. Wrapper function for modwt
of the wavelets
package. It also allows the automatic selection
of the level and filter of the transform using fittestWavelet
.
WaveletT.rev()
reverses the transformation based on the imodwt
function.
WaveletT(
x,
level = NULL,
filter = c("haar", "d4", "la8", "bl14", "c6"),
boundary = "periodic",
...
)WaveletT.rev(pred = NULL, wt_obj)
A list containing each component series resulting from
the decomposition of x
(level
wavelet coefficients series and
level
scaling coefficients series).
An object of class modwt
containing the wavelet transformed/decomposed
time series is passed as an attribute named "wt_obj".
This attribute is passed to wt_obj
in WaveletT.rev()
.
A numeric vector or univariate time series to be decomposed.
An integer specifying the level of the decomposition. If
NULL
, it is automatically selected using fittestWavelet
.
A character string indicating which
wavelet filter to use in the decomposition. If NULL
, or a vector and length(filters)>1
, the
wavelet transform filter is automatically selected using fittestWavelet
.
See modwt
.
Additional arguments passed to fittestWavelet
.
A list containing component series (such as) resulting from wavelet transform (WaveletT()
).
Object of class modwt
containing the wavelet transformed series.
Rebecca Pontes Salles
A. J. Conejo, M. A. Plazas, R. Espinola, A. B. Molina, Day-ahead electricity price forecasting using the wavelet transform and ARIMA models, IEEE Transactions on Power Systems 20 (2005) 1035-1042.
T. Joo, S. Kim, Time series forecasting based on wavelet filtering, Expert Systems with Applications 42 (2015) 3868-3874.
C. Stolojescu, I. Railean, S. M. P. Lenca, A. Isar, A wavelet based prediction method for time series. In Proceedings of the 2010 International Conference Stochastic Modeling Techniques and Data Analysis, Chania, Greece (pp. 8-11) (2010).
fittestWavelet
, fittestEMD
Other transformation methods:
Diff()
,
LogT()
,
emd()
,
mas()
,
mlm_io()
,
outliers_bp()
,
pct()
,
train_test_subset()
data(CATS)
# \donttest{
w <- WaveletT(CATS[,1])
#plot wavelet transform/decomposition
plot(attr(w,"wt_obj"))
x <- WaveletT.rev(pred=NULL, attr(w,"wt_obj"))
all(round(x,4)==round(CATS[,1],4))
# }
Run the code above in your browser using DataLab