Evaluasi Information Gain pada Random Forest, Decision Tree, dan KNN Klasifikasi Tanaman

Authors

  • Dina Andayati Universitas AKPRIND Indonesia Author
  • Suraya Universitas AKPRIND Indonesia Author
  • Muhammad Sholeh Universitas AKPRIND Indonesia Author
  • Suparyanto STMIK EL RAHMA Yogyakarta Author

DOI:

https://doi.org/10.61805/fahma.v24i3.262

Keywords:

machine learning, Information Gain, Random Forest, Decision Tree, K-Nearest Neighbors

Abstract

Selecting suitable crop types based on soil and environmental conditions is essential for improving agricultural productivity. Machine learning enables crop classification using soil and climate characteristics, but using all features may increase model complexity without necessarily improving performance. This study analyzes the effect of Information Gain-based feature selection on Random Forest, Decision Tree, and K-Nearest Neighbors (KNN) for crop classification. The farming.csv dataset contains 2,200 samples, seven input features—nitrogen (N), phosphorus (P), potassium (K), temperature, humidity, pH, and rainfall—and 22 crop classes. The experiment employed an 80:20 train-test split with random_state 42. Feature selection using mutual_info_classif with a threshold >1.0 reduced the features to six: humidity, K, rainfall, P, temperature, and N. Model performance was evaluated using accuracy, precision, recall, and F1-score. Using all features, Random Forest, Decision Tree, and KNN achieved accuracies of 99.32%, 98.64%, and 97.05%, respectively. After feature selection, Random Forest and Decision Tree achieved 99.09%, while KNN remained at 97.05%. These results indicate that Information Gain can reduce the feature set by one feature while maintaining nearly unchanged classification performance.

Downloads

Download data is not yet available.

References

Y. Kamakaula, "Optimasi Pertanian Berkelanjutan : Pengabdian Masyarakat untuk Peningkatan Produktivitas," Communnity Development Journal, vol. 4, no. 6, pp. 11463-11471, 2023.

M. Sihite, A. M. Hsb, R. Syahputra, M. R. Amri, R. Alwi, and Sakuntala, "Peran Sektor Pertanian dan Distribusi Pendapatan di Indonesia : Analisis Model Faktor Spesifik," JURNAL MEDIA AKADEMIK (JMA), vol. 3, no. 1, 2025.

N. Fajeriana, "Kesesuaian Lahan dan Kesuburan Tanah pada Lahan Budidaya Kacang Tanah (Arachis hypogaea) di Kampung Kofalit Distrik Salkma Kabupaten Sorong Selatan," Agroteknika, vol. 7, no. 1, pp. 51-66, 2024.

https://doi.org/10.55043/agroteknika.v7i1.254

R. Manurung, J. Gunawan, R. Hazriani, and J. Suharmoko, "Pemetaan Status Unsur Hara N, P Dan K Tanah pada Perkebunan Kelapa Sawit di Lahan Gambut," Jurnal Pedon Tropika Edisi, vol. 3, no. 1, 2020.

https://doi.org/10.26418/pedontropika.v3i1.23438

A. N. Sandil, M. Montolalu, and R. I. Kawulusan, "Kajian Sifat Kimia Tanah Pada Lahan Berlereng Tanaman Cengkeh (Syzygium Aromaticum L) dI Salurang Kecamatan Tabukan Selatan Tengah," Soil Environmental, vol. 21, no. 3, pp. 18-23, 2021.

R. Abiri, N. Rizan, S. K. Balasundram, A. Bayat, and H. Abdul-hamid, "Heliyon Application of digital technologies for ensuring agricultural productivity," Heliyon, vol. 9, no. 12, p. e22601, 2023, doi: 10.1016/j.heliyon.2023.e22601.

https://doi.org/10.1016/j.heliyon.2023.e22601

A. Hamdani, "Implementasi Machine Learning untuk Prediksi Kebutuhan Irigasi Tanaman pada Sistem Smart Agriculture Berbasis Internet of Things," Karapan Network Journal, vol. 02, no. 03, 2026.

R. H. Aditya, "Implementasi Metode Boosting Untuk Prediksi Jenis Tanaman Berdasarkan Kondisi Tanah," 135 Jurnal Inovasi Komputer (INOKOM), vol. 1, no. 3, pp. 135-145, 2025.

https://doi.org/10.71200/inokom.v1i3.135

P. N. Sabrina and A. Komarudin, "Prediksi Penyakit Diabetes dengan Metode K-Nearest Neighbor ( KNN ) dan Seleksi Fitur Information Gain," JATI (Jurnal Mahasiswa Teknik Informatika), vol. 8, no. 6, pp. 11320-11326, 2024.

https://doi.org/10.36040/jati.v8i6.11364

G. Manikandan and A. Murugappan, "An efficient feature selection framework based on information theory for high dimensional data," Applied Soft Computing, vol. 111, p. 107729, Jul. 2021, doi: 10.1016/j.asoc.2021.107729.

https://doi.org/10.1016/j.asoc.2021.107729

M. Chiregi, M. Mazinani, and M. Mirzarezaee, "A New Feature Selection Method Using Deep Learning and Graph Representation in High-Dimensional Datasets," Knowledge-Based Systems, vol. 329, p. 114338, Aug. 2025, doi: 10.1016/j.knosys.2025.114338.

https://doi.org/10.1016/j.knosys.2025.114338

M. Sholeh, U. Lestari, and D. Andayati, "Comparison of Feature Selection with Information Gain Method in Decision Tree , Regression Logistic and Random Forest," Journal of Applied Business and Technology, vol. 5, no. 3, pp. 146-153, 2024.

https://doi.org/10.35145/jabt.v5i3.155

A. H. Mohammad, "Comparing Two Feature Selections Methods (Information Gain and Gain Ratio) on Three Different Classification Algorithms using Arabic Dataset," Journal of Theoretical and Applied Information Technology, vol. 96, no. 6, 2018.

R. Annisa, R. Amelia, M. Putri, and C. Febriyani, "Pengembangan Model Klasifikasi Citra Tanaman Hutan Melicopelatifolia Berbasis CNN dengan Custom-Built Dataset," JUKI : Jurnal Komputer dan Informatika, vol. 6, pp. 174-181, 2024.

https://doi.org/10.53842/juki.v6i2.704

M. Abdullah and I. Fahrurrozi, "Model Comparison and Feature Selection for Crop Recommendation," Jurnal Pepadun, vol. 7, no. 1, pp. 16-25, 2026, doi: 10.23960/pepadun.v7i3.345.

A. Aryanti and N. Iryani, "A Smart Recommendation System for Crop Seed Selection Using Gradient Boosting Based on Environmental and Geospatial Data," Journal of Applied Informatics and Computing (JAIC), vol. 9, no. 6, pp. 2965-2973, 2025.

https://doi.org/10.30871/jaic.v9i6.10249

E. Sari, H. Nurdiniyah, A. Nur, A. Yusuf, R. L. Prasetyo, and R. Shabihah, "Seleksi Fitur Berbasis Mutual Information untuk Optimalisasi Model Prediksi Tingkat Kematian Penderita Gagal Jantung Menggunakan Machine Learning," Jurnal, Juritek Teknik, Ilmiah Komputer, Elektro, vol. 5, no. 2, 2025, doi: 10.51903/Juritek.V5i2.5084.

https://doi.org/10.51903/juritek.v5i2.5044

Z. J. Zumantara et al., "Perbandingan algoritma random forest dan logistic regression dalam prediksi penyakit diabetes," Swadharma, vol. 6, no. 1, 2026.

https://doi.org/10.56486/jeis.vol6no1.998

Downloads

Published

30-09-2026

How to Cite

Evaluasi Information Gain pada Random Forest, Decision Tree, dan KNN Klasifikasi Tanaman. (2026). FAHMA : Jurnal Informatika Komputer, Bisnis Dan Manajemen, 24(3), 387-395. https://doi.org/10.61805/fahma.v24i3.262

Similar Articles

31-40 of 62

You may also start an advanced similarity search for this article.