Explainable and Fair Credit Risk Scoring with Counterfactual Explanations: A Reproducible Evaluation on the German Credit Dataset (HELOC-Motivated) - Qi Xin (LPPM Universitas Bhinneka Nusantara, 2026)
Credit risk scoring requires models that are accurate, fair, and able to provide actionable explanations for adverse decisions. Motivated by the HELOC explainable lending benchmark, but using the publicly downloadable Statlog German Credit dataset as a fully reproducible proxy when direct HELOC access is constrained, this study evaluates explainable and fair credit scoring on 1,000 applicants. We train five common models—logistic regression (LR), decision tree (DT), random forest (RF), XGBoost (XGB), and LightGBM (LGBM)—on a fixed 600/200/200 train/validation/test split with a consistent preprocessing pipeline. Thresholds are selected on the validation set to maximize F1 for bad-risk detection. LR achieves the best test AUC (0.7888), LGBM the highest test accuracy (0.6550), and RF the best calibration (ECE=0.0473), showing that discrimination, thresholded accuracy, and calibration do not align. Fairness is audited by a derived sex attribute using demographic parity and equalized odds. Baseline LGBM shows an approval-rate difference of −0.0846 (female minus male) and an equalized-odds gap of 0.1000. Reweighing reduces the approval-rate difference to −0.0642 while preserving AUC (0.7804), and equal-opportunity thresholding reduces the equalized-odds gap to 0.0750. For individual explainability, we generate counterfactual recourse for rejected applicants using six actionable features. Feasible recourse is defined as the existence of at least one action-constrained counterfactual that changes the decision from reject to approve; 78.64% of rejected applicants receive such recourse, with mean cost 1.5298 measured as standardized numeric change plus categorical steps. Across five retraining seeds, LGBM AUC is stable (mean 0.7742, std 0.0022), but fairness gaps vary. The study provides a reproducible template for jointly evaluating performance, calibration, fairness, mitigation, and recourse in credit scoring