Bayesian Structural Time Series for Forecasting Oil Prices

There are many methods of forecasting, and these methods take data only, analyze it, make a prediction by analyzing, neglect the prior information side and do not considering the fluctuations that occur overtime. The best way to forecast oil prices that takes the fluctuations that occur overtime and is updated by entering prior information is the Bayesian structural time series (BSTS) method. Oil prices fluctuations have an important role in economic so predictions of future oil prices that are crucial for many countries whose economies depend mainly on oil, such as Iraq. Oil prices directly affect the health of the economy. Thus, it is necessary to forecast future oil price with models adapted for emerging events. In this article, we study the Bayesian structural time series (BSTS) for forecasting oil prices. Results show that the price of oil will increase to 156.2$ by 2035.


Introduction
Oil prices are incredibly significant as an economic source of Iraq, because in fact there is no economy in Iraq. Iraq depends on the price of oil. This was what we noticed when the price of oil decreased due to coronavirus. Oil prices have two major junctures, the first juncture initiated from 1859 when the oil was discovered until 1970 and when the organization of OPEC was established and instituted itself as one of the important players in oil market. The second juncture has been initiated since 1970 till present where new producers and government companies have come in the market. There are many opinions that explain the impact of the change in oil prices on the global economy. Morana [1], Barsky [2], Kilian.L. [3], Segal.P. [4], Sundry studies found that high oil prices have a negative impact on oil importing countries and a positive effect on countries whose economies depend on oil revenues [5,6]. Moreover, such positive effect impact of higher oil price on oil exporting Iraq is found out to be the most useful [7,8]. To make suitable decisions about the direction of economic policy, it is important to accurately forecast future oil prices [9]. Global oil prices in 2008 witnessed rise to $ 134/Bbl., which has been on an upward trend since 2003. In 2014 the price of Crude Oil fell below $ 50 /Bbl. The proven Iraqi oil reserves are about 112 billion barrels, while 80% of Iraqi oil is uncertain, with a total unconfirmed reserve ratio of about 360 billion barrels. In 1996, during the blockade, Iraq relied heavily on the oil-for-food program and contributed to a partial lifting of the suffering of the Iraqi citizen. After 2003 and the absence of industry and agriculture significantly, the Iraqi economy became dependent on 90% of oil exports. Bayesian structural time series model can reliably predict oil price, which creates difficulties when using classical statistical methods to forecast oil prices. However, predicting the oil prices is more complex and difficult to model because oil prices fluctuations are non-linear, unstable, and very volatile. Bayesian structural time series (BSTS) has shown great power in forecasting nonlinear and complex time series. Many papers have presented successful application of bsts for forecasting the oil price series for example YuzeLi et al. [10], Choi.D. [11], Bekiros et al [12], Jinwen Qiu et al [13].

Model Used to Predict of Oil Prices
There are different time series forecasting methods; they are: Auto-regressive, Moving Average, Autoregressive Moving Average, Integrated Moving Average, Seasonal Autoregressive Integrated Moving-Average (SARIMA), Bayesian structural time series (BSTS) [14]. There is no best way of doing time series modeling. It all depends on the problem. But it is almost always true that bringing in some prior information is helpful. For example, oil prices are down now due to the coronavirus outbreak. In other words, if your model is not taking that into account, it will be useless. Thus, the Bayesian structural time series of predicting oil prices is the basis of the optimal decision making to control the country's economic situation.

Bayesian structural time series (BSTS):
Bayesian structural time series model is a technique used for time series nowcasting, forecasting, inferring causal impact a sequence of data. Samples are taken in time order with equal time intervals. Time series are analyzed to understand the past and to forecast the future. The goal of time series is forecasting, improved computing power, have made time series methods widely applicable. Time series forecasting has many real applications in various areas such as forecasting of economy, business weather, decease, and others. Suppose where βt is vector of variables, Xt is a vector of parameters and εt ~(0, 2 ).
In addition, βt is represented as the following transition equation Where ~(0, 2 ) and , are transition matrix. The above equations describe the observed data, and through them we can build time series models to forecast in the short and long term [15,16].

Bayesian Structural Time Series Model for Forecasting Oil Prices:
Oil price changes overtime because of crises, political conflicts, supply and demand to oil. For this reason, investors and policymakers need to know the direction of future oil prices. This leads to the need for the use of BSTS. BSTS features input of backend and Bayesian component regression for updating the timeline model. Hence, in this paper, we are forecasting oil prices data over time by BSTS. We use the Bayesian approach in the first place. There are many advantages in doing this such as to help us update our data continuously by entering prior information and estimating models with large numbers of parameters [17]. The Bayesian approach is based on Bayes' theorem, and we express it in the following equation: Here ( | ) is the posterior distribution for the parameter for, ( ) is the prior distribution for the parameter , likelihood function and ( ) is marginal probability of the y, this marginal probability is computed as: Forecast equation is defined as

Data:
The data of oil prices is taken from EIA, from 2006 to 2020 years where it has a variety of information available. This contains prices, production levels and many other relevant statistics. The results obtained from BSTS are compared with that of EIA. For the use of the Bayesian structural time series model, this study will focus on the yearly crude oil future pricing shown in Table .1 and represented in Figure .1 The data represent oil price from EIA. It is the US Energy Information Administration which is a major agency of the United States Federal Statistical System responsible for collecting, analyzing, and disseminating information on energy to promote sound policies, market efficiency, and public understanding of energy and its interaction with the economy and the environment.

Modeling
Bayesian structural has an advantage to apply for short and long-term forecasting. However, most of models involve complicated mathematics and it is almost impossible for the statistician who does not have strong mathematical background to conduct forecasting. Meanwhile, BSTS allows us to conduct this study with some lines of R code. To run simulations with MCMC in the Bayesian time series in R, there is a package called a (BSTS) package. Automatically performs sample generating operations etc. The BSTS is a function specific to the Bayesian time series which includes the MCMC simulation method for generating samples and calculating parameters in the Bayesian regression model [18].

Forecasting Oil Price
In this section, we present the expected results obtained by applying the BSTS model to oil prices. Predicting the price of oil is very difficult due to the variables that change or occur overtime, for example the outbreak of the Corona virus and political conflicts, and thus the price of oil changes within a short period of time. Meaning demand and supply are not static.
This means that there is no exact model for this. All models are probabilistic models. We carry out the bsts modeling for forecasting 15 years. To predict future values for the years 2021 to 2035 we use forecast package of the forecast code based on the coding of Rprogramming such that the value (64.02)we are getting from forecast package. Table 2 shows the prediction results by BSTS. The oil price was evaluated to increase to 119.88in 2035. In 2035year, EIA has estimated that the oil price will reach 120.47. The price we value in this paper is lower than the EIA because we use moderate assumptions regarding the future oil market.

Conclusion
In this study we have provided a method to build a model forecast long-term oil prices. In this study, we applied BSTS using R program. Bayesian structural time series suitable method. Since the oil price change constantly it is useful to incorporate some prior information in the model for example, the coronavirus outbreak. This study predicts oil prices through 2035, oil price is expected to rise to $ 119.88in 2035, and the EIA predicts that oil price in 2035 will reach 120.47$.