Predicting Stock Market Trends Through a Hybrid Machine Learning Framework That Combines Technical Indicators with News Sentiment Analysis
Abstract
This paper proposes a hybrid model based on LSTM(Long Short-Term Memory)and BERT(Bidirectional Encoder Representations from Transformers)for stock market trend prediction, which innovatively integrates the quantitative analysis of technical indicators and qualitative analysis of news sentiment. The framework first utilizes a pre-trained FinBERT model--optimized for financial text processing--to extract fine-grained sentiment features from multi-source financial data, including official earnings reports, mainstream financial news, and social media financial discussions. These sentiment features, together with key technical indicators derived from historical stock price data(such as moving averages, relative strength index, and trading volume), are standardized and concatenated into a comprehensive feature vector, which is then fed into a two-layer LSTM network for capturing temporal dependencies and dynamic sequence prediction. The experimental results, derived from a dataset encompassing 50 top stocks from the S&P 500 over a span of 5 years, show that the proposed hybrid model consistently surpasses single-model methods--such as standalone LSTM, BERT, and traditional ARIMA--in terms of both short-term(1-day ahead)and medium-term(5-day ahead)prediction accuracy, as well as its ability to generalize across various market conditions, including bullish, bearish, and volatile environments. This confirms the significant value of multi-source data fusion in financial forecasting, as it effectively complements the limitations of single data types and enhances the model’s robustness to market noise.
References
- Vargas, M. R., de Lima, B. S., & Evsukoff, A. G. (2018). Deep learning for stock market prediction from financial news articles. 2018 IEEE International Conference on Computational Intelligence and Virtual Environments for Measurement Systems and Applications (CIVEMSA).
- Shah, D., Isah, H., & Zulkernine, F. (2024). A comprehensive analysis of BERT-based models for stock market sentiment analysis and prediction. Expert Systems with Applications, 238, 122066.
- Sohangir, S., Wang, D., Pomeranets, A., & Khoshgoftaar, T. M. (2018). Big Data: Deep Learning for financial sentiment analysis. Journal of Big Data, 5(1), 1-25.
- Zhiyuan Community (2024). Predicting Stock Prices with FinBERT-LSTM: Integrating News Sentiment Analysis. Technical report. From Zhiyuan Community.
- Gupta, S., & Bathla, G. (2024). FinBERT and LSTM-Based Novel Model for Stock Price Prediction Using Technical Indicators and Financial News. International Journal of Economics and Business Research, 28(1), 1–16.
- Hochreiter, S., & Schmidhuber, J. (1997). Long Short-Term Memory. Neural Computation, 9(8), 1735–1780.