DOI QR코드

DOI QR Code

Deep Learning-based Stock Price Prediction Using Limit Order Books and News Headlines

호가창과 뉴스 헤드라인을 이용한 딥러닝 기반 주가 변동 예측 기법

  • Ryoo, Euirim (Department of Big Data Analysis and Convergence, Sookmyung Women's University) ;
  • Lee, Ki Yong (Division of Computer Science, Sookmyung Women's University) ;
  • Chung, Yon Dohn (Department of Computer Science & Engineering, Korea University)
  • Received : 2021.11.15
  • Accepted : 2022.01.06
  • Published : 2022.02.28

Abstract

Recently, various studies have been conducted on stock price prediction using machine learning and deep learning techniques. Among these studies, the latest studies have attempted to predict stock prices using limit order books, which contain buy and sell order information of stocks. However, most of the studies using limit order books consider only the trend of limit order books over the most recent period of a specified length, and few studies consider both the medium and short term trends of limit order books. Therefore, in this paper, we propose a deep learning-based prediction model that predicts stock price more accurately by considering both the medium and short term trends of limit order books. Moreover, the proposed model considers news headlines during the same period to reflect the qualitative status of the company in the stock price prediction. The proposed model extracts the features of changes in limit order books with CNNs and the features of news headlines using Word2vec, and combines these information to predict whether a particular company's stock will rise or fall the next day. We conducted experiments to predict the daily stock price fluctuations of five stocks (Amazon, Apple, Facebook, Google, Tesla) with the proposed model using the real NASDAQ limit order book data and news headline data, and the proposed model improved the accuracy by up to 17.66%p and the average by 14.47%p on average. In addition, we conducted a simulated investment with the proposed model and earned a minimum of $492.46 and a maximum of $2,840.93 depending on the stock for 21 business days.

최근 머신러닝 및 딥러닝 기법을 활용한 주식 가격 예측 연구가 다양하게 이루어지고 있다. 그 중에서도 최근에는 주식 매수 및 매도 주문 정보를 담고 있는 호가창을 이용하여 주가를 예측하려는 연구가 시도되고 있다. 하지만 호가창을 활용한 연구는 대부분 가장 최근 일정 기간 동안의 호가창 추이만을 고려하며, 호가창의 중기 추이와 단기 추이를 같이 고려하는 연구는 거의 진행되지 않았다. 이에 본 논문에서는 호가창의 중기와 단기 추이를 모두 고려하여 주가 등락을 보다 정확히 예측하는 딥러닝 기반 예측 모델을 제안한다. 더욱이 본 논문에서 제안하는 모델은 중단기 호가창 정보 외에도 해당 종목에 대한 동기간 뉴스 헤드라인까지 고려하여 기업의 정성적 상황까지 주가 예측에 반영한다. 본 논문에서 제안하는 딥러닝 기반 예측 모델은 호가창 변화의 특징을 합성곱 신경망으로 추출하고 뉴스 헤드라인의 특징을 Word2vec을 이용하여 추출한 뒤, 이들 정보를 결합하여 특정 기업 주식의 다음 날 등락 여부를 예측한다. 실제 NASDAQ 호가창 데이터와 뉴스 헤드라인 데이터를 사용하여 제안 모델로 5개 종목(Amazon, Apple, Facebook, Google, Tesla)의 일일 주가 등락을 예측한 결과, 제안 모델은 기존 모델에 비해 정확도를 최대 17.66%p, 평균 14.47%p 향상시켰다. 또한 해당 모델로 모의 투자를 수행한 결과, 21 영업일 동안 종목에 따라 최소 $492.46, 최대 $2,840.83의 수익을 얻었다.

Keywords

Acknowledgement

이 성과는 2021년도 정부(과학기술정보통신부)의 재원으로 한국연구재단의 지원을 받아 수행된 연구임(No. NRF-2021R1A2C1012543). 또한, 이 성과는 2021년도 정부(과학기술정보통신부)의 재원으로 한국연구재단의 지원을 받아 수행된 연구임(No. NRF-2019H1D8A2105513).

References

  1. Akita, R., Yoshihara, A., Matsubara, T., and Uehara, K., "Deep learning for stock prediction using numerical and textual information," 2016 IEEE/ACIS 15th International Conference on Computer and Information Science (ICIS), pp. 1-6, 2016.
  2. Bao, W., Yue, J., and Rao, Y., "A deep learning framework for financial time series using stacked autoencoders and longshort term memory," PLOS ONE, Vol. 12, No. 7, 2017.
  3. Kim, M., Ryu, J., Cha, D., and Sim, M. K., "Stock price prediction using sentiment analysis: From 'stock discussion room' in Naver," The Journal of Society for e-Business Studies, Vol. 25, No. 4, pp. 61-75, 2020.
  4. Lavrenko, V., Schmill, M., Lawrie, D., Ogilvie, P., Jensen, D., and Allan, J., "Mining of concurrent text and time series," In KDD-2000 Workshop on Text Mining, pp. 37-44, 2000.
  5. Lee, C. and Soo, V., "Predict Stock Price with Financial News Based on Recurrent Convolutional Neural Networks," 2017 Conference on Technologies and Applications of Artificial Intelligence (TAAI), pp. 160-165, 2017.
  6. Li, X., Xie, H., Chen, L., Wang, J., and Deng, X., "News impact on stock price return via sentiment analysis," Knowledge-Based Systems, Vol. 69, pp. 14-23, 2014.
  7. Nasdaq TotalView-ITCH, https://www.nasdaqtrader.com/Trader.aspx?id=Totalview2.
  8. Peng, Y. and Jiang, H., "Leverage financial news to predict stock price movements using word embeddings and deep neural networks," in Proc. NAACL-HLT. San Diego, CA, USA: Association for Computational Linguistics, pp. 374-379, 2016.
  9. Ryoo, E., Kim, C., and Lee, K. Y., "Deep learning-based stock price prediction using limit order books and News Headlines," Annual Conference of KIPS (ACK) 2021, pp. 541-544, 2021.
  10. Tsantekidis, A., Passalis, N., Tefas, A., Kanniainen, J., Gabbouj, M., and Iosifidis, A., "Using deep learning to detect price change indications in financial markets," 2017 25th European Signal Processing Conference (EUSIPCO), pp. 2511-2515, 2017.
  11. Vargas, M. R., de Lima, B. S. L. P., and Evsukoff, A. G., "Deep learning for stock market prediction from financial news articles," 2017 IEEE International Conference on Computational Intelligence and Virtual Environments for Measurement Systems and Applications (CIVEMSA), pp. 60-65, 2017.
  12. W. Jiang, "Applications of deep learning in stock market prediction: Recent progress," Expert Systems with Applications, Vol. 184, 2021.
  13. Word2vec, https://code.google.com/archive/p/word2vec.
  14. Zhang, Z., Zohren, S., and Roberts, S., "DeepLOB: Deep convolutional neural networks for limit order books," IEEE Transactions on Signal Processing, Vol. 67, No. 11, pp. 3001-3012, 2019. https://doi.org/10.1109/tsp.2019.2907260
  15. Zhou, X., Pan, Z, Hu, G., Tang, S., and Zhao, C., "Stock market prediction on high-frequency data using generative adversarial nets," Mathematical Problems in Engineering, Vol. 2018, Article ID 4907423, 11 pages, 2018.