Thresholding
threshold(M, thresh)—Returns the matrix M with every element below thresh set to thresh. If thresh is negative, every element above −thresh is set to −thresh.
Thresholding can be used to remove background features (or noise) in an image or to shift its intensity spectrum.
* 
This function can be used in one of three ways:
When thresh is zero, all elements are set to zero.
When thresh is positive, elements of M less than thresh are set to zero; otherwise they retain their original value.
When thresh is negative, elements of M greater than the absolute value of thresh are set to zero; otherwise they retain their original value.
Arguments
M is an image matrix.
thresh a real number.
Was this helpful?