Estimating HANK Models with Neural Networks

Matthias Rottner (Bundesbank)

June 7, 2022

BDF Paris

Séminaire Banque de France


We leverage recent developments in machine learning to develop methods to estimate large and complex nonlinear macroeconomic models, e.g. HANK models. Our method relies on neural networks because of their appealing feature that even models with hundreds of state variables can be solved. While likelihood estimation requires the repeated solving of the model, something that is infeasible for highly complex models, we overcome this problem by exploiting the scalability of neural networks. Including the parameters of the model as pseudo state variables in the neural network, we solve this extended neural network and apply it directly in the estimation. As a proof of concept, we demonstrate with a tractable RANK model augmented with a zero lower bound that our approach coincides with an estimation based on conventional methods for nonlinear models. To show the full potential of our approach, we then estimate a quantitative HANK model that features nonlinearities on an individual (borrowing limit) and aggregate level (zero lower bound) using simulated data.


Machine Learning; Neural Networks; Bayesian Estimation; HANK; Heterogeneity; Nonlinearities;

JEL codes

  • C11: Bayesian Analysis: General
  • C45: Neural Networks and Related Topics
  • D31: Personal Income, Wealth, and Their Distributions
  • E32: Business Fluctuations • Cycles
  • E52: Monetary Policy