IDEAS home Printed from https://ideas.repec.org/a/rjr/romjef/vy2021i2p22-34.html
   My bibliography  Save this article

Forecasting Stock Market Dynamics using Bidirectional Long Short-Term Memory

Author

Listed:
  • Daehyeon PARK

    (College of Economics, Sungkyunkwan University, Seoul, Republic of Korea)

  • Doojin RYU

    (College of Economics, Sungkyunkwan University, Seoul, Republic of Korea)

Abstract

This study forecasts stock market dynamics using machine learning techniques. Specifically, we use long short-term memory (LSTM) and bidirectional LSTM (Bi-LSTM) networks to predict the spot index return and implied volatility series in the Korean market. The Bi-LSTM model exhibits better out-of-sample forecasting performance than the LSTM and classic autoregressive models do, reflecting the fact that the Bi-LSTM model learns data patterns more accurately through a bidirectional process. The Bi-LSTM model with the longest time lag (i.e., 22 days) exhibits the best performance in predicting returns and volatility over the entire sample period. In contrast, during the global financial crisis and COVID-19 pandemic periods, when the stock market dynamics are unstable, Bi-LSTM models with shorter time lags (i.e., five or ten days) predict volatility more accurately.

Suggested Citation

  • Daehyeon PARK & Doojin RYU, 2021. "Forecasting Stock Market Dynamics using Bidirectional Long Short-Term Memory," Journal for Economic Forecasting, Institute for Economic Forecasting, vol. 0(2), pages 22-34, June.
  • Handle: RePEc:rjr:romjef:v::y:2021:i:2:p:22-34
    as

    Download full text from publisher

    File URL: http://www.ipe.ro/rjef/rjef2_21/rjef2_2021p22-34.pdf
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Jieun Lee & Doojin Ryu, 2019. "The impacts of public news announcements on intraday implied volatility dynamics," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 39(6), pages 656-685, June.
    2. Eunsun Yang & Sunghyun Henry Kim & Maria H Kim & Doojin Ryu, 2018. "Macroeconomic shocks and stock market returns: the case of Korea," Applied Economics, Taylor & Francis Journals, vol. 50(7), pages 757-773, February.
    3. Lee, Jaeram & Kang, Jangkoo & Ryu, Doojin, 2015. "Common deviation and regime-dependent dynamics in the index derivatives markets," Pacific-Basin Finance Journal, Elsevier, vol. 33(C), pages 1-22.
    4. Hyein Shim & Hyeyoen Kim & Sunghyun Kim & Doojin Ryu, 2016. "Testing the relative purchasing power parity hypothesis: the case of Korea," Applied Economics, Taylor & Francis Journals, vol. 48(25), pages 2383-2395, May.
    5. Doowon Ryu & Doojin Ryu & Joon Ho Hwang, 2017. "Corporate governance, product-market competition, and stock returns: evidence from the Korean market," Asian Business & Management, Palgrave Macmillan, vol. 16(1), pages 50-91, April.
    6. Myounghwa Sim & Doojin Ryu & Heejin Yang, 2016. "Tests on the Monotonicity Properties of KOSPI 200 Options Prices," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 36(7), pages 625-646, July.
    7. Park, Seongkyu Gilbert & Ryu, Doojin, 2019. "Speed and trading behavior in an order-driven market," Pacific-Basin Finance Journal, Elsevier, vol. 53(C), pages 145-164.
    8. Doojin Ryu & Jinyoung Yu, 2021. "Informed options trading around holidays," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 41(5), pages 658-685, May.
    9. Park, Sung Y. & Ryu, Doojin & Song, Jeongseok, 2017. "The dynamic conditional relationship between stock market returns and implied volatility," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 482(C), pages 638-648.
    10. Cao, Jian & Li, Zhi & Li, Jian, 2019. "Financial time series forecasting model based on CEEMDAN and LSTM," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 519(C), pages 127-139.
    11. Doojin RYU & Hyein SHIM, 2017. "Intraday Dynamics of Asset Returns, Trading Activities, and Implied Volatilities: A Trivariate GARCH Framework," Journal for Economic Forecasting, Institute for Economic Forecasting, vol. 0(2), pages 45-61, June.
    12. Han, Heejoon & Kutan, Ali M. & Ryu, Doojin, 2015. "Effects of the US stock market return and volatility on the VKOSPI," Economics - The Open-Access, Open-Assessment E-Journal (2007-2020), Kiel Institute for the World Economy (IfW Kiel), vol. 9, pages 1-34.
    13. Doojin Ryu & Doowon Ryu & Heejin Yang, 2021. "The impact of net buying pressure on index options prices," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 41(1), pages 27-45, January.
    14. Hee‐Joon Ahn & Jangkoo Kang & Doojin Ryu, 2008. "Informed trading in the index option market: The case of KOSPI 200 options," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 28(12), pages 1118-1146, December.
    15. Hyeongjun Kim & Hoon Cho & Doojin Ryu, 2020. "Corporate Default Predictions Using Machine Learning: Literature Review," Sustainability, MDPI, vol. 12(16), pages 1-11, August.
    16. Wonho Song & Doojin Ryu & Robert I. Webb, 2018. "Volatility dynamics under an endogenous Markov-switching framework: a cross-market approach," Quantitative Finance, Taylor & Francis Journals, vol. 18(9), pages 1559-1571, September.
    17. Dohyun CHUN & Hoon CHO & Doojin RYU, 2018. "Macroeconomic Structural Changes in a Leading Emerging Market: The Effects of the Asian Financial Crisis," Journal for Economic Forecasting, Institute for Economic Forecasting, vol. 0(2), pages 22-42, December.
    18. Yu-Long Zhou & Ren-Jie Han & Qian Xu & Wei-Ke Zhang, 2018. "Long Short-Term Memory Networks for CSI300 Volatility Prediction with Baidu Search Volume," Papers 1805.11954, arXiv.org.
    19. Song, Wonho & Ryu, Doojin & Webb, Robert I., 2016. "Overseas market shocks and VKOSPI dynamics: A Markov-switching approach," Finance Research Letters, Elsevier, vol. 16(C), pages 275-282.
    20. Heejin Yang & Ali M. Kutan & Doojin Ryu, 2018. "Option moneyness and price disagreements," Applied Economics Letters, Taylor & Francis Journals, vol. 25(3), pages 192-196, February.
    21. Doojin Ryu & Heejin Yang, 2018. "The directional information content of options volumes," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 38(12), pages 1533-1548, December.
    22. Karam KIM & Doojin RYU, 2020. "Predictive ability of investor sentiment for the stock market," Journal for Economic Forecasting, Institute for Economic Forecasting, vol. 0(4), pages 33-46, December.
    23. Hyein Shim & Maria H. Kim & Doojin Ryu, 2017. "Effects of intraday weather changes on asset returns and volatilities," Zbornik radova Ekonomskog fakulteta u Rijeci/Proceedings of Rijeka Faculty of Economics, University of Rijeka, Faculty of Economics and Business, vol. 35(2), pages 301-330.
    24. Fischer, Thomas & Krauss, Christopher, 2018. "Deep learning with long short-term memory networks for financial market predictions," European Journal of Operational Research, Elsevier, vol. 270(2), pages 654-669.
    25. Yang, Heejin & Ahn, Hee-Joon & Kim, Maria H. & Ryu, Doojin, 2017. "Information asymmetry and investor trading behavior around bond rating change announcements," Emerging Markets Review, Elsevier, vol. 32(C), pages 38-51.
    26. Ryu, Doojin, 2013. "What types of investors generate the two-phase phenomenon?," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 392(23), pages 5939-5946.
    27. Song, Joonhyuk & Ryu, Doojin, 2016. "Credit cycle and balancing the capital gap: Evidence from Korea," Economic Systems, Elsevier, vol. 40(4), pages 595-611.
    28. Song, Wonho & Park, Sung Y. & Ryu, Doojin, 2018. "Dynamic conditional relationships between developed and emerging markets," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 507(C), pages 534-543.
    29. Ryu, Doojin & Yang, Heejin, 2019. "Who has volatility information in the index options market?," Finance Research Letters, Elsevier, vol. 30(C), pages 266-270.
    30. Yang, Heejin & Kutan, Ali M. & Ryu, Doojin, 2019. "Volatility information trading in the index options market: An intraday analysis," International Review of Economics & Finance, Elsevier, vol. 64(C), pages 412-426.
    31. Chung, Kee H. & Park, Seongkyu “Gilbert” & Ryu, Doojin, 2016. "Trade duration, informed trading, and option moneyness," International Review of Economics & Finance, Elsevier, vol. 44(C), pages 395-411.
    32. Omer Berat Sezer & Mehmet Ugur Gudelek & Ahmet Murat Ozbayoglu, 2019. "Financial Time Series Forecasting with Deep Learning : A Systematic Literature Review: 2005-2019," Papers 1911.13288, arXiv.org.
    33. Ryu, Doojin & Yu, Jinyoung, 2020. "Hybrid bond issuances by insurance firms," Emerging Markets Review, Elsevier, vol. 45(C).
    34. Heejin Yang & Hyung‐Suk Choi & Doojin Ryu, 2017. "Option Market Characteristics and Price Monotonicity Violations," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 37(5), pages 473-498, May.
    35. Doojin Ryu, 2011. "Intraday price formation and bid–ask spread components: A new approach using a cross‐market model," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 31(12), pages 1142-1169, December.
    36. Doojin Ryu & Heejin Yang, 2020. "Noise traders, mispricing, and price adjustments in derivatives markets," The European Journal of Finance, Taylor & Francis Journals, vol. 26(6), pages 480-499, April.
    37. Heejin Yang & Doojin Ryu & Doowon Ryu, 2018. "Market Reform and Efficiency: The Case of KOSPI200 Options," Emerging Markets Finance and Trade, Taylor & Francis Journals, vol. 54(12), pages 2687-2697, September.
    38. Hyein Shim & Hyeyoen Kim & Junyeup Kim & Doojin Ryu, 2015. "Weather and stock market volatility: the case of a leading emerging market," Applied Economics Letters, Taylor & Francis Journals, vol. 22(12), pages 987-992, August.
    39. Kim, Karam & Ryu, Doojin & Yu, Jinyoung, 2021. "Do sentiment trades explain investor overconfidence around analyst recommendation revisions?," Research in International Business and Finance, Elsevier, vol. 56(C).
    40. Lee, Jaeram & Ryu, Doojin & Yang, Heejin, 2021. "Does vega-neutral options trading contain information?," Journal of Empirical Finance, Elsevier, vol. 62(C), pages 294-314.
    41. Heejin Yang & Jaeram Lee & Doojin Ryu, 2018. "Market depth, domestic investors and price monotonicity violations," Applied Economics Letters, Taylor & Francis Journals, vol. 25(10), pages 688-692, June.
    42. Lee, Jaeram & Lee, Geul & Ryu, Doojin, 2019. "The difference in the intraday return-volume relationships of spot and futures: A quantile regression approach," Economics - The Open-Access, Open-Assessment E-Journal (2007-2020), Kiel Institute for the World Economy (IfW Kiel), vol. 13, pages 1-38.
    43. Jinyoung Yu & Doojin Ryu, 2021. "Effectiveness Of The Basel Iii Framework: Procyclicality In The Banking Sector And Macroeconomic Fluctuations," The Singapore Economic Review (SER), World Scientific Publishing Co. Pte. Ltd., vol. 66(03), pages 855-879, June.
    44. Chun, Dohyun & Cho, Hoon & Ryu, Doojin, 2020. "Economic indicators and stock market volatility in an emerging economy," Economic Systems, Elsevier, vol. 44(2).
    45. Chun, Dohyun & Cho, Hoon & Ryu, Doojin, 2019. "Forecasting the KOSPI200 spot volatility using various volatility measures," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 514(C), pages 156-166.
    Full references (including those not matched with items on IDEAS)

    Citations

    Citations are extracted by the CitEc Project, subscribe to its RSS feed for this item.
    as


    Cited by:

    1. Radu LUPU & Iulia LUPU & Tanase STAMULE & Mihai ROMAN, 2022. "Entropy as Leading Indicator for Extreme Systemic Risk Events," Journal for Economic Forecasting, Institute for Economic Forecasting, vol. 0(4), pages 58-73, December.

    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. Chun, Dohyun & Cho, Hoon & Ryu, Doojin, 2020. "Economic indicators and stock market volatility in an emerging economy," Economic Systems, Elsevier, vol. 44(2).
    2. Doojin Ryu & Jinyoung Yu, 2021. "Informed options trading around holidays," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 41(5), pages 658-685, May.
    3. Doojin Ryu & Doowon Ryu & Heejin Yang, 2021. "The impact of net buying pressure on index options prices," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 41(1), pages 27-45, January.
    4. Daehyeon Park & Jiyeon Park & Doojin Ryu, 2020. "Volatility Spillovers between Equity and Green Bond Markets," Sustainability, MDPI, vol. 12(9), pages 1-12, May.
    5. Lee, Jaeram & Ryu, Doojin & Yang, Heejin, 2021. "Does vega-neutral options trading contain information?," Journal of Empirical Finance, Elsevier, vol. 62(C), pages 294-314.
    6. Chun, Dohyun & Cho, Hoon & Ryu, Doojin, 2019. "Forecasting the KOSPI200 spot volatility using various volatility measures," Physica A: Statistical Mechanics and its Applications, Elsevier, vol. 514(C), pages 156-166.
    7. Yang, Heejin & Kutan, Ali M. & Ryu, Doojin, 2019. "Volatility information trading in the index options market: An intraday analysis," International Review of Economics & Finance, Elsevier, vol. 64(C), pages 412-426.
    8. Lee, Jieun & Ryu, Doojin, 2019. "How does FX liquidity affect the relationship between foreign ownership and stock liquidity?," Emerging Markets Review, Elsevier, vol. 39(C), pages 101-119.
    9. Jieun Lee & Doojin Ryu, 2019. "The impacts of public news announcements on intraday implied volatility dynamics," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 39(6), pages 656-685, June.
    10. Joonhyuk Song & Doojin Ryu & Jinyoung Yu, 2023. "Changes in the options contract size and arbitrage opportunities," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 43(1), pages 122-137, January.
    11. Xingguo Luo & Wenye Cai & Doojin Ryu, 2022. "Information contents of intraday SSE 50 ETF options trades," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 42(4), pages 580-604, April.
    12. Doojin Ryu & Robert I. Webb & Jinyoung Yu, 2023. "Who pays the liquidity cost? Central bank announcements and adverse selection," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 43(7), pages 904-924, July.
    13. Doojin Ryu & Jinyoung Yu, 2022. "Sentiment‐dependent impact of funding liquidity shocks on futures market liquidity," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 42(1), pages 61-76, January.
    14. Jung Park, Yuen & Kutan, Ali M. & Ryu, Doojin, 2019. "The impacts of overseas market shocks on the CDS-option basis," The North American Journal of Economics and Finance, Elsevier, vol. 47(C), pages 622-636.
    15. Lee, Jaeram & Lee, Geul & Ryu, Doojin, 2018. "Difference in the intraday return-volume relationships of spots and futures: A quantile regression approach," Economics Discussion Papers 2018-68, Kiel Institute for the World Economy (IfW Kiel).
    16. Karam KIM & Doojin RYU, 2020. "Predictive ability of investor sentiment for the stock market," Journal for Economic Forecasting, Institute for Economic Forecasting, vol. 0(4), pages 33-46, December.
    17. Sang Ik Seok & Hoon Cho & Chanhi Park & Doojin Ryu, 2019. "Do Overnight Returns Truly Measure Firm-Specific Investor Sentiment in the KOSPI Market?," Sustainability, MDPI, vol. 11(13), pages 1-14, July.
    18. Dohyun CHUN & Hoon CHO & Doojin RYU, 2018. "Macroeconomic Structural Changes in a Leading Emerging Market: The Effects of the Asian Financial Crisis," Journal for Economic Forecasting, Institute for Economic Forecasting, vol. 0(2), pages 22-42, December.
    19. Doojin Ryu & Heejin Yang, 2018. "The directional information content of options volumes," Journal of Futures Markets, John Wiley & Sons, Ltd., vol. 38(12), pages 1533-1548, December.
    20. Hyein Shim & Maria H. Kim & Doojin Ryu, 2017. "Effects of intraday weather changes on asset returns and volatilities," Zbornik radova Ekonomskog fakulteta u Rijeci/Proceedings of Rijeka Faculty of Economics, University of Rijeka, Faculty of Economics and Business, vol. 35(2), pages 301-330.

    More about this item

    Keywords

    Bidirectional long short-term memory; Forecasting; Machine learning; Implied volatility; Stock return;
    All these keywords.

    JEL classification:

    • C14 - Mathematical and Quantitative Methods - - Econometric and Statistical Methods and Methodology: General - - - Semiparametric and Nonparametric Methods: General
    • C45 - Mathematical and Quantitative Methods - - Econometric and Statistical Methods: Special Topics - - - Neural Networks and Related Topics
    • G17 - Financial Economics - - General Financial Markets - - - Financial Forecasting and Simulation

    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:rjr:romjef:v::y:2021:i:2:p:22-34. 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: Corina Saman (email available below). General contact details of provider: https://edirc.repec.org/data/ipacaro.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.