Interactive demo · Nonparametric Statistical Inference · Chapter 7

SURE and thresholding

Observe Zi = θi + εi, i = 1, …, n, with εi ~ N(0, 1). The soft threshold sets small Zi to zero and pulls the others towards zero by λ. Its risk depends on the unknown θ, but Stein's unbiased risk estimate (7.22), SURE(λ) = Σ [1 − 2 I(|Zi| ≤ λ) + min(Zi², λ²)], is computed from the data alone and has the right expectation for every λ. Panel (a) shows the data and the estimate; panel (b) compares SURE with the exact risk, the oracle risk Σ min(θi², 1), the James–Stein risk and the risk n of the raw data.

Mean vector θ

Number of means n

Rule

Threshold λ

Try these

The data come from a seeded generator (mulberry32 uniforms, Box–Muller normals), Zi = θi + εi in index order. Exact risks use the closed forms of Exercise 7: for one coordinate the soft-threshold risk is 1 + λ² + (θ² − λ² − 1)[Φ(λ − θ) − Φ(−λ − θ)] − (λ − θ)φ(λ + θ) − (λ + θ)φ(λ − θ). The James–Stein risk is the exact Poisson-mixture formula (7.44). SURE is not drawn for hard thresholding, which is not weakly differentiable (Exercise 6).

In the lecture notes