Twitter Sentiment Towards 2024 Jakarta Governor Candidates With Naïve Bayes Algorithm
DOI:
10.47709/cnahpc.v7i1.5358Keywords:
Sentiment Analysis, Twitter, Naïve Bayes Algorithm, Jakarta Governor Election 2024, Public Sentiment, Social Media, Text ClassificationDimension Badge Record
Abstract
This study aims to analyze public sentiment towards candidates for the 2024 Governor of DKI Jakarta through the Twitter platform, with a focus on classifying positive and negative sentiment. Along with the rapid development of social media, Twitter has become the main channel for people to voice political opinions. Sentiment analysis was conducted using the Naive Bayes algorithm to classify the sentiment of tweets collected through crawling techniques during the campaign period. The data used includes user tweets, with features such as frequently occurring words, popular hashtags, and discussion topics related to each gubernatorial candidate. The results showed that the Naive Bayes algorithm provided the best performance in classifying sentiment data in the period August 1 to December 26, 2024, with the highest accuracy rate reaching 75% at a data ratio of 90:10. This research also identified challenges in sentiment classification, such as the presence of new terms in test documents that are not recognized by the training model. The findings are expected to provide a clearer picture of public perceptions of gubernatorial candidates and contribute to the analysis of political sentiment on social media
Downloads
Abstract viewed = 35 times
References
Abidin, Z. (2024). Text Stemming and Lemmatization of Regional Languages in Indonesia: A Systematic Literature Review. Journal of Information Systems Engineering and Business Intelligence, 10(2), 217–231. https://doi.org/10.20473/jisebi.10.2.217-231
Athanasios. (2022). Ontology-Driven Data Cleaning Towards Lossless Data Compression. Studies in Health Technology and Informatics, 294, 421–422. https://doi.org/10.3233/SHTI220492
Azhar, R. (2022). Analisis Sentimen Terhadap Cryptocurrency Berbasis Python TextBlob Menggunakan Algoritma Naïve Bayes. Jurnal Sains Komputer & Informatika (J-SAKTI, 6(1), 267–281. https://doi.org/10.30645/j-sakti.v6i1.443
Bodell, M. H. (2022). From Documents to Data: A Framework for Total Corpus Quality. Socius, 8, 1–15. https://doi.org/10.1177/23780231221135523
Cassidy, B. (2022). Analysis of the ISIC image datasets: Usage, benchmarks and recommendations. Medical Image Analysis, 75, 102305. https://doi.org/10.1016/j.media.2021.102305
Darwis, D. (2021). Penerapan Algoritma Naive Bayes Untuk Analisis Sentimen Review Data Twitter Bmkg Nasional. Jurnal Tekno Kompak, 15(1), 131. https://doi.org/10.33365/jtk.v15i1.744
Fan, C. (2021). A Review on Data Preprocessing Techniques Toward Efficient and Reliable Knowledge Discovery From Building Operational Data. Frontiers in Energy Research, 9(March), 1–17. https://doi.org/10.3389/fenrg.2021.652801
Febriyani, E. (2023). Analisis Sentimen Terhadap Program Kampus Merdeka Menggunakan Algoritma Naive Bayes Classifier Di Twitter. Jurnal Tekno Kompak, 17(1), 25. https://doi.org/10.33365/jtk.v17i1.2061
Gómez, C. S. F. K. J. M. (2021). A Systematic Literature Review on Applying CRISP-DM Process Model. Procedia Computer Science, 181(2021), 526–534. https://doi.org/10.1016/j.procs.2021.01.199
Huang, L., Qin, J., Zhou, Y., Zhu, F., Liu, L., & Shao, L. (2023). Normalization Techniques in Training DNNs: Methodology, Analysis and Application. IEEE Transactions on Pattern Analysis and Machine Intelligence, 45(8), 10173–10196. https://doi.org/10.1109/TPAMI.2023.3250241
Insan, M. K. (2023). ANALISIS SENTIMEN APLIKASI BRIMO PADA ULASAN PENGGUNA DI GOOGLE PLAY MENGGUNAKAN ALGORITMA NAIVE BAYES. Jurnal Mahasiswa Teknik Informatika, 7(1), 478–483. https://doi.org/10.36040/jati.v7i1.6373
Isnain, A. R. (2021). Sentiment Analysis Of Government Policy On Corona Case Using Naive Bayes Algorithm. IJCCS (Indonesian Journal of Computing and Cybernetics Systems), 15(1), 55–64. https://doi.org/10.22146/ijccs.60718
Jeng, C. V. J. J. M. J.-G. H. X. A. I. J.-H. (2021). Twitter Sentiment Analysis towards COVID-19 Vaccines in the Philippines Using Naïve Bayes. Information (Switzerland), 12(5), 1–16. https://doi.org/10.3390/info12050204
Kim, S., Shen, S., Thorsley, D., Gholami, A., Kwon, W., Hassoun, J., & Keutzer, K. (2022). Learned Token Pruning for Transformers. Proceedings of the ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, 22, 784–794. https://doi.org/10.1145/3534678.3539260
Lestari, S. (2021). Analisis Sentimen Vaksin Sinovac Pada Twitter Menggunakan Algoritma Naive Bayes. Seminar Nasional Sistem Informasi Dan Manajemen Informatika, 7(1), 163–170. Retrieved from https://sismatik.nusaputra.ac.id/index.php/sismatik/article/view/23
Nguyen, Q. H., Ly, H. B., Ho, L. S., Al-Ansari, N., Van Le, H., Tran, V. Q., … Pham, B. T. (2021). Influence of data splitting on performance of machine learning models in prediction of shear strength of soil. Mathematical Problems in Engineering, 2021, 1–15. https://doi.org/10.1155/2021/4832864
Peretz. (2024). Naive Bayes classifier – An ensemble procedure for recall and precision enrichment. Engineering Applications of Artificial Intelligence, 136(1), 108972. https://doi.org/10.1016/j.engappai.2024.108972
Samsir, Irmayani, D., Edi, F., Harahap, J. M., Jupriaman, Rangkuti, R. K., … Watrianthos, R. (2021). Naives Bayes Algorithm for Twitter Sentiment Analysis. Journal of Physics: Conference Series, 1933(1), 1–6. https://doi.org/10.1088/1742-6596/1933/1/012019
Sarica, S., & Luo, J. (2021). Stopwords in technical language processing. PLoS ONE, 16(8), 1–13. https://doi.org/10.1371/journal.pone.0254937
Satria, A. R. (2020). Analisis Sentimen Ulasan Aplikasi Mobile menggunakan Algoritma Gabungan Naive Bayes dan C4.5 berbasis Normalisasi Kata Levenshtein Distance. Jurnal Pengembangan Teknologi Informasi Dan Ilmu Komputer, 4(11), 4154–4163. Retrieved from https://j-ptiik.ub.ac.id/index.php/j-ptiik/article/view/8270
Selvi, B. (2021). Word Clouds in Grammar Production. Turkish Online Journal of English Language Teaching (TOJELT), 6(1), 44–57.
Sulaeman, A. A. (2024). Sentiment Analysis on Social Media X (Twitter) Against ChatGBT Using the K-Nearest Neighbors Algorithm. Brilliance: Research of Artificial Intelligence, 4(1), 265–275. https://doi.org/10.47709/brilliance.v4i1.4105
Sun, W., Yan, L., Chen, Z., Wang, S., Zhu, H., Ren, P., … Ren, Z. (2023). Learning to Tokenize for Generative Retrieval. NeurIPS Proceedings, 36, 1–17. Retrieved from http://arxiv.org/abs/2304.04171
Tijan, E. (2021). Digital transformation in the maritime transport sector. Technological Forecasting and Social Change, 170, 1–15. https://doi.org/10.1016/j.techfore.2021.120879
Viet, T. N. (2021). The naÏve bayes algorithm for learning data analytics. Indian Journal of Computer Science and Engineering, 12(4), 1038–1043. https://doi.org/10.21817/indjcse/2021/v12i4/211204191
Wornow, M. (2023). APLUS: A Python library for usefulness simulations of machine learning models in healthcare. Journal of Biomedical Informatics, 139(February), 1–12. https://doi.org/10.1016/j.jbi.2023.104319
Zhang, Y., Ling, H., Gao, J., Yin, K., Lafleche, J. F., Barriuso, A., … Fidler, S. (2021). DatasetGAN: Efficient Labeled Data Factory with Minimal Human Effort. Proceedings of the IEEE Computer Society Conference on Computer Vision and Pattern Recognition, 10140–10150. https://doi.org/10.1109/CVPR46437.2021.01001
Downloads
ARTICLE Published HISTORY
How to Cite
Issue
Section
License
Copyright (c) 2025 Fikri Abei, Asep Arwan Sulaeman, Suprapto

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.