Filter löschen
Filter löschen

how to label y axis of a graph in horizontal manner

14 Ansichten (letzte 30 Tage)
how to label y axis of a graph in horizontal manner... my output should be jan feb march

Akzeptierte Antwort

Azzi Abdelmalek
Azzi Abdelmalek am 10 Mai 2013
Example
y=[1 2 3 4];
plot(y),
set(gca,'ytick',y,'yticklabel',{'Jan','Feb','March','April'})

Weitere Antworten (2)

Azzi Abdelmalek
Azzi Abdelmalek am 10 Mai 2013
By default, y ticks are horizontal

David Sanchez
David Sanchez am 10 Mai 2013
Here you are:
ylabel({'jan';'feb';'march'},'Rotation',0)
  2 Kommentare
Sivakumaran Chandrasekaran
how to increase space between jan and feb
Welbeck Sintim
Welbeck Sintim am 6 Sep. 2020
Thanks for sharing! Works perfectly fine.

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu 2-D and 3-D Plots finden Sie in Help Center und File Exchange

Tags

Produkte

Community Treasure Hunt

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

Start Hunting!

Translated by