Discussion:
simple question on close figure
(too old to reply)
Jade
2005-05-13 15:27:41 UTC
Permalink
Hi, all

My program has many lines of

figure, imshow(....)

when the program finish, it open a lot of figure windows, I would
like to know, what command should I use , to close all these figure
in one time? I use window 2000. Also , even I use XP, it will close
the whole matlab, instead of just figure window.

Thanks in advance!
Jade
Guillermo
2005-05-13 15:37:47 UTC
Permalink
close all
Post by Jade
Hi, all
My program has many lines of
figure, imshow(....)
when the program finish, it open a lot of figure windows, I would
like to know, what command should I use , to close all these figure
in one time? I use window 2000. Also , even I use XP, it will close
the whole matlab, instead of just figure window.
Thanks in advance!
Jade
Sachin
2005-05-13 15:40:33 UTC
Permalink
'close all'??
Post by Jade
Hi, all
My program has many lines of
figure, imshow(....)
when the program finish, it open a lot of figure windows, I would
like to know, what command should I use , to close all these figure
in one time? I use window 2000. Also , even I use XP, it will
close
the whole matlab, instead of just figure window.
Thanks in advance!
Jade
Chrissy
2005-05-13 15:42:06 UTC
Permalink
Hi,

You can just write:

close(figure)

after you do you plot or whatever. You'll want to save it first
though:
ex.

figName = '\directory where you want it saved';
saveas(gcf, figName)

Chrissy
Amin Mohammed
2015-05-19 05:54:23 UTC
Permalink
How to close abundance number of figures at once
%%%%%%%%%%%%%%%%%%%
1.What you could do is that, if you can reach the command window, or you've an opening m-flie, or create new one and type anything in it, let say you just type: % anywhere in the file regardless is already open or you create it as a new file.
2. The next step is that you need to right click on the matlab icon appearing down on your taskbar and select the last option i.e. close all windows, once you do all the figure will get closed, however, because you've typed % early in an m-flie, the matlab program will not close immediately, fist it will ask you whether you want to save you change; yes, no, or cancel. Just select cancel which will keep you the program open. Both yer/no will save/discard the change and close the program.

I hope this help.
Steven Lord
2015-05-19 13:27:56 UTC
Permalink
Post by Amin Mohammed
How to close abundance number of figures at once
%%%%%%%%%%%%%%%%%%%
1.What you could do is that, if you can reach the command window, or
you've an opening m-flie, or create new one and type anything in it, let
say you just type: % anywhere in the file regardless is already open or
you create it as a new file. 2. The next step is that you need to right
click on the matlab icon appearing down on your taskbar and select the
last option i.e. close all windows, once you do all the figure will get
closed, however, because you've typed % early in an m-flie, the matlab
program will not close immediately, fist it will ask you whether you want
to save you change; yes, no, or cancel. Just select cancel which will keep
you the program open. Both yer/no will save/discard the change and close
the program.
I hope this help.
Or you could just call CLOSE with the ALL flag.

close all

http://www.mathworks.com/help/matlab/ref/close.html
--
Steve Lord
***@mathworks.com
To contact Technical Support use the Contact Us link on
http://www.mathworks.com
tamirat zemenu
2021-01-03 13:15:50 UTC
Permalink
Post by Steven Lord
Post by Amin Mohammed
How to close abundance number of figures at once
%%%%%%%%%%%%%%%%%%%
1.What you could do is that, if you can reach the command window, or
you've an opening m-flie, or create new one and type anything in it, let
say you just type: % anywhere in the file regardless is already open or
you create it as a new file. 2. The next step is that you need to right
click on the matlab icon appearing down on your taskbar and select the
last option i.e. close all windows, once you do all the figure will get
closed, however, because you've typed % early in an m-flie, the matlab
program will not close immediately, fist it will ask you whether you want
to save you change; yes, no, or cancel. Just select cancel which will keep
you the program open. Both yer/no will save/discard the change and close
the program.
I hope this help.
Or you could just call CLOSE with the ALL flag.
close all
http://www.mathworks.com/help/matlab/ref/close.html
--
Steve Lord
To contact Technical Support use the Contact Us link on
http://www.mathworks.com
could you help me by sending source code with simulation result for performance analysis of sparse code multiple access(SCAM) over AWGN and Rayleigh fading channel?
Loading...