Digital Zone: Jurnal Teknologi Informasi dan Komunikasi (Nov 2024)
Comparative Analysis of KNN and Neavy Bayes Algorithms in Socio-Economic Data Classification in Indonesia
Abstract
The global economy continues to recover as trade flows, employment, and incomes improve. However, the economic recovery is uneven across countries and business sectors. The economic recovery has also resulted in structural changes, meaning that some sectors, jobs, technologies and behaviors will not return to pre-pandemic trends. Future developments depend on local economic conditions. The economy has the most important aspect in a country where the economy makes a country capable of meeting its needs by utilizing limited resources. This study aims to compare two data mining classification algorithms, namely Naïve Bayes and K-Nearest Neighbor, in analyzing socio-economic data in Indonesia. Based on this problem, the data mining classification method is used in determining the algorithm that is suitable for predicting socio-economic data in Indonesia. The two algorithms used are K-NN and Naive Bayes. After testing the two algorithms using confusion matrix and K-Fold Cross Validation, the results obtained from the two models have an accuracy of Naïve Bayes 98.25% and K-NN 97.78% and the results of K-Fold Cross Validation Naïve Bayes 98% and K-NN 96%. Naïve Bayes is superior to K-NN in this context of socioeconomic data classification in Indonesia, especially in terms of accuracy. Although K-NN shows good consistency, Naïve Bayes provides more accurate results.
Keywords