File Exchange Pick of the Week

Close All But…

Posted by Brett Shoelson,

Like this blog post, today's Pick is short and sweet. File cab.m, by new first-time contributor Karl, allows you to keep only the figures you specify, and to close the rest .

Back in 2004, our predecessor Doug Hull selected file keep as a Pick of the Week. In that write-up, Doug wrote: "I find KEEP to be one of those functions I use so much that I forget it isn't part of MATLAB." I couldn't agree more, and today's Pick is a great companion; it's the "figure version of keep."

So now I can use my own togglefig function to create my figures, and CAB to destroy them.

Comments? Share them here.


Get the MATLAB code

Published with MATLAB® 7.8

Comments are closed.

These postings are the author's and don't necessarily represent the opinions of MathWorks.