Next Article in Journal
What Matters for Comovements among Gold, Bitcoin, CO2, Commodities, VIX and International Stock Markets during the Health, Political and Bank Crises?
Previous Article in Journal
Robust Estimation of the Tail Index of a Single Parameter Pareto Distribution from Grouped Data
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Navigating Inflation Challenges: AI-Based Portfolio Management Insights

1
HUN-REN, Centre for Economic and Regional Studies, Institute of Economics, 1097 Budapest, Hungary
2
Department of Statistics, Finances and Controlling, Széchenyi István University, 9026 Győr, Hungary
3
Doctoral School of Economics and Regional Sciences, Hungarian University of Agriculture and Life Sciences, 7400 Kaposvár, Hungary
*
Author to whom correspondence should be addressed.
Risks 2024, 12(3), 46; https://doi.org/10.3390/risks12030046
Submission received: 23 January 2024 / Revised: 21 February 2024 / Accepted: 28 February 2024 / Published: 1 March 2024

Abstract

:
After 2010, the consumer price index fell to a low level in the EU. In the euro area, it remained low between 2010 and 2020. The European Central Bank has even had to take action against the emergence of deflation. The situation changed significantly in 2021. Inflation jumped to levels not seen for 40 years in the EU. Our study aims to use artificial intelligence to forecast inflation. We also use artificial intelligence to forecast stock index changes. Based on the forecasts, we propose portfolio reallocation decisions to protect against inflation. The forecasting literature does not address the importance of structural breaks in the time series, which, among other things, can affect both the pattern recognition and prediction capabilities of various machine learning models. The novelty of our study is that we used the Zivot–Andrews unit root test to determine the breakpoints and partitioned the time series into training and testing datasets along these points. We then examined which database partition gives the most accurate prediction. This information can be used to re-balance the portfolio. Two different AI-based prediction algorithms were used (GRU and LSTM), and a hybrid model (LSTM–GRU) was also included to investigate the predictability of inflation. Our results suggest that the average error of the inflation forecast is a quarter of that of the stock market index forecast. Inflation developments have a fundamental impact on equity and government bond returns. If we obtain a reliable estimate of the inflation forecast, we have time to rebalance the portfolio until the inflation shock is incorporated into government bond returns. Our results not only support investment decisions at the national economy level but are also useful in the process of rebalancing international portfolios.

1. Introduction

After 2010, the consumer price index fell to a low level in the EU. In the euro area, it remained low between 2010 and 2020. It only slightly exceeded 3% (3.29%) in 2011 (Macrotrends 2024). The European Central Bank has even had to take action against the emergence of deflation. The situation changed significantly in 2021, as the COVID-19 epidemic passed and the economies of individual countries opened up in turn. Households wanted to spend the savings they had accumulated during the epidemic. The need to meet this demand quickly appeared on the market. Governments’ stimulus measures also generated demand. Moreover, supply chains had not yet been restored, so rapidly growing demand caused price increases in producer markets and in consumer goods markets. The outbreak of the Russia–Ukraine war in early 2022 led to a surge in energy and commodity prices. This rise in energy prices and commodity prices fed through to consumer prices. Consumer prices rose at a rate not seen in forty years (Bouri et al. 2023).
Inflation can devalue the savings of savers if they are not invested properly. Looking at the data, although the European Union is a single economic area, inflation rates (Harmonized Index of Consumer Prices (HICP)) vary between Member States. There are also differences in the euro area countries sharing a single currency. In our study, we examine how portfolio re-allocation can be an effective hedge against inflation. We assume an investor who holds a portfolio of stocks and government bonds and actively manages the portfolio. In portfolio management, they invest in equity indices of each EU Member State. An artificial intelligence-based process is used to optimize the investment. This is used to forecast inflation trends in each country to identify investment opportunities with the highest expected real returns, broadening the active portfolio management toolbox.

1.1. Inflation Forecast

Several researchers have previously worked on predicting inflation using artificial intelligence. The new methods are intended to achieve better results than the statistical forecasting models used previously. Theoharidis et al. (2023) proposed a deep learning model. In their hybrid model, they wanted to combine Variational Autoencoders and Convolutional LSTM Network (VAE-ConvLSTM) models for prediction. In their study, they used monthly US data for inflation from January 1978 to December 2019. The output results of their model were compared with several commonly used models such as Ridge regression, LASSO regression, Random Forests, Bayesian methods, and multilayer perceptron. In presenting their results, they found that deep learning models provide more accurate predictions than traditional statistical methods. Aras and Lisboa (2022) investigated the applicability of machine learning methods for forecasting inflation in Turkey. Turkish inflation was high during the period they analysed and showed a high volatility. The authors’ intention was, therefore, to find a more efficient method than the factor models that have generally been used in the past. As a result of their investigations, they advocated the use of machine learning methods for forecasting. Choudhary and Haider (2011) emphasized the predictive ability of machine learning methods using Brazilian inflation data. In their study, they tested traditional statistical methods and modern machine learning methods using extensive datasets. Summarising their results, they found that the forecasting accuracy of machine learning methods generally outperforms the forecasting ability of traditional econometric methods. This is mainly due to the treatment of nonlinear relationships. Masini et al. (2023) provided an overview of methods used to analyse and forecast financial time series. In their study they evaluated both linear and nonlinear methods. They compared the performance of traditional regression methods, machine learning methods, and also evaluated hybrid methods. They found that nonlinear machine learning methods can be very useful for analysing large datasets.
The literature suggests that the use of artificial intelligence is preferable to traditional statistical methods in economic forecasting and can be used to handle large numbers of input variables and to model nonlinear relationships.

1.2. Protection against Inflation through Portfolio Re-Allocation

The literature provides a rich source of studies on the future evolution of various financial instruments and macroeconomic data. Most of the research focuses on the forecasting of financial markets (Liu et al. 2021; Ayala et al. 2021; Bhandari et al. 2022; Hanauer and Kalsbach 2023; Vancsura and Bareith 2023; Md et al. 2023; Vancsura et al. 2023). Among the publications dealing with macro data, the topic of inflation is quite popular (Ülke et al. 2018; Medeiros et al. 2021; Joseph et al. 2021; Aras and Lisboa 2022; Araujo and Gaglianone 2023). It is a restricted group of studies where researchers analyse inflation data and stock markets combined. Constantinos et al. (2012) examined the hypothesized relationship between inflation and stock returns for Greece. They argue that previous empirical research did not take into account asymmetric dynamic effects. Their research suggests that monetary policy reacts to inflation and that monetary policy actions affect stock prices; however, monetary intervention has different effects on inflation and stock prices. Economic agents use shares as a hedge against inflation. Their purchases raise the price of shares. When inflation falls, portfolio adjustments lead to sales. This causes stock prices to fall. Their empirical results show that there is a positive relationship between inflation and stock prices. Nevertheless, monetary intervention has less effect on the change in stock prices than on the change of the inflation rate. Nwude (2013) analysed how the share prices of the chemical and paint industries listed on the Nigerian Stock Exchange have evolved between 2000 and 2011. The objective of the study was to determine whether the shares provided a hedge against inflation during the given period. The author conducted a regression analysis between real stock prices and inflation. This was used to filter out stocks that provided a real hedge against inflation and a positive real return. As a result of the analysis, the author concluded that equities did not provide a significant hedge against inflation. Chaves and Silva (2019) examined the relationship between stock returns and expected inflation in the Brazilian stock market. The study covered the period 2003–2016. They found a negative correlation between stock returns and inflation. This suggests that it makes sense to actively manage investments. They recommend that if expected inflation rises, it is worth selling equities and investing in fixed-income, short-term assets. When the magnitude of inflation expectations falls, the portfolio should be held back in equities. Marjohan et al. (2023) investigated the factors affecting stock returns in the Indonesian banking sector. Their quantitative analysis showed that investment risk did not significantly affect the returns of the stocks studied. In contrast, market liquidity had a significant impact on the assessed stock returns. They also found that the magnitude of inflation influences the relationship between the above factors and stock returns. Higher inflation may strengthen the relationship between investment risk and stock returns. The same amplifying effect was found between liquidity and returns when inflation increases. The aim of the study by Eldomiaty et al. (2020) was to assess the relationship between inflation rates, interest rates, and stock prices of non-financial companies included in the DJIA30 and NASDAQ100 indices. The period under study was from 1999 to 2016. For the analysis, the authors used standard statistical tools, such as Johansen’s co-integration test, linearity and normality tests, and co-integration regression calculation. According to their results, both the change in inflation rate and the change in real interest rates have a significant effect on the evolution of stock prices. A negative relationship between the change in inflation rate and the evolution of stock prices was found according to the authors’ results. The starting point of the study by Neville et al. (2021) was that there has been no significant inflation in developed countries over the past three decades. In their study, they examined the exchange rate developments of different asset classes in the UK, the US, and Japan over a period of about 100 years. Their analyses showed that active strategies could also provide a hedge against rising inflation in equity investments. Stock prices fell in the face of soaring inflation, but profitable strategies could be developed with active portfolio management. Active portfolio management proved more effective than passive investment strategies. Karimi et al. (2015) evaluated the relationship between stock returns and inflation rates using a study of 546 companies on the Tehran Stock Exchange. They studied the period between 2007 and 2013. At a 95% confidence level, they showed that there was a significant positive relationship between stock returns and the inflation rate of the companies included in the study. They pointed out in their conclusions that quantifying the relationship using a price index rather than the consumer price index yields different results. Bouri et al. (2023) evaluated the relationship between expected inflation and stock returns in the US stock market using time series from January 2003 to December 2022. Their method of analysis was multiple correlation calculation. The time series data covered the period of the 2008 global financial crisis, the COVID-19 pandemic and the beginning of the Russian–Ukrainian war. Their results were heterogeneous, which may be due to the intervention of monetary policy in the deflationary period following the global financial crisis. In the period of rising inflation following the COVID-19 pandemic, the correlations took increasingly positive values. Yeoh (2023) investigated the relationship between the diversified portfolio represented by the Malaysian Stock Exchange index and the inflation rate over a 20 year time series, using data from 2002 to 2021. The research method used was correlation and regression calculation. The calculations showed a weak positive correlation between the factors. However, it showed that the average annual increase in the value of the portfolio represented by the stock market index exceeded the increase in the consumer price index. They concluded that investing in a stock portfolio could provide a hedge against inflation. Giofré (2012) analysed whether, after the establishment of the monetary union, portfolio convergence in the member countries of the monetary union was faster relative to each other than relative to non-euro area member countries. The study covered the period 1997–2004. The faster convergence could have been based on convergence of inflation rates as a result of the common monetary policy and exposure to the common currency. In addition, investment barriers have also disappeared. The result of the study was that the convergence of investment portfolios in the Member States belonging to the monetary union was faster. This was despite the fact that the convergence of inflation rate fluctuations was not significant. The convergence in portfolio composition cannot, therefore, be seen as a similarity in hedging strategies against inflation. Ni et al. (2023) tested a neural network method for portfolio optimization. The optimal dynamic allocation was studied for a high inflation period. The objective was to outperform a benchmark portfolio. The optimal asset allocation was achieved using a novel neural network model. The performance of their model was measured using historical data from a high inflation environment. Their results showed that their neural network method has a 90% probability of outperforming the benchmark portfolio constructed using the alternative method used in the test.
Our study aims to use artificial intelligence to forecast inflation. We also use artificial intelligence to forecast stock index changes. Based on the forecasts, we propose portfolio re-allocation decisions to protect against inflation.
The forecasting literature does not address the importance of structural breaks in the time series, which, among other things, can affect both the pattern recognition and prediction capabilities of various machine learning models. The novelty of our study is that we used the Zivot–Andrews unit root test to determine the breakpoints and partitioned the time series into training and testing datasets along these points. We then examined which database partition gives the most accurate prediction.

2. Results

Forecasts have always played an important role in investment decisions. In most cases, a forecast can be an estimate based on intuition or some kind of technical or fundamental analysis. With the development of information technology and AI, the availability of technical forecasts has improved a lot. There are many free solutions available on the internet, but of course they require programming and/or mathematical skills. The automation of technical forecasts is relatively simple, no human decision is required and results are obtained in a flash according to predefined criteria.
Speed is only one aspect, however, and equally, or more importantly, is the accuracy and reliability of these algorithms. In the absence of accuracy, portfolio rebalancing carries a significant risk, as the main motivation for their use is to maximise the returns while reducing the risk. Based on the literature, there is no single recipe, and not one predictive algorithm can be said to be better or worse than another. Different economic time series have different characteristics and, therefore, it is unlikely that a single algorithm can be applied in all cases. In our study, we investigate which forecasting model performs better in different European countries, whether similarities can be observed, or whether stock market and inflation data behave completely differently. A further research question is whether these forecasts are sufficiently accurate to make portfolio restructuring decisions (risk-free share).
The results are presented separately for each of the forecasting algorithms, including inflation and the stock market index forecasts for the country in question. In total, nine countries were included in the study: Austria, Belgium, Czech Republic, Germany, Hungary, the Netherlands, Poland, Slovakia, and Sweden. For the train–test database splitting, we first divided the database into two parts along the structural breaks defined by the Zivot–Andrews unit root test, followed by the 80% - 20% split ratio most commonly used in the literature and finally the 90% - 10% split.
A total of two predictive models (GRU, LSTM) and a hybrid model (LSTM–GRU) were used in the study. The advantages and disadvantages of each predictive model are discussed in the methodology chapter. Also in the methodology chapter are the indicators used to evaluate the predictions (RMSE, MAPE, and MAE).

2.1. GRUs

The results of the GRU (Gated Recurrent Unit) forecasts are shown in Table 1, with the forecast errors for inflation in the top half of the table and the forecast accuracy of the stock market index for the country in the second half. The table follows the same pattern for the next two forecasting techniques. For all values in the table, the lower one is the better value. Due to its scale independence, the MAPE can also be used for comparisons between countries.
In the case of inflation, a ratio of 85% - 15% for most of the different indicators gives the best results. Based on the GRU-based forecast, the forecast of inflation shows a significantly higher accuracy. When the best model is selected for each country, the average MAPE for inflation is 1.17%, compared to a forecast error of 5.53% for the stock market index. One reason for this is that expert forecasts of macroeconomic indicators are also typically more accurate than exchange rate forecasts.
Examining the average MAPE values of the three database distributions using country-specific criteria, we see that the GRU model is the most accurate for Swedish inflation and the least accurate for Slovak inflation (Figure 1). At the same time, the stock market indices were analysed, with the Slovak index (SAX) performing the best and the Austrian index (ATX) performing the worst (Figure 2).

2.2. LSTM

For LSTM, the 90% - 10% database split for inflation does not give the best result for any country, with 80% - 20% and 85% - 15% giving the best result with almost equal frequency. For the stock market index, the picture is clearer, with the 80% - 20% ratio dominating, while for the MAPE it is the only one that gives the best result. In terms of estimation accuracy, the MAPE indicator can still be relied on, with an error of 1.32% for inflation and 5.66% for the stock market index, using the best models. This shows no significant difference compared to the GRU, as the difference is not significant (Table 2).
Examining the average MAPE values of the database distributions using country-specific criteria, we see that the LSTM model is the most accurate for Swedish inflation and the least accurate for Hungarian inflation (Figure 3). When examining stock market indices, similar to the GRU, the best results were observed for the Slovak (SAX) index and the worst were observed for the Austrian (ATX) index (Figure 4).

2.3. LSTM–GRU

Hybrid models are designed to give a more accurate estimate than predictive algorithms alone. For inflation, the situation is similar to that of the LSTM with the ratios 80% - 20% and 85% - 15% giving the lowest error in most cases. For the stock market indices, the 80% - 20% learner-testing database gives the best results. For inflation, the average MAPE is 1.22%; for the stock market index the same value is 5.39%. The hybrid model does not give the lowest error among the inflation forecasts, but the LSTM–GRU is 0.05 percentage points weaker than the best value (GRUs), with no significant difference. For the stock market index, the hybrid model gave the best result, but there is no significant difference from the second place (Table 3).
In the case of the hybrid model (LSTM–GRU), examining the average MAPE values of the database split using country-specific criteria, we see that the most accurate inflation estimate is for Austria, while the least accurate is for Hungary (Figure 5). As before, when looking at the stock market indices, the best results were found for the Slovak (SAX) index and the worst for the Austrian (ATX) index (Figure 6).
The average MAPE values are presented in Table 4, which shows that the GRU model is the best model for forecasting inflation data, while the hybrid LSTM–GRU model is the best model for forecasting stock prices.

3. Materials and Methods

3.1. Gated Recurrent Units (GRUs)

Recurrent neural networks (RNNs) of the kind called GRUs are exceptionally accurate at predicting time series. While GRUs and the other type of neural network model (LSTM) are similar, GRUs use less processing power, which can greatly increase learning efficiency.
They have the same input and output structures as a basic RNN. The update gate z t and the reset gate r t are the only two gates that make up the internal structure of the GRU. The update gate z t   ascertains the value of the previous memory saved for the current time, while the restoration gate rt defines how the new input data is to be combined with the previous memory value. Unlike the LSTM technique, the z t update gate can forget and choose memory contents, improving computational efficiency and lowering runtime requirements. The GRU is determined using the following equations (Xiao et al. 2022):
z t = σ W z h t 1 + U z x t
r t = σ W r h t 1 + U r x t
h ~ t = tanh W 0 h t 1 r + U 0 x t
h t = z t h ~ t + 1 z t   h t 1
In this case, h t 1 represents the hidden state of the neuron at the previous time and σ(·) is a logistic sigmoid function, meaning σ ( x ) = 1 / 1 + e x . The weight matrices of the update gate are W z and U z . The weight matrices of the reset gate are W r and U r . The weight matrices of the intermediate output are denoted by W 0 and U 0 . The input value at time t is denoted by x t , whereas the information vectors h t ~ and h t represent the hidden layer output and temporary unit state, respectively, at time t (Xiao et al. 2022). The hyperparameters of the GRU model are specified in Table 5.

3.2. Long–Short Term Memory (LSTM)

Recurrent neural networks (RNNs), like LSTM, are frequently used in sequential data analysis. While short-term memory is associated with internal cell states, long-term memory is correlated with learning weights. LSTM was created to solve the issue of disappearing gradients in RNNs; the main distinction is that an LSTM block is used in place of the RNN’s intermediate layer. The primary benefit of LSTM is its capacity for long-term affiliations learning, a skill that RNNs were not previously able to provide. The initial time interval data must be preserved in order to update the weight values of the network and forecast the data associated with the following time point. An RNN is not able to learn long-term time series, but it can learn a finite number of short-term associations. It is possible for LSTM to manage the problem effectively. Memory blocks, or recurrent subnets, make up the LSTM model. Three multiple units (input, output, and forget) that regulate the continuous write, read, and cell operation are present in each block along with one or more autoregressive memory cells (Ortu et al. 2022). The following formulas constitute the LSTM model (Dai et al. 2022):
I t = σ ( X t W x i + H t 1 W h i + b i )
F t = σ ( X t W x f + H t 1 W h f + b f )
C ~ t = t a n h ( X t W x c + H t 1 W h c + b c )
C t = F t   C t 1 + I t   C ~ t
O t = σ ( X t W x o + H t 1 W h o + b o )
W x c and W h c are the gated unit’s weight matrix and b c is the offset term of the gated unit. C t is the new cell state at this moment and C t 1 is the cell state at the preceding time. W x o and W h o are the weight matrices of the output gate and b o is the offset term of the output gate (Dai et al. 2022).
Where X t is the small batch input of a given time unit t, H t 1 is the hidden state of the data from the previous period, W x i and W h i are the weight matrices of the input gate, and b i is the offset term of the input gate. σ represents the sigmoid function in this equation. The weight matrices of the forgetting gate are W x f and W h f , and its offset term is b f . The candidate memory cells are C t ~ . The weight matrices of the gated unit are W x c and W h c , and its offset term is b c . The current cell state, C t , is different from the previous cell state, C t 1 , at this moment. The output gate’s weight matrices are W x o and W h o , and its offset term is b o (Dai et al. 2022). Hyperparameters of the LSTM model are specified in Table 6.

3.3. LSTM–GRU Hybrid

Both the GRU and the LSTM can selectively remember important information and forget irrelevant information. The LSTM uses its own three-gated devices to control the flow of data and information across the network, solving the problem of long-term dependency. However, due to the excessive number of parameters set by the LSTM network, each cell has four fully interconnected layers. In practice, if a large time interval is involved and the LSTM network is deep, overfitting is likely to occur. This generates high computational capacity requirements. Compared to LSTM, GRUs replace the input gate, forget gate, and output gate of LSTM with a z t update gate and an r t reset gate. GRUs are a simplification of LSTM with fewer parameters, which reduces the risk of overfitting. However, for large datasets, it does not perform as well as LSTM. A hybrid LSTM–GRU model based on LSTM and GRU retains the advantages of both models, reduces overfitting, and, thus, allows highly accurate forecasts to be achieved (Zhao et al. 2023). In this model, the first hidden layer is LSTM. Each LSTM neuron collects the data and a weighted value is then generated. Then, data are passed from the LSTM to the GRU layer, which is the second hidden layer. A weighted value is, again, generated along the path from the LSTM layer to the GRU layer. Similarly, data are then passed to the third hidden layer (dense layer). A weighted value is generated from the GRU to the dense layer as well. The dense layer is a normal neural network layer that is used to produce output. From the dense layer, the data are then passed to the output neuron (Islam and Hossain 2021).

3.4. Performance Evaluation

The Mean Absolute Percentage Error (MAPE) was employed in our study to assess the predictive models. For a given set of forecasts, this indicator computes the average magnitude of the error I and displays the deviations as a percentage.
M A P E = 1 n i = 1 n y i y ^ i y i
Forecasts have a greater accuracy and dependability when the indicator has a lower value. The MAPE is a scale-independent indicator, as it is not affected by the nominal magnitude of prices. Therefore, it is an excellent tool for comparing different models and instruments, as well as different time periods.

3.5. Zivot–Andrews Unit Root Test

To obtain a more accurate understanding of the time series, a Zivot–Andrews unit root test (Table A1) was also applied to account for structural breaks in the time series (Zivot and Andrews 2002). For this test, the information of interest was the structural breakage test, i.e., whether we could identify a point in time where the “behaviour” of the time series suddenly changes and a break occurs. This is a common phenomenon for macroeconomic variables (Glynn et al. 2007) and we could make our estimates in further analysis with this in mind and could control for this.
To forecast the inflation time series with AI, we do not need stationary time series, as this information is not used in the Zivot–Andrews unit root test. The purpose of running the test is to find the break point at which the time series will break into a new trend. We incorporated this information into the prediction model by separating the learning and testing databases at this point. In this way, we selected an objective point in time to choose the learning–testing period, rather than making a decision based on habit (80% - 20%). At the same time, we were hopeful that the prediction accuracy would improve with it.
In our analysis, we used, monthly, the Harmonised Index of Consumer Prices (HICP) and stock market index data for Austria, Belgium, the Czech Republic, Germany, Hungary, the Netherlands, Poland, Slovakia, and Sweden for the period January 1996 (base period) to January 2023. Inflation data were collected from Eurostat, while the stock index information was collected from the stock exchange data platforms of the individual countries. Descriptive statistics for inflation data are shown in Table A2 and for stock indices in Table A3. Correlation matrices are presented in Table A4 (inflation) and Table A5 (stock indices). For both inflation and the stock market index, univariate models were applied, using a 36 month time frame for estimation.

4. Conclusions

In our study we investigated the usefulness of artificial intelligence in portfolio management. We assumed that the portfolio consists of a well-diversified set of stocks and government securities. The well-diversified stock portfolio is represented by the stock market indices of each country. We sought to capture government bond returns indirectly through inflation. In a high-inflation environment, equity prices fall while government bond yields typically rise. By forecasting inflation as accurately as possible, we can rebalance the portfolio in time to maximise returns.
In total, two different AI-based prediction algorithms were used (GRU and LSTM), and a hybrid model (LSTM–GRU) was also included in the study. In addition to the predictability of inflation, we also examined the forecast accuracy of stock market indices from a risk management perspective. The avoidance of stock price declines may be an important objective. We used three splits for the split of the train–test database: 80% - 20%, 85% - 15%, and 90% - 10%. The split 85% - 15% was selected based on the time series break established by the Zivot–Andrews unit tests. Furthermore, we investigated what happens in the case where the break falls in the learner or in the tester database part.
Our results show that when inflation is more predictable, the mean error of forecasting (MAPE) is smaller. This is due to the significantly lower volatility of inflation, which makes it easier to forecast. For the train–test-database split, the 80% - 20% split gave the most accurate forecast in most cases, while for inflation, 85% - 15% gave the better result for some countries. Therefore, we can say that the excellent pattern recognition ability of neural models is not significantly affected by structural breaks in the time series.
Contrary to the literature, the hybrid model (LSTM–GRU) did not perform better than its non-hybrid counterparts. In fact, there was no significant difference in prediction accuracy between the three models. Table 4 summarises the average MAPE values based on the AI models. As can be seen, there is no significant difference between the individual MAPE values; these differences are most likely due to chance.
When looking at the inflation and stock market index forecasts as a whole, taking country-specific aspects into account, we can conclude that Slovakia’s data were the most accurate and Hungary’s data the least accurate. This is supported by all the methodologies used, which is not so surprising in the light of the fact that all the algorithms belong to the group of recurrent neural networks.
Our results show that the average error of the inflation forecast is a quarter of the forecast of the stock market index. Inflation developments have a fundamental impact on stock and government bond returns. If we obtain a reliable estimate of the inflation forecast, we can expect to have time to rebalance the portfolio until the inflation shock is incorporated into government bond returns. Our results not only support investment decisions at the national economy level but are also useful in the process of rebalancing international portfolios.
The limitations of the study include the use of univariate estimation on both inflation and stock index data. Also, we have not explored the potential of various AI-based portfolio management tools such as BlackRock Aladdin, Wealthfront, Betterment, SigFid, Qplum, Alpaca, etc. Future research could be based on the inclusion of additional machine learning models, the use of multivariate estimators, and the expansion of the range of investment products.

Author Contributions

Conceptualization, L.V., T.T. and T.B.; methodology, L.V.; formal analysis, T.B.; data curation, L.V.; writing—original draft preparation, L.V., T.T. and T.B.; writing—review and editing, L.V., T.T. and T.B.; funding acquisition, T.T. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

All data used in the present study are publicly available.

Conflicts of Interest

The authors declare no conflicts of interest.

Appendix A

Table A1. Results of the Zivot–Andrews unit test (Source: own editing).
Table A1. Results of the Zivot–Andrews unit test (Source: own editing).
CountryDate of Structural BreakInflation (%)
January 1996 = 100%
AustriaDecember 2018148.7
BelgiumDecember 2018152.4
Czech RepublicDecember 2018179.1
GermanyNovember 2018137.6
HungaryNovember 2018336.9
NetherlandsNovember 2018150.2
PolandNovember 2018223.2
SlovakiaNovember 2018236.4
SwedenDecember 2018139.6
Table A2. Descriptive statistics, inflation (Source: own editing).
Table A2. Descriptive statistics, inflation (Source: own editing).
CountryNAverageMedianStDMinMax
Austria325126.22123.719.0999.40177.00
Belgium325129.25128.420.2199.20183.50
Czech Republic325154.03155.928.7696.90248.40
Germany325121.78121.215.1599.20163.10
Hungary325258.62271.585.0192.30493.80
Netherlands325132.51132.419.6198.70190.20
Poland325190.24196.441.8093.00302.00
Slovakia325196.22207.648.3198.00307.70
Sweden325122.94124.414.9799.00165.50
Table A3. Descriptive statistics, stock market indices (Source: own editing).
Table A3. Descriptive statistics, stock market indices (Source: own editing).
IndexNAverageMedianStDMinMax
Austria_ATX3252371.142396.9980.771028.704885.38
Belgium_BEL203253060.063096.91726.321635.224697.86
Czech_PX325935.83973.1360.78331.901908.30
Germany_DAX3257693.886772.263561.292423.8715,884.86
Hungary_BUX32520,826.4619,023.9612,736.302068.0654,197.71
Netherlands_AEX325456.11449.83131.96216.98810.91
Poland_WIG32538,366.7242,405.8317,819.5310,413.1073,586.32
Slovakia_SAX325258.74241.25110.8273.66475.23
Sweden_OMX_Stockholm303251142.941072.45469.47343.822419.73
Table A4. Correlation with inflation data (Source: own editing).
Table A4. Correlation with inflation data (Source: own editing).
AustriaBelgiumCzech RepublicGermanyHungaryThe NetherlandsPolandSlovakiaSweden
Austria1
Belgium0.99761
Czech Republic0.98310.98611
Germany0.99780.99830.98761
Hungary0.98070.98640.99030.98601
Netherlands0.98660.99040.99020.99080.99231
Poland0.96340.97100.98860.97000.99360.98521
Slovakia0.94810.95840.96700.95710.98690.97820.98571
Sweden0.99340.99620.98970.99570.99080.99240.97710.96581
Table A5. Correlation of stock market index data (Source: own editing).
Table A5. Correlation of stock market index data (Source: own editing).
Austria_ATXBelgium_BEL20Czech_PXGermany_DAXHungary_BUXNetherlands_AEXPoland_WIGSlovakia_SAXSweden_OMX_Stockholm30
Austria_ATX1
Belgium_BEL200.74771
Czech_PX0.95910.60981
Germany_DAX0.54080.71980.42831
Hungary_BUX0.74040.70080.65060.89811
Netherlands_AEX0.29900.75680.15770.69720.55761
Poland_WIG0.82550.69570.77510.84810.89680.38061
Slovakia_SAX0.85700.56950.84340.45270.70370.15220.68211
Sweden_OMX_Stockholm300.55480.72200.47240.97810.88600.73280.83650.44671

References

  1. Aras, Serkan, and Paulo J. G. Lisboa. 2022. Explainable Inflation Forecasts by Machine Learning Models. Expert Systems with Applications 207: 117982. [Google Scholar] [CrossRef]
  2. Araujo, Gustavo Silva, and Wagner Piazza Gaglianone. 2023. Machine Learning Methods for Inflation Forecasting in Brazil: New Contenders versus Classical Models. Latin American Journal of Central Banking 4: 100087. [Google Scholar] [CrossRef]
  3. Ayala, Jordan, Miguel García-Torres, José Luis Noguera, Francisco Gómez-Vela, and Federico Divina. 2021. Technical Analysis Strategy Optimization Using a Machine Learning Approach in Stock Market Indices. Knowledge-Based Systems 225: 107119. [Google Scholar] [CrossRef]
  4. Bhandari, Hum Nath, Binod Rimal, Nawa Raj Pokhrel, Ramchandra Rimal, Keshab R. Dahal, and Rajendra K.C. Khatri. 2022. Predicting Stock Market Index Using LSTM. Machine Learning with Applications 9: 100320. [Google Scholar] [CrossRef]
  5. Bouri, Elie, Ramzi Nekhili, Harald Kinateder, and Tonmoy Choudhury. 2023. Expected Inflation and U.S. Stock Sector Indices: A Dynamic Time-Scale Tale from Inflationary and Deflationary Crisis Periods. Finance Research Letters 55: 103845. [Google Scholar] [CrossRef]
  6. Chaves, Carlos, and André C. Silva. 2019. Inflation and Stock Returns at B3. Brazilian Review of Finance 16: 521–44. [Google Scholar] [CrossRef]
  7. Choudhary, M. Ali, and Adnan Haider. 2011. Neural Network Models for Inflation Forecasting: An Appraisal. Applied Economics 44: 2631–35. [Google Scholar] [CrossRef]
  8. Constantinos, Katrakilidis, Lake Andreas Ektor, and Trachanas Emmanouil. 2012. Asymmetric Effects of Inflation on Stock Market Prices: New Empirical Evidence Using Greek Data. Journal of Applied Business Research (JABR) 28: 325. [Google Scholar] [CrossRef]
  9. Dai, Yeming, Qiong Zhou, Mingming Leng, Xinyu Yang, and Yanxin Wang. 2022. Improving the Bi-LSTM Model with XGBoost and Attention Mechanism: A Combined Approach for Short-Term Power Load Prediction. Applied Soft Computing 130: 109632. [Google Scholar] [CrossRef]
  10. Eldomiaty, Tarek, Yasmeen Saeed, Rasha Hammam, and Salma AboulSoud. 2020. The Associations between Stock Prices, Inflation Rates, Interest Rates Are Still Persistent. Journal of Economics, Finance and Administrative Science 25: 149–61. [Google Scholar] [CrossRef]
  11. Giofré, Maela. 2012. Convergence of Emu Equity Portfolios. Open Economies Review 23: 381–419. [Google Scholar] [CrossRef]
  12. Glynn, John, Nelson Perera, and Reetu Verma. 2007. Unit root tests and structural breaks: A survey with applications. Journal of Quantitative Methods for Economics and Business Administration 3: 63–79. [Google Scholar]
  13. Hanauer, Matthias X., and Tobias Kalsbach. 2023. Machine Learning and the Cross-Section of Emerging Market Stock Returns. Emerging Markets Review 55: 101022. [Google Scholar] [CrossRef]
  14. Islam, Md. Saiful, and Emam Hossain. 2021. Foreign Exchange Currency Rate Prediction Using a GRU-LSTM Hybrid Network. Soft Computing Letters 3: 100009. [Google Scholar] [CrossRef]
  15. Joseph, Andreas, Eleni Kalamara, George Kapetanios, and Galina Potjagailo. 2021. Forecasting UK Inflation Bottom Up. SSRN Electronic Journal, 195. [Google Scholar] [CrossRef]
  16. Karimi, Mahdi, Darush Javid, and Hossein Afshari. 2015. The Study of the Relationship between Inflation Rate and Stock Yield in the Companies Active in Polluting Industries in Tehran Stock Exchange. International Journal of Management 1: 17–26. [Google Scholar]
  17. Liu, Keyan, Jianan Zhou, and Dayong Dong. 2021. Improving Stock Price Prediction Using the Long Short-Term Memory Model Combined with Online Social Networks. Journal of Behavioral and Experimental Finance 30: 100507. [Google Scholar] [CrossRef]
  18. Macrotrends. 2024. Euro Area Inflation Rate 1960–2024. Available online: https://www.macrotrends.net/countries/EMU/euro-area/inflation-rate-cpi (accessed on 25 January 2024).
  19. Marjohan, Masno, Anggun Anggraini, Sayu Ketut Sutrisna Dewi, and Arsid. 2023. Opportunity Set, Liquidity, Stock Return, Inflation as a Moderator Investment Risk, Investment. Jurnal Manajemen 27: 381–402. [Google Scholar] [CrossRef]
  20. Masini, Ricardo P., Marcelo C. Medeiros, and Eduardo F. Mendes. 2023. Machine Learning Advances for Time Series Forecasting. Journal of Economic Surveys 37: 76–111. [Google Scholar] [CrossRef]
  21. Md, Abdul Quadir, Sanjit Kapoor, Chris Junni A.V., Arun Kumar Sivaraman, Kong Fah Tee, Sabireen H., and Janakiraman N. 2023. Novel Optimization Approach for Stock Price Forecasting Using Multi-Layered Sequential LSTM. Applied Soft Computing 134: 109830. [Google Scholar] [CrossRef]
  22. Medeiros, Marcelo C., Gabriel F. Vasconcelos, Álvaro Veiga, and Eduardo Zilberman. 2021. Forecasting Inflation in a Data-Rich Environment: The Benefits of Machine Learning Methods. Journal of Business & Economic Statistics 39: 98–119. [Google Scholar] [CrossRef]
  23. Nabipour, Mojtaba, Pooyan Nayyeri, Hamed Jabani, Shahab S., and Amir Mosavi. 2020. Predicting stock market trends using machine learning and deep learning algorithms via continuous and binary data; a comparative analysis on the Tehran stock exchange. IEEE Access 8: 150199–212. [Google Scholar] [CrossRef]
  24. Neville, Henry, Teun Draaisma, Ben Funnell, Campbell R. Harvey, and Otto Van Hemert. 2021. The Best Strategies for Inflationary Times. The Journal of Portfolio Management 47: 8–37. [Google Scholar] [CrossRef]
  25. Ni, Chendi, Yuying Li, and Peter Forsyth. 2023. Neural Network Approach to Portfolio Optimization with Leverage Constraints: A Case Study on High Inflation Investment. arXiv arXiv:2304.05297. [Google Scholar]
  26. Nwude, E. Chuke. 2013. Common stock returns and inflation: The case of chemical/paints sector stocks of the Nigerian Stock Exchange. European Journal of Business and Management 5: 21. [Google Scholar]
  27. Ortu, Marco, Nicola Uras, Claudio Conversano, Silvia Bartolucci, and Giuseppe Destefanis. 2022. On Technical Trading and Social Media Indicators for Cryptocurrency Price Classification through Deep Learning. Expert Systems with Applications 198: 116804. [Google Scholar] [CrossRef]
  28. Theoharidis, Alexandre Fernandes, Diogo Abry Guillén, and Hedibert Lopes. 2023. Deep Learning Models for Inflation Forecasting. Applied Stochastic Models in Business and Industry 39: 447–70. [Google Scholar] [CrossRef]
  29. Ülke, Volkan, Afsin Sahin, and Abdulhamit Subasi. 2018. A Comparison of Time Series and Machine Learning Models for Inflation Forecasting: Empirical Evidence from the USA. Neural Computing and Applications 30: 1519–27. [Google Scholar] [CrossRef]
  30. Vancsura, László, and Tibor Bareith. 2023. Analysis of the Performance of Predictive Models during COVID-19 and the Russian-Ukrainian War. Pénzügyi Szemle Public Finance Quarterly 69: 123–38. [Google Scholar] [CrossRef]
  31. Vancsura, László, Tibor Tatay, and Tibor Bareith. 2023. Evaluating the Effectiveness of Modern Forecasting Models in Predicting Commodity Futures Prices in Volatile Economic Times. Risks 11: 27. [Google Scholar] [CrossRef]
  32. Xiao, Haohan, Zuyu Chen, Ruilang Cao, Yuxin Cao, Lijun Zhao, and Yunjie Zhao. 2022. Prediction of Shield Machine Posture Using the GRU Algorithm with Adaptive Boosting: A Case Study of Chengdu Subway Project. Transportation Geotechnics 37: 100837. [Google Scholar] [CrossRef]
  33. Yeoh, Wee Win. 2023. To Study Inflation Impact in Malaysia against the Stock Portfolio Investment in Bursa Malaysia. Interdisciplinary Social Studies 2: 2016–24. [Google Scholar] [CrossRef]
  34. Zhao, Lingxiao, Zhiyang Li, Leilei Qu, Junsheng Zhang, and Bin Teng. 2023. A Hybrid VMD-LSTM/GRU Model to Predict Non-Stationary and Irregular Waves on the East Coast of China. Ocean Engineering 276: 114136. [Google Scholar] [CrossRef]
  35. Zivot, Eric, and Donald W. Andrews. 2002. Further Evidence on the Great Crash, the Oil-Price Shock, and the Unit-Root Hypothesis. Journal of Business & Economic Statistics 20: 25–44. [Google Scholar] [CrossRef]
Figure 1. GRU forecast average MAPE inflation values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Figure 1. GRU forecast average MAPE inflation values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Risks 12 00046 g001
Figure 2. GRU forecast average MAPE indices values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Figure 2. GRU forecast average MAPE indices values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Risks 12 00046 g002
Figure 3. LSTM forecast average MAPE inflation values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Figure 3. LSTM forecast average MAPE inflation values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Risks 12 00046 g003
Figure 4. LSTM forecast average MAPE indices values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Figure 4. LSTM forecast average MAPE indices values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Risks 12 00046 g004
Figure 5. LSTM–GRU forecast average MAPE inflation values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Figure 5. LSTM–GRU forecast average MAPE inflation values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Risks 12 00046 g005
Figure 6. LSTM–GRU forecast average MAPE indices values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Figure 6. LSTM–GRU forecast average MAPE indices values by country. Ordered from worst (higher MAPE) to best (lower MAPE). (Source: own editing).
Risks 12 00046 g006
Table 1. GRU forecast MAPE values. (Source: own editing).
Table 1. GRU forecast MAPE values. (Source: own editing).
InflationStock Indices
80%-20%85%-15%90%-10%80%-20%85%-15%90%-10%
Austria0.0130.0100.0210.0770.0790.072
Belgium0.0130.0100.0190.0520.0550.054
Czech Republic0.0110.0160.0190.0520.0620.057
Germany0.0150.0120.0120.0680.0590.050
Hungary0.0170.0140.0220.0700.0710.086
Netherlands0.0150.0130.0210.0470.0480.060
Poland0.0140.0190.0140.0640.0710.073
Slovakia0.0110.0220.0210.0330.0350.035
Sweden0.0090.0120.0140.0520.0600.057
Table 2. LSTM forecast MAPE values. (Source: own editing).
Table 2. LSTM forecast MAPE values. (Source: own editing).
InflationStock Indices
80%-20%85%-15%90%-10%80%-20%85%-15%90%-10%
Austria0.0110.0140.0140.0720.0810.072
Belgium0.0140.0120.0180.0550.0560.055
Czech Republic0.0130.0150.0240.0510.0590.054
Germany0.0120.0150.0130.0560.0680.063
Hungary0.0230.0230.0300.0660.0710.076
Netherlands0.0140.0140.0160.0480.0690.062
Poland0.0150.0140.0160.0670.0710.082
Slovakia0.0080.0170.0140.0390.0350.034
Sweden0.0120.0120.0130.0550.0670.050
Table 3. LSTM–GRU forecast MAPE values. (Source: own editing).
Table 3. LSTM–GRU forecast MAPE values. (Source: own editing).
InflationStock indices
80%-20%85%-15%90%-10%80%-20%85%-15%90%-10%
Austria0.0130.0110.0100.0830.0780.079
Belgium0.0130.0110.0180.0520.0640.045
Czech Republic0.0110.0160.0170.0520.0570.062
Germany0.0150.0130.0140.0530.0660.066
Hungary0.0230.0220.0270.0620.0800.076
Netherlands0.0120.0130.0190.0480.0520.054
Poland0.0110.0200.0150.0620.0710.072
Slovakia0.0130.0100.0170.0330.0340.037
Sweden0.0100.0160.0110.0560.0480.054
Table 4. Average MAPE values. (Source: own editing).
Table 4. Average MAPE values. (Source: own editing).
ModelInflationStock Indices
GRU1.17%5.53%
LSTM1.32%5.66%
LSTM–GRU1.22%5.39%
Table 5. Hyperparameters of GRU model. (Source: own editing based on Nabipour et al. (2020)).
Table 5. Hyperparameters of GRU model. (Source: own editing based on Nabipour et al. (2020)).
ModelParametersValue
GRUHidden Layers2
Hidden layer neuron count150
Batch size32
Epochs100
Activationtanh
Learning rate0.001
OptimizerAdam
Table 6. Hyperparameters of LSTM model. (Source: own editing based on Nabipour et al. (2020)).
Table 6. Hyperparameters of LSTM model. (Source: own editing based on Nabipour et al. (2020)).
ModelParametersValue
LSTMHidden Layers2
Hidden layer neuron count150
Batch size32
Epochs100
Activationtanh
Learning rate0.001
OptimizerAdam
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Bareith, T.; Tatay, T.; Vancsura, L. Navigating Inflation Challenges: AI-Based Portfolio Management Insights. Risks 2024, 12, 46. https://doi.org/10.3390/risks12030046

AMA Style

Bareith T, Tatay T, Vancsura L. Navigating Inflation Challenges: AI-Based Portfolio Management Insights. Risks. 2024; 12(3):46. https://doi.org/10.3390/risks12030046

Chicago/Turabian Style

Bareith, Tibor, Tibor Tatay, and László Vancsura. 2024. "Navigating Inflation Challenges: AI-Based Portfolio Management Insights" Risks 12, no. 3: 46. https://doi.org/10.3390/risks12030046

APA Style

Bareith, T., Tatay, T., & Vancsura, L. (2024). Navigating Inflation Challenges: AI-Based Portfolio Management Insights. Risks, 12(3), 46. https://doi.org/10.3390/risks12030046

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop