Application of the K-Nearest Neighbor Algorithm for Performance Classification Based on Students' Academic Performance and Lifestyle

Authors

  • Zaehol Fatah Universitas Ibrahimy, Indonesia

DOI:

https://doi.org/10.70609/g-tech.v10i3.10315

Keywords:

Academic Performance, Classification, K-Nearest Neighbor, Lifestyle

Abstract

Conventional student performance evaluation mechanisms often fail to detect a decline in performance in a timely manner because they overlook non-academic factors. This study aims to build a comprehensive student performance classification model by simultaneously integrating academic performance and lifestyle patterns using the k-Nearest Neighbor (k-NN) algorithm. The research method utilizes 1,000 student datasets from Kaggle, which were divided using the Stratified Split method into 80% training data and 20% test data. Simulations were run using RapidMiner Studio software with the Euclidean Distance metric and varying k values of 3, 5, and 7. Experimental results show the model achieved a peak global accuracy of 97% at the optimal k value of 5, where the model successfully classified 194 out of 200 test data samples correctly. Lifestyle attributes independently influence students’ academic performance, with the number of study hours per day being the most significant predictor (47.94%). Sensitivity analysis confirms that k=5 is the optimal value to avoid data noise at k=3 (94.50%) and oversmoothing at k=7. In conclusion, this k-NN-based model is highly suitable for application as an early warning system for schools to provide proactive and personalized pedagogical interventions.

References

Ajitama, A. H., & Rosa, P. H. P. (2022). Klasifikasi Prestasi Akademik Mahasiswa Berdasar Hasil Tes Potensi Akademik Menggunakan Support Vector Machine. Prosiding Seminar Nasional Ilmu Sosial Dan Teknologi (SNISTEK), 4, 319–323.

Hidayatullah, A. V. D., Nilogiri, A., & Al Faruq, H. A. (2022). Klasifikasi Siswa Berprestasi Menggunakan Metode K-Nearest Neighbor (KNN) Pada SMA Negeri 2 Situbondo. Jurnal Smart Teknologi, 3(6), 602–611.

Aswandi, A. S., & Nurjaya. (2025). Penerapan Algoritma k-Nearest Neighbor untuk Prediksi Kinerja Akademik Mahasiswa. JISTech : Journal of Information Systems and Technology, 2(2), 87–92. https://doi.org/10.71234/jistech.v2i2.101

Buzducea (Drăgoi), C.-A., Drăgoi, M.-V., Cristoiu, C., Puiu, R.-A., Puiu, M., Petrea, G., & Navligu, B.-C. (2026). Machine Learning in Education: Predicting Student Performance and Guiding Institutional Decisions. Education Sciences, 16(1), 1–14. https://doi.org/10.3390/educsci16010076

Gharkan, M. (2025). Predicting Student Performance Using a Hybrid Model Based on Machine Learning and Feature Selection Techniques. Journal of Information Systems Engineering and Management, 10(4), 192–199. https://doi.org/10.52783/jisem.v10i4.8921

Fatah, Z., & Hali Mukid. (2026). Analisis Kelulusan Siswa Menggunakan Metode KNN (K-Nearest Neighbor) pada Dataset “Students Performance.” Jurnal Informatika Dan Teknik Elektro Terapan, 14(1), 390–396. https://doi.org/10.23960/jitet.v14i1.8384

Husen, D. (2026). Predictive Modeling of Student Academic Performance Using Regression Methods. Bit-Tech, 8(3), 3194–3204. https://doi.org/10.32877/bt.v8i3.3391

Kotjek, R., Pricillia, Wijaya, F., Wahyudi, M., Sumanto, & Budiman, A. (2025). Klasifikasi Nilai Ujian Siswa Berdasarkan Kebiasaan Belajar Menggunakan K-Nearest Neighbor dan Support Vector Machine. Jurnal Sains Informatika Terapan (JSIT), 4(2), 63–71. https://doi.org/10.62357/jsit.v4i2.612

Mahsun, M., Hariyadi, M. A., & Harini, S. (2025). Utilizing Random Forest Method for Predicting Student Dropout Risk in Madrasah Environments. Journal of Information Systems and Informatics, 7(4), 3434–3453. https://doi.org/10.63158/journalisi.v7i4.1364

Martey, E. M., Abdullah, A., & Appiah, O. (2024). Predicting Student Academic Performance Using an Optimised Regression Machine Learning Model. IEEE International Conference on Adaptive Science and Technology, ICAST, 1–7. https://doi.org/10.1109/ICAST61769.2024.10856498

Muhaimin, A., Amin Hariyadi, M., & Imamudin, M. I. (2024). Klasifikasi Prestasi Akademik Siswa Berdasarkan Nilai Rapor dan Kedisiplinan dengan Metode K-Nearest Neighbor. Jurnal Ilmu Komputer Dan Sistem Informasi (JIKOMSI), 7(1), 193–202. https://doi.org/10.55338/jikomsi.v7i1.2865

Pan, J., Zhao, Z., & Han, D. (2025). Academic Performance Prediction Using Machine Learning Approaches: A Survey. IEEE Transactions on Learning Technologies, 18. https://doi.org/10.1109/TLT.2025.3554174

Romero, C., & Ventura, S. (2010). Educational Data Mining: A Review of the State of the Art. Systems, Man, and Cybernetics, Part C: Applications and Reviews, IEEE Transactions On, 40, 601–618. https://doi.org/10.1109/TSMCC.2010.2053532

Sastra, A., Sabri, K., Yanto, B., Asmen, F., Inal, I., & Crisdianto, A. (2023). Analisis Pengaruh Gaya Hidup Mahasiswa terhadap Indeks Prestasi Kumulatif (IPK) Menggunakan Model Regresi. KERNEL: Jurnal Riset Inovasi Bidang Informatika Dan Pendidikan Informatika, 4(2), 89–101. https://doi.org/10.31284/j.kernel.2023.v4i2.7384

Shafie, S. N. M., Shahri, M. S., Izuddi, N. N. N. I., Shukri, N. M., Aziz, N. A., Amran, A., & Nafi, M. N. A. (2022). Association between Lifestyle-Related Behaviors and Academic Performance among Students. Proceedings, 82(1). https://doi.org/10.3390/proceedings2022082105

Sofiyatus Zawiyah, Lailatul Qodriyah, & Moh. Badri Tamam. (2025). Klasifikasi Prestasi Akademik Mahasiswa Menggunakan Metode Random Forest. Journal of Digital Business and Information Technology, 1(2). https://doi.org/10.23971/jobit.v1i2.317

Teoh, C. W., Ho, S. B., Dollmat, K. S., & Tan, C. H. (2022). Predicting Student Performance from Video-Based Learning System: A Case Study. Journal of Logistics, Informatics and Service Science, 9(3), 64–77. https://doi.org/10.33168/LISS.2022.0306

TYCS, H. J. D., SYCS, S. S. C., & Nayak, A. A. (2025). The Impact of Sleep Patterns on the Academic Performance of Undergraduate Students: A Behavioral and Cognitive Study. The Voice of Creative Research, 7(2), 410–418. https://doi.org/10.53032/tvcr/2025.v7n2.50

Villar, A., & de Andrade, C. R. V. (2024). Supervised Machine Learning Algorithms for Predicting Student Dropout and Academic Success: A Comparative Study. Discover Artificial Intelligence, 4(2), 1–24. https://doi.org/10.1007/s44163-023-00079-z

Widaningsih, S. (2022). Penerapan Data Mining untuk Memprediksi Siswa Berprestasi dengan Menggunakan Algoritma K Nearest Neighbor. JATISI (Jurnal Teknik Informatika Dan Sistem Informasi), 9(3), 2598–2611. https://doi.org/10.35957/jatisi.v9i3.859

Yadav, A. (2025). Predicting Student Academic Performance: A Machine Learning Analysis of Study Habits and Lifestyle Factors. International Journal of Advanced Research, 13(9), 244–252. https://doi.org/10.21474/ijar01/21706

Yağcı, M. (2022). Educational Data Mining: Prediction of Students’ Academic Performance Using Machine Learning Algorithms. Smart Learning Environments, 9(11), 1–19. https://doi.org/10.1186/s40561-022-00192-z

Zaragosa, A. R., & Wenceslao, J. (2026). A Comparative Analysis of Data Mining Algorithms in Predicting the Academic Performance of University Students. 2026 7th International Conference on Mobile Computing and Sustainable Informatics (ICMCSI), 1563–1568. https://doi.org/10.1109/ICMCSI67283.2026.11412479

Downloads

Published

2026-07-10

How to Cite

Application of the K-Nearest Neighbor Algorithm for Performance Classification Based on Students’ Academic Performance and Lifestyle. (2026). G-Tech: Jurnal Teknologi Terapan, 10(3), 1226-1234. https://doi.org/10.70609/g-tech.v10i3.10315

Most read articles by the same author(s)