Borrar filtros
Borrar filtros

How to plot histogram from two vectors

5 visualizaciones (últimos 30 días)
Martin Park
Martin Park el 9 de Oct. de 2013
Comentada: Daniela Rodríguez Castro el 19 de Feb. de 2020
Can someone help me how can I plot a histogram when I have two vectors where one vector is the x values say x=[1 2 3 4 5] and y is the count of each x y=[5 3 2 6 1]

Respuesta aceptada

Wayne King
Wayne King el 9 de Oct. de 2013
You want to use bar()
x = 1:5;
y = [5 3 2 6 1];
bar(x,y)
  1 comentario
Daniela Rodríguez Castro
Daniela Rodríguez Castro el 19 de Feb. de 2020
how can I do the same but with the histogram function?

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Histograms en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by