How can I use sliceomatic for 3D plots without getting the below errors?
1 view (last 30 days)
I have trying to use slicematics for a 3D plot, but I keep getting the error below
here is the code.
here is the error below
Error using matlab.graphics.axis.Axes/set
While setting the 'NextPlot' property of 'Axes':
'new' is not a valid value. Use one of these values: 'add' | 'replace' |
'replacechildren' | 'replaceall'.
Error in sliceomaticfigure (line 162)
Error in sliceomatic (line 203)
d = sliceomaticfigure(d);
DGM on 20 Jun 2022
As far as I know, sliceomatic() has been broken for years. As the error says, 'new' is not a valid option for the 'nextplot' property of an axes object. It is in R2009b, but it's not in R2015b. I'm going to assume that this error has existed since R2014b or so, but nailing down the exact change in options would require documentation which no longer exists. Considering when the last update was, I have to assume that the last update was broken in the current version when it was posted.
How can the error be avoided? As far as I know, you either use an older version of MATLAB, or you rewrite sliceomatic() to be compatible with newer versions. The above issue with the 'nextplot' property isn't the only problem. There are multiple comments like this one which attempt to patch the known problems. You'll have to read the comments and debug as necessary. I'm not even sure that any of these recommended edits work, and I'm not sure whether there are new version-dependencies among them.