Skip to content

Commit

Permalink
Use nstates instead of nx in lsimplot (#508)
Browse files Browse the repository at this point in the history
* Use nstates instead of nx in lsimplot
  • Loading branch information
albheim authored May 16, 2021
1 parent 0d9ec6f commit 6853c47
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plotting.jl
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ lsimplot
s2i(i,j) = LinearIndices((ny,1))[j,i]
for (si,s) in enumerate(systems)
s = systems[si]
y, t = lsim(s, p.args[2:end]...; x0 = x0 == 0 ? zeros(s.nx) : x0)
y, t = lsim(s, p.args[2:end]...; x0 = x0 == 0 ? zeros(nstates(s)) : x0)
seriestype := iscontinuous(s) ? :path : :steppost
for i=1:ny
ytext = (ny > 1) ? "Amplitude to: y($i)" : "Amplitude"
Expand Down

0 comments on commit 6853c47

Please sign in to comment.