Technical requirements
In this chapter, we will be utilizing the statsmodels
library, specifically its time-series analysis packages (tsa
and statespace
). statsmodels
is a comprehensive Python module that offers a wide range of classes and functions for estimating various statistical models, performing statistical tests, and conducting statistical data exploration. For time-series analysis, it provides essential models such as univariate autoregressive (AR) models, vector AR (VAR) models, and univariate AR moving average (ARMA) models. Furthermore, it offers descriptive statistics for time series, such as the autocorrelation and partial autocorrelation functions (ACF and PACF).
If you have not worked with statsmodels
before, it can be installed using the following command:
pip install statsmodels
The documentation for statsmodels
can be found at https://www.statsmodels.org/stable/index.html.
We will also be utilizing pmdarima
, which allows us to interact with automatic modeling...