Decision Tree for Sentiment Analysis of Facebook Social Media Posts Related to Traffic Congestion in Palembang City

Authors

  • Sukemi Sukemi Universitas Sriwijaya
  • Ahmad Fali Oklilas Universitas Sriwijaya
  • Hatta Efrizal Universitas Sriwijaya

DOI:

https://doi.org/10.30871/jaic.v10i3.12627

Keywords:

Decision Tree, Sentiment Analysis, Traffic Congestion, Facebook Social Media

Abstract

This study aims to analyze public perception of traffic congestion in Palembang City through sentiment analysis on Facebook using the Decision Tree algorithm. Data were collected from public comments related to traffic over 32 months using web scraping techniques. Text data were processed through preprocessing stages including case folding, tokenization, stemming, and stopword removal, followed by TF-IDF feature extraction with unigram representation. The model classifies sentiments into positive, negative, and neutral categories. The results show an accuracy of 90.42%. However, the model tends to perform better on the neutral class, influenced by imbalanced data distribution. Therefore, evaluation metrics such as precision and recall are also considered to provide a more comprehensive analysis.

Downloads

Download data is not yet available.

References

[1] D. Antoni, M. I. Herdiansyah, M. Akbar, and A. Sumitro, “Pengembangan Infrastruktur Jaringan Untuk Meningkatkan Pelayanan Publik di Kota Palembang,” J. Media Inform. Budidarma, vol. 5, no. 4, p. 1652, 2021, doi: 10.30865/mib.v5i4.3318.

[2] Peraturan Pemerintah Republik Indonesia Nomor 30, “Peraturan Pemerintah Republik Indonesia Nomor: 30 Tahun 2O21, Tentang Penyelenggaraan Bidang Lalu Lintas Dan Angkutan Jalan,” LN.2021/No.40, TLN No.6642, jdih.setkab.go.id43 hlm., no. 085113, pp. 1–57, 2021, [Online]. Available: https://peraturan.bpk.go.id/Home/Details/161874/pp-no-30-tahun-2021.

[3] J. J. Van Bavel, C. E. Robertson, K. del Rosario, J. Rasmussen, and S. Rathje, “Social Media and Morality,” Annu. Rev. Psychol., vol. 75, pp. 311–340, 2024, doi: 10.1146/annurev-psych-022123-110258.

[4] F. Bruno, A. Mautone, D. A. Ali, A. Fassima, H. Khabbache, and A. Rizzo, “Evaluating Facebook scales: A systematic review of the psychological assessment tools,” Syst. Rev. Artic. Psychol., vol. 2, no. 3, pp. 142–156, 2025, doi: 10.5281/zenodo.13351015.

[5] A. Nazir, Y. Rao, L. Wu, and L. Sun,“Issues and Challenges of Aspect-based Sentiment Analysis: A Comprehensive Survey,” IEEE Trans. Affect. Comput., vol. 13, no. 2, pp. 845–863, 2022, doi: 10.1109/TAFFC.2020.2970399.

[6] H. M. Sayeed, W. Smallwood, S. G. Baird, and T. D. Sparks, “NLP meets materials science: Quantifying the presentation of materials data in literature,” Matter, vol. 7, no. 3, pp. 723–727, 2024, doi: 10.1016/j.matt.2023.12.032.

[7] Y. Mao, Q. Liu, and Y. Zhang,“Sentiment-analysis-methods, applications, and challenges: A systematic-literature-review,” J. King Saud Univ. Comput. Inf. Sci., vol.36, no.4, p.102048, 2024, doi: 10.1016/j.jksuci.2024.102048.

[8] A. Chamekh, M. Mahfoudh, and G. Forestier,“Sentiment Analysis Based on Deep Learning in E-Commerce,” Lect. Notes Comput. Sci. (including Subser. Lect. Notes Artif. Intell. Lect. Notes Bioinformatics), vol. 13369 LNAI, pp. 498–507, 2022, doi: 10.1007/978-3-031-10986-7_40.

[9] E. Helmud, E. Helmud, F. Fitriyani, and P. Romadiana, “Classification Comparison Performance of Supervised Machine Learning Random Forest and Decision Tree Algorithms Using Confusion Matrix,” J. Sisfokom (Sistem Inf. dan Komputer), vol. 13, no. 1, pp. 92–97, 2024, doi: 10.32736/sisfokom.v13i1.1985.

[10] C.A. Nurhaliza Agustina, R. Novita, Mustakim, and N.E. Rozanda, “The Implementation of TF-IDF and Word2Vec on Booster Vaccine Sentiment Analysis Using Support Vector Machine Algorithm,” Procedia Comput. Sci., vol.234, pp.156–163, 2024, doi: 10.1016/j.procs.2024.02.162.

[11] J. Jin, “Research and construction of student management platform for special needs students with decision tree model and big data technology,” Syst. Soft Comput., vol. 7, no. May, p. 200310, 2025, doi: 10.1016/j.sasc.2025.200310.

[12] R. R. Fajriani et al., “Analisis sentimen pengguna lrt jabodebek di platform x menggunakan algoritma svm,” vol. 8, no. 6, pp. 12446–12453, 2024.

[13] M. A. Brown, A. Gruen, G. Maldoff, S. Messing, Z. Sanderson, and M. Zimmer, “Webscraping for research: legal, ethical, institutionall, and Scientific Considerations,” pp.1–43, 2024, [Online].Available: http://arxiv.org/abs/2410.23432, 2024.

[14] I. Lauriola, A. Lavelli, and F. Aiolli, “An introduction to Deep Learning in Natural Language Processing: Models, techniques, and tools,” Neurocomputing, vol. 470, no. xxxx, pp. 443–456, 2022, doi: 10.1016/j.neucom.2021.05.103.

[15] A. Kurniasih and L. P. Manik, “On the Role of Text Preprocessing in BERT embedding-based DNNs for Classifying Informal Texts,” Int. J. Adv. Comput. Sci. Appl., vol. 13, no. 6, pp. 927–934, 2022, doi: 10.14569/IJACSA.2022.01306109.

[16] N.Wulandari, Y.Cahyana, and H.Handayani, “Sentiment Analysis on the Relocation of the National Capital (IKN) on Social Media X-Using Naive Bayes and K-Nearest Neighbor (KNN) Methods,” vol.9, no.3, pp.724–731, 2025.

[17] M. Heydarian, T. E. Doyle, and R. Samavi, “MLCM: Multi-Label Confusion Matrix,” IEEE Access, vol. 10, pp. 19083–19095, 2022, doi: 10.1109/ACCESS.2022.3151048.

[18] N. Trung Tuyen, N. Thanh Dang, D. Hon Minh, and T. Q. Nguyen, “Enhancing human activity recognition model performance through KMeans-based stratified data splitting,” Meas. Control (United Kingdom), 2025, doi: 10.1177/00202940241312873.

[19]M. Grootendorst, “BERTopic: Neural topic modeling with a class-based TF-IDF procedure,” 2022, [Online]. Available: http://arxiv.org/abs/2203.05794, 2022.

[20] A. Ayashi, A. Pourahmad, H. A. Faraji Sabokbar, S. Zanganeh Shahraki, and F. Carbone, “Introducing an intelligent web scraping (mining) method for analyzing online reviews of Tehran accommodation users,” J. Urban Tour., vol.12, no.1, pp.99–118, 2025, [Online]. Available: http://doi.org/10.22059/JUT.2025.378415.1221

Downloads

Published

2026-06-10

How to Cite

[1]
S. Sukemi, A. F. Oklilas, and H. Efrizal, “Decision Tree for Sentiment Analysis of Facebook Social Media Posts Related to Traffic Congestion in Palembang City”, JAIC, vol. 10, no. 3, pp. 2295–2304, Jun. 2026.

Similar Articles

1 2 3 4 5 > >> 

You may also start an advanced similarity search for this article.