Main Content

clearScalarAndLineData

Clear data from children of real-time instrument object

Description

example

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.

Examples

collapse all

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

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

Input Arguments

collapse all

To create the instrument object, use the Instrument function.

Example: hInst

Introduced in R2020b