This project is a supervised machine learning application that predicts whether a loan will be approved based on applicant financial and demographic information.
The goal of this project is to build a classification model that can determine loan approval status using features such as income, CIBIL score, loan amount, and assets. The project also includes a simple web interface built with Streamlit for real-time predictions.
- Number of dependents
- Education
- Self-employed status
- Annual income
- Loan amount
- Loan term
- CIBIL score
- Total assets (combined from multiple asset types)
- Logistic Regression (baseline model)
- Random Forest (final model)
The Random Forest model was selected due to its ability to capture non-linear relationships and feature interactions.
- Logistic Regression Accuracy: ~80%
- Random Forest Accuracy: ~97–98%
- Cross-validation Accuracy: ~97.5%
Feature importance analysis showed that CIBIL score is the most influential factor in loan approval.
Loan-Approval-Prediction/
├── app.py
├── model.pkl
├── columns.pkl
├── requirements.txt
├── README.md
└── notebook/
└── training.ipynb
- Clone the repository:
git clone https://github.com/your-username/Loan-Approval-Prediction.git
cd Loan-Approval-Prediction- Create and activate environment (optional but recommended):
conda create -n loanenv python=3.10
conda activate loanenv- Install dependencies:
pip install -r requirements.txtstreamlit run app.pyThe application will open in your browser at:
http://localhost:8501
- The model is trained on a structured dataset and may not generalize to real-world banking systems without further validation.
- The dataset used is relatively clean and may not reflect real-world noise and complexity.
- Hyperparameter tuning
- Try advanced models like XGBoost
- Add probability-based output
- Deploy the app online