APPLICATION OF RANDOM FOREST ALGORITHM FOR ARRHYTHMIA DETECTION BASED ON ELECTROCARDIOGRAM DATA
DOI:
https://doi.org/10.33480/jitk.v11i2.7136Keywords:
arrhythmia, electrocardiogram, random forestAbstract
Arrhythmia is a common cardiac disorder that requires early detection to prevent serious complications. This study applied the Random Forest algorithm to enhance electrocardiogram (ECG) analysis and enable accurate arrhythmia classification. Unlike prior studies that focused primarily on resting ECG signals, this research incorporated dynamic data collected from 26 participants performing three physical activities for three minutes each, capturing physiological variations across multiple activity states. The Random Forest model was constructed and evaluated using ECG-derived temporal and morphological features to detect potential arrhythmias. Experimental results showed that the model achieved an accuracy of 97.4%, with precision, recall, and F1-score each reaching 98%, and an AUC of 0.97. However, several limitations remain, including the relatively small and homogeneous sample, as well as the short recording duration. Nonetheless, the proposed approach demonstrates strong potential to support early cardiac screening and real-time monitoring, particularly in portable and resource-limited healthcare applications
Downloads
References
S. Manao D. Sitanggang A. Sagala A. Oktarino and M. Turnip “Journal of Computer Networks Architecture and High Performance Computing APPLICATION OF KNN METHOD FOR CLASSIFICATION OF ARRHYTHMIA TYPES BASED ON ECG DATA Journal of Computer Networks Architecture and High Performance Computing vol. 7 no. 3 pp. 629–637 2025.
D. Farell et al “Classification of Arrhythmia Potential using the K-Nearest Neighbor Algorithm Internetworking Indones. J vol. 16 no. 2 pp. 3–9 2024.
M. P. Rivaldi “Overview of Heart and Vascular Disease Patients at Lamaddukelleng Sengkang Hospital in 2023 An Idea Heal. J vol. 5 no. 02 pp. 151–157 2025.
N. E. Almansouri et al., “Early Diagnosis of Cardiovascular Diseases in the Era of Artificial Intelligence: An In-Depth Review,” Cureus, vol. 16, no. 3, pp. 1–18, 2024, doi: 10.7759/cureus.55869.
M. Turnip I. Putra D. Telaumbanua A. Nicol A. Dharma and D. Sitanggang “Early Identification of Potential Heart Abnormalities with Decision Tree Method Proc. - 2024 2nd Int. Conf. Technol. Innov. Its Appl. ICTIIA 2024 2024 doi: 10.1109/ICTIIA61827.2024.10761420.
P. Kamga R. Mostafa and S. Zafar “The Use of Wearable ECG Devices in the Clinical Setting: a Review Curr. Emerg. Hosp. Med. Rep vol. 10 no. 3 pp. 67–72 2022 doi: 10.1007/s40138-022-00248-x.
C. Spaccarotella A. Polimeni C. Mancuso G. Pelaia G. Esposito and C. Indolfi “Assessment of Non-Invasive Measurements of Oxygen Saturation and Heart Rate with an Apple Smartwatch: Comparison with a Standard Pulse Oximeter J. Clin. Med vol. 11 no. 6 pp. 0–6 2022 doi: 10.3390/jcm11061467.
A. Emmett B. Kent A. James and J. March-McDonald “Experiences of health professionals towards using mobile electrocardiogram (ECG) technology: A qualitative systematic review J. Clin. Nurs vol. 32 no. 13–14 pp. 3205–3218 2023 doi: 10.1111/jocn.16434.
S. Bala et al “Comparative study on the quality of electrocardiogram and arrhythmia detection using wireless ambulatory Vigo SmartHeart Holter and conventional Holter MRIMS J. Heal. Sci vol. 12 no. 3 pp. 166–170 2024 doi: 10.4103/mjhs.mjhs_148_22.
P. C. Chang M. S. Wen C. C. Chou C. C. Wang and K. C. Hung “Atrial fibrillation detection using ambulatory smartwatch photoplethysmography and validation with simultaneous holter recording Am. Heart J vol. 247 pp. 55–62 2022 doi: 10.1016/j.ahj.2022.02.002.
A. A. Hamidi B. Robertson and J. Ilow “A new approach for ECG artifact detection using fine-KNN classification and wavelet scattering features in vital health applications Procedia Comput. Sci vol. 224 pp. 60–67 2023 doi: 10.1016/j.procs.2023.09.011.
Z. Li and H. Zhang “Fusing deep metric learning with KNN for 12-lead multi-labelled ECG classification Biomed. Signal Process. Control vol. 85 no. February p. 104849 2023 doi: 10.1016/j.bspc.2023.104849.
H. Yadav et al “CNN and Bidirectional GRU-Based Heartbeat Sound Classification Architecture for Elderly People Mathematics vol. 11 no. 6 pp. 1–25 2023 doi: 10.3390/math11061365.
R. R. Van De Leur et al “Discovering and Visualizing Disease-Specific Electrocardiogram Features Using Deep Learning: Proof-of-Concept in Phospholamban Gene Mutation Carriers Circ. Arrhythmia Electrophysiol vol. 14 no. 2 p. E009056 2021 doi: 10.1161/CIRCEP.120.009056.
N. Jannah S. Hadjiloucas and J. Al-Malki “Arrhythmia detection using multi-lead ECG spectra and Complex Support Vector Machine Classifiers Procedia Comput. Sci vol. 194 pp. 69–79 2021 doi: 10.1016/j.procs.2021.10.060.
K. Sharma and R. K. Sunkaria “Cardiac arrhythmia detection using cross-sample entropy measure based on short and long RR interval series J. Arrhythmia vol. 39 no. 3 pp. 412–421 2023 doi: 10.1002/joa3.12839.
M. Badr S. Al-Otaibi N. Alturki and T. Abir “Detection of Heart Arrhythmia on Electrocardiogram using Artificial Neural Networks Comput. Intell. Neurosci vol. 2022 2022 doi: 10.1155/2022/1094830.
B. Krithiga P. Sabari I. Jayasri and I. Anjali “Early detection of coronary heart disease by using naive bayes algorithm J. Phys. Conf. Ser vol. 1717 no. 1 2021 doi: 10.1088/1742-6596/1717/1/012040.
D. Setiawan Ali Muhammad and Siti Herawati Fransiska Dewi “Penerapan Algoritma Klasifikasi untuk Deteksi Dini Penyakit Jantung Koroner Berdasarkan Gejala Klinis Tek. J. Ilmu Tek. dan Inform vol. 5 no. 1 pp. 18–26 2025 doi: 10.51903/teknik.v5i1.706.
J. N. Sari P. Madona H. Kusryanto M. M. Zain and M. Valzon “Electrocardiogram signals classification using random forest method for web-based smart healthcare Int. J. Adv. Appl. Sci vol. 12 no. 2 pp. 133–143 2023 doi: 10.11591/ijaas.v12.i2.pp133-143.
Q. Mastoi H. Farman and S. Ahmed “Novel framework for Efficient Detection of QRS Morphology for The Cardiac Arrhythmia Classification | Journal of Computing & Biomedical Informatics vol. 05 no. 02 2023 [Online]. Available: https://jcbi.org/index.php/Main/article/view/190
A. Masbakhah, U. Sa’adah, and M. Muslikh, “Heart Disease Classification Using Random Forest and Fox Algorithm as Hyperparameter Tuning,” J. Electron. Electromed. Eng. Med. Informatics, vol. 7, no. 4, pp. 964–976, 2025, doi: 10.35882/jeeemi.v7i4.932.
Downloads
Published
How to Cite
Issue
Section
License
Copyright (c) 2025 Mardi Turnip, Fransido Situmorang, David William, Jennifer Patterson, Niki Ardila

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






-a.jpg)
-b.jpg)











