Documentation

Simulink.sdi.copyRunViewSettings

Copy signal line style and color specifications from one run to another run

Syntax

alignedSignals = Simulink.sdi.copyRunViewSettings(sourceRun,destinationRun,moveCheckboxes)

Description

example

alignedSignals = Simulink.sdi.copyRunViewSettings(sourceRun,destinationRun,moveCheckboxes) copies the signal line style and color from one run to another run. The function returns an array of signal identifiers that align between runs where the settings were copied.

Examples

collapse all

% Configure model 'slexAircraftExample' for logging and simulate
simOut = sim('slexAircraftExample','SaveOutput','on',...
             'SaveFormat','StructureWithTime',...
             'ReturnWorkspaceOutputs','on');

% Create the first Simulation Data Inspector run
runID_1 = Simulink.sdi.createRun('First Run','base',{'simOut'});

% Simulate the model again
simOut = sim('slexAircraftExample','SaveOutput','on',...
             'SaveFormat','StructureWithTime',...
             'ReturnWorkspaceOutputs','on');

% Create second run in the Simulation Data Inspector
runID_2 = Simulink.sdi.createRun('Second Run','base',{'simOut'});

% Copy the signal settings from first run to the second run
alignedSignals = Simulink.sdi.copyRunViewSettings(runID_1,runID_2,true);

Input Arguments

collapse all

A run ID, specified as an integer, or a Simulink.sdi.Run object, specified as an object, for the source run.

A run ID, specified as an integer, or a Simulink.sdi.Run object, specified as an object, for the destination run.

Indicate to move the check boxes in the Runs pane, which plot signals, from the source run to the destination run, specified as true or false.

Output Arguments

collapse all

Signals that match between runs where the settings were copied, returned as an array of signal identifiers. See Signal Alignment in the Simulation Data Inspector for more information on signal alignment.

Introduced in R2016a

Was this topic helpful?