How to change the name of the run in Simulation Data Inspector programmatically?
4 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
MathWorks Support Team
el 28 de Mzo. de 2017
Editada: MathWorks Support Team
el 5 de Feb. de 2022
I perform multiple simulations and inspect the data with the Simulation Data Inspector (SDI). In the Simulation Data Inspector all runs are identified by model name with run number. How can I programmatically specify a user defined string in the run name?
Respuesta aceptada
MathWorks Support Team
el 5 de Feb. de 2022
Editada: MathWorks Support Team
el 5 de Feb. de 2022
It is possible to specify a user defined string in the run name programmatically. This can be achieved by specifying the string - 'runName' in the following function:
Simulink.sdi.createRun(runName)
For example, if you simulate a model named 'MyModel', with the parameter V = [1.4, 3.5] then you can specify the string 'runName' as:
runName = ['MyModel_V=' num2str(V(1))]\nrunName = ['MyModel_V=' num2str(V(2))]
Now, after simulating the model, the first run will be named as 'MyModel_V=1.4' and the second run will be named as 'MyModel_V=3.5'. For easier understanding using an example, please find attached the script -'sampleScript.m'.
0 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Create Large-Scale Model Components en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!