Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
ShayanHodai authored Jun 1, 2024
1 parent 9685c02 commit c6116c1
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
The repository contains code to analyze credit card transactions and predict whether transactions are fraudulent using machine learning algorithms. Machine learning workflow has been followed to train and fine-tune classification models. The steps are data collection and exploration, data processing, feature correlations, automating processing by pipelines, building models, evaluating performance by cross-validation, and fine-tuning the best-performing model based on precision, recall, and F1 score metrics.
The link to the kaggle dataset is: https://www.kaggle.com/datasets/mlg-ulb/creditcardfraud

To work with the code, clone the repository:
# To work with the code, clone the repository:
git clone https://github.com/ShayanHodai/fraud-detection.git

The dataset:
# The dataset:
![Example Image](images/dataset.png)

The dataset is highly imbalanced as, less than 1% of total transactions are fraud
# The dataset is highly imbalanced as, less than 1% of total transactions are fraud
![Example Image](images/imbalanced%20dataset.png)

Features histograms: as seen, most features are centred around 0
Expand All @@ -22,7 +22,7 @@ And Amount feature is scaled by RobustScaler -> deals better with outliers
correlation of fraud/normal transactions with non-redundant features
![Example Image](images/corr2.png)

Machine learning classification models evaluation metrics:
# Machine learning models:
As the cost of False Positive and False Negative in this problem varies, Precision and Recall and, eventually, f1-score are the evaluation metrics of the model performance
Logistic regression:
![Example Image](images/logistic%20regression.png)
Expand All @@ -33,11 +33,11 @@ SVM:
Decision tree classifier, which is highly overfitting:
![Example Image](images/Decision%20Tree.png)

ROC carve:
# ROC carve:
![Example Image](images/ROC.png)

Fine-tuning the best performing model, which is logistic regression:
# Fine-tuning the best performing model, which is logistic regression:
![Example Image](images/fine-tuning.png)

Evaluation on the test set:
# Evaluation on the test set:
![Example Image](images/evaluation%20on%20test.png)

0 comments on commit c6116c1

Please sign in to comment.