Learn R Programming

rwavelet (version 0.4.2)

HardThresh: Apply Hard Threshold

Description

Apply Hard Threshold

Usage

HardThresh(y, t)

Value

A numeric vector with entries

\(x_i = y_i \mathbf{1}_{\{|y_i| > t\}}\).

Arguments

y

Noisy Data.

t

Threshold.

See Also

SoftThresh.

Examples

Run this code
f <- MakeSignal('HeaviSine',2^3)
qmf <- MakeONFilter('Daubechies', 10)
L <- 0
wc <- FWT_PO(f, L, qmf)
thr <- 2
wct <- HardThresh(wc, thr)
fhard <- IWT_PO(wct, L, qmf)

Run the code above in your browser using DataLab