Penerapan Algoritma K-Means Untuk Klasterisasi Pasien Berdasarkan Riwayat Kesehatan dan Jenis Layanan Kesehatan - Riza Dwi Putri; Rizki Muliono (Mahesa Research Institute, 2025)
The digital transformation in the healthcare sector has led to the generation of large and complex datasets, requiring appropriate analytical techniques to extract meaningful information. This study aims to implement the K-Means algorithm to cluster patients based on their health history and the types of healthcare services they use, in order to support data-driven decision-making in hospital management. The dataset consists of 1,459 patient records from Sapta Medika Hospital, covering attributes such as age, gender, chronic disease history (diabetes, hypertension, heart disease), visit frequency, medical costs, and healthcare service types including outpatient, inpatient, emergency (ER), and telemedicine. The research stages involved data preprocessing, transformation, categorical data encoding, numerical data normalization, and clustering using the K-Means algorithm. The optimal number of clusters was determined using the Elbow Method, which identified K = 3. The clustering results revealed three distinct patient groups: chronic patients with high treatment costs and frequent inpatient services, routine patients with stable conditions mostly using outpatient services, and general patients, usually younger with mild conditions. Principal Component Analysis (PCA) was used to visualize the cluster separation, while the clustering quality was evaluated with a Silhouette Score of 0.47. These results conclude that the K-Means algorithm is effective in producing meaningful and practical patient segmentation, which can be used to design more adaptive, efficient, and patient-centered healthcare service strategies.