ENHANCING SENTIMENT ANALYSIS OF THE 2024 INDONESIAN PRESIDENTIAL INAUGURATION ON X USING SMOTE-OPTIMIZED NAIVE BAYES CLASSIFIER

  • Lasmedi Afuan Informatics, Universitas Jenderal Soedirman, Indonesia
  • Muthia Khanza Informatics, Universitas Jenderal Soedirman, Indonesia
  • Adila Zahira Hasyati Informatics, Universitas Jenderal Soedirman, Indonesia
Keywords: 2024 Indonesian Presidential Inauguration, Naïve Bayes Classifier, Sentiment Analysis, Synthetic Minority Over-sampling Technique (SMOTE), TF-IDF, TextBlob, Twitter

Abstract

The inauguration of the President and Vice President of Indonesia for the 2024-2029 period has drawn significant public attention, reflecting widespread political and societal interest. This study aims to optimize sentiment analysis of public opinion on X (formerly Twitter) regarding the inauguration by enhancing the Naïve Bayes Classifier (NBC) with the Synthetic Minority Over-sampling Technique (SMOTE). Addressing the issue of class imbalance in sentiment data, the research demonstrates how SMOTE improves classification robustness. The methodology includes data crawling from X, preprocessing involving tokenization, stemming, and TF-IDF feature extraction, and sentiment labeling using TextBlob. Sentiment classification is conducted with NBC, evaluated under conditions with and without SMOTE. Metrics such as accuracy, precision, recall, and F1-score are utilized to assess performance. Results indicate that the application of SMOTE increases the accuracy of NBC from 98% to 99%, with precision improving from 0.98 to 1 and recall maintaining high levels (0.99). This 1% accuracy enhancement underscores the significance of addressing class imbalance for reliable sentiment analysis. The findings contribute to a better understanding of public sentiment during critical political events and highlight the effectiveness of SMOTE in improving text classification tasks. This research provides valuable insights into leveraging machine learning techniques for analyzing imbalanced datasets, offering implications for both academic and practical applications in sentiment analysis and political studies.

Downloads

Download data is not yet available.

References

J. Jtik et al., “Analisis Semiotika Pierce terhadap Pasangan Prabowo-Gibran dalam Pilpres 2024,” vol. 8, no. 4, 2024.

DDTC News, "Sah! Prabowo-Gibran Resmi Jadi Presiden dan Wakil Presiden 2024-2029," DDTC News, 3 Desember 2024. [Online]. Tersedia: https://news.ddtc.co.id/berita/nasional/1806298/sah-prabowo-gibran-resmi-jadi-presiden-dan-wakil-presiden-2024-2029.

Kementerian Pertahanan Republik Indonesia, "Pelantikan Prabowo Subianto dan Gibran Rakabuming Raka sebagai Presiden dan Wakil Presiden RI 2024-2029," Kementerian Pertahanan RI, 21 Oktober 2024. [Online]. Tersedia: https://www.kemhan.go.id/2024/10/21/pelantikan-prabowo-subianto-dan-gibran-rakabuming-raka-sebagai-presiden-dan-wakil-presiden-ri-2024-2029.html.

E. Memi, “applied sciences Comparative Study for Sentiment Analysis of Financial Tweets with Deep Learning Methods,” 2024.

J. L. Kent K. Lee, Marilyn L. Abbott, Shiran Wang, “The Uses of X/Twitter by Members of the TESOL Community,” CJLT RCAT, vol. 49, no. 3, 2023, [Online]. Available: https://cjlt.ca/index.php/cjlt/article/view/28495/20792

K. P. Widiatmika, “Seeking Answers In The Shadowsthe Use of Auto-Based Accounts on Twitter/X As A Platform for Social Q&A,” J. Sos. Hmaniora, vol. 15, 2024, [Online]. Available: https://ojs.unida.ac.id/JSH/article/view/12884/5066

D. B. R. Krishna, “Twitter Sentiment Analysis,” Int. J. Innov. Eng. Manag. Res., vol. 24, no. 05, pp. 811–825, 2022, doi: 10.48047/ijiemr/v11/i06/53.

S. Setianingsih et al., “Implementation of SMOTE to Overcome Class Imbalance in the Naive Bayes Classifier in Sentiment Analysis of Presidential Candidates in the 2024 General Election,” TELKOMNIKA Telecommun. Comput. Electron. Control, vol. 99, no. 1, pp. 1–1, 2099, doi: 10.12928/TELKOMNIKA.v99i1.paperID.

Y. Afrianto Singgalen, “Sentiment Classification of Over-Tourism Issues in Responsible Tourism Content using Naïve Bayes Classifier,” J. Comput. Syst. Informatics, vol. 5, no. 2, pp. 275–285, 2024, doi: 10.47065/josyc.v5i2.4904.

Z. Gao, S. Wu, Z. Wan, and S. Agaian, “A Hybrid Method for Implicit Intention Inference Based on Punished-Weighted Naïve Bayes,” IEEE Trans. Neural Syst. Rehabil. Eng., vol. 31, pp. 1826–1836, 2023, doi: 10.1109/TNSRE.2023.3259550.

A. V. D. Sano, A. A. Stefanus, E. D. Madyatmadja, H. Nindito, A. Purnomo, and C. P. M. Sianipar, “Proposing a visualized comparative review analysis model on tourism domain using Naïve Bayes classifier,” Procedia Comput. Sci., vol. 227, pp. 482–489, 2023, doi: 10.1016/j.procs.2023.10.549.

B. Nemade, V. Bharadi, S. S. Alegavi, and B. Marakarkandy, “A Comprehensive Review: SMOTE-Based Oversampling Methods for Imbalanced Classification Techniques, Evaluation, and Result Comparisons,” Int. J. Intell. Syst. Appl. Eng., vol. 11, no. 9s, pp. 790–803, 2023.

T. Watthaisong and N. M. , Khamron Sunat, “Comparative Evaluation of Imbalanced Data Management Techniques for Solving Classification Problems on Imbalanced Datasets,” Int. Acad. Press, vol. 12, pp. 547–570, 2024, [Online]. Available: http://www.iapress.org/index.php/soic/article/view/1890/1063

Y. Zhang, L. Deng, and B. Wei, “Imbalanced Data Classification Based on Improved Random-SMOTE and Feature Standard Deviation,” pp. 1–17, 2024.

M. J. A. Fatemeh Daneshfar, “Enhanced text classification through an improved discrete laying chicken algorithm,” Wiley, 2024, [Online]. Available: https://onlinelibrary.wiley.com/doi/epdf/10.1111/exsy.13553

V. R. Revathy, A. S. Pillai, and F. Daneshfar, “LyEmoBERT: Classification of lyrics’ emotion and recommendation using a pre-trained model,” Procedia Comput. Sci., vol. 218, pp. 1196–1208, 2022, doi: 10.1016/j.procs.2023.01.098.

J. Park, S. Kwon, and S. P. Jeong, “A study on improving turnover intention forecasting by solving imbalanced data problems : focusing on SMOTE and generative adversarial networks,” J. Big Data, 2023, doi: 10.1186/s40537-023-00715-6.

Y. A. Singgalen, “Comparative Analysis of DT and SVM Model Performance with SMOTE in Sentiment Classification,” vol. 4, no. 5, pp. 2485–2494, 2024, doi: 10.30865/klik.v4i5.1828.

D. A. Fatah, E. M. S. Rochman, W. Setiawan, A. R. Aulia, F. I. Kamil, and A. Su’ud, “Sentiment Analysis of Public Opinion Towards Tourism in Bangkalan Regency Using Naïve Bayes Method,” E3S Web Conf., vol. 499, pp. 1–8, 2024, doi: 10.1051/e3sconf/202449901016.

A. B. Putra Negara, “The Influence Of Applying Stopword Removal And Smote On Indonesian Sentiment Classification,” Lontar Komput. J. Ilm. Teknol. Inf., vol. 14, no. 3, p. 172, 2023, doi: 10.24843/lkjiti.2023.v14.i03.p05.

S. Saranya and G. Usha, “A Machine Learning-Based Technique with Intelligent WordNet Lemmatize for Twitter Sentiment Analysis,” Intell. Autom. Soft Comput., vol. 36, no. 1, pp. 339–352, 2023, doi: 10.32604/iasc.2023.031987.

E. D. Ajik, A. B. Suleiman, and M. Ibrahim, “Enhancing User Experience Through Sentiment Analysis for Katsina State Transport Agency: a Textblob Approach,” Fudma J. Sci., vol. 7, no. 6, pp. 117–122, 2023, doi: 10.33003/fjs-2023-0706-2057.

O. Abiola, A. Abayomi-Alli, O. A. Tale, S. Misra, and O. Abayomi-Alli, “Sentiment analysis of COVID-19 tweets from selected hashtags in Nigeria using VADER and Text Blob analyser,” J. Electr. Syst. Inf. Technol., vol. 10, no. 1, 2023, doi: 10.1186/s43067-023-00070-9.

Ilham Firman Ashari, F. A, M. Daffa, and Sekar A, “Sentiment Analysis of Tweets About Allowing Outdoor Mask Wear Using Naïve Bayes and TextBlob,” Indones. J. Comput. Sci., vol. 12, no. 3, pp. 1092–1103, 2023, doi: 10.33022/ijcs.v12i3.3238.

Nehal, D. Jeet, V. Sharma, S. Mishra, C. Iwendi, and J. Osamor, “Twitter Sentiment Analysis and Emotion Detection Using NLTK and TextBlob,” 2023 4th Int. Conf. Comput. Autom. Knowl. Manag. ICCAKM 2023, 2023, doi: 10.1109/ICCAKM58659.2023.10449540.

B. Wahyu Andrian, F. Adline Twince Tobing, I. Zuhdi Pane, and A. Kusnadi, “Implementation of Naïve Bayes Algorithm in Sentiment Analysis of Twitter Social Media Users Regarding Their Interest to Pay the Tax,” Int. J. Sci. Technol. Manag., vol. 4, no. 6, pp. 1733–1742, 2023, doi: 10.46729/ijstm.v4i6.1015.

A. A. Ajhari, “The Comparison of Sentiment Analysis of Moon Knight Movie Reviews between Multinomial Naive Bayes and Support Vector Machine,” Appl. Inf. Syst. Manag., vol. 6, no. 1, pp. 13–20, 2023, doi: 10.15408/aism.v6i1.26045..

Published
2025-02-12
How to Cite
[1]
L. Afuan, M. Khanza, and A. Zahira Hasyati, “ENHANCING SENTIMENT ANALYSIS OF THE 2024 INDONESIAN PRESIDENTIAL INAUGURATION ON X USING SMOTE-OPTIMIZED NAIVE BAYES CLASSIFIER”, J. Tek. Inform. (JUTIF), vol. 6, no. 1, pp. 325-333, Feb. 2025.