Main Content


Clear data from children of real-time instrument object

Since R2020b



clearScalarAndLineData(instrument_object) clears data from a real-time instrument object. For each scalar and axes control connected through connectLine or connectScalar, the clearScalarAndLineData function clears the UI control data. In a gauge for example, the Value field is reset and the needle points to 0. On axes for example, the line data is cleared and the axes are empty.


collapse all

Select real-time application file. Create instrument object. Clear data from instrument object.

mldatxfile = 'slrt_ex_pendulum_100Hz.mldatx';
hInst = slrealtime.Instrument(mldatxfile);
% . . . hInst streams data

Input Arguments

collapse all

To create the instrument object, use the Instrument function.

Example: hInst

Version History

Introduced in R2020b