in data.m file I’ve defined simulink.parameters variables
when I load model , data are loaded in workspace and I would like to get the list of variables defined in data.m file
I tried :
a = whos('-file', 'data');
but this is used only for MAT files , is there an equivalent for m files ?
Thanks
Create a function
This should do the job. In this way you read the file in a function workspace, after that you list all of the loaded variables and exclude the parameter you pass to the function itself. Returned are only the function names that are contained in the data.m file.
Call it by