Perbandingan Kinerja Algoritma SVM dan Random Forest dalam Klasifikasi Tuberkulosis di Puskesmas Sandar Angin
Abstract
Tuberculosis (TBC) remains a major infectious disease and public health problem in Indonesia, requiring approaches that can support accurate diagnosis. Machine learning can assist TBC classification based on patients’ clinical characteristics, but different algorithms may produce different performance. This study aims to compare the performance of Support Vector Machine (SVM) and Random Forest and determine the best-performing algorithm for TBC classification using patient data from Sandar Angin Public Health Center, Pagar Alam. The study used primary data from 201 patients recorded from January 2023 to October 2025, consisting of 14 variables: number, gender, age, chest pain, productive cough, cough duration, shortness of breath, fatigue, weight loss, body temperature, cold sweats, decreased appetite, sputum, and diagnosis. Model evaluation was conducted using an 80:20 data-splitting scheme and 5-Fold Cross Validation. In the 80:20 split, SVM achieved 98% accuracy, 94% precision, 100% recall, and 97% F1-score, while Random Forest achieved 93% accuracy, 88% precision, 94% recall, and 91% F1-score. Based on 5-Fold Cross Validation, SVM achieved the highest accuracy of 90%, while Random Forest achieved 88%. Overall, SVM demonstrated superior classification performance and was selected as the best-performing algorithm for TBC classification using patient data from Sandar Angin Public Health Center, Pagar Alam.
Downloads
References
Adventino Gulo, S., Amelia Pertiwi, A., Putri Syaifullah Nasution, S., & Syahputra, H. (2025). Deteksi Deepfake Dalam Citra Menggunakan Convolutional Neural Network (Cnn). JATI (Jurnal Mahasiswa Teknik Informatika), 9(5), 8655–8660. https://doi.org/10.36040/jati.v9i5.14896
Aini, S. A., Fitriani, D., & Awwalin, M. A. (2026). Klasifikasi penyakit jantung berdasarkan faktor klinis menggunakan algoritma XGBoost, Random Forest, Support Vector Machine (SVM) dan K-Nearest Neighbor (KNN). JATI (Jurnal Mahasiswa Teknik Informatika), 10(2), 3449–3454. https://doi.org/10.36040/jati.v10i2.17644
Astuti, L. W., Saluza, I., Yulianti, E., & Dhamayanti. (2022). Feature Selection Menggunakan Binary Wheal Optimizaton Algorithm ( BWOA ) pada Klasifikasi Penyakit Diabetes. Jurnal Ilmiah Informatika Global. 13(4), 1–6. https://doi.org/10.36982/jiig.v13i1.2057
Azhari, M., Situmorang, Z., & Rosnelly, R. (2021). Perbandingan Akurasi , Recall , dan Presisi Klasifikasi pada Algoritma. Jurnal Media Informatika Budidarma. 5(April), 640–651. https://doi.org/10.30865/mib.v5i2.2937
Biddinika, M. K., Masitha, A., & Fatimah, F. A. N. (2024). Machine Learning Techniques for Heart Disease Prediction Using a Multi Algorithm Approach. 12(2), 149–158. https://doi.org/10.30595/juita.v12i2.24153
Du, K. L., Jiang, B., Lu, J., Hua, J., & Swamy, M. N. S. (2024). Exploring Kernel Machines and Support Vector Machines: Principles, Techniques, and Future Directions. Mathematics, 12(24), 1–58. https://doi.org/10.3390/math12243935
Gasim, Heriansyah, R., Irfani, M. H., & Cahyani, S. (2026). Buku Ajar Pengenalan Pola Pattern Recognition (1st ed.). Repository Global Aksara Pers.
Ihsan, C. (2025). Dasar-Dasar Machine Learning Teori, Algoritma, dan Implementasi. Greenbook Publisher.
Irfani, M. H., & Gasim. (2024). Segmentasi teks pada citra tulisan tangan kalimat menggunakan metode Median Filtering dan Otsu. 18(April), 88–97. https://doi.org/10.24252/teknosains.v18i1.44307
Kementerian Kesehatan Republik Indonesia. (2024). Laporan Kinerja Kementerian Kesehatan Republik Indonesia Tahun 2024.
Luthfi, A. M., & Fauzi, F. (2024). Perbandingan Klasifikasi Random Forest , Support Vector Machines , dan LGBM Pada Klasifikasi Kualitas Udara di Jakarta. JUSTINDO (Jurnal Sistem dan Teknologi Informasi Indonesia) 9(2), 99–108. https://doi.org/10.32528/justindo.v9i2.1912
Manurung, S. Z. Y. B., Aldo, D., & Sa’adah, A. (2025). Perbandingan Algoritma Support Vector Machine Dan Algoritma Random Forest Dalam Prediksi Hipertensi. E-Proceeding of Engineering, 12(4), 6934.
Mutmainah, M., Cipta, S. P., Mambang, M., Zulfadhilah, M., Naparin, H., & Syapotro, U. (2024). Analisis Sentimen Terhadap Aplikasi Parak Acil Online Berdasarkan Ulasan Masyarakat Menggunakan Metode Support Vector Machine (SVM). Jurnal Nasional Komputasi Dan Teknologi Informasi (JNKTI), 7(5), 1042–1049. https://doi.org/10.32672/jnkti.v7i5.7962
Nugroho, A., & Harini, D. (2024). Teknik Random Forest untuk Meningkatan Akurasi Data Tidak Seimbang. JSITIK: Jurnal Sistem Informasi Dan Teknologi Informasi Komputer, 2(2), 128–140. https://doi.org/10.53624/jsitik.v2i2.379
Nugroho, M. W. (2025). Analisis Performa Algoritma Random Forest dalam Mengatasi Overfitting pada Model Prediksi. Jurnal JTIK (Jurnal Teknologi Informasi Dan Komunikasi), 9(4), 1562–1571. https://doi.org/10.35870/jtik.v9i4.4236
Oktaviani, V., Rosmawarni, N., & Muslim, M. P. (2024). Perbandingan Kinerja Random Forest Dan Smote Random Forest Dalam Mendeteksi Dan Mengukur Tingkat Stres Pada Mahasiswa Tingkat Akhir. 4221(April), 43–49. https://doi.org/10.52958/iftk.v20i1.9158
Prasetyo, E. (2022). Data Mining: Konsep dan Aplikasi menggunakan MATLAB. ANDI.
Putra, R. S., Izhari, F., Syekh, U. I. N., Hasan, A., & Addary, A. (2025). Analisis Komparasi Algoritma Random Forest dan Support Vector Machine untuk Deteksi Intrusi Jaringan. TECHSI: Jurnal Teknik Informatika, 16(2), 74–87. https://doi.org/10.29103/techsi.v16i2.25811
Rahman, F. D., Zulfa, M. I., & Taryana, A. (2024). Clustering dan Klasifikasi Data Cuaca Kota Cilacap Menggunakan K-Means dan Random Forest. 1(April), 90–97. https://doi.org/10.61124/sinta.v1i2.15
Rindu, A. A. C., Astriratma, R., & Zaidiah, A. (2026). K-Means Algorithm Implementation for Project Health Clustering. 5(158), 1064–1076. https://doi.org/10.29207/resti.v7i5.5181
Sahona, M. A., Astuti, L. W., & Irfani, M. H. (2026). Klasifikasi Usia Pengguna Berdasarkan Nilai Guna Perangkat Seluler Menggunakan Metode Support Vector Machine. 7(3), 815–821. https://doi.org/https://doi.org/10.55338/jumin.v7i3.8798
Sakmar, M., Kadir, N. T., Shofo, P. A., & Darmawan, A. (2026). Efektivitas XGBoost, LightGBM, dan CatBoost pada Dataset Imbalanced Predictive Maintenance. 3, 36–44. https://doi.org/10.61124/sinta.v3i1.145
Triloka, J., & Sugianto, D. (2025). Prediction of Tuberculosis Treatment Outcomes in Indonesia Using Support Vector Machine and Random Forest. Journal of Applied Informatics and Computing, 9(5), 2478–2485. https://doi.org/10.30871/jaic.v9i5.10018
Wahyudi, A., & Setyawan, D. (2022). Manajemen Pelayanan Kesehatan. Deepublish.
Wiyanto, A., Puspasari, S., Astuti, L. W., Komputer, I., Informatika, T., Indo, U., & Mandiri, G. (2025). Perbandingan Kinerja Algoritma Support Vector Machine dan Random Forest dalam Analisis Sentimen Ulasan Hotel di Kota Palembang pada Google Map. Jurnal Teknik Informatika dan Teknologi Informasi, 2, 679–691. https://doi.org/https://doi.org/10.55606/jutiti.v5i2.5802
World Health Organization. (2024). Global tuberculosis report 2024. https://iris.who.int/handle/10665/379339
Zahra, A., Azzahirah, A., & Ahmad, A. M. (2025). Penerapan Support Vector Machine untuk Klasifikasi Tuberkulosis Paru dari Citra Rontgen Dada. 1(1), 17–25.
Bila bermanfaat silahkan share artikel ini
Berikan Komentar Anda terhadap artikel Perbandingan Kinerja Algoritma SVM dan Random Forest dalam Klasifikasi Tuberkulosis di Puskesmas Sandar Angin
Pages: 1642-1652
Copyright (c) 2026 Rinda Desfourtheen, Lastri Widya Astuti, Muhammad Haviz Irfani

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).













