setdiff
Return difference between two arrays of
Simulink.VariableUsage objects
Description
returns an array that identifies the variables described in
VarsOut = setdiff(VarsIn1,VarsIn2)VarsIn1 but not in VarsIn2, which are
arrays of Simulink.VariableUsage objects. If a
variable is described by a Simulink.VariableUsage object in
VarsIn1 but not in VarsIn2, the function
returns a copy of the object.
setdiff compares the Name,
Source, SourceType, and
Users properties of the
Simulink.VariableUsage objects in VarsIn1
with the same properties of the objects in VarsIn2. If
VarsIn1 and VarsIn2 each contain a
Simulink.VariableUsage object with the same values for these
three properties, the objects describe the same variable, and
setdiff does not return an object to describe it.
To create Simulink.VariableUsage objects that
describe the usage of variables in a model, use the Simulink.findVars function.
Examples
Input Arguments
Output Arguments
Version History
Introduced in R2012b