IDEAS home Printed from https://ideas.repec.org/p/cpr/ceprdp/19381.html
   My bibliography  Save this paper

Bayesian Neural Networks for Macroeconomic Analysis

Author

Listed:
  • Hauzenberger , Niko
  • Huber, Florian
  • Klieber, Karin
  • Marcellino, Massimiliano

Abstract

Macroeconomic data is characterized by a limited number of observations (small T), many time series (big K) but also by featuring temporal dependence. Neural networks, by contrast, are designed for datasets with millions of observations and covariates. In this paper, we develop Bayesian neural networks (BNNs) that are well-suited for handling datasets commonly used for macroeconomic analysis in policy institutions. Our approach avoids extensive specification searches through a novel mixture specification for the activation function that appropriately selects the form of nonlinearities. Shrinkage priors are used to prune the network and force irrelevant neurons to zero. To cope with heteroskedasticity, the BNN is augmented with a stochastic volatility model for the error term. We illustrate how the model can be used in a policy institution through simulations and by showing that BNNs produce more accurate point and density forecasts compared to other machine learning methods.

Suggested Citation

  • Hauzenberger , Niko & Huber, Florian & Klieber, Karin & Marcellino, Massimiliano, 2024. "Bayesian Neural Networks for Macroeconomic Analysis," CEPR Discussion Papers 19381, C.E.P.R. Discussion Papers.
  • Handle: RePEc:cpr:ceprdp:19381
    as

    Download full text from publisher

    File URL: https://cepr.org/publications/DP19381
    Download Restriction: CEPR Discussion Papers are free to download for our researchers, subscribers and members. If you fall into one of these categories but have trouble downloading our papers, please contact us at subscribers@cepr.org
    ---><---

    As the access to this document is restricted, you may want to look for a different version below or search for a different version of it.

    Other versions of this item:

    References listed on IDEAS

    as
    1. Kastner, Gregor & Frühwirth-Schnatter, Sylvia, 2014. "Ancillarity-sufficiency interweaving strategy (ASIS) for boosting MCMC estimation of stochastic volatility models," Computational Statistics & Data Analysis, Elsevier, vol. 76(C), pages 408-423.
    2. Ramsey James B. & Lampart Camille, 1998. "The Decomposition of Economic Relationships by Time Scale Using Wavelets: Expenditure and Income," Studies in Nonlinear Dynamics & Econometrics, De Gruyter, vol. 3(1), pages 1-22, April.
    3. Ivo Welch & Amit Goyal, 2008. "A Comprehensive Look at The Empirical Performance of Equity Premium Prediction," The Review of Financial Studies, Society for Financial Studies, vol. 21(4), pages 1455-1508, July.
    4. Yu Bai & Andrea Carriero & Todd E. Clark & Massimiliano Marcellino, 2022. "Macroeconomic forecasting in a multi‐country context," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 37(6), pages 1230-1255, September.
    5. Blix, Mårten, 1999. "Forecasting Swedish Inflation With a Markov Switching VAR," Working Paper Series 76, Sveriges Riksbank (Central Bank of Sweden).
    6. David S. Lee & Thomas Lemieux, 2010. "Regression Discontinuity Designs in Economics," Journal of Economic Literature, American Economic Association, vol. 48(2), pages 281-355, June.
    7. Carlos M. Carvalho & Nicholas G. Polson & James G. Scott, 2010. "The horseshoe estimator for sparse signals," Biometrika, Biometrika Trust, vol. 97(2), pages 465-480.
    8. Michael W. McCracken & Serena Ng, 2016. "FRED-MD: A Monthly Database for Macroeconomic Research," Journal of Business & Economic Statistics, Taylor & Francis Journals, vol. 34(4), pages 574-589, October.
    9. Barbara Rossi, 2013. "Exchange Rate Predictability," Journal of Economic Literature, American Economic Association, vol. 51(4), pages 1063-1119, December.
    10. Vasicek, Oldrich A & Fong, H Gifford, 1982. "Term Structure Modeling Using Exponential Splines," Journal of Finance, American Finance Association, vol. 37(2), pages 339-348, May.
    11. Daniel R. Kowal & David S. Matteson & David Ruppert, 2019. "Dynamic shrinkage processes," Journal of the Royal Statistical Society Series B, Royal Statistical Society, vol. 81(4), pages 781-804, September.
    12. Marcellino, Massimiliano & Stock, James H. & Watson, Mark W., 2006. "A comparison of direct and iterated multistep AR methods for forecasting macroeconomic time series," Journal of Econometrics, Elsevier, vol. 135(1-2), pages 499-526.
    13. John Y. Campbell & Tuomo Vuolteenaho, 2004. "Inflation Illusion and Stock Prices," American Economic Review, American Economic Association, vol. 94(2), pages 19-23, May.
    14. Diebold, Francis X & Mariano, Roberto S, 2002. "Comparing Predictive Accuracy," Journal of Business & Economic Statistics, American Statistical Association, vol. 20(1), pages 134-144, January.
    15. Stock, James H. & Watson, Mark W., 1999. "Forecasting inflation," Journal of Monetary Economics, Elsevier, vol. 44(2), pages 293-335, October.
    16. Huber, Florian & Koop, Gary & Onorante, Luca & Pfarrhofer, Michael & Schreiner, Josef, 2023. "Nowcasting in a pandemic using non-parametric mixed frequency VARs," Journal of Econometrics, Elsevier, vol. 232(1), pages 52-69.
    17. John Y. Campbell, Robert J. Shiller, 1988. "The Dividend-Price Ratio and Expectations of Future Dividends and Discount Factors," The Review of Financial Studies, Society for Financial Studies, vol. 1(3), pages 195-228.
    18. Miguel A.G. Belmonte & Gary Koop & Dimitris Korobilis, 2014. "Hierarchical Shrinkage in Time‐Varying Parameter Models," Journal of Forecasting, John Wiley & Sons, Ltd., vol. 33(1), pages 80-94, January.
    19. Barro, Robert J. & Lee, Jong-Wha, 1994. "Sources of economic growth," Carnegie-Rochester Conference Series on Public Policy, Elsevier, vol. 40(1), pages 1-46, June.
    20. Fama, Eugene F. & Schwert, G. William, 1977. "Asset returns and inflation," Journal of Financial Economics, Elsevier, vol. 5(2), pages 115-146, November.
    21. Campbell, John Y., 1987. "Stock returns and the term structure," Journal of Financial Economics, Elsevier, vol. 18(2), pages 373-399, June.
    22. Joscha Beckmann & Gary Koop & Dimitris Korobilis & Rainer Alexander Schüssler, 2020. "Exchange rate predictability and dynamic Bayesian learning," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 35(4), pages 410-421, June.
    23. Greene, William, 2010. "Testing hypotheses about interaction terms in nonlinear models," Economics Letters, Elsevier, vol. 107(2), pages 291-296, May.
    24. Florian Huber & Michael Pfarrhofer, 2021. "Dynamic shrinkage in time‐varying parameter stochastic volatility in mean models," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 36(2), pages 262-270, March.
    25. Lewellen, Jonathan, 2004. "Predicting returns with financial ratios," Journal of Financial Economics, Elsevier, vol. 74(2), pages 209-235, November.
    26. Amisano, Gianni & Fagan, Gabriel, 2013. "Money growth and inflation: A regime switching approach," Journal of International Money and Finance, Elsevier, vol. 33(C), pages 118-145.
    27. Guido W. Imbens & Jeffrey M. Wooldridge, 2009. "Recent Developments in the Econometrics of Program Evaluation," Journal of Economic Literature, American Economic Association, vol. 47(1), pages 5-86, March.
    28. Hamilton, James D, 1989. "A New Approach to the Economic Analysis of Nonstationary Time Series and the Business Cycle," Econometrica, Econometric Society, vol. 57(2), pages 357-384, March.
    29. Fama, Eugene F. & French, Kenneth R., 1988. "Dividend yields and expected stock returns," Journal of Financial Economics, Elsevier, vol. 22(1), pages 3-25, October.
    30. Florian Huber & Gary Koop & Luca Onorante, 2021. "Inducing Sparsity and Shrinkage in Time-Varying Parameter Models," Journal of Business & Economic Statistics, Taylor & Francis Journals, vol. 39(3), pages 669-683, July.
    31. Gallegati, Marco, 2008. "Wavelet analysis of stock returns and aggregate economic activity," Computational Statistics & Data Analysis, Elsevier, vol. 52(6), pages 3061-3074, February.
    32. Hodrick, Robert J, 1992. "Dividend Yields and Expected Stock Returns: Alternative Procedures for Inference and Measurement," The Review of Financial Studies, Society for Financial Studies, vol. 5(3), pages 357-386.
    33. Raffaella Giacomini & Barbara Rossi, 2010. "Forecast comparisons in unstable environments," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 25(4), pages 595-620.
    34. Spyros Makridakis & Evangelos Spiliotis & Vassilios Assimakopoulos, 2018. "Statistical and Machine Learning forecasting methods: Concerns and ways forward," PLOS ONE, Public Library of Science, vol. 13(3), pages 1-26, March.
    35. McCrary, Justin, 2008. "Manipulation of the running variable in the regression discontinuity design: A density test," Journal of Econometrics, Elsevier, vol. 142(2), pages 698-714, February.
    36. Anirban Bhattacharya & Debdeep Pati & Natesh S. Pillai & David B. Dunson, 2015. "Dirichlet--Laplace Priors for Optimal Shrinkage," Journal of the American Statistical Association, Taylor & Francis Journals, vol. 110(512), pages 1479-1490, December.
    37. Ai, Chunrong & Norton, Edward C., 2003. "Interaction terms in logit and probit models," Economics Letters, Elsevier, vol. 80(1), pages 123-129, July.
    38. George, Edward I. & Sun, Dongchu & Ni, Shawn, 2008. "Bayesian stochastic search for VAR model restrictions," Journal of Econometrics, Elsevier, vol. 142(1), pages 553-580, January.
    39. A. Bhattacharya & D. B. Dunson, 2011. "Sparse Bayesian infinite factor models," Biometrika, Biometrika Trust, vol. 98(2), pages 291-306.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Hauzenberger, Niko & Huber, Florian & Klieber, Karin, 2023. "Real-time inflation forecasting using non-linear dimension reduction techniques," International Journal of Forecasting, Elsevier, vol. 39(2), pages 901-921.
    2. Rapach, David & Zhou, Guofu, 2013. "Forecasting Stock Returns," Handbook of Economic Forecasting, in: G. Elliott & C. Granger & A. Timmermann (ed.), Handbook of Economic Forecasting, edition 1, volume 2, chapter 0, pages 328-383, Elsevier.
    3. Jiang, Fuwei & Lee, Joshua & Martin, Xiumin & Zhou, Guofu, 2019. "Manager sentiment and stock returns," Journal of Financial Economics, Elsevier, vol. 132(1), pages 126-149.
    4. Sung Won Seo & Suk Joon Byun & Jun Sik Kim, 2020. "Index options open interest and stock market returns," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 40(6), pages 989-1010, June.
    5. Kothari, Pratik & O’Doherty, Michael S., 2023. "Job postings and aggregate stock returns," Journal of Financial Markets, Elsevier, vol. 64(C).
    6. Mykola Babiak & Jozef Barunik, 2020. "Deep Learning, Predictability, and Optimal Portfolio Returns," CERGE-EI Working Papers wp677, The Center for Economic Research and Graduate Education - Economics Institute, Prague.
    7. Schrimpf, Andreas, 2010. "International stock return predictability under model uncertainty," Journal of International Money and Finance, Elsevier, vol. 29(7), pages 1256-1282, November.
    8. Ferreira, Miguel A. & Santa-Clara, Pedro, 2011. "Forecasting stock market returns: The sum of the parts is more than the whole," Journal of Financial Economics, Elsevier, vol. 100(3), pages 514-537, June.
    9. Pierre Giot & Mikael Petitjean, 2009. "Short-term market timing using the bond-equity yield ratio," The European Journal of Finance, Taylor & Francis Journals, vol. 15(4), pages 365-384.
    10. Maio, Paulo & Santa-Clara, Pedro, 2012. "Multifactor models and their consistency with the ICAPM," Journal of Financial Economics, Elsevier, vol. 106(3), pages 586-613.
    11. Li, Yan & Ng, David T. & Swaminathan, Bhaskaran, 2013. "Predicting market returns using aggregate implied cost of capital," Journal of Financial Economics, Elsevier, vol. 110(2), pages 419-436.
    12. Ekaterini Panopoulou & Sotiria Plastira, 2014. "Fama French factors and US stock return predictability," Journal of Asset Management, Palgrave Macmillan, vol. 15(2), pages 110-128, April.
    13. Faias, José Afonso, 2023. "Predicting the equity risk premium using the smooth cross-sectional tail risk: The importance of correlation," Journal of Financial Markets, Elsevier, vol. 63(C).
    14. Yu, Jialin, 2011. "Disagreement and return predictability of stock portfolios," Journal of Financial Economics, Elsevier, vol. 99(1), pages 162-183, January.
    15. John Y. Campbell & Samuel B. Thompson, 2005. "Predicting the Equity Premium Out of Sample: Can Anything Beat the Historical Average?," Harvard Institute of Economic Research Working Papers 2084, Harvard - Institute of Economic Research.
    16. Jurdi, Doureige & Kim, Jae, 2019. "Predicting the U.S. Stock Market Return: Evidence from the Improved Augmented Regression Method," MPRA Paper 94028, University Library of Munich, Germany.
    17. Bandi, F.M. & Perron, B. & Tamoni, A. & Tebaldi, C., 2019. "The scale of predictability," Journal of Econometrics, Elsevier, vol. 208(1), pages 120-140.
    18. Nima Nonejad, 2021. "An Overview Of Dynamic Model Averaging Techniques In Time‐Series Econometrics," Journal of Economic Surveys, Wiley Blackwell, vol. 35(2), pages 566-614, April.
    19. Thomadakis, Apostolos, 2016. "Do Combination Forecasts Outperform the Historical Average? Economic and Statistical Evidence," MPRA Paper 71589, University Library of Munich, Germany.
    20. Wang, Yudong & Pan, Zhiyuan & Liu, Li & Wu, Chongfeng, 2019. "Oil price increases and the predictability of equity premium," Journal of Banking & Finance, Elsevier, vol. 102(C), pages 43-58.

    More about this item

    Keywords

    Bayesian neural networks; Model selection; Shrinkage priors; Macro forecasting;
    All these keywords.

    JEL classification:

    • C11 - Mathematical and Quantitative Methods - - Econometric and Statistical Methods and Methodology: General - - - Bayesian Analysis: General
    • C30 - Mathematical and Quantitative Methods - - Multiple or Simultaneous Equation Models; Multiple Variables - - - General
    • C45 - Mathematical and Quantitative Methods - - Econometric and Statistical Methods: Special Topics - - - Neural Networks and Related Topics
    • C53 - Mathematical and Quantitative Methods - - Econometric Modeling - - - Forecasting and Prediction Models; Simulation Methods
    • E3 - Macroeconomics and Monetary Economics - - Prices, Business Fluctuations, and Cycles
    • E44 - Macroeconomics and Monetary Economics - - Money and Interest Rates - - - Financial Markets and the Macroeconomy

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:cpr:ceprdp:19381. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: the person in charge (email available below). General contact details of provider: https://www.cepr.org .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.