(To be removed) Standard deviation of input or sequence of inputs
The dsp.StandardDeviation
object computes the standard
deviation for an input or sequence of inputs.
The dsp.StandardDeviation
System
object™ will be removed in a future release. To compute the standard deviation, use
the std
function. To compute the running standard
deviation in MATLAB®, use the dsp.MovingStandardDeviation
object. For more
information, see Compatibility Considerations.
To compute the standard deviation for an input or sequence of inputs:
Create the dsp.StandardDeviation
object and set its properties.
Call the object with arguments, as if it were a function.
To learn more about how System objects work, see What Are System Objects? (MATLAB).
returns a
standard deviation System
object, std
= dsp.StandardDeviationstd
, that computes the standard deviation for the
columns of input.
returns a standard deviation System
object, std
= dsp.StandardDeviation(Name,Value
)std
, with each specified property set to the specified
value.
To use an object function, specify the
System
object as the first input argument. For
example, to release system resources of a System
object named obj
, use
this syntax:
release(obj)
Note: If you are using R2016a or an
earlier release, replace each call to the object with the equivalent step
syntax. For example, obj(x)
becomes
step(obj,x)
.
Compute the running standard deviation of a signal using
dsp.StandardDeviation
object. To activate this mode, set the
RunningStandardDeviation
property to true
.
std2 = dsp.StandardDeviation; std2.RunningStandardDeviation = true; x = randn(100,1); y = std2(x);
y(i) is the standard deviation of the ith input sample with respect to all the past input samples.
This object implements the algorithm, inputs, and outputs described on the Standard
Deviation block reference page. The object properties correspond to the block
parameters, except the Reset port block parameter corresponds to the
ResetInputPort
and ResetCondition
object properties.