Training the model
We are going to use sales data of quarters for the years 2012 to 2015 to design and train the forecast time-series model. With this design, we will test the predictions with a group of known sales for 2016 to 2017. Finally, we will make a forecast for 2018 to 2019.
The model has to take both of these components (known sales and forecast) to make a good prediction. The steps to develop a forecast, as we will see in this chapter, are as follows:
- Look at the data chart to decide whether it has autocorrelation or not.
- Test the autocorrelation with the Durbin-Watson test.
- Calculate the moving average (explained in Chapter 12, Working with Time Series Using the Centered Moving Average and a Trending Component) to smooth the peaks of the data.
- Design the model, calculating the seasonal trends.
- Test the forecast by multiplying the seasonal trend by the regression line.
- Use the model to make forecasts.
In this chapter, we will design...