How can I turn off the subplot from a prior string?

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

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.
Thank you. Close all hidden worked.
Ah! OK, thanks for letting us know...
@Ray Johnstonwhere did you use close all hidden function
Hi, you must write "figure," before the new image
with no quotation marks
@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...

Sign in to comment.

Answers (0)

Products

Tags

Asked:

on 12 Sep 2018

Commented:

dpb
on 23 Nov 2022

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!