No BSD License
% Function to calculate Threshold for BayesShrink function threshold=bayes(X,sigmahat) len=length(X); sigmay2=sum(X.^2)/len; sigmax=sqrt(max(sigmay2-sigmahat^2,0)); if sigmax==0 threshold=max(abs(X)); else threshold=sigmahat^2/sigmax; end
Contact us at files@mathworks.com