Skip to content

Trained over 30,000 data to predict the outcome of the subscription by customer.

Notifications You must be signed in to change notification settings

safwanshamsir99/Customer-Campaign-Prediction

Repository files navigation

R spyder Kaggle NumPy Pandas scikit-learn SciPy tf customer campaign

Outcome Prediction Using a Simple Two-Layers Deep Learning Model for Customer Campaign.

Trained over 31,000 data to predict the outcome of the term deposit subscription by customer based on a campaign.

Description

  1. The project's objective is to predict the outcome of a campaign based on the customer's data
  2. Based on the dataset description, the dataset contains details of marketing campaigns done via phonecall with various details for customers such as demographics, last campaign details, many more.
  3. The dataset contains 6 continuous features, 10 categorical features, 1 categorical target. It has no duplicate data but has a lot of NaNs especially for 'days_since_prev_campaign_contact' column. The dataset can be downloaded from the link given in the credit section below.
  4. The only features selected from the dataset are all of the continuous columns since they have the highest correlation to the target, which is outcome of the campaign.
  5. By using the simple two layer deep learning model which only comprises of Dense, Dropout, and Batch Normalization layers, the model successfully achieved 90.1% accuracy.
  6. Methods that used to improve the deep learning model are by increasing the number of epochs inside the model and by using the early stopping callbacks to prevent the model from overfitting.

Deep learning model image

model_score

Results

Training loss & Validation loss:

model_loss

Training accuracy & Validation accuracy:

model_accuracy

Model score:

model_score

Discussion

  1. The deep learning model achieved 90.1% accuracy during the model evaluation.
  2. Recall and f1 score reported 99% and 95% respectively for outcome 0 of term_deposit_subscribed. But for outcome 1, the f1-score value is very low due to the imbalance dataset. The total count of term_deposit_subscribed which is equal to 0 is way higher than 1, which causes imbalance of data and inaccurate prediction of the model. Thus, adding more data may help to improve the model.

model_loss

  1. Early stopping callback was used to prevent overfitting of the deep learning model, and during the model training, the epochs stop at 32.
  2. Tensorboard was used to visualize the the loss and accuracy graph of the model. The snipping shot from the tensorboard is shown below. tensorboard

Credits:

Shout out to Kunal Gupta from Kaggle for the Customer Segmentation Dataset. Check out the dataset by clicking the link below. 😄

Dataset link

HackerEarth HackLive: Customer Segmentation

About

Trained over 30,000 data to predict the outcome of the subscription by customer.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages