Skip to content

Credit risk refers to the chance that a borrower will be unable to make their payments on time and default on their debt.

Notifications You must be signed in to change notification settings

rahkum96/Credit-Risk-Modelling-in-Python

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 

Repository files navigation

Credit-Risk-Modelling-in-Python

Credit risk refers to the chance that a borrower will be unable to make their payments on time and default on their debt. It refers to the risk that a lender may not receive their interest due or the principal lent on time.

More detail explanation

Read in my blogs https://medium.com/mlearning-ai/credit-risk-modelling-in-python-7b21a0b794b1

Objective

The objective of this project is to predict the probability of default on a given obligation, in this case, credit cards. This will allow the generation of strategies that minimize the risk of deterioration of the client's financial health.

Approach

  1. Data preparation and Pre-processing
    • Checking missing values
    • Outliers removal
    • Encoding concept
  2. Feature Engineering and Selection
    • features selection
    • Scaling the features
    • Balancing the data
  3. Model Development and Model Evaluation
    • Logistic regression
    • Random Forest
    • Xgboost
    • Hyperparameter tuning
    • Cross validation

Dependencies

  • numpy
  • matplotlib
  • scikit-learn
  • XGBOOST
  • seaborn
  • pyhthon 3.9

Usage

Just run jupyter notebook in terminal and it will run in your browser.

  • Install Jupyter here i've you haven't.

  • install xgboost by using pip install xgb in command line prompt/ anconda i've you haven't.

Machine learning algorithm

  • Logistic regression
  • Random Forest
  • Xgboost Classifer
  • Cross validation

Model Evaluation

  • we have acheived the final model accuracy 82%

Steps to run this model in your system

  • Clone or download the repo.
  • Open command prompt in the downloaded folder

Conclusion:

We have built the credit risk model by using python. we have tried with different machine learning algorithms ie. Logistic regression, Random Forest, and Xgboost classifier. we have also done hyperparameter tuning and cross-validation. The final accuracy of the model we achieved was 82%.

Dataset:

About

Credit risk refers to the chance that a borrower will be unable to make their payments on time and default on their debt.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published