DOI QR코드

DOI QR Code

Predicting Stock Prices Based on Online News Content and Technical Indicators by Combinatorial Analysis Using CNN and LSTM with Self-attention

  • Sang Hyung Jung (Business Administration at the School of Business, Hanyang University) ;
  • Gyo Jung Gu (Department of Finance at the School of Business, Hanyang University) ;
  • Dongsung Kim (Business Administration at the School of Business, Hanyang University) ;
  • Jong Woo Kim (School of Business, Hanyang University)
  • 투고 : 2020.03.10
  • 심사 : 2020.08.26
  • 발행 : 2020.12.31

초록

The stock market changes continuously as new information emerges, affecting the judgments of investors. Online news articles are valued as a traditional window to inform investors about various information that affects the stock market. This paper proposed new ways to utilize online news articles with technical indicators. The suggested hybrid model consists of three models. First, a self-attention-based convolutional neural network (CNN) model, considered to be better in interpreting the semantics of long texts, uses news content as inputs. Second, a self-attention-based, bi-long short-term memory (bi-LSTM) neural network model for short texts utilizes news titles as inputs. Third, a bi-LSTM model, considered to be better in analyzing context information and time-series models, uses 19 technical indicators as inputs. We used news articles from the previous day and technical indicators from the past seven days to predict the share price of the next day. An experiment was performed with Korean stock market data and news articles from 33 top companies over three years. Through this experiment, our proposed model showed better performance than previous approaches, which have mainly focused on news titles. This paper demonstrated that news titles and content should be treated in different ways for superior stock price prediction.

키워드

과제정보

This work was supported by Institute of Information & Communications Technology Planning & Evaluation (IITP) grant funded by the Korea government (MSIT) [2016-0-00562(R0124-16-0002), Emotional Intelligence Technology to Infer Human Emotion and Carry on Dialogue Accordingly].

참고문헌

  1. Bank, M., Larch, M., and Peter, G. (2011). Google search volume and its influence on liquidity and returns of German stocks. Financial Markets and Portfolio Management, 25(3), 239.
  2. Bharathi, S., Geetha, A., and Sathiynarayanan, R. (2017). Sentiment analysis of twitter and RSS news feeds and its impact on stock market prediction. International Journal of Intelligent Engineering and Systems, 10(6), 68-77. https://doi.org/10.22266/ijies2017.1231.08
  3. Bollen, J., Mao, H., and Zeng, X. (2010). Twitter mood predicts the stock market. Journal of Computational Science, 2(1), 1-8.
  4. Bruni, R. (2017). Stock market index data and indicators for day trading as a binary classification problem. Data in Brief, 10, 569-575. https://doi.org/10.1016/j.dib.2016.12.044
  5. Chen, K., Zhou, Y., and Dai, F. (2015). A LSTM-based method for stock returns prediction: A case study of China stock market. In 2015 IEEE International Conference on Big Data(Big Data), IEEE, 2823-2824.
  6. Choudhry, R., and Garg, K. (2008). A hybrid machine learning system for stock market forecasting. World Academy of Science, Engineering and Technology, 39(3), 315-318.
  7. Ding, X., Zhang, Y., Liu, T., and Duan, J. (2014). Using structured events to predict stock price movement: An empirical investigation. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing(EMNLP), 1415-1425.
  8. Ding, X., Zhang, Y., Liu, T., and Duan, J. (2015). Deep learning for event-driven stock prediction. In Twenty-Fourth International Joint Conference on Artificial Intelligence, 2327-2333.
  9. Fu, T. C., Lee, K. K., Sze, D., Chung, F. L., and Ng, C. M. (2008). Discovering the correlation between stock time series and financial news. In 2008 IEEE/WIC/ACM International Conference on Web Intelligence and Intelligent Agent Technology, IEEE, 1, 880-883.
  10. Hochreiter, S., and Schmidhuber, J. (1997). Long short-term memory. Neural Computation, 9(8), 1735-1780. https://doi.org/10.1162/neco.1997.9.8.1735
  11. Hsu, C. M. (2011). A hybrid procedure for stock price prediction by integrating self-organizing map and genetic programming. Expert Systems with Applications, 38(11), 14026-14036. https://doi.org/10.1016/j.eswa.2011.04.210
  12. Jeong, J. S., Kim, D. S., and Kim, J. W. (2015). Influence analysis of Internet buzz to corporate performance: Individual stock price prediction using sentiment analysis of online news. Journal of Intelligence and Information Systems, 21(4), 37-51. https://doi.org/10.13088/jiis.2015.21.4.037
  13. Kalchbrenner, N., Grefenstette, E., and Blunsom, P. (2014). A convolutional neural network for modelling sentences. arXiv preprint arXiv:1404.2188.
  14. Kim, Y. (2014). Convolutional neural networks for sentence classification. arXiv preprint arXiv:1408.5882.
  15. LeCun, Y., and Bengio, Y. (1995). Convolutional networks for images, speech, and time series. In The handbook of brain theory and neural networks. MIT Press.
  16. Lee, S. H., and Lim, J. S. (2011). Forecasting KOSPI based on a neural network with weighted fuzzy membership functions. Expert Systems with Applications, 38(4), 4259-4263. https://doi.org/10.1016/j.eswa.2010.09.093
  17. Li, X., Huang, X., Deng, X., and Zhu, S. (2014). Enhancing quantitative intra-day stock return prediction by integrating both market news and stock prices information. Neurocomputing, 142, 228-238. https://doi.org/10.1016/j.neucom.2014.04.043
  18. Li, Z., Yang, D., Zhao, L., Bian, J., Qin, T., and Liu, T. Y. (2019). Individualized indicator for all: Stock-wise technical indicator optimization with stock embedding. In Proceedings of the 25th ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, 894-902.
  19. Lin, Y., Guo, H., and Hu, J. (2013). An SVM-based approach for stock market trend prediction. In The 2013 International Joint Conference on Neural Networks(IJCNN), IEEE, 1-7.
  20. Lin, Z., Feng, M., Santos, C. N. D., Yu, M., Xiang, B., Zhou, B., and Bengio, Y. (2017). A structured self-attentive sentence embedding. arXiv preprint arXiv:1703.03130.
  21. Liu, H. (2018). Leveraging financial news for stock trend prediction with attention-based recurrent neural network. arXiv preprint arXiv:1811.06173.
  22. Malkiel, B. G. (1999). A random walk down Wall Street: Including a life-cycle guide to personal investing. WW Norton and Company.
  23. Mikolov, T., Chen, K., Corrado, G., and Dean, J. (2013). Efficient estimation of word representations in vector space. arXiv preprint arXiv:1301.3781.
  24. Mittal, A., and Goel, A. (2012). Stock prediction using twitter sentiment analysis. Standford University, CS229. Available at: http://cs229.stanford.edu/proj2011/GoelMittal-StockMarketPredictionUsingTwitterSentimentAnalysis.pdf
  25. Mizuno, H., Kosaka, M., Yajima, H., and Komoda, N. (1998). Application of neural network to technical analysis of stock market prediction. Studies in Informatic and Control, 7(3), 111-120.
  26. Nair, B. B., Mohandas, V. P., and Sakthivel, N. R. (2010). A decision tree-rough set hybrid system for stock market trend prediction. International Journal of Computer Applications, 6(9), 1-6. https://doi.org/10.5120/1106-1449
  27. Park, J., Woo, S., Lee, J. Y., and Kweon, I. S. (2018). Bam: Bottleneck attention module. arXiv preprint arXiv:1807.06514.
  28. Patel, J., Shah, S., Thakkar, P., and Kotecha, K. (2015). Predicting stock market index using fusion of machine learning techniques. Expert Systems with Applications, 42(4), 2162-2172. https://doi.org/10.1016/j.eswa.2014.10.031
  29. Ren, G., Hong, T., and Park, Y. (2015). Multi-class SVM+ MTL for the prediction of corporate credit rating with structured data. Asia Pacific Journal of Information Systems, 25(3), 579-596. https://doi.org/10.14329/apjis.2015.25.3.579
  30. Schumaker, R. P., and Chen, H. (2009). A quantitative stock prediction system based on financial news. Information Processing and Management, 45(5), 571-583. https://doi.org/10.1016/j.ipm.2009.05.001
  31. Shah, V. H. (2007). Machine learning techniques for stock prediction. Foundations of Machine Learning|| Spring, 1(1), 6-12.
  32. Shen, S., Jiang, H., and Zhang, T. (2012). Stock market forecasting using machine learning algorithms. Department of Electrical Engineering, Stanford University, Stanford, CA, pp. 1-5.
  33. Shen, T., Zhou, T., Long, G., Jiang, J., Pan, S., and Zhang, C. (2018). Disan: Directional self-attention network for rnn/cnn-free language understanding. In Thirty-Second AAAI Conference on Artificial Intelligence.
  34. Si, J., Mukherjee, A., Liu, B., Li, Q., Li, H., and Deng, X. (2013). Exploiting topic based twitter sentiment for stock prediction. In Proceedings of the 51st Annual Meeting of the Association for Computational Linguistics, 2, 24-29.
  35. Song, Y. (2018). Stock trend prediction: Based on machine learning methods. Diss UCLA.
  36. Sundermeyer, M., Schluter, R., and Ney, H. (2012). LSTM neural networks for language modeling. In Thirteenth Annual Conference of the International Speech Communication Association, 194-197.
  37. Teixeira, L. A., and De Oliveira, A. L. I. (2010). A method for automatic stock trading combining technical analysis and nearest neighbor classification. Expert Systems with Applications, 37(10), 6885-6890. https://doi.org/10.1016/j.eswa.2010.03.033
  38. Vargas, M. R., Dos Anjos, C. E., Bichara, G. L., and Evsukoff, A. G. (2018). Deep learning for stock market prediction using technical indicators and financial news articles. In 2018 International Joint Conference on Neural Networks(IJCNN), IEEE, 1-8.
  39. Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, L., and Polosukhin, I. (2017). Attention is all you need. In Advances in Neural Information Processing Systems, 5998-6008.
  40. Woo, S., Park, J., Lee, J. Y., and Kweon, I. S. (2018). Cbam: Convolutional block attention module. In Proceedings of the European Conference on Computer Vision(ECCV), 3-19.
  41. Yin, W., Kann, K., Yu, M., and Schutze, H. (2017). Comparative study of cnn and rnn for natural language processing. arXiv preprint arXiv:1702.01923.
  42. Yoshihara, A., Fujikawa, K., Seki, K., and Uehara, K. (2014). Predicting stock market trends by recurrent deep neural networks. In Pacific Rim International Conference on Artificial Intelligence, Springer, Cham, 759-769.
  43. Yu, E., Kim, Y., Kim, N., and Jeong, S. R. (2013). Predicting the direction of the stock index by using a domain-specific sentiment dictionary. Journal of Intelligence and Information Systems, 19(1), 95-110. https://doi.org/10.13088/jiis.2013.19.1.095
  44. Yu, H., Chen, R., and Zhang, G. (2014). A SVM stock selection model within PCA. Procedia Computer Science, 31, 406-412. https://doi.org/10.1016/j.procs.2014.05.284
  45. Zhai, Y., Hsu, A., and Halgamuge, S. K. (2007). Combining news and technical indicators in daily stock price trends prediction. In International Symposium on Neural Networks, Springer, Berlin, Heidelberg, 1087-1096.
  46. Zhang, X., Zhao, J., and LeCun, Y. (2015). Character-level convolutional networks for text classification. In Advances in Neural Information Processing Systems, 649-657.
  47. Zhou, C., Sun, C., Liu, Z., and Lau, F. C. M. (2015). A C-LSTM neural network for text classification. arXiv preprint arXiv:1511.08630