Learn R Programming

wavethresh (version 4.7.3)

Cthreshold: Calls C code to threshold wd class object.

Description

A routine that calls a C code function to do thresholding. This is really a test routine to call a C thresholding function (Cthreshold) and the user is advised to use the R based generic thresholding function threshold and/or its methods as they contain a wider range of thresholding options.

Usage

Cthreshold(wd, thresh.type = "soft", value = 0, levels = 3:(nlevelsWT(wd) - 1))

Value

A wd.object class object, but containing thresholded coefficients.

Arguments

wd

The wavelet object that you wish to threshold.

thresh.type

The type of thresholding. This can be "soft" or "hard". See threshold and methods for further details.

value

The threshold value that you want to be used (e.g. for hard thresholding wavelet coefficients whose absolute value is less than

levels

The resolution levels that you wish to compute the threshold on and apply the threshold to.

Author

G P Nason

Details

For general use it is recommended to use the threshold functions as they have a wider variety of options and also work for more complex varieties of wavelet transforms (i.e. non-decimated, complex-valued, etc). However, in the right, limited, situation this function can be useful. This function directly calls the C thresholding function Cthreshold(). The C function is used by routines that operate on behalf of the function that carries out two-fold cross validation in C (CWCV) which is also accessible using the policy="cv" option too threshold.wd

This function can be used by the user. It might be a bit faster than threshold.wd but mostly because it is simpler and does less checking than threshold.wd.

See Also

threshold

Examples

Run this code
#
# See copious examples in the help to threshold.wd
#

Run the code above in your browser using DataLab