| Contents | Index |
runID = Simulink.sdi.getRunIDByIndex(runIndex)
runID = Simulink.sdi.getRunIDByIndex(runIndex) returns the run ID for the run corresponding to the run index.
runIndex |
Number representing an index to the list of runs currently in the Simulation Data Inspector. |
runID |
Run ID, a unique number identifying a run in the Simulation Data Inspector. |
Get the run IDs for all runs currently in the Simulation Data Inspector.
% Configure model "sldemo_f14" for logging and simulate
simOut = sim('sldemo_f14','SaveOutput','on', ...
'SaveFormat','StructureWithTime', ...
'ReturnWorkspaceOutputs','on');
% Create a Simulation Data Inspector run
[runID, runIndex, signalIDs] = Simulink.sdi.createRun('Run1','base',{'simOut'});
% Get the ID of the previously created run by index
runID2 = Simulink.sdi.getRunIDByIndex(runIndex);
% Both runID and runID2 reference the same run and should be equal
isequal(runID, runID2)Simulink.sdi.createRun | Simulink.sdi.getRunCount | Simulink.sdi.isValidRunID

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |