threshold_coefficients: Threshold wavelet coefficients

View source: R/wavelet_core.R

threshold_coefficientsR Documentation

Threshold wavelet coefficients

Description

Applies a thresholding rule to the detail coefficients of a periodic DWT.

* '"hard"': term-by-term hard thresholding, \hat d\,1\{|\hat d| > \lambda\}, with \lambda = c\,\hat\sigma\sqrt{\log(n)/n} (Chesneau, Dewan and Doosti 2016; c = 8 in their implementation). * '"block"': the BlockJS rule of Cai (1999) used by Shirazi and Doosti (2022): at each level the coefficients are grouped in blocks of length L = \lfloor \log n \rfloor; a block is kept if \sum_{j \in B} \hat d_j^2 \ge \lambda^* L \hat\sigma^2 with \lambda^* = 4.50524 ('rule = "truncate"'), or shrunk by (1 - \lambda^* L \hat\sigma^2 / S_B^2)_+ ('rule = "james-stein"').

\hat\sigma is the MAD of the finest-level coefficients.

Usage

threshold_coefficients(
  w,
  L,
  n,
  type = c("hard", "block"),
  const = NULL,
  block_length = NULL,
  rule = c("truncate", "james-stein")
)

Arguments

w

coefficient vector from [dwt_periodic()].

L

number of DWT levels used to produce 'w'.

n

sample size (enters the threshold).

type

'"hard"' or '"block"'.

const

threshold constant: 'c' for '"hard"', \lambda^* for '"block"'.

block_length

block length for '"block"'; default \lfloor\log n\rfloor.

rule

for '"block"': '"truncate"' (keep/kill) or '"james-stein"'.

Value

thresholded coefficient vector.

References

Cai, T. T. (1999). Adaptive wavelet estimation: a block thresholding and oracle inequality approach. *Annals of Statistics*, 27, 898–924.


qdfauction documentation built on Nov. 10, 2026, 5:07 p.m.