Deep Learning

A Machine Learning Approach to Simulation-Based MLE and Bayesian Estimation of Heterogeneous and Representative Agent Models

This paper introduces a machine learning algorithm called Sequential Neural Posterior Estimation (SNPE) for estimating structural heterogeneous agent macroeconomic models. SNPE is a simulation-based algorithm that aims to approximate the joint distribution of parameters and simulated data. It then uses a conditional density estimator to obtain the posterior distribution. The algorithm offers several advantages, including the ability to handle any black box solution method, improved speed and accuracy compared to existing Bayesian algorithms, and statistically efficient simulation-based estimates. The algorithm outperforms Markov Chain Monte Carlo in estimating Bayesian posteriors for benchmark models such as Smets-Wouters (2007) and improves estimation speed for Heterogeneous Agent New Keynesian (HANK) models. An empirical application demonstrates the effectiveness of this technique in estimating a heterogeneous agent model using both aggregate time series and cross-sectional micro-data. A tutorial can be found at: https://shorturl.at/pMQ18

Improving External Validity of Machine Learning, Reduced Form, and Structural Macroeconomic Models using Panel Data

We investigate the impact of adding countries as a panel dimension to Macroeconomic data for economic forecasting. We find that this approach significantly improves the generalization ability of both structural and reduced-form models, and works synergistically with Machine Learning methods to further outperform traditional macroeconomic forecasting models. The addition of country-specific data reduces the root mean squared error (RMSE) by 12-24% across horizons and models. Furthermore, excluding US data and forecasting each country individually enhances the policy invariance and performance of both structural and reduced-form models. Additionally, the study demonstrates that the use of Recurrent Neural Network (RNN) models and Automated Machine Learning (AutoML) outperform baseline economic models in a data-rich regime. The findings are robust, reproducible, numerically stable, and applicable across various models.