histogram

3 views (last 30 days)
javeed miyandad
javeed miyandad on 10 Apr 2011
how to calculate threshold value using histogram ,that is average of two hightest velles in in histogram

Answers (2)

Walter Roberson
Walter Roberson on 10 Apr 2011
sort() the values of interest, take the first two of the sorted results and average them.
  3 Comments
Oleg Komarov
Oleg Komarov on 10 Apr 2011
How do you generate the histogram?
javeed miyandad
javeed miyandad on 10 Apr 2011
img= histeq(BW);%BW is a binary image
figure, imhist(BW,100)% 100 is number of bins

Sign in to comment.


Oleg Komarov
Oleg Komarov on 10 Apr 2011
[counts,x] = imhist(BW,100)

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!