For a complete discussion of this method, see K.V. Mardia and T.J. Hainsworth, A Spatial Thresholding Method for Image Segmentation, IEEE Trans. Pattern Anal. Machine Intell., 10 (1988) pp. 919-927.