How to change the name of the run in Simulation Data Inspector programmatically?
4 ビュー (過去 30 日間)
古いコメントを表示
MathWorks Support Team
2017 年 3 月 28 日
編集済み: MathWorks Support Team
2022 年 2 月 5 日
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?
採用された回答
MathWorks Support Team
2022 年 2 月 5 日
編集済み: MathWorks Support Team
2022 年 2 月 5 日
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 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Create Large-Scale Model Components についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!