IDEAS home Printed from https://ideas.repec.org/p/zbw/iwqwdp/032023.html
   My bibliography  Save this paper

Forecasting realized volatility in turbulent times using temporal fusion transformers

Author

Listed:
  • Frank, Johannes

Abstract

This paper analyzes the performance of temporal fusion transformers in forecasting realized volatilities of stocks listed in the S&P 500 in volatile periods by comparing the predictions with those of state-of-the-art machine learning methods as well as GARCH models. The models are trained on weekly and monthly data based on three different feature sets using varying training approaches including pooling methods. I find that temporal fusion transformers show very good results in predicting financial volatility and outperform long short-term memory networks and random forests when using pooling methods. The use of sectoral pooling substantially improves the predictive performance of all machine learning approaches used. The results are robust to different ways of training the models.

Suggested Citation

  • Frank, Johannes, 2023. "Forecasting realized volatility in turbulent times using temporal fusion transformers," FAU Discussion Papers in Economics 03/2023, Friedrich-Alexander University Erlangen-Nuremberg, Institute for Economics.
  • Handle: RePEc:zbw:iwqwdp:032023
    as

    Download full text from publisher

    File URL: https://www.econstor.eu/bitstream/10419/268951/1/1837499578.pdf
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Asger Lunde & Peter R. Hansen, 2005. "A forecast comparison of volatility models: does anything beat a GARCH(1,1)?," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 20(7), pages 873-889.
    2. Andrea Bucci, 2020. "Realized Volatility Forecasting with Neural Networks," Journal of Financial Econometrics, Oxford University Press, vol. 18(3), pages 502-531.
    3. 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.
    4. Engle, Robert F. & Gallo, Giampiero M., 2006. "A multiple indicators model for volatility using intra-daily data," Journal of Econometrics, Elsevier, vol. 131(1-2), pages 3-27.
    5. Charlotte Christiansen & Maik Schmeling & Andreas Schrimpf, 2012. "A comprehensive look at financial volatility prediction by economic variables," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 27(6), pages 956-977, September.
    6. Brenner, Robin J. & Harjes, Richard H. & Kroner, Kenneth F., 1996. "Another Look at Models of the Short-Term Interest Rate," Journal of Financial and Quantitative Analysis, Cambridge University Press, vol. 31(1), pages 85-107, March.
    7. Scott R. Baker & Nicholas Bloom & Steven J. Davis, 2016. "Measuring Economic Policy Uncertainty," The Quarterly Journal of Economics, President and Fellows of Harvard College, vol. 131(4), pages 1593-1636.
    8. Hyndman, Rob J. & Koehler, Anne B., 2006. "Another look at measures of forecast accuracy," International Journal of Forecasting, Elsevier, vol. 22(4), pages 679-688.
    9. R. F. Engle & A. J. Patton, 2001. "What good is a volatility model?," Quantitative Finance, Taylor & Francis Journals, vol. 1(2), pages 237-245.
    10. Bollerslev, Tim, 1986. "Generalized autoregressive conditional heteroskedasticity," Journal of Econometrics, Elsevier, vol. 31(3), pages 307-327, April.
    11. Chuong Luong & Nikolai Dokuchaev, 2018. "Forecasting of Realised Volatility with the Random Forests Algorithm," JRFM, MDPI, vol. 11(4), pages 1-15, October.
    12. Andersen, Torben G. & Bollerslev, Tim & Diebold, Francis X. & Ebens, Heiko, 2001. "The distribution of realized stock return volatility," Journal of Financial Economics, Elsevier, vol. 61(1), pages 43-76, July.
    13. Miguel López Santos & Xela García-Santiago & Fernando Echevarría Camarero & Gonzalo Blázquez Gil & Pablo Carrasco Ortega, 2022. "Application of Temporal Fusion Transformer for Day-Ahead PV Power Forecasting," Energies, MDPI, vol. 15(14), pages 1-22, July.
    14. Imlak Shaikh, 2019. "On the Relationship between Economic Policy Uncertainty and the Implied Volatility Index," Sustainability, MDPI, vol. 11(6), pages 1-11, March.
    15. Lim, Bryan & Arık, Sercan Ö. & Loeff, Nicolas & Pfister, Tomas, 2021. "Temporal Fusion Transformers for interpretable multi-horizon time series forecasting," International Journal of Forecasting, Elsevier, vol. 37(4), pages 1748-1764.
    16. Schnaubelt, Matthias & Fischer, Thomas G. & Krauss, Christopher, 2020. "Separating the signal from the noise – Financial machine learning for Twitter," Journal of Economic Dynamics and Control, Elsevier, vol. 114(C).
    17. Engle, Robert F, 1982. "Autoregressive Conditional Heteroscedasticity with Estimates of the Variance of United Kingdom Inflation," Econometrica, Econometric Society, vol. 50(4), pages 987-1007, July.
    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. Xue Gong & Weiguo Zhang & Yuan Zhao & Xin Ye, 2023. "Forecasting stock volatility with a large set of predictors: A new forecast combination method," Journal of Forecasting, John Wiley & Sons, Ltd., vol. 42(7), pages 1622-1647, November.
    2. Kim Christensen & Mathias Siggaard & Bezirgen Veliyev, 2021. "A machine learning approach to volatility forecasting," CREATES Research Papers 2021-03, Department of Economics and Business Economics, Aarhus University.
    3. Andrea BUCCI, 2017. "Forecasting Realized Volatility A Review," Journal of Advanced Studies in Finance, ASERS Publishing, vol. 8(2), pages 94-138.
    4. Torben G. Andersen & Tim Bollerslev & Peter F. Christoffersen & Francis X. Diebold, 2005. "Volatility Forecasting," PIER Working Paper Archive 05-011, Penn Institute for Economic Research, Department of Economics, University of Pennsylvania.
    5. Andersen, Torben G. & Bollerslev, Tim & Christoffersen, Peter F. & Diebold, Francis X., 2006. "Volatility and Correlation Forecasting," Handbook of Economic Forecasting, in: G. Elliott & C. Granger & A. Timmermann (ed.), Handbook of Economic Forecasting, edition 1, volume 1, chapter 15, pages 777-878, Elsevier.
    6. Chao Zhang & Yihuang Zhang & Mihai Cucuringu & Zhongmin Qian, 2022. "Volatility forecasting with machine learning and intraday commonality," Papers 2202.08962, arXiv.org, revised Feb 2023.
    7. Andrea Bucci, 2020. "Realized Volatility Forecasting with Neural Networks," Journal of Financial Econometrics, Oxford University Press, vol. 18(3), pages 502-531.
    8. Mittnik, Stefan & Robinzonov, Nikolay & Spindler, Martin, 2015. "Stock market volatility: Identifying major drivers and the nature of their impact," Journal of Banking & Finance, Elsevier, vol. 58(C), pages 1-14.
    9. Koopman, Siem Jan & Jungbacker, Borus & Hol, Eugenie, 2005. "Forecasting daily variability of the S&P 100 stock index using historical, realised and implied volatility measurements," Journal of Empirical Finance, Elsevier, vol. 12(3), pages 445-475, June.
    10. Wei, Yu & Wang, Peng, 2008. "Forecasting volatility of SSEC in Chinese stock market using multifractal analysis," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 387(7), pages 1585-1592.
    11. Nikita Medvedev & Zhiguang Wang, 2022. "Multistep forecast of the implied volatility surface using deep learning," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 42(4), pages 645-667, April.
    12. Christian T. Brownlees & Giampiero Gallo, 2007. "Volatility Forecasting Using Explanatory Variables and Focused Selection Criteria," Econometrics Working Papers Archive wp2007_04, Universita' degli Studi di Firenze, Dipartimento di Statistica, Informatica, Applicazioni "G. Parenti".
    13. McAleer, Michael & Medeiros, Marcelo C., 2008. "A multiple regime smooth transition Heterogeneous Autoregressive model for long memory and asymmetries," Journal of Econometrics, Elsevier, vol. 147(1), pages 104-119, November.
    14. Turan Bali, 2007. "Modeling the dynamics of interest rate volatility with skewed fat-tailed distributions," Annals of Operations Research, Springer, vol. 151(1), pages 151-178, April.
    15. Neil Shephard & Kevin Sheppard, 2010. "Realising the future: forecasting with high-frequency-based volatility (HEAVY) models," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 25(2), pages 197-231.
    16. Wei, Yu, 2012. "Forecasting volatility of fuel oil futures in China: GARCH-type, SV or realized volatility models?," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 391(22), pages 5546-5556.
    17. H. J. Turtle & Kainan Wang, 2014. "Modeling Conditional Covariances With Economic Information Instruments," Journal of Business & Economic Statistics, Taylor & Francis Journals, vol. 32(2), pages 217-236, April.
    18. Wang, Chengyang & Nishiyama, Yoshihiko, 2015. "Volatility forecast of stock indices by model averaging using high-frequency data," International Review of Economics & Finance, Elsevier, vol. 40(C), pages 324-337.
    19. Wang Pu & Yixiang Chen & Feng Ma, 2016. "Forecasting the realized volatility in the Chinese stock market: further evidence," Applied Economics, Taylor & Francis Journals, vol. 48(33), pages 3116-3130, July.
    20. Ma, Feng & Wei, Yu & Huang, Dengshi & Chen, Yixiang, 2014. "Which is the better forecasting model? A comparison between HAR-RV and multifractality volatility," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 405(C), pages 171-180.

    More about this item

    Keywords

    Realized volatility; temporal fusion transformer; long short-term memory network; random forest;
    All these keywords.

    JEL classification:

    • 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
    • C58 - Mathematical and Quantitative Methods - - Econometric Modeling - - - Financial Econometrics
    • E44 - Macroeconomics and Monetary Economics - - Money and Interest Rates - - - Financial Markets and the Macroeconomy

    NEP fields

    This paper has been announced in the following NEP Reports:

    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:zbw:iwqwdp:032023. 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: ZBW - Leibniz Information Centre for Economics (email available below). General contact details of provider: https://edirc.repec.org/data/vierlde.html .

    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.