The Power of Predictive Magic: Decoding the Secrets Behind Successful Banking Campaigns

Elsa Saji
7 min readDec 23, 2023

--

Welcome to a riveting journey into the heart of direct marketing campaigns, where phone calls transform into potent spells, and data takes center stage in the world of Portuguese banking institutions. Today, we unravel the mysteries of predictive magic that swirl around the enchanting goal of predicting whether a client will subscribe to a term deposit.

The Magic Behind the Curtain

Imagine a world where every phone call is a chance to create real magic — a magic that foretells whether a client will take the plunge into the world of term deposits. In this magical realm, data becomes our wand, and predictive modeling becomes the spell that can shape the future.

Our story begins with a quest for predictive prowess. How do these Portuguese banking wizards foresee the future behavior of their clients? The answer lies in the meticulous art of data analysis. Every phone call, every interaction, every piece of information becomes a clue in the grand puzzle of client behavior.

The Sorcery of Predictive Model

Imagine having the ability to predict whether a client will subscribe to a term deposit. PredictEasy promises just that — a journey into the heart of predictive analytics, where data becomes a compass, guiding us through the labyrinth of the clients behavior.

As we embark on this journey with PredictEasy, the tool takes us through a seamless process. It begins by ingesting a comprehensive dataset that encapsulates the nuances of various client’s and their behaviors. The algorithm then learns from this information, identifying patterns and correlations that might escape the untrained observer. The end result is a predictive model capable of classifying if the client will subscribe to a term deposit of not.

Let’s first understand our data. The bank dataset is a multivariate categorical dataset with 16 features and 45211 instances of which a sample of 4521 instances were taken. The data is related with direct marketing campaigns of a Portuguese banking institution. The marketing campaigns were based on phone calls. Often, more than one contact to the same client was required, in order to access if the product (bank term deposit) would be (‘yes’) or not (‘no’) subscribed. The variable information is given below:

  • age (numeric)
  • job : type of job (categorical: “admin.”, ”unknown”, ”unemployed”, ”management”, ”housemaid”, ”entrepreneur”, ”student”, “blue-collar”, ”self-employed”, ”retired”, ”technician”, ”services”)
  • marital : marital status (categorical: “married”, ”divorced”, ”single”; note: “divorced” means divorced or widowed)
  • education (categorical: “unknown”, ”secondary”, ”primary”, ”tertiary”)
  • default: has credit in default? (binary: “yes”, ”no”)
  • balance: average yearly balance, in euros (numeric)
  • housing: has housing loan? (binary: “yes”, ”no”)
  • loan: has personal loan? (binary: “yes”, ”no”)
  • contact(related with the last contact of the current campaign): contact communication type (categorical: “unknown”, ”telephone”, ”cellular”)
  • day: last contact day of the month (numeric)
  • month: last contact month of year (categorical: “jan”, “feb”, “mar”, …, “nov”, “dec”)
  • duration: last contact duration, in seconds (numeric) \
  • campaign: number of contacts performed during this campaign and for this client (numeric, includes last contact)
  • pdays: number of days that passed by after the client was last contacted from a previous campaign (numeric, -1 means client was not previously contacted)
  • previous: number of contacts performed before this campaign and for this client (numeric)
  • poutcome: outcome of the previous marketing campaign (categorical: “unknown”,”other”,”failure”,”success”)
  • y (Output variable (desired target)): has the client subscribed a term deposit? (binary: “yes”,”no”)

Using the Google sheets add-on PredictEasy a classification model was built. In order to know more about how to use the tool please refer to my previous blog posts (linked at the end of this blog). To interpret the visualizations that the tool provides click here.

The tool helped me build a classification model with 89% accuracy in just a few minutes. It also gave an interface in which I can feed the features of the given client and predict if they might subscribe for a term deposit. Let’s take a look into the results.

  • The predictive model achieved an accuracy of 0.89, indicating that it correctly classified 89% of the instances.
  • The precision score of 0.87 suggests that the model has a high proportion of true positive predictions compared to false positives.
  • The recall score of 0.89 indicates that the model has a high proportion of true positive predictions compared to false negatives.
  • The F1 score of 0.87 represents the harmonic mean of precision and recall, providing an overall measure of the model’s performance.

The predictive model shows promising results with high accuracy, precision, recall, and F1 score. This indicates that it can effectively classify instances and make accurate predictions.

ROC Curve
Confusion Matrix

The ROC curve and Confusion Matrix for the model shows the results given by the model and supports the model.

XAI Plot and Interpretation by PredictEasy
Feature Rank Plot

The XAI and Feature Rank plot suggests the main features that predict the subscription to the term deposit and the importance of these features. The feature scores provide insights into the importance of different features in predicting the target class.

The most important features for predicting the target variable are ‘month’, ‘poutcome’, ‘campaign’, ‘previous’, and ‘balance’, as they have the highest feature scores. The ‘month’ feature has the highest score, suggesting that the month in which the marketing campaign is conducted plays a significant role in predicting the outcome. The ‘poutcome’ feature also has a high score, indicating that the outcome of the previous marketing campaign has a strong influence on the current campaign’s success. ‘Campaign’ and ‘previous’ features are also important, implying that the number of contacts made during the current and previous campaigns impact the outcome. ‘Balance’, ‘loan’, ‘pdays’, ‘education’, ‘housing’, ‘duration’, and ‘job’ features also contribute to the prediction, although to a lesser extent.

The ‘month’ and ‘poutcome’ features are particularly important in predicting the outcome. Therefore, it is recommended to focus on the timing of marketing campaigns and leverage the knowledge of previous campaign outcomes to improve future campaigns.

A scenario created using real-time interface and its results

Closing Thoughts: Embracing the Magic Within Data

As the dust settles from our magical journey, the impact on marketing strategies becomes clear. Armed with the knowledge of who is likely to subscribe, these banking institutions can tailor their messages, optimize their resources, and create campaigns that resonate with the very essence of what clients desire. In the world of direct marketing campaigns, every phone call becomes an opportunity to cast a spell, to predict the future with the finesse of a seasoned sorcerer. The magic lies in the data, in the dance of algorithms, and in the precision of predictive modeling.

Analyze the success rates of marketing campaigns conducted in different months to identify patterns and optimize future campaigns accordingly. Investigate the impact of the outcome of previous marketing campaigns on the current campaign’s success and tailor strategies accordingly. Explore the relationship between the number of contacts made during the current and previous campaigns and the likelihood of a positive outcome. Consider the influence of customers’ account balance, loan status, education level, housing situation, duration of contact, and job type on the campaign’s success. The number of contacts made during the current and previous campaigns, as well as customers’ account balance, loan status, education level, housing situation, duration of contact, and job type, should also be considered when designing marketing strategies. Further analysis can be conducted to gain deeper insights into the relationships between these features and the target variable, which can help refine the predictive model and enhance campaign effectiveness.

So, dear reader, as you navigate the landscape of digital marketing, remember the enchanting world of predictive magic. The next phone call might just be the one that reveals the secrets of client subscriptions.

References:

Decoding the Endgame: Navigating Tic-Tac-Toe’s Final Moves- https://medium.com/@elsasaji02/decoding-the-endgame-navigating-tic-tac-toes-final-moves-46fcce8dd6fb

Unveiling the Secrets of Mushrooms: A Predictive Journey with PredictEasy: https://medium.com/@elsasaji02/unveiling-the-secrets-of-mushrooms-a-predictive-journey-with-predicteasy-613246064c81

Unraveling Predictive Patterns for CHP in Conventional Power Plants Through Data-Driven Insight- https://medium.com/@elsasaji02/unraveling-predictive-patterns-for-chp-in-conventional-power-plants-through-data-driven-insight-a5a1677b24e2

Mastering the Supply Chain: Optimizing Back Order Shipment Prediction Through Feature Engineering- https://medium.com/@elsasaji02/mastering-the-supply-chain-optimizing-back-order-shipment-prediction-through-feature-engineering-1f55b7e11627

Prescriptive Analysis of Employee Attrition: A Data-Driven Approach- https://medium.com/@elsasaji02/prescriptive-analysis-of-employee-attrition-a-data-driven-approach-1d1b595ba828

Analyzing Direct Marketing Campaigns for Term Deposits in a Portuguese Banking Dataset: https://medium.com/@kumarshivang1111/analyzing-direct-marketing-campaigns-for-term-deposits-in-a-portuguese-banking-dataset-440f0eafbc45

Dataset Source:

Moro,S., Rita,P., and Cortez,P.. (2012). Bank Marketing. UCI Machine Learning Repository. https://doi.org/10.24432/C5K306.

Until our next magical rendezvous, may your campaigns be enchanting and your predictions be ever precise.

--

--