Removing Values from Histogram
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I want to remove gray levels of particular range from Histogram of an Image. Anyone Know how to do?
1 Kommentar
Akzeptierte Antwort
Image Analyst
am 22 Dez. 2012
Let's say you had a masked image where a huge number of pixels were black and this produced a big spike in the histogram at zero. You can suppress this by setting that bin to zero.
[pixelCount, grayLevels] = imhist(grayImage, 256);
% Suppress zero bin:
pixelCount(1) = 0;
% Now plot:
bar(grayLevels, pixelCount);
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Histograms finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!