stacked plot x axis change in 2015 matlab version

1 visualización (últimos 30 días)
SOMNATH MAHATO
SOMNATH MAHATO el 9 de Jun. de 2021
Comentada: SOMNATH MAHATO el 9 de Jun. de 2021
Y=[ 1 9 5 4 20
6 6 7 5 19
10 10 6 5 21]
need stacked plot of these data. But x axis would be 1, 6, 10 and y axis stacked bar data (9,5,4,20), (6,7,5,19) and (10,6,5,21)

Respuesta aceptada

Joel Lynch
Joel Lynch el 9 de Jun. de 2021
Editada: Joel Lynch el 9 de Jun. de 2021
bar(Y(:,1),Y(:,2:end))
  3 comentarios
Joel Lynch
Joel Lynch el 9 de Jun. de 2021
bar(Y(:,1),Y(:,2:end),'stacked')

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Line Plots 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