Table of Contents

Imports

Useful Functions

Load the data

Data for modelling

Modelling

Logistic Regression

Logistic Regression with p-values

Feature selection using p_values

Logistic Regression with p-values selected features

Model evaluation on test data

Predicted Probabilities

Model evaluation: confusion matrix

Model evaluation: AUC

Sort by yhat_prob and find Gini and Kolmogorov-Smirnov

Plot Gini Curve

Plot K-S curve

Create Scorecard

If preliminary values are out of range

Calculate Credit Score

Convert Credit Score to PD

Setting Cut-offs