Text Classification on Social Media X Using Support Vector Machine (SVM) for Public Opinion on the Pertamina Corruption Case
DOI:
https://doi.org/10.59934/jaiea.v6i1.2946Keywords:
Crisp-Dm, Text Classification, Pertamina Corruption, Support vector Machine, Tf-IdfAbstract
Social media X (Twitter) is one of the platforms used by the public to express opinions on various public issues, including the Pertamina corruption case. The large amount of unstructured text-based opinions makes manual analysis difficult. This study aims to analyze public sentiment regarding the Pertamina corruption case on social media X using the Support Vector Machine (SVM) algorithm with Term Frequency–Inverse Document Frequency (TF-IDF) weighting. The study applies the CRISP-DM method, which includes business understanding, data understanding, data preparation, modeling, evaluation, and deployment. Data were obtained through crawling on social media X using several keywords related to the Pertamina corruption case during the period from 2018 to 2026, resulting in 3,671 tweets. The preprocessing stage included case folding, cleaning, tokenizing, stopword removal, and stemming. The data were then labeled as positive, negative, and neutral using a lexicon-based method. TF-IDF was used for word weighting, after which the data were divided into 80% training data and 20% testing data for classification using SVM with a linear kernel. The results show that the SVM model achieved good classification performance, with an accuracy of 87.76%, precision of 88.07%, recall of 87.76%, and F1-score of 87.18%. Positive sentiment was the most dominant category. The model was also implemented in a Streamlit application to display preprocessing, data visualization, sentiment prediction, and model evaluation interactively.
Downloads
References
U. I. Arsyah, M. Pratiwi, and A. Muhammad, “Twitter sentiment analysis of public space opinions using SVM and TF-IDF methods,” The Indonesian Journal of Computer Science, vol. 13, no. 1, 2024, doi: 10.33022/ijcs.v13i1.3594.
R. D. Pebrianti, “Analisis sentimen masyarakat platform X terhadap korupsi PT. Pertamina (Persero) menggunakan metode SVM,” Jurnal Informatika dan Teknik Elektro Terapan, vol. 13, no. 2, 2025, doi: 10.23960/jitet.v13i2.6399.
F. Caroline, R. G. S. Budi, and M. E. Al Rivan, “Analisis sentimen masyarakat terhadap kasus korupsi PT. Timah menggunakan metode Support Vector Machine,” Jurnal Ilmu Komputer dan Informatika, vol. 4, no. 1, pp. 43–50, 2024, doi: 10.54082/jiki.141.
A. Rianti, N. W. A. Majid, and A. Fauzi, “CRISP-DM: Metodologi proyek data science,” Prosiding Seminar Nasional Teknologi Informasi dan Bisnis (SENATIB), pp. 107–114, 2023.
S. Hidayat, H. Napitupulu, and N. Gusriani, “Penerapan model Support Vector Machine pada kasus klasifikasi teks berdasarkan tujuan SDGs ke tiga, empat, dan enam,” SisInfo, vol. 6, no. 2, pp. 115–124, 2024, doi: 10.37278/sisinfo.v6i2.893.
D. F. Sebastian, H. Sulistiani, and A. R. Isnain, “Sentiment analysis of public opinion on the right of inquiry in Indonesia in 2024 using the Support Vector Machine (SVM) method,” Jurnal Teknik Informatika (JUTIF), vol. 5, no. 4, pp. 1025–1034, 2024, doi: 10.52436/1.jutif.2024.5.4.1968.
Khadapi M, Pakpahan VM. Analisis sentimen berbasis jaringan LSTM dan BERT terhadap diskusi Twitter tentang Pemilu 2024. JUKI: Jurnal Komputer dan Informatika. 2024 Nov;6(2):130-7.
Downloads
Published
How to Cite
Issue
Section
License
Copyright (c) 2026 Journal of Artificial Intelligence and Engineering Applications (JAIEA)

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








