Create subtree from robot model
robot— Robot model
Robot model, specified as a
newSubtree— Robot subtree
Robot subtree, returned as a
rigidBodyTree object. This new subtree uses
the parent name of the body specified by
bodyname as the base name.
All bodies that are attached in the previous robot model (including the body with
bodyname specified) are added to the subtree.
Usage notes and limitations:
When creating the
rigidBodyTree object, use the syntax that specifies the
MaxNumBodies as an upper bound for adding bodies to the robot model.
You must also specify the
DataFormat property as a name-value pair. For
robot = rigidBodyTree("MaxNumBodies",15,"DataFormat","row")
To minimize data usage, limit the upper bound to a number close to the expected number of bodies in the model. All data formats are supported for code generation. To use the dynamics functions, the data format must be set to