Defect Rate Prediction in Manufacturing Process Using K-Nearest Neighbor Algorithm
Abstract
The efficiency and effectiveness in the manufacturing industry are significantly impacted by artificial intelligence technology. An important application involves the improvement of product quality, which is measurable through the defects occurring during the production process. This research is aimed at predicting defects in the manufacturing process using the K-Nearest Neighbor (KNN) algorithm with various distance measurement methods, namely Euclidean, Minkowski, and Manhattan distances. The research methodology is composed of four stages: dataset collection, data preprocessing, modeling, and evaluation. The focus of this research is on the optimal K value and the conditions that yield the highest accuracy, considering various scenarios of training and test data splitting ratios and different random state values. The test results indicate that the Minkowski distance method, with a data division ratio of 80% for training data, 20% for test data, and a random state value of 32, provides the best performance, with an optimal K value of 10 and an accuracy of 86.41%.
References
[2] M. Rifaldi and W. Sudarwati, “Penerapan Metode Six Sigma dan FMEA Sebagai Usaha Untuk Mengurangi Cacat Pada Produk Bracket,” in Seminar Nasional Sains dan Teknologi 2024, Fakultas Teknik Universitas Muhammadiyah Jakarta, (2024) April 30.
[3] T. Arifin, W. Sanjaya, I. M. M. Shahih, and E. Sopiah, “Pemanfaatan Algoritma Restricted Boltzmann Machines (RBM) Untuk Prediksi Dini Kanker Paru-Paru,” in Jurnal Responsif, Vol. 5, No. 2, 2023, pp. 138-146.
[4] Iswanto, Tulus, and P. Sihombing, “Comparison of Distance Models on K-Nearest Neighbor Algorithm in Stroke Disease Detection,” in Applied Technology and Computing Science Journal, Vol. 4, No. 1, 2021, pp. 63-68.
[5] Putri, C. S. Hardiana, E. Novfuja, F. T. P. Siregar, Rahmaddeni, Y. Fatma, and R. Wahyuni, “Komparasi Algoritma K-NN, Naïve Bayes dan SVM Untuk Prediksi Kelulusan Mahasiswa Tingkat Akhir,” in Malcom: Indonesian Journal of Machine Learning and Computer Science, Vol. 3, Issue. 1, 2023, pp. 20-26.
[6] E. Irawan and R. S. Wahono, “Penggunaan Random Under Sampling Untuk Penanganan Ketidakseimbangan Kelas Pada Prediksi Cacat Software Berbasis Neural Network,” in Journal of Software Engineering, Vol. 1, No. 2, 2015, pp. 92-100.
[7] G. H. Martono and N. Sulistianingsih, “Perbandingan Matriks Jarak Pada Algoritma K-NN Untuk Prediksi Penyakit Diabetes,” in JoMI: Journal of Millennial Informatics, Vol. 2, No. 1, 2024, pp. 1-6.
[8] M. M. Abualhaj, A. A. Abu-Shareha, Q. Y. Shambour, A. Alsaaidah, S. N. Al-Khatib, and M. Anbar, “Customized K-Nearest Neighbors’ Algorithm for Malware Detection,” in International Journal of Data and Network Science., Vol. 8, Issue. 1, 2024, pp. 431-438.
[9] Salsabila, S. Martha, and W. Andani, “Komparasi Algoritma K-Nearest Neighbor Dengan Euclidean Distance dan Manhattan Distance Untuk Klasifikasi Stunting Balita (Studi Kasus : Puskesmas Kelurahan Parit Mayor),” in Buletin Ilmiah Matematika, Statistika dan Terapannya (Bimaster), Vol. 13, No. 2, 2024, pp. 285-292.
[10] M. Nishom, “Perbandingan Akurasi Euclidean Distance, Minkowski Distance, dan Manhattan Distance pada Algoritma K-Means Clustering Berbasis Chi-Square,” in Jurnal Informatika: Jurnal Pengembangan IT (JPIT), Vol. 4, No. 1, 2019, pp. 20-24.
[11] R. Lina and D. C. Wati, “Klasifikasi Pengeluaran per Kapita di Tiga Provinsi Sulawesi Menggunakan K-Nearest Neighbor,” in J Statistika, No. 16, No. 1, 2023, pp. 395-406.
[12] Sudriyanto, F. Syahro, and N. Fitriani, “Perbandingan Performa Model Machine Learning Support Vector Machine, Neural Network, dan K-Nearest Neighbors Dalam Prediksi Harga Saham,” in JARS: Journal of Advanced Research in Informatics, Vol. 2, No. 1, 2023, pp. 1-9.
[13] M. S. Pangestu and M. A. Fitriani, “Perbandingan Perhitungan Jarak Euclidean Distance, Manhattan Distance, dan Cosine Similarity Dalam Pengelompokan Data Bibit Padi Menggunakan Algoritma K-Means,” in Sainteks, Vol. 19, No. 2, 2022, pp. 141-155.

This work is licensed under a Creative Commons Attribution 4.0 International License.