putD.wd3D: Put wavelet coefficient array into a 3D wavelet object

putD.wd3DR Documentation

Put wavelet coefficient array into a 3D wavelet object

Description

This function put an array of wavelet coefficients, corresponding to a particular resolution level into a wd wavelet decomposition object.

The pyramid of coefficients in a wavelet decomposition (returned from the wd3D function, say) are packed into a single array in WaveThresh3.

Usage

## S3 method for class 'wd3D'
putD(x, v, ...)

Arguments

x

3D Wavelet decomposition object into which you wish to insert the wavelet coefficients.

v

This argument is a list with the following components:

a

A 3-dimensional array with each dimension of length equal to two to the power of lev which is the level at which you wish to insert the coefficients into x.

lev

The level at which you wish to insert the coefficients into x.

block

A character string indicating which coefficient block you wish to insert the coefficients into. This can be one of GGG, GGH, GHG, GHH, HGG, HGH, HHG. Additionally this can be HHH when the lev argument above is zero.

...

Other arguments

Details

The need for this function is a consequence of the pyramidal structure of Mallat's algorithm and the memory efficiency gain achieved by storing the pyramid as an array.

Note that this function is a method for the generic function putD.

Value

A new wd3D.object is returned with the coefficients at level lev in block given by block are replaced by the contents of a, if a is of the correct dimensions!

RELEASE

Version 3.9.6 Copyright Guy Nason 1997

Author(s)

G P Nason

See Also

accessD, accessD.wd3D, print.wd3D, putD, putDwd3Dcheck, summary.wd3D, threshold.wd3D, wd3D, wd3D.object, wr3D.

Examples

#
# Generate some test data
#
a <- array(rnorm(8*8*8), dim=c(8,8,8))
#
# Perform the 3D DWT
#
awd3D <- wd3D(a)
#
# Replace the second level coefficients by uniform random variables
# in block GGG (for some reason)
#
#
newsubarray <- list(a = array(runif(4*4*4), dim=c(4,4,4)), lev=2, block="GGG")
awd3D <- putD(awd3D,  v=newsubarray)

wavethresh documentation built on Sept. 11, 2024, 9:33 p.m.