Implementasi Algoritma Support Vector Machine (SVM) dan Random Forest Untuk Klasifikasi Penyakit Hipertensi Berdasarkan Data Kesehatan - Azhaar, Siti Alia; Mudzakir, Tohirin Al; Novita, Hilda Yulia; Faisal, Sutan (Universitas Budi Darma, 2025)
One of the most common non-communicable diseases causing death in Indonesia is hypertension. At one community health center, the prevalence of hypertension is quite high. Based on examination results, more than 1,000 patients are diagnosed with hypertension each year. The issue faced at this health center is the lack of structured data classification for hypertensive and normal patients. The objective of this study is to compare the performance of the Support Vector Machine (SVM) and Random Forest (RF) algorithms in creating a hypertension classification model based on health examination data from the Anggadita Health Center. Data from 2,500 patients was collected and preprocessed, including handling missing values, removing duplicate data, transforming data using label encoding, and dividing the data into training and testing sets. The SVM method applied a Radial Basis Function (RBF) kernel, while the RF consisted of 100 decision trees. Evaluation was conducted using a confusion matrix to calculate accuracy, precision, recall, and F1-score. The results showed that the SVM method achieved an accuracy of 93%, precision of 0.96 (Normal) and 0.90 (Hypertension), and F1-scores of 0.94 and 0.92. Meanwhile, the RF model showed superior performance with an accuracy of 96%, precision of 0.97 (Normal) and 0.95 (Hypertension), and F1-scores of 0.97 and 0.95, respectively. Thus, the Random Forest algorithm performs better in classifying hypertension data and can be implemented as a tool to assist healthcare institutions in managing patient data.