Multiple image histogram on the same figure

Hi I would like to know how I can plot multiple histogram on the same figure with different color next to each other using imhist command. I know how to do it using hist for a vector but I am looking for doing exactly same thing but for images. something like uploaded image but using imhist.

 Respuesta aceptada

Image Analyst
Image Analyst el 4 de Ag. de 2014

0 votos

Why can't you just use hist() or histc(), and bar() or plot()???

2 comentarios

chess
chess el 4 de Ag. de 2014
Because when I do that I get something like: which is very strange.
You have to vectorize the array first:
counts = hist(array2d(:), 256);
Otherwise you'll get a histogram for every column in the image.

Iniciar sesión para comentar.

Más respuestas (0)

Etiquetas

Preguntada:

el 4 de Ag. de 2014

Comentada:

el 4 de Ag. de 2014

Community Treasure Hunt

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

Start Hunting!

Translated by