eprintid: 96574 rev_number: 18 eprint_status: archive userid: 599 dir: disk1/00/09/65/74 datestamp: 2025-08-05 06:50:46 lastmod: 2025-08-05 06:50:46 status_changed: 2025-08-05 06:50:46 type: thesis metadata_visibility: show creators_name: RAHMAN, RAVI ADITYA creators_nimnip: 41521010052 creators_id: raviadityarahman13@gmail.com contributors_type: http://www.loc.gov/loc.terms/relators/THS contributors_name: Hakim, Lukman contributors_nidn: 0327107701 contributors_id: lib.mercubuana.ac.id title: IMPLEMENTASI METODE STACKING MENGGUNAKAN RANDOM FOREST DAN XGBOOST UNTUK MENGKLASIFIKASI RISIKO SERANGAN JANTUNG ispublished: pub subjects: S006.31 subjects: S025.46 subjects: S518.1 subjects: S616.1 divisions: 415 full_text_status: restricted keywords: Serangan Jantung, Klasifikasi, Stacking, Random Forest, XGBoost. abstract: Heart attack disease is one of the leading causes of death in the world and is a significant burden on the health system in Indonesia. Accurate early detection is essential in preventing and managing the risk of heart attack. This study aims to develop a heart attack risk classification model by applying the ensemble learning method using the stacking approach, which combines two machine learning algorithms, namely the Random Forest and XGBoost algorithms. The dataset used is secondary data entitled "Heart Attack Prediction in Indonesia" downloaded from Kaggle, with a total of 158,355 individual data. The research process includes data preprocessing stages, such as categorical variable numbering, normalization using MinMaxScaler, and class balancing. The Random Forest and XGBoost models were each evaluated individually before being combined using the stacking technique with XGBoost as a meta-learner. Performance evaluation was carried out using cross validation and metrics of accuracy, precision, recall, and F1-score. The results showed that the stacking model produced the highest accuracy of 85%, better than the Random Forest (76%) and XGBoost (74%) models. Feature importance analysis shows that features such as history of heart disease, hypertension, and cholesterol levels have significant contributions in the classification process. The results of this study prove that the application of the stacking method can improve the performance of machine learning algorithm models in the classification of heart attack disease. Keywords: Heart Attack, Classification, Stacking, Random Forest, XGBoost. Penyakit serangan jantung merupakan salah satu penyebab kematian utama di dunia dan menjadi beban signifikan bagi sistem kesehatan di Indonesia. Deteksi dini yang akurat sangat penting dalam upaya pencegahan dan pengelolaan risiko serangan jantung. Penelitian ini bertujuan untuk mengembangkan model klasifikasi risiko serangan jantung dengan menerapkan metode ensemble learning menggunakan pendekatan stacking, yang menggabungkan dua algoritma machine learning yaitu algoritma Random Forest dan XGBoost. Dataset yang digunakan adalah data sekunder berjudul “Heart Attack Prediction in Indonesia” yang diunduh dari Kaggle, dengan total 158.355 data individu. Proses penelitian mencakup tahapan data preprocessing, seperti penomoran variabel kategorikal, normalisasi menggunakan MinMaxScaler, dan penyeimbangan kelas. Model Random Forest dan XGBoost masing-masing dievaluasi secara individual sebelum digabungkan menggunakan teknik stacking dengan XGBoost sebagai meta-learner. Evaluasi kinerja dilakukan menggunakan cross validation dan metrik akurasi, presisi, recall, serta F1-score. Hasil menunjukkan bahwa model stacking menghasilkan akurasi tertinggi sebesar 85%, lebih baik dibandingkan model Random Forest (76%) dan XGBoost (74%). Analisis feature importance menunjukkan bahwa fitur-fitur seperti riwayat penyakit jantung, hipertensi, dan kadar kolesterol memiliki kontribusi signifikan dalam proses klasifikasi. Hasil penelitian ini membuktikan bahwa penerapan metode stacking dapat memberikan peningkatan kinerja model algoritma machine learning dalam klasifikasi penyakit serangan jantung. Kata kunci: Serangan Jantung, Klasifikasi, Stacking, Random Forest, XGBoost. date: 2025-07-19 date_type: published pages: 49 institution: Universitas Mercu Buana Jakarta department: Biro Perpustakaan thesis_type: s1 thesis_name: tugas_akhir kampus: meruya call_number_cd: FIK/INFO. 25 116 kota: Jakarta kolasi: xii, 49 hlm citation: RAHMAN, RAVI ADITYA (2025) IMPLEMENTASI METODE STACKING MENGGUNAKAN RANDOM FOREST DAN XGBOOST UNTUK MENGKLASIFIKASI RISIKO SERANGAN JANTUNG. S1 thesis, Universitas Mercu Buana Jakarta. document_url: http://repository.mercubuana.ac.id/96574/1/01%20COVER.pdf document_url: http://repository.mercubuana.ac.id/96574/2/02%20BAB%201.pdf document_url: http://repository.mercubuana.ac.id/96574/3/03%20BAB%202.pdf document_url: http://repository.mercubuana.ac.id/96574/4/04%20BAB%203.pdf document_url: http://repository.mercubuana.ac.id/96574/5/05%20BAB%204.pdf document_url: http://repository.mercubuana.ac.id/96574/6/06%20BAB%205.pdf document_url: http://repository.mercubuana.ac.id/96574/7/07%20DAFTAR%20PUSTAKA.pdf document_url: http://repository.mercubuana.ac.id/96574/8/08%20LAMPIRAN.pdf