Modelling Petrol Prices in Kenya from 2014 to 2023 Using Sarimax Model: A Case Study of Nairobi County
Authors: Nyamai Fidelis , Esekon Joseph , Atitwa Edwine 
Published: August 2024

The requirement for petrol price information is crucial for majority of enterprises. This is because fluctuations in petrol prices impact inflation hence affecting daily lives of citizens. In analyzing the prices of petrol, researchers have employed several models but encountered various limitations. These limitations include; the Error Correction Model can examine only one co-integrating association. The Vector Autoregression (VAR) model does not account for the structural changes in the data. Additionally, the AutoRegressive Integrated Moving Average (ARIMA) model does not take into consideration the seasonal component in the data. The Generalized Autoregressive Conditional Heteroskedasticity (GARCH) model assumes that over time the volatility is constant. Moreover, the Seasonal Autoregressive Integrated Moving Average (SARIMA) model does not integrate the external factors. Hence in this study Seasonal Autoregressive Integrated Moving Average with Exogenous Variables (SARIMAX) model was employed since it captures seasonality in data and incorporates the exogenous variables. The research’s aim was to model prices of petrol in Kenya for the period between 2014 to 2023 with exchange rates as an external factor. Secondary data was obtained from Energy and Petroleum Regulatory Authority (EPRA), Kenya National Bureau of Statistics (KNBS) and Central Bank of Kenya (CBK) websites. R software was used to analyze the data. By the use of historical data of petrol prices and exchange rates, the study sought to fit the best Seasonal Autoregressive Integrated Moving Average with Exogenous Variables (SARIMAX) model, validate the model and predict the petrol prices. The petrol price data was found to be non-stationary using Augmented Dickey Fuller test (ADF). Regular differencing was conducted to make the data stationary. Seasonal differencing due to seasonality component available in the data was also performed. Best SARIMAX model was chosen from various SARIMAX models according to Box-Jenkins methodology which uses least Akaike Information Criterion (AIC) value. SARIMAX (0,1,1)(2,1,2)&lt;sub&gt;12&lt;/sub&gt; model was selected since it had least Akaike Information Criterion (AIC) value of 656.3733 and the model validated using the hold out technique. The forecasts errors from the training set were; Mean Squared Error (MSE)=10.4970, Root Mean Square Error (RMSE)=3.239911, Mean Absolute Percentage Error (MAPE)=2.309268% while those from the testing set were; Mean Squared Error (MSE)=3271.1012, Root Mean Square Error (RMSE)=57.193542, Mean Absolute Percentage Error (MAPE)=26.695390%. There was less error in the training set than in the testing set as it was expected hence the model suited the data well and could be used for future predictions. The model was then used for five year forecast into the future. This study’s findings will offer sound suggestions to policymakers, businesses and consumers. This study recommends a model to be fitted using other factors affecting petrol prices and fitting Fourier terms, Behavioral Assessment Tools (BATS) and Trigonometric Box-Cox ARMA Trend Seasonal (TBATS) models.