All projects

07Predictive models

Home Credit: credit risk

Analysis of 307,511 loan applications and comparison of logistic regression, Random Forest and LightGBM to estimate the risk of payment difficulties.

Training dataset exploration · 8.03% with payment difficulties

Target variable · 246,008 applications

No payment difficulties
91.97% 226,257
Payment difficulties
8.03% 19,751

Redrawn from the values in the notebook output.

Technical approach

  • Dataset: 246,008 applications for training and 61,503 for test. 20% of the training set is held out for validation: 196,806 to train and 49,202 to evaluate, with seed 42.
  • Validation ROC AUC: 0.6772 with the initial logistic regression, 0.7465 inside a pipeline, 0.7323 with a tuned Random Forest and 0.7551 with LightGBM.
  • LightGBM uses early stopping and reaches its best iteration at round 218. The result corresponds to the validation set used during tuning, not to the test set.
  • Metrics come from the outputs saved in the notebook; the experiment was not rerun for this portfolio.

Interested in something similar?

Tell me what you need to solve and let’s talk it through.

Contact me

Project screenshot

Real application interface · Sample data