遇见数据集

Software Defect Prediction Using Machine Learning: A Comparative Analysis of Random Forest, Decision Tree, and XGBoost

收藏
Zenodo2026-06-06 更新2026-06-12 收录
官方服务:

资源简介:

Software defect prediction (SDP) is a critical proactivemethodology in modern software engineering, allowingdevelopment teams to allocate testing resources efficiently byidentifying fault-prone modules. However, the inherent class imbalancein software repositories where clean code vastly outnumbersdefective code severely limits the reliability of traditionalclassification models, a phenomenon known as the AccuracyParadox. This study presents a comparative analysis of three treebasedmachine learning architectures: a baseline Decision Tree,a bagging ensemble (Random Forest), and a boosting ensemble(XGBoost), to evaluate their robustness against imbalancedstatic code metrics. Utilizing the NASA MDP JM1 dataset, themethodology incorporates the Synthetic Minority Over-samplingTechnique (SMOTE) to balance the training space. Performancewas evaluated using Accuracy, Precision, Recall, F1-Score, andROC-AUC. The empirical results confirm the Accuracy Paradox:while XGBoost achieved the highest global accuracy (80.15%),it exhibited the lowest recall (31.03%), missing a critical volumeof actual defects. Conversely, the Random Forest model provedsuperior in navigating the noisy feature space, achieving thehighest F1-Score (0.4187) and ROC-AUC (0.7472). The findingsdemonstrate that for static software metric analysis, variancereduction through bootstrap aggregating provides a more reliablepredictive threshold than sequential error correction.

提供机构:
Zenodo
创建时间:
2026-06-06
二维码
社区交流群
二维码
科研交流群
商业服务