graythresh
Global image threshold using Otsu's method
Description
T = graythresh(I)T from grayscale image
                        I, using Otsu's method [1].
                    Otsu's method chooses a threshold that minimizes the intraclass variance of the
                    thresholded black and white pixels. The global threshold T
                    can be used with imbinarize to convert a
                    grayscale image to a binary image.
Examples
Input Arguments
Output Arguments
Tips
- By default, the function - imbinarizecreates a binary image using a threshold obtained using Otsu’s method. This default threshold is identical to the threshold returned by- graythresh. However,- imbinarizeonly returns the binary image. If you want to know the level or the effectiveness metric, use- graythreshbefore calling- imbinarize.
References
[1] Otsu, N., "A Threshold Selection Method from Gray-Level Histograms." IEEE Transactions on Systems, Man, and Cybernetics. Vol. 9, No. 1, 1979, pp. 62–66.
