How can I turn off the subplot from a prior string?
Show older comments
I am writing a long series of strings with several different graphs. I used the subplot function in a previous string, and now every time I try to graph subsequently, it defaults to the same subplot. How can i revert to a single graph with multiple curves in the subsequent string?
7 Comments
dpb
on 12 Sep 2018
I don't know what "writing a long series of strings with several different graphs" means; we can't debug code we can't see.
If you're getting a subplot instead of a full-sized axes, then you're still plotting into an existing axes or have done something more insidious/subtle such as inadvertently aliasing one of the other commands/functions.
Try
close all hidden
and then
axes
and see if all doesn't return to normal.
If still is a subplot, then you definitely have managed to redefine something somehow; in that case
clear all
and try again.
If that doesn't do it, will need more extensive bird-dogging to uncover just what you actually did.
Ray Johnston
on 12 Sep 2018
dpb
on 12 Sep 2018
Ah! OK, thanks for letting us know...
Jiby
on 28 Sep 2022
Cesar Antenor
on 23 Nov 2022
Hi, you must write "figure," before the new image
Cesar Antenor
on 23 Nov 2022
with no quotation marks
dpb
on 23 Nov 2022
@Jiby Although this is late, didn't see until @Cesar Antenor's response brought the thread to the top again -- for the record and anybody who stumbles on later, the use of the clear command was done at the command line to clean up the environment before trying again...
Answers (0)
Categories
Find more on Subplots in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!