Moving Average in Forecasting

Moving Average in Forecasting

Moving Average in Forecasting

Description

  • The Moving Average is also known as Naïve Forecasting or moving/rolling mean.
  • It is an indicator that creates a series of averages of several subsets of a complete dataset

Why to use

The Moving Average is used with time-series for forecasting.

When to use

To analyze trends in linear or non-linear time-series data

When not to use

  • When the data is not time-series based
  • On textual and categorical data

Prerequisites

A time-series data should not contain null or missing values.

Input

Any dataset that contains time-series data

Output

  • Root mean Square Error (RMSE)
  • Baseline and Prediction Plot
  • Predicted Values of the selected Variable

Statistical Methods Used

  • Average
  • Root Mean Square Error

Limitations

Cannot identify the time series components


Consider a time-series data containing the following annual sales figures. We calculate the Moving Average over three years, for years 2015-2016-2017, 2016-2017-2018, and 2017-2018-2019. These values are given in the table below. 

Year

Sales (In Millions)

Moving Average (Three Year Average)

2015

5.0

NA

2016

5.4

NA

2017

5.7

(5.0 + 5.4 + 5.7) / 3 = 5.366

2018

6.1

(5.4 + 5.7 + 6.1) / 3 = 5.733

2019

6.4

(5.7 + 6.1 + 6.4) / 3= 6.066