| vwc {vectorwavelet} | R Documentation | 
Compute n-dimensional vector wavelet coherence
Description
Compute n-dimensional vector wavelet coherence
Usage
vwc(
  y,
  x,
  pad = TRUE,
  dj = 1/12,
  s0 = 2 * dt,
  J1 = NULL,
  max.scale = NULL,
  mother = "morlet",
  param = -1,
  lag1 = NULL,
  sig.level = 0.95,
  sig.test = 0,
  nrands = 300,
  quiet = FALSE
)
Arguments
| y | time series y in matrix format ( | 
| x | multivariate time series x in matrix format ( | 
| pad | pad the values will with zeros to increase the speed of the transform. Default is TRUE. | 
| dj | spacing between successive scales. Default is 1/12. | 
| s0 | smallest scale of the wavelet. Default is  | 
| J1 | number of scales - 1. | 
| max.scale | maximum scale. Computed automatically if left unspecified. | 
| mother | type of mother wavelet function to use. Can be set to
 | 
| param | nondimensional parameter specific to the wavelet function. | 
| lag1 | vector containing the AR(1) coefficient of each time series. | 
| sig.level | significance level. Default is  | 
| sig.test | type of significance test. If set to 0, use a regular
 | 
| nrands | number of Monte Carlo randomizations. Default is 300. | 
| quiet | Do not display progress bar. Default is  | 
Value
Return a vectorwavelet object containing:
| coi | matrix containg cone of influence | 
| rsq | matrix of wavelet coherence | 
| phase | matrix of phases | 
| period | vector of periods | 
| scale | vector of scales | 
| dt | length of a time step | 
| t | vector of times | 
| xaxis | vector of values used to plot xaxis | 
| s0 | smallest scale of the wavelet | 
| dj | spacing between successive scales | 
| mother | mother wavelet used | 
| type | type of  | 
| signif | matrix containg  | 
Author(s)
Tunc Oygur (info@tuncoygur.com.tr)
References
T. Oygur, G. Unal.. Vector wavelet coherence for multiple time series. Int. J. Dynam. Control (2020).
Examples
old.par <- par(no.readonly=TRUE)
t <- (-100:100)
y <- sin(t*2*pi)+sin(t*2*pi/4)+sin(t*2*pi/8)+sin(t*2*pi/16)+sin(t*2*pi/32)+sin(t*2*pi/64)
x1 <- sin(t*2*pi/8)
x2 <- sin(t*2*pi/16)
x3 <- sin(t*2*pi/32)
x4 <- sin(t*2*pi/64)
y <- cbind(t,y)
x <- cbind(t,x1,x2,x3,x4)
## n-dimensional multiple wavelet coherence
result <- vwc(y, x, nrands = 10)
result <- vwc(y, x)
## Plot wavelet coherence and make room to the right for the color bar
## Note: plot function can be used instead of plot.vectorwavelet
par(oma = c(0, 0, 0, 1), mar = c(5, 4, 4, 5) + 0.1,  pin = c(3,3))
plot.vectorwavelet(result, plot.cb = TRUE, main = "Plot n-dimensional vwc (n=5)")
par(old.par)