Macro Forecasting with Machine Learning

PAPERS

"Deus ex Machina? A Framework for Macro Forecasting with Machine Learning." with Brett Rayner (International Monetary Fund). IMF Working Paper No. 20/45.

We develop a framework to nowcast (and forecast) economic variables with machine learning techniques. We explain how machine learning methods can address common shortcomings of traditional OLS-based models and use several machine learning models to predict real output growth with lower forecast errors than traditional models. By combining multiple machine learning models into ensembles, we lower forecast errors even further. We also identify measures of variable importance to help improve the transparency of machine learning-based forecasts. Applying the framework to Turkey reduces forecast errors by at least 30 percent relative to traditional models. The framework also better predicts economic volatility, suggesting that machine learning techniques could be an important part of the macro forecasting toolkit of many countries.

Code: [here]


"The More the Merrier? A Machine Learning Algorithm for Optimal Pooling of Panel Data." with Brett Rayner (International Monetary Fund) IMF Working Paper No. 20/44.

We leverage insights from machine learning to optimize the tradeoff between bias and variance when estimating economic models using pooled datasets. Specifically, we develop a simple algorithm that estimates the similarity of economic structures across countries and selects the optimal pool of countries to maximize out-of-sample prediction accuracy of a model. We apply the new algorithm by nowcasting output growth with a panel of 102 countries and are able to significantly improve forecast accuracy relative to alternative pools. The algorithm improves nowcast performance for advanced economies, as well as emerging market and developing economies, suggesting that machine learning techniques using pooled data could be an important macro tool for many countries.


I explore to what extent machine learning (ML) models can improve expert forecasts in the IMF World Economic Outlook. The goal of this project is not to get most accurate prediction, but rather to compare the performance of forecasts based on ML models relative to expert forecasts, and to identify settings in which ML models and expert forecasts complement each other. I first document that WEO forecast errors are significantly higher (i) during periods of low growth, (ii) for low-income countries, and (iii) during recessions. I then explain the strengths and weaknesses of ML models for macroeconomic forecasting. I forecast GDP growth for countries in the 2004-2016 WEO and compare the forecasts with the realized GDP growth in the 2018 WEO. Standard ML models improve reduce forecast errors by 15 to 20 percent compared to the WEO forecasts. These gains are driven by forecasts for slow-growing countries and poorer countries.