I have m file (main.m
), and I have some variables that I have in this file.
In the end of the file, I wrote: clear all
I want to clear all the variables. so in the Matlab, I wrote: main
, in order to run the function.
When the function completes, I wrote in MATLAB console the name of one of the variables of main.m
.
For example, I wrote the variable: data
Surprisingly, the variable exists.
Why the expression clear all
doesn't delete it?
Thank you.