Main Content

Moving root mean square

The `dsp.MovingRMS`

System object™ computes the moving root mean square (RMS) of the input signal along each
channel, independently over time. The object uses either the sliding window method or the
exponential weighting method to compute the moving RMS. In the sliding window method, a window
of specified length is moved over the data, sample by sample, and the RMS is computed over the
data in the window. In the exponential weighting method, the object squares the data samples,
multiplies them with a set of weighting factors, and sums the weighed data. The object then
computes the RMS by taking the square root of the sum. For more details on these methods, see
Algorithms.

To compute the moving RMS of the input:

Create the

`dsp.MovingRMS`

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?.

returns a moving RMS
object, `movRMS`

= dsp.MovingRMS`movRMS`

, using the default properties.

sets the `movRMS`

= dsp.MovingRMS(`Len`

)`WindowLength`

property to `Len`

.

specifies additional properties using `movRMS`

= dsp.MovingRMS(`Name,Value`

)`Name,Value`

pairs. Unspecified
properties have default values.

```
movRMS = dsp.MovingRMS('Method','Exponential
weighting','ForgettingFactor',0.9);
```

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)

[1] Bodenham, Dean. “Adaptive Filtering and Change Detection for Streaming Data.” PH.D. Thesis. Imperial College, London, 2012.

`dsp.MedianFilter`

|`dsp.MovingAverage`

|`dsp.MovingMaximum`

|`dsp.MovingMinimum`

|`dsp.MovingStandardDeviation`

|`dsp.MovingVariance`