Level Based Persona and Segmentation

Ogulcan Ertunc
7 min readJan 23, 2021

How to Create Customer Profiles

Every successful sale starts with successful marketing, whether it’s word of mouth, direct sales, or an advertising campaign based on a sophisticated algorithm.

Before customers buy something, someone has to show them something. Therefore, if a system does not have enough sales in service, the marketing of that system, should be reconsidered/evaluated.

There are two main points of must-have marketing:

  • Who are your customers?
  • Why are they buying?

Thousands of e-commerce stores around the world struggle to develop marketing and products without understanding or understanding their target audience. However, better sales figures will come with better marketing, if a company that does not learn this will do a lot wrong if it wants to sell better. To market better, it is necessary to reach the finest points of target audiences. Customer profiles appear exactly at this point.

Customer profiles determine who our target customers are, what they care about, and where to find them.

What is a Customer Profile?

In the field of marketing, a customer profile means a fictional biography of the target customers. For example, consider it as a document that summarizes who your ideal customers are, and why they are ideal customers.

As you can see here, the more diverse the product catalog, the larger the profile, the more profiles you will need to target.

For example, a store that offers e-sport related equipment and accessories may have 3–4 customer profiles. However, there may be thousands or even more targeted profiles in a multi-species vineyard like amazon.

In general, customer profiles are based on two things:

  • Demographic data
  • Psychographic data

Demographic Data

It contains basic and factual information about buyers.
And it contains data as I mentioned below:

  • Age
  • Place
  • Sex
  • Income
  • Educational Background or Career
  • Technological use (favorite social media network, phone, computer use, etc.)

Psychographic Data

If we understand the “who” of the buyer with demographic information, we explain “why” by psychography.

With this information, we can access customer preferences, hobbies, spending habits, and values. Information such as lifestyle and ideas are included in the scope of psychographic information.

If you dig deeper, psychographic information may also include details such as:

  • Preferred communication method
  • Motivates for using a product
  • Dreams and longings

This is the information you need to understand who buys what is sold.
However, we need to avoid unnecessary crowds of information, we need to make sure that the information we collect is relevant to what is sold.

For example, if you sell gamer mice, you probably don’t need to know which brand of cat food the customer prefers.

However, if you are selling sustainably sourced home supplies to a customer, the relevant question to ask would be which brand they prefer.

Why Develop Customer Profiles?

There is a lot of evidence that using customer profiles can help you earn more money and provide better service by having 10 thousand data instead of 1 million data, considering customer data.

In particular, there are several reasons for developing customer profiles:

  • You will get better conversions
    It’s pretty simple: If you know what your customers like, you can send them content and offers to interact with.
  • You will develop and sell better products
    Think every time you go out to buy a gift for your friend, mother, or grandmother. The closer you are to that person, the less likely it will take to pick the right gift. Customer profiles work the same way.
    With the help of profiles, it is much easier to create and present the right products because you already know what they want and need.
    You can even find real customers matching your profiles to collaborate on new products and opportunities. They help you identify problems and challenges, then you can maximize your competition with new solutions for your industry.
    Your products and services will be tailored to their needs, so they have a better chance of staying as customers longer.
  • Helps you understand where your customers are spending their time
    When you understand the background to each of your profiles, it will help you understand where your customers spend most of their time online and what online channels they are using.
    This will help you optimize your marketing spend.
    Example: If your customers spend most of their time on Twitter and do not prefer Facebook, your advertising choice should be Twitter.

If we want to make an example with a project. The definition of “Level Based Persona” will be a suitable example for us.

Our aim in this project is to obtain information about the customers in the dataset and their purchases, divide them into certain levels, and apply persona. It would be more appropriate to use the demographic information provided by the dataset while applying these procedures. After creating the persona groups using demographic data, we will be able to predict which persona group they are in when we obtain new customer data in the future.

If you want to access all the codes, you can check my repo.

First, let’s get to know our data sets.

Our Users dataset contains user id(uid), day of registration (reg_date), device (device), gender (gender), country (country) and age (age) variables.

Our purchase dataset shows the date of purchase (date), user id(uid), and the amount spent (purchase).

import pandas as pd
users = pd.read_csv('users.csv')
purchases = pd.read_csv('purchases.csv')
print(users.head(), "\n\n\n",purchases.head())
df = purchases.merge(users, how = "inner", on = "uid")tot_price = df.groupby(["country", "device", "gender", "age"]).agg({"price" : sum})
tot_price.head(15)

First of all, we merged the 2 datasets we have based on uid. Because the sizes of the datasets we have are different, we need to bring them together on a common variable.
(I did this as not all registered users have purchased)

Then, using a groupby function, I found the total amount of charges for each country, device, gender, and age range.

# sorted tot_price dfagg_df = tot_price.sort_values(by = "price", ascending = False)
agg_df.head()

Here in terms of being informative, I’ve sorted by descending price.

# adding age_cat
agg_df["age_cat"] = pd.cut(agg_df["age"], bins=[0, 18, 23, 30, 40, 75], labels=['0_18', '19_23', '24_30', '31_40', '41_75'])
agg_df.head()

As we can see from the previous output, there is a confusion in the output part because of the distribution of ages. It would be the right choice to divide the age variable into certain slices semantically. By creating the “age_cat” variable, I wanted to assign those aged between ‘0_18’, ‘19_23’, ‘24_30’, ‘31_40’, ‘41_75’ to these slices. For this, I determined the limits with bins and applied them with the “cut” function.

# customer_level_based
agg_df["customer_level_based"] = [row[0] + "_" + row[1].upper() + "_" + row[2] + "_" + row[5] for row in agg_df.values]
agg_df.head()

Then I wanted to create a meaningful change from all variables that even someone who is not related to the subject can understand when they look. When creating the variable, I used country, device, gender, and age range.

agg_df = agg_df[["customer_level_based","price"]]
agg_df.head()

Then I created a data frame in the form of “agg_df”. I created this data frame with the variable “customer_level_based” and “price” that I already know in the previous step.

agg_df = agg_df.groupby("customer_level_based").agg({"price":"mean"})
#agg_df = agg_df.groupby("customer_level_based").agg({"price":["mean","max","min"]})
agg_df.reset_index(inplace = True)
agg_df["segment"] = pd.qcut(agg_df["price"], 4 ,labels = ["D","C", "B", "A"])
agg_df.groupby("segment").agg({"price" : "mean"}).reset_index(inplace = True)
agg_df.head()

In this step, I wanted to create a segment variable with the “cut” function by using the “price” variable. Here I aimed to segmentation with letters from A to D. For example, if someone has an A segment, he or she will be in the best, most valuable people segment for us.

Now, let’s see how well the segmentation we have made will work, what criteria the “new_user” I created met, firstly after seeing it, saying new_customer = agg_df [agg_df [“customer_level_based”] == new_user] to match a common part from the data we already have and will show us.

# A female user between the ages of 31 and 40, whose country is in Germany, has an iOS platform.
new_user = "DEU_IOS_F_31_40"
new_customer = agg_df[agg_df["customer_level_based"] == new_user]
new_customer
new_customer["segment"]

I would like to express my sincere thanks to Vahit Keskin and my mentor Atilla Yardimci who helped and taught the completion of this project.

--

--

Ogulcan Ertunc

I’m an IT Consultant,graduated Data Analytics. I’m a Data Enthusiast 💻 😃 passionate about learning and working with new tech. https://github.com/ogulcanertunc