Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Matlab - Close figure windows

Tags:

matlab

figures

i'm writting some code in Matlab editor, which has about 30 figures. So, when I publish it, it opens 30 figures windows, which is annoying. How do I keep it from opening the windows, but keeping the figures in the published window?

I've tried with close(figure), but then the figures don't show on the published window.

Thanks in advance

like image 391
Marco Castanho Avatar asked Feb 23 '13 15:02

Marco Castanho


People also ask

How do I close a figure window in MATLAB?

Calling close is equivalent to calling close(gcf) . close( fig ) closes the figure specified by fig . close all closes all figures whose handles are visible. A figure handle is hidden if the HandleVisibility property is set to 'callback' or 'off' .

How do you close all in MATLAB?

clr performs: clear all; close all; clc; This clears your workspace, closes all figures, and clears command window.

How do you close all tabs in MATLAB?

This can be done by clicking the cross button on the top right of the Editor window.

How can we close all graphs in MATLAB *?

6. How can we close all graphs in MATLAB? Explanation: The in-built command to close the windows containing graphs is 'close all'. This command should be placed at the beginning of a function which creates graphs so that future commands do not affect the graph generated every time the function is called.


1 Answers

The simplest thing to do is close all when you are done with the figures. I'm not sure if that can be part of the script or if you have to run it manually after publishing.

like image 190
shoelzer Avatar answered Oct 22 '22 21:10

shoelzer