Learn practical skills, build real-world projects, and advance your career

Bank marketing

Problem Statement

You work as a Business Analytics Consultant at the Bank of Corporate. The bank provides financial services/products such as savings accounts, current accounts, debit cards, etc. to its customers. In order to increase its overall revenue, the bank conducts various marketing campaigns for its financial products such as credit cards, term deposits, loans, etc. These campaigns are intended for the bank’s existing customers. However, the marketing campaigns need to be cost-efficient so that the bank not only increases their overall revenues but also the total profit.

In 2019, the bank conducted a telemarketing campaign for one of its financial products ‘Term Deposits’ to help foster long-term relationships with the existing customers. The dataset (provided below) contains the information about all the customers who were contacted during this year to open term deposit accounts.

What are term deposits?

Term deposits, also called fixed deposits, are the cash investments made for a specific time period ranging from 1 month to 5 years for predetermined fixed interest rates. The fixed interest rates offered for term deposits are higher than the regular interest rates for savings accounts. The customers receive the total amount (investment plus the interest) at the end of the maturity period. Also, the money can only be withdrawn at the end of the maturity period. Withdrawing money before that will result in an added penalty associated, and the customer will not receive any interest returns. This kind of investment deposits provides the required funds to the bank for lending money to the corporates or individuals at a higher interest rate than what is paid to the customer.

Business objectives

Your aim is to identify the target customer segments for the term deposits from the pool of the bank’s existing customers.

Optimisation
For its future marketing campaign, the bank has allocated a budget of ₹1,50,000 and has also decided to segment the customers based on their marital status and educational background. Also, notably, the cost incurred by the bank for a one-minute call to any customer is ₹10. Considering all these factors, you, as a consultant, need to provide the analysis to the bank regarding the number of calls to be made to each customer segment ('Customer segment' is explained below) such that the total number of customers opening the term deposit account is maximised.

Customer Segment

In the data set, the customers are segregated based on their marital status and educational background. 'Marital status' and 'educational background' has three categories as follows.

Marital StatusEducational Background
SingleBachelors
MarriedMasters
DivorcedDoctorate

Each combination of marital status and educational background is considered as a customer segment. 

Examples: ‘Single - Bachelors’ is considered as one segment. ‘Single - Masters’ is considered as one segment. Similarly, ‘Married - Masters’ is considered as one segment, ‘Married - Doctorates’ is considered as one segment and so on.

The Conditions of the Bank:

  • The bank is concerned about the overall customer diversification. It wants to ensure that it reaches out to all the customer segments. For this, it has provided you with the following information to include in your analysis:

    • From each customer segment (‘customer segment’ as explained above), at least 50 customers need to be contacted.

    • The total number of calls made to each customer category should meet the minimum number of calls (provided in the data file).

    • The total number of conversions for the customer categories should match a minimum number.

Main Objective of the optimisation problem:

Within the conditions given above, you need to estimate the number of calls that have to be made for each customer segment such that the total estimated no of converted calls for the future marketing campaign is maximised.

Mathematical formulation / Pyomo components


Sets:

The indexes for the given problem are,

  • Marital status, mmarital_statusm \in marital\_status
  • Degree status, ddegreed \in degree

Parameters:

  • \text{duration_nconverted}_{m,d} \text{ - Avg. call duration for non-converted calls}
  • \text{duration_converted}_{m,d} \text{ - Avg. call duration for converted calls}
  • \text{conv_rate}_{m,d} \text{ - Conversion rate}
  • \text{min_tcalls}_{m | d} \text{ - Minimum no. of calls by either marital status / degree}
  • \text{min_ccalls}_{m | d} \text{ - Minimum no. of converted calls by either marital status / degree}

Decision variables:

  • Total number of calls (converted + non-converted) to be made for each customer segment

total_callsm,dwhere mmarital_status,ddegree{total\_calls}_{m,d} \,\,\,\,\,\,\, \text{where} \ m \in marital\_status, d \in degree


Objective:

To maximize conversions for each combination of marital status and degree

\begin{align}
\textrm{max} \sum \limits {m,d} \text{total_calls}{m,d}* \text{conv_rate}_{m,d}
\end{align}
where mmarital_statusm \in marital\_status and ddegreed \in degree


Constraints:

  • At-least 50 customers need to be contacted from each segment
  • \text{total_calls}_{m,d}\geq\text{50}\ \ \ \ \forall {d \in degree, m \in marital\_status}
  • Minimum number of total calls for each marital status
  • \sum \limits _{d} \text{total_calls}_{m,d} \geq\text{min_tcalls}_{m}
  • Minimum number of total calls for each degree
  • \sum \limits _{m} \text{total_calls}_{m,d} \geq\text{min_tcalls}_{d}
  • Minimum number of converted calls for each marital status
  • \sum \limits _{d} (\text{total_calls}_{m,d}* \text{conv_rate}_{m,d}) \geq\text{min_tcalls}_{m}
  • Minimum number of converted calls for each degree
  • \sum \limits _{m} (\text{total_calls}_{m,d}* \text{conv_rate}_{m,d}) \geq\text{min_tcalls}_{d}
  • Budget Constraint

\begin{align}
\sum \limits {m,d} \Bigg[\text{total_calls}{m,d}* \text{conv_rate}{m,d}* \frac{\text{duration_converted}{m,d}}{60}* \text{cost_per_min}\Bigg] & +\Bigg[\text{total_calls}{m,d}* \text{(1- conv_rate}{m,d})* \frac{\text{duration_nconverted}_{m,d}}{60}* \text{cost_per_min}\Bigg] \leq\text{total_budget}
\end{align}


!pip install -q pyomo
!apt-get install -y -qq coinor-cbc
!apt-get install -y -qq glpk-utils

Step1:

Import Pyomo Environment