Description Details Author(s) References Examples
Computes continuous wavelet transform of multiple irregularly sampled time series.
Package: | mvcwt |
Type: | Package |
Version: | 1.0 |
Date: | 2013-10-27 |
License: | GPL |
The main functions are mvcwt
, which computes the wavelet transform of multiple time series, and wmr
, which computes the wavelet modulus ratio, a measure of time series coherence.
Note that this is a complete rewrite of the code used in the reference below, and as such it is not well tested. It may give different or inaccurate results. I recommend you run tests on known data.
The most recent development version of this package can be found at https://bitbucket.org/tkeitt/mvcwt/overview.
Timothy H. Keitt (http://www.keittlab.org)
Tim Keitt <tkeitt@gmail.com>
Keitt, T. H. 2008. Coherent ecological dynamics induced by large-scale disturbance. Nature 454:331-4. doi:10.1038/nature06935.
1 2 3 4 5 6 7 8 9 10 11 12 13 | ## Not run:
stopifnot(require(foreach))
stopifnot(require(RColorBrewer))
x = seq(-pi, pi, len = 200)
y1 = sin(8 * x) + sin(32 * x)
y2 = sin(8 * (x + pi/8)) + sin(32 * x)
matplot(x, cbind(y1, y2), type = "l", lty = 1)
w = mvcwt(x, cbind(y1, y2))
plot(w, var = 1:2, scale = 2^seq(log2(min(w$y)), log2(max(w$y)), len = 5))
mr = wmr(w, smoothing = 2)
image(mr, reset.par = FALSE)
contour(mr, levels = c(0.01, 0.05, 0.1, 0.25, 0.5, 0.75, 0.9, 0.95, 0.99), add = TRUE)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.