How to I get a threshold value from looking at histogram
13 次查看（过去 30 天）
Youssef Khmou 2015-3-29
Otsu's method exists as built in function with name graythresh, here is an example taken from Mathworks help page :
I = imread('coins.png');
level = graythresh(I);
BW = im2bw(I,level);
there might be other techniques to choose an adequate threshold.