Perform soft or hard thresholding.
Syntax
Y = wthresh(X,SORH,T)
Description
Y = wthresh(X,SORH,T) returns the soft (if SORH = 's') or hard (if SORH = 'h') T-thresholding of the input vector or matrix X. T is the threshold value.
Y = wthresh(X,'s',T) returns
, soft thresholding is wavelet shrinkage.
Y = wthresh(X,'h',T) returns
, hard thresholding is more crude.
Examples
% Generate signal and set threshold.
y = linspace(-1,1,100);
thr = 0.4;
% Perform hard thresholding.
ythard = wthresh(y,'h',thr);
% Perform soft thresholding.
ytsoft = wthresh(y,'s',thr);

See Also
wden, wdencmp, wpdencmp
[ Previous | Help Desk | Next ]