MovAvg

Syntax

MovAvg(Input: ITimeSeries,
       Period: IMsPeriod,
       WindowSize: Integer,
       Casewise: MsCasewise,
       Method: MsMovingAverageType)

Parameters

Input. Output variable.

Period. Period, at which the method is calculated. If the parameter value is Null, the method is calculated at the entire time period.

WindowSize. Window size. Optional parameter. The parameter is set to 5 by default.

Casewise. Missing data treatment method. Optional parameter. The parameter is set to MsCasewise.No by default, that is, missing data treatment is not used.

Method. Moving average calculation method. Optional parameter. The parameter is set to MsMovingAverageType.Centered by default, that is, centered moving average method.

Description

It converts variable using moving average.

Comments

The moving average method is based on representing a series as a sum of a relatively smooth trend and a random component.

Example

Formula Result Application
= MovAvg({Brazil|BCA}, SetPeriod("01.01.2000", "01.01.2015"), 3, MsCasewise.Yes, MsMovingAverageType.Forward)

For the Brazil|BCA factor the method of moving average is applied with the window of three at the period of 2000-2015. Calculation is executed using the Casewise missing data treatment method.

The method can be used in universal expression editor formulas in any platform tool where it is available.
= MovAvg(X1, SetPeriod("01.01.1990", "01.01.2016")) For the X1 factor the centered moving average method is applied at the period of 1990-2016. It can be used in model formulas of modeling container.

See also:

Functions Available in Expression Editor │ SmoothingIModelling.MovAvg |  Calculation Method of moving average