convertUnits
R2026b Convert units of Simulink.sdi.Signal object
Syntax
Description
convertUnits(
converts the stored units of the sig,units)Simulink.sdi.Signal object
sig to the units specified by units. When
you convert the stored units, the software also updates the display units. For a
list of supported units, see Allowed
Units. The convertUnits function converts the units
of Simulink.sdi.Signal objects that contain data of all built-in
and fixed-point types.
Changing the stored units of a Signal object does not affect the
model that created the signal. Subsequent simulations of the model log data using
the original units.
Note
Unit conversion does not support undo and may lead to precision loss.
Examples
Input Arguments
Version History
Introduced in R2018a