marg.spec | R Documentation |
marg.spec
returns the time-average spectra of LSWP processes for each packet.
marg.spec(bas, spec, plot = TRUE)
bas |
is a (|b| x 2) matrix containing indices of a wavelet packet basis, where |b| is the number of packets in the basis. |
spec |
is a (|b| x T) matrix containing, in each row, the values of the time-varying spectra for each packet. |
plot |
should a plot of the marginal spectra vs frequency intervals be returned? |
This function computes the frequency intervals corresponding to each packet, along with the (time) average spectra for each packet.
This function is used to compute, and eventually plot, the time averaged spectra (or spectral estimate) vs packet frequencies. The arguments bas and spec shuld be provided as matrices.
A (|b| x 2) matrix. In the first column the lower frequency relative to each packet is displayed. The second column contains the (time) average spectra.
Alessandro Cardinali
A. Cardinali and G.P. Nason (2017). Locally Stationary Wavelet Packet Processes: Basis Selection and Model Fitting. Journal of Time Series Analysis, 38:2, 151-174.
best.basis
, get.wavelet.basis
wwb <- get.wavelet.basis(scale = 4) wwp <- matrix(2^{-(1:4)}, nrow = 4, ncol = 512, byrow = FALSE) msp <- marg.spec(bas = wwb, spec = wwp, plot = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.