Comparative Analysis of 2024 Election Results Classification Using Machine Learning (K-Means + KNN) and Deep Learning (MLP) Approaches
DOI:
https://doi.org/10.55749/ijdrr.v1i1.184Keywords:
Election Classification, Gower Distance, K-Means, K-Nearest Neighbors: Multilayer PerceptronAbstract
General elections, as a foundation of democracy, require a thorough understanding of voting patterns influenced by socio-economic factors. This research compares two classification approaches: K-Means combined with K-Nearest Neighbors (KNN) and Multilayer Perceptron (MLP), in predicting the 2024 election results based on education and economic indicators. The dataset comprises 514 districts and municipalities in Indonesia, using six numerical features from the Central Statistics Agency (BPS) and class labels derived from the presidential candidate pair with the highest vote share. To address the mixed data structure, the KNN model employed Gower Distance, while the MLP model utilized standardized data and hyperparameter tuning via Bayesian Optimization. Evaluation results indicate that the K-Means + KNN model achieved an accuracy of 0.8932 and a weighted F1 score of 0.8709. Conversely, the MLP model attained the highest ROC-AUC score of 0.7420, reflecting its advantage in probabilistic estimation. These findings suggest that model selection should align with the primary classification objective, either predictive precision or the ability to model uncertainty in minority classes.
References
[1] D. K. Kirana, M. O. E. Setiawan, and S. Priza, “Demokrasi Indonesia dalam kapasitas pemilu yang luber jurdil,” Journal of Law and Social Society, vol. 1, no. 1, 2024, doi: 10.70656/jolasos.v1i1.80.
[2] S. Rahmawati and H. Halking, “Pengaruh tingkat status sosial ekonomi terhadap pemahaman pemilu pemilih pemula pada pilpres 2024 di desa suka mulia kecamatan secanggang kabupaten Langkat,” Madani Jurnal Politik dan Sosial Kemasyarakatan, vol. 16, no. 02, 2024, doi: 10.52166/madani.v16i02.7385.
[3] D. Zhao et al., “K-means clustering and kNN classification based on negative databases,” Appl. Soft Comput., vol. 110, 2021, doi: 10.1016/j.asoc.2021.107732.
[4] F. Murtagh, “Multilayer perceptrons for classification and regression,” Neurocomputing, vol. 2, no. 5–6, 1991, doi: 10.1016/0925-2312(91)90023-5.
[5] R. K. Jain and G. K. Singh, “Clustering-based hybrid approach for multiclass classification using SVM,” in Advances in Intelligent Systems and Computing, 2020. doi: 10.1007/978-981-32-9515-5_35.
[6] S. Gupta, B. Parekh, and A. Jivani, “A hybrid model of clustering and classification to enhance the performance of a classifier,” in Communications in Computer and Information Science, 2019. doi: 10.1007/978-981-15-0111-1_34.
[7] A. Alarbi and Z. Albayrak, “Core classifier algorithm: A hybrid classification algorithm based on class core and clustering,” Applied Sciences (Switzerland), vol. 12, no. 7, 2022, doi: 10.3390/app12073524.
[8] M. Badrul, “Perbandingan algoritma C4.5 dan neural network untuk memprediksi hasil pemilu legislatif dki jakarta,” Jurnal Pilar Nusa Mandiri, vol. 10, no. 2, pp. 127–138, 2014.
[9] T. Jo, “K Means Algorithm,” in Machine Learning Foundations, Cham: Springer International Publishing, 2021, pp. 217–240. doi: 10.1007/978-3-030-65900-4_10.
[10] G. Tuerhong and S. B. Kim, “Gower distance-based multivariate control charts for a mixture of continuous and categorical variables,” Expert Syst. Appl., vol. 41, no. 4 PART 2, 2014, doi: 10.1016/j.eswa.2013.08.068.
[11] K. B. Prakash, “Multilayer Perceptron (in Neural Networks),” in Machine Learning for Industrial Applications, Wiley, 2025, pp. 51–61. doi: 10.1002/9781394268993.ch3.
[12] S. Adiningsi, B. Pramono, A. Mashur Sajiah, and R. Adi Saputra, “Identifikasi kualitas ikan cakalang segar berbasis citra mata menggunakan metode Support Vector Machine (SVM) dengan fungsi kernel radial basis function,” JATI (Jurnal Mahasiswa Teknik Informatika), vol. 9, no. 1, 2025, doi: 10.36040/jati.v9i1.12641.
