Sentiment analysis for event-based stock price predictions using bidirectional long short term memory

  • Okki Setyawan Universitas Nusa Mandiri
  • Hilman F. Pardede Universitas Nusa Mandiri


The stock market has become an important role in the economy and attracts the attention of investors because it also generates funds and makes investment decisions for companies and investors. The most important thing investors do before investing is to look at information about the capital market in various media, both social media and news portals circulating on the internet to see stock movements that often change due to fluctuations. Sentiment analysis carried out in this study uses a public dataset from the dataset portal at, namely the DJIA (Dow Jones Industrial Average) dataset in the form of events (timeseries) which contains data from a collection of news headlines from as many as 1990 lines of data and has a class label. to go up or down, then trained with deep learning models, namely BiLSTM and LSTM with variations of hyperparameter tuning, and compared with other models including SVM, KNN, Logistic Regression, Naïve Bayes Multinomial. From this research, the best results were obtained with the Deep BiLSTM model with 1 hidden layers, Epoch 20 and batch size 16 resulting in an accuracy score of 0.8677 and F1 score 0.8674 also AUC  0.8671, this study is an improvement from previous research using the LSTM model with an accuracy rate of 0.5212. F1 Score 0.6762 and  AUC 0.6211.


Download data is not yet available.


[1] A. Wulandari, “Perbandingan Klasifikasi Pergerakan Harga Saham Pt. Astra Internasional Tbk Menggunakan Vector Auto Regressive (var) Stasioner Dan Logistic …,” eProceedings Eng., vol. 7, no. 1, pp. 2614–2626, 2020.
[2] B. Beers, “How the News Affects Stock Prices,” 2021.
[3] N. C. C. A. Phitaloka, “Web Content Mining Di Sektor Perbankan Pada Lq45 Untuk Pendukung Keputusan Investasi Saham,” Telematika, vol. 16, no. 1, p. 18, 2019, doi: 10.31315/telematika.v16i1.2989.
[4] M. V. Sukriti Jaitly, “IRJET- Forecasting Stock Market Trends using News Headline Analysis,” Irjet, vol. 8, no. 9, pp. 1141–1144, 2021.
[5] Aaron7sun, “Daily News for Stock Market Prediction,” 2016.
[6] H. F. Fadli, “Identifikasi Cyberbullying pada Media Sosial Twitter Menggunakan Metode LSTM dan BiLSTM,” 2019.
[7] S. Siami-Namini, N. Tavakoli, and A. S. Namin, “The Performance of LSTM and BiLSTM in Forecasting Time Series,” Proc. - 2019 IEEE Int. Conf. Big Data, Big Data 2019, pp. 3285–3292, 2019, doi: 10.1109/BigData47090.2019.9005997.
[8] H. Zheng, H. Wang, and J. Chen, “Evolutionary Framework with Bidirectional Long Short-Term Memory Network for Stock Price Prediction,” Math. Probl. Eng., vol. 2021, 2021, doi: 10.1155/2021/8850600.
[9] A. G. Salman, Y. Heryadi, E. Abdurahman, and W. Suparta, “Single Layer & Multi-layer Long Short-Term Memory (LSTM) Model with Intermediate Variables for Weather Forecasting,” Procedia Comput. Sci., vol. 135, pp. 89–98, 2018, doi: 10.1016/j.procs.2018.08.153.
How to Cite
SETYAWAN, Okki; PARDEDE, Hilman F.. Sentiment analysis for event-based stock price predictions using bidirectional long short term memory. JISICOM (Journal of Information System, Informatics and Computing), [S.l.], v. 6, n. 1, p. 50-58, june 2022. ISSN 2597-3673. Available at: <>. Date accessed: 14 apr. 2024. doi: