Discrete Wavelet Transform Operator

DESCRIPTION:

Creates a matrix which can be applied to a vector to obtain the discrete wavelet transform.

USAGE:

dwt.matrix(wavelet="d4", n=NULL, boundary="periodic", n.levels=1, 
           mix=F, dual=F) 

OPTIONAL ARGUMENTS:

wavelet
a character string giving the name of the wavelet, e.g. "d4", "s8". See dwt for a list of all available wavelet names.
n
an even number, giving the number of rows. This corresponds to the number of data points in the transform. Default value is set based on boundary rule and the length of the filter.
boundary
a character string giving the boundary rules, e.g. "periodic", "infinite", "zero". See dwt for a complete list of available boundary rules.
n.levels
the number of levels in the transform. For boundary="periodic", n.levels can be an integer greater than or equal to 1. For all other boundary rules, only n.levels=1 is allowed.
mix
logical flag indicating if the low-pass filter and high-pass filter are mixed. Default is FALSE, the filters are not mixed.
dual
logical flag indicating if a dual filter matrix is requested. Default is FALSE.
filter.reverse
logical flag indicating should wavelet filters be reversed.

VALUE:

n by n matrix, which can be used to perform the discrete wavelet transform (DWT).

DETAILS:

The DWT matrix is orthogonal when boundary="periodic" or "interval" with precondition=F. Coefficients obtained by dwt can be obtained by direct multiplication of the DWT matrix and the data, see example below.

SEE ALSO:

, .

EXAMPLES:

n <- 48 
xx <- rnorm(n) 
ww <- dwt(xx, wavelet="s8", n.levels=3) 
mm <- dwt.matrix(wavelet="s8", n, n.levels=3) 
yy <- mm%*%xx 
vecnorm(ww-yy)          # < .Machine$single.eps