Sistemasi: Jurnal Sistem Informasi
Vol 15, No 5 (2026): Sistemasi: Jurnal Sistem Informasi

Classification of Diabetes Mellitus using the K-Nearest Neighbor (KNN) Algorithm: A Case Study of Patient Data at Salatiga Regional Hospital

Gwen Theresia Grandis Aritonang (Universitas Kristen Satya Wacana - UKSW)
Magdalena A. Ineke Pakereng (Universitas Kristen Satya Wacana)



Article Info

Publish Date
28 May 2026

Abstract

One of the most common metabolic diseases in Indonesia, including at RSUD Salatiga, is Diabetes Mellitus. Early diagnosis of this disease is crucial to prevent the development of more severe complications; however, this process is often challenging because the initial symptoms are difficult to recognize. This study implements the K-Nearest Neighbor (KNN) algorithm as a classification technique for predicting diabetes mellitus risk based on clinical data from patients at RSUD Salatiga. The dataset used in this research included variables such as gender, age, hypertension history, glucose level, HbA1c level, smoking status, liver disease history, and Body Mass Index (BMI). The research stages consisted of data collection, preprocessing (data cleaning, normalization, and variable encoding), feature selection, and optimization of the k parameter. Model evaluation was conducted using a confusion matrix with performance metrics including accuracy, precision, recall, and F1-score. The results indicate that the KNN algorithm achieved the highest accuracy of 92.08% when feature selection was applied with k = 6. This improvement demonstrates that both k-parameter optimization and feature selection significantly affect model performance. Therefore, the KNN algorithm can serve as an effective early prediction tool to assist medical personnel in identifying diabetes mellitus patients, enabling faster and more accurate interventions.

Copyrights © 2026






Journal Info

Abbrev

stmsi

Publisher

Subject

Computer Science & IT Electrical & Electronics Engineering

Description

Sistemasi adalah nama terbitan jurnal ilmiah dalam bidang ilmu sains komputer program studi Sistem Informasi Universitas Islam Indragiri, Tembilahan Riau. Jurnal Sistemasi Terbit 3x setahun yaitu bulan Januari, Mei dan September,Focus dan Scope Umum dari Sistemasi yaitu Bidang Sistem Informasi, ...