How can I find the intensity value which has the maximum number of pixels in the histogram? I'm using grayscale image. please I need a code ..
조회 수: 2 (최근 30일)
이전 댓글 표시
how can find a function to solve this?
댓글 수: 0
채택된 답변
Walter Roberson
2016년 10월 16일
[counts, edges] = histcounts(YourIntensityImage(:), 0:255);
[maxcount, maxidx] = max(counts);
most_common_intensity = edges(maxidx);
추가 답변 (1개)
Image Analyst
2016년 10월 16일
For a more general and somewhat different solution, you might look at the color frequency image: http://www.mathworks.com/matlabcentral/fileexchange/28164-color-frequency-image
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

