Journal of Artificial Intelligence and Engineering Applications (JAIEA)
Vol. 5 No. 3 (2026): June 2026

Comparison of Naive Bayes and KNN Algorithms for Heart Attack Disease Classification

Syahril Arsad (Universitas Muhammadiyah Pontianak)
Sucipto (Universitas Muhammadiyah Pontianak)
Barry Caesar Octariadi (Universitas Muhammadiyah Pontianak)



Article Info

Publish Date
15 Jun 2026

Abstract

This Heart attack is one of the leading causes of death worldwide and requires early diagnosis to reduce fatal risks. This study aims to compare the performance of the Naive Bayes and K-Nearest Neighbors (KNN) algorithms in classifying heart attack disease. The dataset used consists of medical records containing clinical parameters such as age, blood pressure, cholesterol level, and heart rate. The research methodology includes data preprocessing, splitting the dataset into training and testing sets, and evaluating performance using accuracy, precision, recall, and F1-score metrics. The results show that Naive Bayes demonstrates advantages in computational speed and performs well on smaller datasets, achieving an accuracy of 85%. In contrast, KNN provides better performance on larger datasets, reaching an accuracy of 90%, particularly when the optimal K value is applied. These findings indicate that algorithm selection for heart attack classification depends on dataset characteristics and specific implementation needs. This study is expected to contribute to the development of artificial intelligence–based clinical decision support systems for early heart attack diagnosis and improved healthcare outcomes.

Copyrights © 2026






Journal Info

Abbrev

JAIEA

Publisher

Subject

Automotive Engineering Computer Science & IT Control & Systems Engineering

Description

The Journal of Artificial Intelligence and Engineering Applications (JAIEA) is a peer-reviewed journal. The JAIEA welcomes papers on broad aspects of Artificial Intelligence and Engineering which is an always hot topic to study, but not limited to, cognition and AI applications, engineering ...