Skip to content

Commit

Permalink
Merge pull request #704 from aviralgarg05/main-1
Browse files Browse the repository at this point in the history
Loan Repayment Prediction Project
  • Loading branch information
abhisheks008 authored Jul 14, 2024
2 parents 6d2d3bc + 5077133 commit b90eead
Show file tree
Hide file tree
Showing 11 changed files with 2,695 additions and 0 deletions.
368 changes: 368 additions & 0 deletions Loan Repayment Prediction/Datasets/test.csv

Large diffs are not rendered by default.

615 changes: 615 additions & 0 deletions Loan Repayment Prediction/Datasets/train.csv

Large diffs are not rendered by default.

Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1,586 changes: 1,586 additions & 0 deletions Loan Repayment Prediction/Model/Loan Repayment Prediction.ipynb

Large diffs are not rendered by default.

120 changes: 120 additions & 0 deletions Loan Repayment Prediction/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,120 @@
# Loan Repayment Prediction

## Overview

Welcome to the Loan Repayment Prediction Project! This project aims to build a predictive model to identify the likelihood of a loan application being approved. Leveraging machine learning techniques, this project helps financial institutions streamline their loan approval processes and minimize risks.

## Table of Contents

- [Project Description](#project-description)
- [Data Description](#data-description)
- [Installation](#installation)
- [Usage](#usage)
- [Modeling](#modeling)
- [Results](#results)
- [Contributing](#contributing)
- [License](#license)
- [Contact](#contact)

## Project Description

The Loan Repayment Prediction Project utilizes various machine learning algorithms to predict loan approvals based on applicant information. The primary goal is to create a model that accurately predicts whether a loan should be approved, thus aiding financial institutions in decision-making.

## Data Description

The dataset used in this project contains information about loan applicants, including:

- **Applicant Information**: Gender, Marital Status, Education, Number of Dependents, etc.
- **Financial Information**: Applicant Income, Co-applicant Income, Loan Amount, Loan Amount Term, Credit History, etc.
- **Loan Information**: Loan ID, Loan Status, Property Area, etc.

## Installation

To run this project, you'll need to have Python installed. Follow the steps below to set up the project:

1. Clone the repository:
```bash
git clone https://github.com/aviralgarg05/Loan-Repayment-Prediciton.git
```
2. Navigate to the project directory:
```bash
cd Loan-Prediciton-Project
```
3. Install the required dependencies:
```bash
pip install -r requirements.txt
```

## Usage

To use the project, follow these steps:

1. Preprocess the data by running the preprocessing script:
```bash
python preprocess.py
```
2. Train the model using the training script:
```bash
python train_model.py
```
3. Evaluate the model using the evaluation script:
```bash
python evaluate_model.py
```

## Modeling

This project explores various machine learning models, including:

- **Logistic Regression**
- **Decision Trees**
- **Random Forest**
- **Gradient Boosting**
- **Support Vector Machine**

Each model is evaluated based on its accuracy, precision, recall, and F1 score. The best-performing model is selected for predicting loan approvals.

## Results

1. The Loan Status is heavily dependent on the Credit History for Predictions.
2. The Logistic Regression algorithm gives us the maximum Accuracy (79% approx) compared to the other Machine Learning Classification Algorithms.

| Model | Accuracy |
|--------------------|--------------------|
| Logistic Regression| 0.7852760736196319 |
| SVM | 0.6503067484662577 |
| Decision Tree | 0.7116564417177914 |
| KNN | 0.6196319018404908 |

The final model demonstrates strong predictive power.

## Contributing

Contributions are welcome! If you'd like to contribute to this project, please follow these steps:

1. Fork the repository.
2. Create a new branch:
```bash
git checkout -b feature-branch
```
3. Make your changes and commit them:
```bash
git commit -m 'Add new feature'
```
4. Push to the branch:
```bash
git push origin feature-branch
```
5. Create a Pull Request.

## License

This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more details.

## Contact

For any questions or suggestions, please feel free to contact:

- **Name**: Aviral Garg
- **Email**: [gargaviral99@gmail.com](mailto:gargaviral99@gmail.com)
- **GitHub**: [aviralgarg05](https://github.com/aviralgarg05)
6 changes: 6 additions & 0 deletions Loan Repayment Prediction/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
numpy==1.23.5
pandas==2.0.3
matplotlib==3.7.2
seaborn==0.12.2
scikit-learn==1.3.0

0 comments on commit b90eead

Please sign in to comment.