clear except...

clear workspace except prescribed variables
3.1K Downloads
Updated 4 Jun 2008

View License

This function clear all variables in the workspace except the variables listed in the function argument.
Example: clearex('var1',var2') will clear all variables in the workspace except var1 and var2.
Note: wildcards (e.g. 'var*') can be used.

Cite As

Arnaud Laurent (2024). clear except... (https://www.mathworks.com/matlabcentral/fileexchange/19548-clear-except), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2007a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Workspace Variables and MAT-Files in Help Center and MATLAB Answers

Community Treasure Hunt

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

Start Hunting!
Version Published Release Notes
1.0.0.0

updated to enable wildcards