Klasifikasi Teks Komentar Penggunaan Listrik Gratis di Youtube Menggunakan Metode Naïve Bayes
Abstract
The growth of social media has made YouTube one of the platforms used by the public to express opinions regarding government policies, including the free electricity program. The large number of comments makes manual analysis difficult; therefore, a text classification method is needed to automatically categorize comments. This study aims to classify YouTube user comments related to the free electricity program using the Naïve Bayes algorithm. The research data were obtained through a crawling process from ten YouTube videos discussing the free electricity policy, resulting in 910 comments, which were reduced to 906 comments after data cleaning. The data processing stages included cleaning, case folding, tokenizing, normalization, stopword removal, stemming, and term weighting using TF-IDF. Furthermore, the data were classified into four categories: Public Discussion and Information, Policy Support and Appreciation, Complaints and Technical Issues, and Non-Electricity. Model evaluation was conducted using a confusion matrix with accuracy, precision, recall, and F1-score metrics. The results showed that the Naïve Bayes algorithm provided fairly good classification performance with an accuracy of 70.9%, precision of 0.62, recall of 0.80, and F1-score of 0.70. The Non-Electricity category achieved the best performance with precision of 0.77, recall of 0.90, and F1-score of 0.83. Based on these findings, the Naïve Bayes method is considered effective for classifying public opinion from social media comment data.
Downloads
References
Afifa, N., Saputra, R. E., & Nugrahaeni, R. A. (2023). Implementasi NLP Pada Chatbot Layanan Akademik Dengan Algoritma Bert. E-Proceedings of Engineering, 10(1), 383–387.
Alfriyanto, N., Purnama, B. C., & Hasanah, F. K. (2024). Analisis Emosi Terhadap Komentar Video Youtube “ Penyebab Kegagalan Adopsi Sistem Pendidikan Finlandia di Indonesia ” Menggunakan Metode Random Forest. 812–827.
Alkadri, S. P. A., & Insani, R. W. S. (2023). Sistem Pendukung Keputusan Rekomendasi Penerima Bantuan Iuran BPJS Kesehatan Menggunakan Metode ROC dan SMART. JURNAL FASILKOM, 13(3), 496–503. https://doi.org/https://doi.org/10.37859/jf.v13i3.6271
Anggrawan, A., Mayadi, M., & Satria, C. (2021). Menentukan Akurasi Tata Letak Barang dengan Menggunakan Algoritma Apriori dan Algoritma FP-Growth. MATRIK : Jurnal Manajemen, Teknik Informatika Dan Rekayasa Komputer, 21(1), 125–138. https://doi.org/10.30812/matrik.v21i1.1260
Darwis, D., Siskawati, N., & Abidin, Z. (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
Mokoagow, M. A., & Purnomo, A. S. (2024). Penerapan Metode Naïve Bayes Pada Sistem Pakar Untuk Mendiagnosis Penyakit Ibu Hamil. 4(2).
Hasibuan, M. S., & Suhardi. (2022). Analisis Sentimen Kebijakan Vaksin Covid-19 Menggunakan SVM dan C4.5. Jurnal Teknik Elektro Dan Komputer TRIAC, 19–21.
Heliyanti Susana. (2022). Penerapan Model Klasifikasi Metode Naive Bayes Terhadap Penggunaan Akses Internet. Jurnal Riset Sistem Informasi Dan Teknologi Informasi (JURSISTEKNI), 4(1), 1–8. https://doi.org/10.52005/jursistekni.v4i1.96
Hendrastuty, N. (2024). Penerapan Data Mining Menggunakan Algoritma K-Means Clustering Dalam Evaluasi Hasil Pembelajaran Siswa. Jurnal Ilmiah Informatika Dan Ilmu Komputer (Jima-Ilkom), 3(1), 46–56.
Insan, M. K., Hayati, U., & Nurdiawan, O. (2023). Analisis Sentimen Aplikasi Brimo Pada Ulasan Pengguna Di. Jurnal Mahasiswa Teknik Informatika, 7(1), 478–483.
Mahiddin, N. B., Othman, Z. A., Bakar, A. A., & Rahim, N. A. A. (2022). An Interrelated Decision-Making Model for an Intelligent Decision Support System in Healthcare. IEEE Access, 10, 31660–31676. https://doi.org/10.1109/ACCESS.2022.3160725
Mukti, A., Hadiyanti, A. D., Nurlaela, A., & Panjaitan, J. (2023). Sistem Analisa Sentiment Bakal Calon Presiden 2024 Menggunakan Metode NLP Berbasis Web. Soscied, 6(1), p-ISSN.
Pebdika, A., Herdiana, R., & Solihudin, D. (2023). Klasifikasi Menggunakan Metode Naive Bayes Untuk Menentukan Calon Penerima Pip. JATI (Jurnal Mahasiswa Teknik Informatika), 7(1), 452–458. https://doi.org/10.36040/jati.v7i1.6303
Prasetya, M., Wulandari, M., & Nikmah, S. A. (2024). Implementasi NLP (Natural Language Processing) Dasar pada Analisis Sentiment Review Spotify. Stains (Seminar Nasional Teknologi & Sains), 3(1), 145–153.
Pratama, A., & Ikhwan, A. (2023). Perancangan Sistem Informasi Monitoring Opini Publik Diskominfo pada Media Online dengan Metode Rapid Application Development. Sudo Jurnal Teknik Informatika, 2(3), 86–95. https://doi.org/10.56211/sudo.v2i3.264
Putri, K. S., Setiawan, I. R., & Pambudi, A. (2023). Analisis Sentimen Terhadap Brand Skincare Lokal Menggunakan Naïve Bayes Classifier. Technologia : Jurnal Ilmiah, 14(3), 227. https://doi.org/10.31602/tji.v14i3.11259
Rahmansyah, N., Lusinia, S. A., Gema, R. L., & Safira, S. (2021). Peramalam Garis Kemiskinan menggunakan Metode Double Moving Average di Provinsi Sumatera Barat. Majalah Ilmiah UPI YPTK, 28, 25–29. https://doi.org/10.35134/jmi.v28i1.68
Santoso, H., Putri, R. A., & Sahbandi, S. (2023). Deteksi Komentar Cyberbullying pada Media Sosial Instagram Menggunakan Algoritma Random Forest. Jurnal Manajemen Informatika (JAMIKA), 13(1), 62–72. https://doi.org/10.34010/jamika.v13i1.9303
Saripah, A. P., & Sibarani, F. H. (2024). Analisis Sentimen Terhadap Aplikasi Maxim Menggunakan Algoritma Random Forest. Journal of Science and Social Research, 7(3), 1201–1208. http://jurnal.goretanpena.com/index.php/JSSR
Septianingrum, F., & Irawan, A. S. Y. (2021). Metode Seleksi Fitur Untuk Klasifikasi Sentimen Menggunakan Algoritma Naive Bayes: Sebuah Literature Review. Jurnal Media Informatika Budidarma, 5(3), 799. https://doi.org/10.30865/mib.v5i3.2983
Sihombing, J. (2021). Klasifikasi Data Antroprometri Individu Menggunakan Algoritma Naïve Bayes Classifier. BIOS : Jurnal Teknologi Informasi Dan Rekayasa Komputer, 2(1), 1–10. https://doi.org/10.37148/bios.v2i1.15
Bila bermanfaat silahkan share artikel ini
Berikan Komentar Anda terhadap artikel Klasifikasi Teks Komentar Penggunaan Listrik Gratis di Youtube Menggunakan Metode Naïve Bayes
Pages: 2206-2217
Copyright (c) 2026 Mikho Alfatih Harahap, Abdul Halim Hasugian

This work is licensed under a Creative Commons Attribution 4.0 International License.
Authors who publish with this journal agree to the following terms:
- Authors retain copyright and grant the journal right of first publication with the work simultaneously licensed under Creative Commons Attribution 4.0 International License that allows others to share the work with an acknowledgment of the work's authorship and initial publication in this journal.
- Authors are able to enter into separate, additional contractual arrangements for the non-exclusive distribution of the journal's published version of the work (e.g., post it to an institutional repository or publish it in a book), with an acknowledgment of its initial publication in this journal.
- Authors are permitted and encouraged to post their work online (e.g., in institutional repositories or on their website) prior to and during the submission process, as it can lead to productive exchanges, as well as earlier and greater citation of published work (Refer to The Effect of Open Access).













