Naive Bayes Algorithm with Feature Selection Using Particle Swarm Optimization

  • Sri Astuti Thamrin Universitas Hasanuddin, Indonesia
  • Iwan Kurniawan Universitas Hasanuddin, Indonesia
  • Siswanto Siswanto Universitas Hasanuddin, Indonesia
Keywords: COVID-19; Classification; Naïve bayes; particle swarm optimization; Twitter.

Abstract

The COVID-19 vaccine in Indonesia has led to the emergence of public opinion which is conveyed on social media such as Twitter. One of the analyses that can be done to produce various information from public opinion is sentiment analysis. Sentiment analysis is used to determine whether an opinion tends to be positive or negative. This study aims to classify the public opinion of the COVID-19 vaccine in Indonesia with sentiment analysis and to visualize the location of the sentiment of the COVID-19 vaccine tweet data in Indonesia. To achieve this aim, the Naïve Bayes algorithm with Particle Swarm Optimization (PSO) feature selection was used. This study uses opinions into positive and negative class sentiments towards 2,547 tweets related to the COVID-19 vaccine in Indonesia from January to June 2021. The results show that the distribution of positive and negative class sentiments is 2,328 and 219, respectively. In addition, the positive sentiment for the COVID-19 vaccine was dominated by people on the island of Java based on a random number matrix initialized by the PSO method. The classification of public opinion on Twitter media provides accurate and optimal performance results using a combination of the Naïve Bayes algorithm with PSO feature selection. The results of the combination of these methods have accuracy and F1 score values of 91.28% and 95.38%, respectively. The visualization of geo-spatial mapping showed that positive sentiments related to the COVID-19 vaccine exist in almost all regions in Indonesia but are dominated by the Jabodetabek area.

References

Ahmed, Zahid, Biju Issac, & Sufal Das. Ok-NB: An Enhanced OPTICS and k-Naive Bayes Classifier for Imbalance Classification with Overlapping. IEEE Access (2024). doi. 10.1109/ACCESS.2024.3391749.
Alsaeedi, Abdullah, & Khan, Mohammad Zubair. (2019). A Study on Sentiment Analysis Techniques of Twitter Data. IJACSA) International Journal of Advanced Computer Science and Applications, 10(2). https://dx.doi.org/10.14569/IJACSA.2019.0100248.
Bahri, Muhammad Syamsul, Hermawan, Agus, Pricilia Kondy, Evlyn, Joyce Semida, Refa, & Siswanto. (2022). Performance Comparison of Supporting Vector Machine Method without or with Particle Swarm Optimization Based on Sentiment Analysis WhatsApp Review. International Journal of Academic and Applied Research, 6(6), 94–101. www.ijeais.org/ijaar.
Bowdle, Andrew, & Munoz-Price, L. Silvia. (2020). Preventing Infection of Patients and Healthcare Workers Should Be the New Normal in the Era of Novel Coronavirus Epidemics. Anesthesiology, 132(6), 1292–1295. https://doi.org/10.1097/ALN.0000000000003295.
Claudy, Yessivha Imanuela, Setya Perdana, Rizal, & Fauzi, M. Ali. (2018). Klasifikasi Dokumen Twitter Untuk Mengetahui Karakter Calon Karyawan Menggunakan Algoritme K-Nearest Neighbor (KNN). Jurnal Pengembangan Teknologi Informasi Dan Ilmu Komputer, 2(8), 2761–2765. https://j-ptiik.ub.ac.id/index.php/j-ptiik/article/view/1967.
Effendy, Veronikha. (2015). Analisis Sentimen Berbahasa Indonesia Dengan Pendekatan Lexicon Based (Studi Kasus: Solusi Pengelolaan Sampah). Jurnal Ilmiah Komputer Dan Informatika (KOMPUTA), 55(1). https://doi.org/10.34010/komputa.v4i1.2411.
Fanissa, Shima, Fauzi, M. Ali, & Adinugroho, Sigit. (2018). Analisis Sentimen Pariwisata di Kota Malang Menggunakan Metode Naive Bayes dan Seleksi Fitur Query Expansion Ranking. Jurnal Pengembangan Teknologi Informasi Dan Ilmu Komputer, 2(8), 2766–2770. https://j-ptiik.ub.ac.id/index.php/j-ptiik/article/view/1962.
Hickman, Louis, Thapa, Stuti, Tay, Louis, Cao, Mengyang, & Srinivasan, Padmini. (2022). Text Preprocessing for Text Mining in Organizational Research: Review and Recommendations. Organizational Research Methods, 25(1), 114–146. https://doi.org/10.1177/1094428120971683.
Hyuningtyas, Ratih Yulia, Retno Sari, and Wina Yusnaeni. Particle swarm optimization for feature selection in sentiment analysis on the application of digital payments OVO using the algorithm of Naive Bayes. AIP Conference Proceedings. Vol. 2714. No. 1. AIP Publishing, 2023. https://doi.org/10.1063/5.0129011.
Khder, Moaiad. (2021). Web Scraping or Web Crawling: State of Art, Techniques, Approaches and Application. International Journal of Advances in Soft Computing and Its Applications, 13(3), 145–168. https://doi.org/10.15849/IJASCA.211128.11.
Lyu, Joanne Chen, Eileen Le Han, & Garving K. Luli. COVID-19 vaccine–related discussion on Twitter: topic modeling and sentiment analysis. Journal of medical Internet research 23.6 (2021): e24435. doi:10.2196/24435.
Mazdadi, Muhammad Itqan, Andi Farmadi, and Dwi Kartini. Implementation of Particle Swarm Optimization Feature Selection on Naïve Bayes for Thoracic Surgery Classification. Journal of Electronics, Electromedical Engineering, and Medical Informatics 5.3 (2023): 150-158. https://doi.org/10.35882/jeemi.v5i3.305.
Palanisamy, Tamilselvi, Sadayan, Geetha, & Pathinetampadiyan, Nagasankar. (2022). Neural network–based leaf classification using machine learning. Concurrency and Computation: Practice and Experience, 34(8). https://doi.org/10.1002/cpe.5366.
Papazoglou, G. and Biskas, P., 2023. Review and comparison of genetic algorithm and particle swarm optimization in the optimal power flow problem. Energies, 16(3), p.1152. https://doi.org/10.3390/en16031152.
Sağlam, Fatih, and Mehmet Ali Cengiz. Local resampling for locally weighted Naïve Bayes in imbalanced data. Computing 106.1 (2024): 185-200. https://doi.org/10.1007/s00607-023-01219-0.
Tijjani, Sani, Mohd Nadhir Ab Wahab, and Mohd Halim Mohd Noor. An enhanced particle swarm optimization with position update for optimal feature selection. Expert Systems with Applications 247 (2024): 123337. https://doi.org/10.1016/j.eswa.2024.123337.
Published
2024-06-30
How to Cite
[1]
S. A. Thamrin, I. Kurniawan, and S. Siswanto, “Naive Bayes Algorithm with Feature Selection Using Particle Swarm Optimization”, Jurnal Varian, vol. 7, no. 2, pp. 127 - 136, Jun. 2024.
Section
Articles

Most read articles by the same author(s)