Extract component object from
extracts a component object,
C = component(
C, from the
path argument is the path of the component object in the
rbobject and can have more than one elements. In other words, the
component method can extract an object from any hierarchical level of the
The extracted object is a copy of the original component object. Therefore, any subsequent changes for the extracted copy do not affect the original object.
rb — Rigid body
Rigid body, specified as a
simscape.multibody.RigidBody object. The
represents the rigid body from which you add the component object.
path — Path of component object
string scalar | character vector
Path of the component object, specified as a string scalar or character vector. The length of the path depends on the hierarchical level of the component object. If the object is at the top level, the path has one element. If the component object is in a subbody, the path has two elements, and the path elements are separated by forward slashes. The first element is the name of the subbody, and the last element is the name of desired component object.
C — Copy of component object
To learn about attributes of methods, see Method Attributes.
Introduced in R2022a