New install 2021a not plotting data
14 views (last 30 days)
Show older comments
Just upgraded from 2019b to 2021a. Standard workflow for plotting data not working in 2021a.
Variable: Y is 5500000x1 double containing reals from -500 to +500 at 4 decimal precision
Calling figure; plot(Y) gives this error:
Array indices must be positive integers or logical values.
Error in matlab.graphics.shape.internal.ScribeStackManager/findLayer
Error in matlab.graphics.shape.internal.ScribeStackManager/getLayer
Error in newplot (line 77)
ax = gca(fig);
Error in matlab.graphics.internal.newplotwrapper (line 11)
axReturn = newplot(varargin{:});
Same data, same command in 2019b plots without issue. Note, even setting Y = [1;2;3;4] and calling plot(Y) fails and gives same error. Is this an installation problem? Some weird incompatibility?
3 Comments
Answers (2)
Steven Lord
on 23 Jul 2021
Let's make sure you haven't accidentally written or downloaded a function that is taking precedence over the built-in functions and the functions included in MATLAB. What do these commands display?
which plot
which gca
which newplot
which get
See Also
Categories
Find more on Introduction to Installation and Licensing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!