Wtransform.image {fields}R Documentation

Quadratic W wavelet transform for an image

Description

Finds the forward or inverse discrete wavelet transform using the quadratic W basis.

Usage

Wtransform.image(x, inv=F, transpose=F, cut.min=8)

Arguments

x Matrix to be transformed
inv If true will compute the inverse transform default is false
transpose If true will compute the transpose of transform default is false
cut.min Minimum level of transformation. cut.min=8 means that the coarsest level will consist of 64=8X8 scale functions centered on an 8X8 grid.

Details

The wavelet transform can be thought as matrix multiplication A %*% vec(x) where vec(x) is the matrix x stacked by columns. The inverse transform is inv(A) %*% vec(x) and transpose is t(A) %*% vec( x)

Value

A matrix the same size as x.

References

Nychka,D. Wikle,C. , Royle, J.A. (1999) Large spatial prediction problems and nonstationary random fields

See Also

plot.coef, WQS, WQSi, Wtransform.D

Examples

# Wtransform of John Lennon image
data(lennon)
look<- Wtransform.image( lennon)
image.plot( look)
#threshhold 
thr<-  quantile( abs( look), .95)
temp<- look
temp[abs(look)< thr] <- 0
look2<- Wtransform.image( temp, inv=T)
image( look2) # 95 % compressed image

 
# a diagonal detail basis function 
temp<- matrix(0, nrow=32, ncol=32) 
temp[12,12]<- 1 
look<- Wtransform.image( temp , inv=T)
persp( look) 

[Package Contents]