Journal of Human‑Social Nexus

Stock Market Forecasting Using Sentiment Analysis: A Machine Learning and Deep Learning Hybrid Approach

  • aAfrican Institute for Mathematical Sciences (AIMS), Cameroon
  • bDepartment of Audit, College of Accounting Science, University of South Africa, Pretoria, South Africa
  • cJomo Kenyatta University of Agriculture and Technology (JKUAT), Nairobi, Kenya
  • dAfrican Institute for Mathematical Sciences (AIMS), Senegal
* Corresponding author.
Received
10 May 2026
Revised
27 Oct 2026
Accepted
18 Nov 2026
Published online
19 November 2026
Open AccessCC BY 4.0
EARLY VIEW
This article is published online as an early view (Wiley Early View / Elsevier Article in Press). It has been typeset from the accepted manuscript. Author proof corrections may still be in progress; the version of record will replace this page at the same URL and DOI when proof is complete. First published online 19 November 2026. DOI: 10.64939/jhsn.1.3.0014.

Abstract

This study develops a hybrid forecasting system that integrates sentiment analysis, deep learning (DL) and machine learning (ML) to improve the forecasting of stock market indices. We focus on three key indices: the FTSE 100 (United Kingdom), the DAX (Germany) and the S&P 500 (United States). Traditional quantitative market indicators are combined with sentiment indicators derived from financial news headlines collected from Yahoo Finance between January 2020 and June 2023. Sentiment is measured with the FinBERT model and aggregated daily to match the market data. Four hybrid models (LSTM + RF, BiLSTM + RF, CNN + RF and DNN + RF) are developed to combine the temporal sequence learning of deep learning with the non-linear modelling capacity of Random Forest, and their performance is compared with that of the stand-alone models (RF, LSTM, BiLSTM, CNN and DNN). Evaluation with the root mean squared error (RMSE), mean absolute error (MAE), coefficient of determination ( R^2 ) and directional accuracy (DirAcc) shows that the hybrid models perform best: LSTM + RF attains the lowest RMSE of 1.97 and a DirAcc of 0.94 for the DAX with sentiment, compared with an RMSE of 14.59 for the stand-alone LSTM. The hybrid models consistently show low errors, high explanatory power and strong directional accuracy. Sentiment improves performance, particularly for the DAX, but has a limited and model-dependent effect for the FTSE 100 and the S&P 500. Future research will target enhanced sentiment analysis and broader market applications.

Keywords


Author Contributions

Tiapo Lydia Chimbaira: Conceptualization, Investigation, Writing – original draft, Writing – review & editing.

Amos Kipkorir Langat: Conceptualization, Data curation, Methodology, Writing – original draft, Writing – review & editing.

Ranya Hamid Elnour Salim: Investigation, Methodology, Writing – original draft, Writing – review & editing, Resources.

Mirriam Chepleting Sitienei: Data curation, Project administration, Formal analysis, Writing – original draft, Writing – review & editing.

John Kamwele Mutinda: Conceptualization, Supervision, Writing – original draft, Writing – review & editing, Software.

David Chepkonga: Formal analysis, Funding acquisition, Writing – original draft, Writing – review & editing.

Tecla Mutave Tecla Mutave Kyalo: Conceptualization, Data curation, Methodology, Writing – review & editing, Writing – original draft.

Millicent Auma Omondi: Data curation, Investigation, Software, Writing – review & editing, Writing – original draft.

Joyce Akhalakwa Mukolwe: Methodology, Validation, Visualization, Writing – review & editing.


Open Access Statement

Open Access — Published under Creative Commons CC BY 4.0

This article is freely available to read, download, and share. Redistribution and adaptation are permitted provided the original work is appropriately cited and the license terms are followed.