Giter VIP home page Giter VIP logo

credit_risk_analysis's Introduction

Credit Risk Analysis

Author

Lydia Delgado Uriarte

Overview

Evaluate machine learning models or algorithms to predict credit risk.

Results

Balanced Random Forest Classifier

  • Balanced accuracy score: 0.7877 -> 79%

  • Sensitivity/recall: 0.67 A low recall is indicative of a large number of false negatives.

Confusion Matrix

Captura de Pantalla 2022-07-10 a la(s) 21 47 43

  • Out of 87 actual high risk , 58 were predicted to be high risked, which we call true positives.

  • Out of 87 actual high risk, 29 were predicted to be low risk, which are considered false negatives.

Imbalanced classification report

Captura de Pantalla 2022-07-07 a la(s) 23 10 41

Easy Ensemble AdaBoost Classifier

  • Balanced accuracy score: 0.9254 -> 93

  • Sensitivity/recall : 0.91 Highest recall of all, meaning high prediction can be likely true negatives.

Confusion Matrix

Captura de Pantalla 2022-07-10 a la(s) 21 48 58

  • Out of 87 Actual High risk 79 were predicted to be high risked, which we call true positives.

  • Out of 87 Actual High risk, 8 were predicted to be low risk, which are considered false negatives.

Imbalanced classification report

Captura de Pantalla 2022-07-07 a la(s) 23 10 20

Naive Random Oversampling

  • Balanced accuracy score: 0.6533 -> 65%

  • Sensitivity/recall : 0.61 A low recall is indicative of a large number of false negatives.

Confusion Matrix

Captura de Pantalla 2022-07-10 a la(s) 21 45 47

  • Out of 87 actual high risk , 53 were predicted to be high risked, which we call true positives.

  • Out of 87 actual high risk, 34 were predicted to be low risk, which are considered false negatives.

Imbalanced classification report

Captura de Pantalla 2022-07-07 a la(s) 23 08 27

SMOTE Oversampling

  • Balanced accuracy score: 0.6512 -> 65%

  • Sensitivity/recall : 0.62 A low recall is indicative of a large number of false negatives.

Confusion Matrix

Captura de Pantalla 2022-07-10 a la(s) 21 28 52

  • Out of 87 actual high risk , 54 were predicted to be high risked, which we call true positives.

  • Out of 87 actual high risk, 33 were predicted to be low risk, which are considered false negatives.

Imbalanced classification report

Captura de Pantalla 2022-07-07 a la(s) 23 06 29

Undersampling ClusterCentroids

  • Balanced accuracy score: 0.5103 -> 51 %

  • Sensitivity/recall : 0.64 A low recall is indicative of a large number of false negatives.

Confusion Matrix

Captura de Pantalla 2022-07-10 a la(s) 21 29 38

  • Out of 87 actual high risk , 56 were predicted to be high risked, which we call true positives.

  • Out of 87 actual high risk, 31 were predicted to be low risk, which are considered false negatives.

Imbalanced classification report

Captura de Pantalla 2022-07-07 a la(s) 23 06 56

Combination (Over and Under) Sampling SMOTEENN

  • Balanced accuracy score: 0.6375 -> 64 %

  • Sensitivity/recall : 0.70

Confusion Matrix

Captura de Pantalla 2022-07-10 a la(s) 21 30 38

  • Out of 87 actual high risk , 61 were predicted to be high risked, which we call true positives.

  • Out of 87 actual high risk, 26 were predicted to be low risk, which are considered false negatives.

Imbalanced classification report

Captura de Pantalla 2022-07-07 a la(s) 23 07 58

Summary

The majority of the models has between the range of 50% - 80% accuracy and the sensivity too. In this case is to take in consideration the sensitivity of each models.

Recommended Model

The best model is the Easy Ensemble AdaBoost Classifier due the sensivity and acccuracy is also important to predictions. It’s more important to detect potentially fraudulent transactions, high sensitivity means that among people who actually have credit risk, most of them will be correct and the problem would be treated right away.

credit_risk_analysis's People

Contributors

lydiadel avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.