clear all variables except some matlab code example Example: matlab clear all clear % Clears all variable data clc % Clears the command line window