How can I change the slopes of stairs plot?

5 次查看(过去 30 天)
The sequence of strokes is: horizontal, vertical _|. How to change it: vertical, horizontal |-?

采纳的回答

Marco Tullio
Marco Tullio 2016-10-10
编辑:Marco Tullio 2016-10-10
Try
x = [1 2 3]
y = [5 6 7]
stairs(x,y,'-.o')
axis([0 11 0 11])
% repeat 1st x
% shift up the y
nx = [x(1) x]
ny = [y(1) y(2:end) y(end)]
hold on
stairs(nx,ny,'-x')

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Graphics 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by