problem with stairs plot
Ältere Kommentare anzeigen
Hello I have just delighted come across 'stairs', which does exactly what I want...except it doesn't.
Even the example given: >> x = linspace(-2*pi,2*pi,40); >> stairs(x,sin(x))
plots me a single straight line between (0,0) and (1,1). (Everything I try gives this plot result)
Any great ideas for the obvious thing I'm doing wrong very gratefully received!
yours, Flummoxed.
Antworten (3)
Daniel Shub
am 20 Aug. 2011
Is something overloading stairs? Try
which -all stairs
it should give something like: .../toolbox/matlab/specgraph/stairs.m
2 Kommentare
deborah
am 20 Aug. 2011
Fangjun Jiang
am 20 Aug. 2011
What do you see if you do:
x = linspace(-2*pi,2*pi,40);
figure;plot(x,sin(x))
Fangjun Jiang
am 20 Aug. 2011
0 Stimmen
What's wrong? try stairs(1:20,1:20)
4 Kommentare
deborah
am 20 Aug. 2011
deborah
am 20 Aug. 2011
Fangjun Jiang
am 20 Aug. 2011
try this.
close all
stairs(1:20,1:20);
deborah
am 20 Aug. 2011
deborah
am 21 Aug. 2011
0 Stimmen
Kategorien
Mehr zu Labels and Styling finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!