Komparasi Naive Bayes dan Support Vector Machine dalam Mendeteksi Sarkasme Teks Twitter (X)

Authors

DOI:

https://doi.org/10.30998/jrami.v7i04.2326

Keywords:

deteksi sarkas, tf-idf, twitter, support vector machine, naive bayes

Abstract

The use of non-standard language on social media has become one of the challenges in detecting sarcasm because the meaning conveyed is not always recognizable based solely on the words present in the text. This study aims to compare the performance of Naive Bayes and Support Vector Machine (SVM) in detecting sarcasm in non-standard Indonesian Twitter text (X). The Wilcoxon Signed-Rank Test is used to test the significance of the performance difference between the two algorithms. The audit results in 15,072 unique tweets, consisting of 12,057 training data and 3,015 test data. The test results show that Naive Bayes achieved an accuracy of 69.45%, precision of 67.66%, recall of 64.19%, and F1-Score of 65.88%, while SVM achieved an accuracy of 68.39%, precision of 66.51%, recall of 62.82%, and F1-Score of 64.61%. In the 5-fold cross-validation, Naive Bayes produced an average accuracy of 68.74% with a standard deviation of ±0.33%, while SVM achieved 68.17% with a standard deviation of ±1.14%. The Wilcoxon Signed-Rank Test results in a p-value of 0.4375 (>0.05), indicating that the performance difference between the two algorithms is not statistically significant. Thus, Naive Bayes shows slightly higher evaluation results numerically, but it cannot yet be stated that it has significantly superior performance compared to SVM on this research dataset.

Downloads

Download data is not yet available.

References

Alqahtani, A., Al-Henaki, L., & Alsheddi, A. (2023). Text-based Sarcasm Detection on Social Networks: A Systematic Review. International Journal of Advanced Computer Science and Applications, 14(3). https://doi.org/10.14569/ijacsa.2023.0140336

Gerliandeva, A., Chrisnanto, Y., & Ashaury, H. (2024). Optimasi Klasifikasi Sentimen pada Komentar Online menggunakan Multinomial Naïve Bayes dan Ekstraksi Fitur TF-IDF serta N-grams. Jurnal Pekommas, 9(2), 260–272. https://doi.org/10.56873/jpkm.v9i2.5585

Jakarta, U. N., Lestari, V. B., & Hutagalung, C. A. (n.d.). J-KOMA Journal of Computer Science and Applications Evaluation of TF-IDF Extraction Techniques in Sentiment Analysis of Indonesian-Language Marketplaces Using SVM, Logistic Regression, and Naive Bayes. 22–2025. https://doi.org/10.21009/j

Khotimah, A. C., & Utami, E. (2022). Comparison Naïve Bayes Classifier, K-Nearest Neighbor And Support Vector Machine In The Classification Of Individual On Twitter Account. Jurnal Teknik Informatika (JUTIF), 3(3). https://doi.org/10.20884/1.jutif.2022.3.3.254

Panjaitan, F., Ce, W., Oktafiandy, H., Kanugrahan, G., Ramdhani, Y., Hafizh, V., Putra, C., & Permai, A. (2025). Studi Komparatif Algoritma Machine Learning Pada Analisis Sentimen Media Sosial. In Jurnal Mahasiswa Teknik Informatika) (Vol. 9, Number 2).

Perdana, A., Sugandi, F., & Raihannicko, A. (2026). JEPIN (Jurnal Edukasi dan Penelitian Informatika).

Prusty, S., Patnaik, S., & Dash, S. K. (2022). SKCV: Stratified K-fold cross-validation on ML classifiers for predicting cervical cancer. Frontiers in Nanotechnology, 4. https://doi.org/10.3389/fnano.2022.972421

Rifa’i, Z., & Mukti, B. P. (2025). Edu Komputika Journal Weakly Supervised Sentiment Analysis of Indonesian Rural Tourism Reviews: A TF-IDF Baseline for Melung Tourism Village Article Info. Edu Komputika, 12(1). https://journal.unnes.ac.id/journals/edukom/

Rosid, M. A., Muharram, F., & Affandi, G. R. (2022). Comparison of the Performance of Machine Learning Algorithms for Sarcasm Detection in Bahasa Perbandingan Kinerja Algoritma Machine Learning Untuk Mendeteksi Kalimat Sarkasme Dalam Bahasa Indonesia. https://pssh.umsida.ac.id.

Widodo, S., Brawijaya, H., & Samudi, S. (2022). Stratified K-fold cross validation optimization on machine learning for prediction. Sinkron, 7(4), 2407–2414. https://doi.org/10.33395/sinkron.v7i4.11792

Yunitasari, Y., Musdholifah, A., & Sari, A. K. (2019). Sarcasm Detection for Sentiment Analysis in Indonesian Tweets. IJCCS (Indonesian Journal of Computing and Cybernetics Systems), 13(1), 53. https://doi.org/10.22146/ijccs.41136

Yusupa, A., & Tarigan, V. (n.d.). JIP (Jurnal Informatika Polinema) Perbandingan Algoritma Maching Learning Dalam Analisis Sentimen Mobil Listrik Di Indonesia Pada Media Sosial Twitter/X.

Published

2026-10-15

How to Cite

Azzahra, S., Sutejo, B. S. I., Aryani, D., & Asri, J. S. (2026). Komparasi Naive Bayes dan Support Vector Machine dalam Mendeteksi Sarkasme Teks Twitter (X). Jurnal Riset Dan Aplikasi Mahasiswa Informatika (JRAMI), 7(04), 824-831. https://doi.org/10.30998/jrami.v7i04.2326