Comparison of Naive Bayes and PSO-Based Naive Bayes Algorithms for Prediction of Covid-19 Patient Recovery Data in Indonesia

  • Alvina Felicia Watratan Universitas Amikom Yogyakarta
  • Ema Utami Universitas Amikom Yogyakarta
  • Anggit Dwi Hartanto Universitas Amikom Yogyakarta
Keywords: Algoritma Naive Bayes, Particle Swarm Optimization, Covid-19, Data mining, Classification


A brand new disease known as COVID 19 was identified in 2019 but has yet to infect humans (World Health Organization, 2019). This group of viruses can infect mammals, including humans and birds, and cause sickness. People commonly contract coronaviruses from the flu and other minor respiratory diseases, but they can also spread serious diseases such as SARS, MERS, and the deadly COVID-19. Therefore, to avoid further casualties, this number must be decreased. It is crucial to understand the variables that can truly reduce the danger of death and gauge the propensity for recovery in Covid-19 patients. Several techniques in data mining can be used to forecast patient recovery rates depending on various characteristics. The criteria of this study included gender, age, province, and status. The Naive Bayes (NB) and Pso-based Naive Bayes algorithms are compared in this study using patient data sets to determine whether the strategy is more accurate. The findings of this study reveal that the NB method has a 94.07% accuracy rate, a precision value of 14%, a recall value of 1% and an AUC value of 0.613, according to the study data. The accuracy rate of the Naive Bayes based on PSO is 95.56%, the precision is 25%, the recall is 1%, and the AUC is 0.540.



Download data is not yet available.


World Health Organization, “Coronavirus”, 2019. [Online]. Available:

V. No and N. Mona, “Konsep Isolasi Dalam Jaringan Sosial Untuk Meminimalisasi Efek Contagious (Kasus Penyebaran Virus Corona Di Indonesia),” J. Sos. Hum. Terap., vol. 2, no. 2, pp. 117–125, 2020, doi: 10.7454/jsht.v2i2.86.

Widiyani, R., "Latar Belakang Virus Corona,Perkembangan hingga Isu Terkini", 2020. Retrieved from detik News: Nuha Medika

N. Salma, T. Ichsan, M. D. Sa’adillah, Z. W. Budiawan,and D. Popon, “Implementation of K-Nearest Neighbor to Predict the Chances of COVID-19 Patients' Recovery,” International Conference on Wireless and Telematics (ICWT), 2022, doi: 10.1109/ICWT55831.2022.9935435

J. S. Widjaya, D. Agushinta R, and S. R. Puspita Sari, “Sistem Prediksi Jumlah Pasien Covid-19 Menggunakan Metode Trend Least Square Berbasis Web,” Sistemasi, vol. 10, no. 1, p. 39, 2021, doi: 10.32520/stmsi.v10i1.1036.

Fei, S. W., Miao, Y. B., & Liu, C. L., "Chinese Grain Production Forecasting Method Based on Particle Swarm Optimization-based Support Vector Machine," Recent Patents on Engineering., vol 3, no. 1, pp. 8-12, 2009.

J. Ipmawati, Kusrini, and E. Taufiq Luthfi, “Komparasi Teknik Klasifikasi Teks Mining Pada Analisis Sentimen,” Indones. J. Netw. Secur., vol. 6, no. 1, pp. 28–36, 2017.

Bramer, M., "Principles of Data Mining", 2007. London: Springer.

H. Muhamad, C. A. Prasojo, N. A. Sugianto, L. Surtiningsih, and I. Cholissodin, “Optimasi Naïve Bayes Classifier Dengan Menggunakan Particle Swarm Optimization Pada Data Iris,” J. Teknol. Inf. dan Ilmu Komput., vol. 4, no. 3, p. 180, 2017, doi: 10.25126/jtiik.201743251.

Suyanto, "Data Mining untuk Klasifikasi dan Klasterisasi Data",2017. Bandung : Informatika Bandung.

J. Žižka, F. Dařena, and A. Svoboda, Introduction to Text Mining with Machine Learning. 2019. doi: 10.1201/9780429469275-1.

A. Mukminin and D. Riana, “Komparasi Algoritma C4 . 5 , Naïve Bayes Dan Neural Network Untuk Klasifikasi Tanah,” J. Inform. Univ. Bina Sarana Inform., vol. 4, no. 1, pp. 21–31, 2017, [Online]. Available:

D. Xhemali, C. J. Hinde, and R. G. Stone, “Naive Bayes vs. Decision Trees vs. Neural Networks in the Classification of Training Web Pages,” Int. J. Comput. Sci., vol. 4, no. 1, pp. 16–23, 2009, [Online]. Available:

J. J. Aripin, “Penerapan Algoritma Naive Bayes Untuk Mengklasifikasi Data Nasabah Asuransi pada BPR Pantura,” 2019, [Online]. Available:

M. O. Okwu and L. K. Tartibu, “Particle Swarm Optimisation,” Stud. Comput. Intell., vol. 927, pp. 5–13, 2021, doi: 10.1007/978-3-030-61111-8_2.

S.-W. Fei, Y.-B. Miao, and C.-L. Liu, “Chinese Grain Production Forecasting Method Based on Particle Swarm Optimization-based Support Vector Machine,” Recent Patents Eng., vol. 3, no. 1, pp. 8–12, 2009, doi: 10.2174/187221209787259947.

S. Sumathi and S. Paneerselvam, Computational Intelligence Paradigms Theory and Applications. 2010.

D. F. Shiau, “A hybrid particle swarm optimization for a university course scheduling problem with flexible preferences,” Expert Syst. Appl., vol. 38, no. 1, pp. 235–248, 2011, doi: 10.1016/j.eswa.2010.06.051.

R. Kohavi, P. Langley, and Y. Yun, “The utility of feature weighting in nearest-neighbor algorithms,” Proc. Ninth Eur. Conf. Mach. Learn., no. September 1997, pp. 85–92, 1997, [Online]. Available:

Gorunescu, F., "Data Mining: Concepts and Techniques", 2011. Verlag berlin Heidelberg: Springer.

M. F. Akay, “Support vector machines combined with feature selection for breast cancer diagnosis,” Expert Syst. Appl., vol. 36, no. 2 PART 2, pp. 3240–3247, 2009, doi: 10.1016/j.eswa.2008.01.009.

M. D. H. Rahiem, “Technological barriers and challenges in the use of ICT during the COVID-19 emergency remote learning,” Univers. J. Educ. Res., vol. 8, no. 11B, pp. 6124–6133, 2020, doi: 10.13189/ujer.2020.082248.

N. Tri Romadloni, I. Santoso, and S. Budilaksono, “Perbandingan Metode Naive Bayes, Knn Dan Decision Tree Terhadap Analisis Sentimen Transportasi Krl Commuter Line,” J. IKRA-ITH Inform., vol. 3, no. 2, pp. 1–9, 2019.

E. M. M. van der Heide, R. F. Veerkamp, M. L. van Pelt, C. Kamphuis, I. Athanasiadis, and B. J. Ducro, “Comparing regression, naive Bayes, and random forest methods in the prediction of individual survival to second lactation in Holstein cattle,” J. Dairy Sci., vol. 102, no. 10, pp. 9409–9421, Oct. 2019, doi: 10.3168/JDS.2019-16295.

M. R. Romadhon and F. Kurniawan, “A Comparison of Naive Bayes Methods, Logistic Regression and KNN for Predicting Healing of Covid-19 Patients in Indonesia,” 3rd 2021 East Indones. Conf. Comput. Inf. Technol. EIConCIT 2021, pp. 41–44, 2021, doi: 10.1109/EIConCIT50028.2021.9431845.

P. T. A. Barus Okky, “Prediksi kesembuhan pasien COVID-19 di Indonesia melalui terapi menggunakan metode Naïve Bayes,” J. Inf. Syst. Dev., vol. 6, no. 2, pp. 59–66, 2021, [Online]. Available:

How to Cite
Alvina Felicia Watratan, Ema Utami, & Anggit Dwi Hartanto. (2023). Comparison of Naive Bayes and PSO-Based Naive Bayes Algorithms for Prediction of Covid-19 Patient Recovery Data in Indonesia. Jurnal RESTI (Rekayasa Sistem Dan Teknologi Informasi), 7(4), 809 - 816.
Information Systems Engineering Articles