A Time Series Analysis and Forecasting, using ARIMA and Prophet models, on a superstore dataset.
Time Series Analysis comprises of motheds for analyzing time series data in order to extract meaningful statistics and other characteristics of the data. Time series forecasting is the use of a model to predict future values based on previously observed values.
Time Series are widely used for non-stationary data like economy, weather, stock price and retail sales.
This project uses Superstore (superstore.xls) Sales data.
This project aims to,
- Analyze time series data.
- Forecast (predict) future values for the same.
In order to achieve the above goals two important and efficient moudules are used,
- ARIMA
- Prophet
The most commonly used method for time series forecasting is known as ARIMA. ARIMA stands for Auto-Regressive Integrated Moving Average.
ARIMA models are denoted with the notation ARIMA(p, d, q). These three parameters account for seasonality, trend, and noise in data.
Released by Facebook in 2017, forecasting tool Prophet is designed for analyzing time-series data based on additive model that display linear and/or non-linear patterns on different time scales such as yearly, weekly and daily. It also has advanced capabilities for modeling the effects of holidays on a time-series and implementing custom changepoints.
It is fast and provides completely automated forecasts that can be tuned by hand by data scientists and analysts. It works best with time series that have strong seasonal effects and several seasons of historical data. Prophet is robust to missing data and shifts in the trend, and typically handles outliers well.
The first model (ARIMA) clearly captured furniture sales seasonality. As the forecast goes further out into the future, it is natural to become less confident with the values. This is reflected by the confidence intervals generated by the first model (ARIMA), which grow larger as the model move further out into the future.
The second model (Prophet) gave following insights,
- The sales for both furniture and office supplies have been linearly increasing over time and will be keep growing, although office supplies’ growth seems slightly stronger.
- The worst month for furniture is April, the worst month for office supplies is February. The best month for furniture is December and the best month for office supplies is October.