Abstract
News sentiment is attracting considerable interest in stock market prediction, given its crucial role in shaping stock prices. Previous research has mainly focused on improving prediction accuracy by exploiting news sentiment, without adequately considering the different levels of attention that individual news articles receive. Furthermore, despite the advanced predictive capabilities of deep learning models, there has been a lack of focus on the interpretability of these models, leading to predictions that are not transparent. This study presents an innovative prediction model that integrates a FinBERT-based analysis of news sentiment and investor attention metrics with an attention-based Temporal Fusion Transformer framework. This approach not only enables highly effective forecasting, but also provides insights into the temporal dynamics that influence the stock market. The effectiveness of the model is demonstrated by analyzing stock price data for 41 of the largest market capitalization companies over the period 2010 to 2021. The results confirm the superiority of the proposed model over existing deep learning approaches, and the attention analysis underscores the critical role of synthesizing news sentiment and attention metrics in predicting stock prices.
Supported by the scientific research project of the Czech Science Foundation Grant No: 22-22586S.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Similar content being viewed by others
References
Allen, D.E., McAleer, M., Singh, A.K.: Daily market news sentiment and stock prices. Appl. Econ. 51(30), 3212–3235 (2019)
Lu, W., Li, J., Wang, J., Qin, L.: A CNN-BiLSTM-AM method for stock price prediction. Neural Comput. Appl. 33, 4741–4753 (2021)
Li, X., Wu, P., Wang, W.: Incorporating stock prices and news sentiments for stock market prediction: a case of Hong Kong. Inf. Process. Manag. 57(5), 102212 (2020)
Sahut, J.M., Hajek, P., Olej, V., Hikkerova, L.: The role of news-based sentiment in forecasting crude oil price during the COVID-19 pandemic. Ann. Oper. Res., 1–24 (2024)
Hajek, P., Novotny, J., Kovarnik, J.: Predicting exchange rate with FinBERT-based sentiment analysis of online news. In: Proceedings of the 2022 6th International Conference on E-Business and Internet, pp. 133–138 (2022)
Hajek, P., Henriques, R.: Predicting M&A targets using news sentiment and topic detection. Technol. Forecast. Soc. Chang. 201, 123270 (2024)
Araci, D.: Finbert: financial sentiment analysis with pre-trained language models. arXiv:1908.10063 (2019)
Mohan, S., Mullapudi, S., Sammeta, S., Vijayvergia, P., Anastasiu, D.C.: Stock price prediction using news sentiment analysis. In: Proceedings of the IEEE 5th International Conference on Big Data Computing Service and Applications (BigDataService), pp. 205–208 (2019)
Nemes, L., Kiss, A.: Prediction of stock values changes using sentiment analysis of stock news headlines. J. Inf. Telecommun. 5(3), 375–394 (2021)
Audrino, F., Sigrist, F., Ballinari, D.: The impact of sentiment and attention measures on stock market volatility. Int. J. Forecast. 36(2), 334–357 (2020)
Yang, D., Ma, T., Wang, Y., Wang, G.: Does investor attention affect stock trading and returns? Evidence from publicly listed firms in China. J. Behav. Financ. 22(4), 368–381 (2021)
Lim, B., Arık, S.Ö., Loeff, N., Pfister, T.: Temporal fusion transformers for interpretable multi-horizon time series forecasting. Int. J. Forecast. 37(4), 1748–1764 (2021)
Schumaker, R.P., Zhang, Y., Huang, C.N., Chen, H.: Evaluating sentiment in financial news articles. Decis. Support Syst. 53(3), 458–464 (2012)
Li, X., Xie, H., Chen, L., Wang, J., Deng, X.: News impact on stock price return via sentiment analysis. Knowl.-Based Syst. 69, 14–23 (2014)
Costola, M., Hinz, O., Nofer, M., Pelizzon, L.: Machine learning sentiment analysis, COVID-19 news and stock market reactions. Res. Int. Bus. Financ. 64, 101881 (2023)
Xu, Y., Liang, C., Li, Y., Huynh, T.L.: News sentiment and stock return: evidence from managers’ news coverages. Financ. Res. Lett. 48, 102959 (2022)
Hung, M.C., Hsia, P.H., Kuang, X.J., Lin, S.K.: Intelligent portfolio construction via news sentiment analysis. Int. Rev. Econ. Financ. 89, 605–617 (2024)
Sharaf, M., Hemdan, E.E.D., El-Sayed, A., El-Bahnasawy, N.A.: An efficient hybrid stock trend prediction system during COVID-19 pandemic based on stacked-LSTM and news sentiment analysis. Multimedia Tools Appl. 82(16), 23945–23977 (2023)
Ray, P., Ganguli, B., Chakrabarti, A.: A hybrid approach of Bayesian structural time series with LSTM to identify the influence of news sentiment on short-term forecasting of stock price. IEEE Trans. Comput. Soc. Syst. 8(5), 1153–1162 (2021)
Jin, Z., Yang, Y., Liu, Y.: Stock closing price prediction based on sentiment analysis and LSTM. Neural Comput. Appl. 32, 9713–9729 (2020)
Li, Q., Tan, J., Wang, J., Chen, H.: A multimodal event-driven LSTM model for stock prediction using online news. IEEE Trans. Knowl. Data Eng. 33(10), 3323–3337 (2020)
Shapiro, A.H., Sudhof, M., Wilson, D.J.: Measuring news sentiment. J. Econometr. 228(2), 221–243 (2022)
Hajek, P.: Combining bag-of-words and sentiment features of annual reports to predict abnormal stock returns. Neural Comput. Appl. 29, 343–358 (2018)
Hajek, P., Barushka, A.: Integrating sentiment analysis and topic detection in financial news for stock movement prediction. In: Proceedings of the 2nd International Conference on Business and Information Management, pp. 158–162 (2018)
Shah, D., Isah, H., Zulkernine, F.: Predicting the effects of news sentiments on the stock market. In: 2018 IEEE International Conference on Big Data (Big Data), pp. 4705–4708 (2018)
Li, Q., Wang, T., Li, P., Liu, L., Gong, Q., Chen, Y.: The effect of news and public mood on stock movements. Inf. Sci. 278, 826–840 (2014)
Han, Y., Tian, Y., Yu, L., Gao, Y.: Economic system forecasting based on temporal fusion transformers: multi-dimensional evaluation and cross-model comparative analysis. Neurocomputing 552, 126500 (2023)
Bouteska, A., Hajek, P., Abedin, M.Z., Dong, Y.: Effect of Twitter investor engagement on cryptocurrencies during the COVID-19 pandemic. Res. Int. Bus. Financ. 64, 101850 (2023)
Chen, Y., Hao, Y.: A feature weighted support vector machine and K-nearest neighbor algorithm for stock market indices prediction. Expert Syst. Appl. 80, 340–355 (2017)
Gupta, U., Bhattacharjee, V., Bishnu, P.S.: StockNet-GRU based stock index prediction. Expert Syst. Appl. 207, 117986 (2022)
Farimani, S.A., Jahan, M.V., Fard, A.M., Tabbakh, S.R.K.: Investigating the informativeness of technical indicators and news sentiment in financial market price prediction. Knowl.-Based Syst. 247, 108742 (2022)
Zhang, C.X., Li, J., Huang, X.F., Zhang, J.S., Huang, H.C.: Forecasting stock volatility and value-at-risk based on temporal convolutional networks. Expert Syst. Appl. 207, 117951 (2022)
Khan, W., Ghazanfar, M.A., Azam, M.A., Karami, A., Alyoubi, K.H., Alfakeeh, A.S.: Stock market prediction using machine learning classifiers and social media, news. J. Ambient. Intell. Humaniz. Comput. 13, 3433–3456 (2022)
Hajek, P., Novotny, J.: Fuzzy rule-based prediction of gold prices using news affect. Expert Syst. Appl. 193, 116487 (2022)
Fatouros, G., Soldatos, J., Kouroumali, K., Makridis, G., Kyriazis, D.: Transforming sentiment analysis in the financial domain with ChatGPT. Mach. Learn. Appl. 14, 100508 (2023)
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2024 IFIP International Federation for Information Processing
About this paper
Cite this paper
Hajek, P., Novotny, J. (2024). Beyond Sentiment in Stock Price Prediction: Integrating News Sentiment and Investor Attention with Temporal Fusion Transformer. In: Maglogiannis, I., Iliadis, L., Macintyre, J., Avlonitis, M., Papaleonidas, A. (eds) Artificial Intelligence Applications and Innovations. AIAI 2024. IFIP Advances in Information and Communication Technology, vol 713. Springer, Cham. https://doi.org/10.1007/978-3-031-63219-8_3
Download citation
DOI: https://doi.org/10.1007/978-3-031-63219-8_3
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-63218-1
Online ISBN: 978-3-031-63219-8
eBook Packages: Computer ScienceComputer Science (R0)