Comparing language conversion rate (I)
The marketing team wants to determine how effective the campaign was on converting English speakers.
In this exercise, you will isolate the data for English speakers and calculate the conversion rate much like in the previous exercises. Remember, the formula for conversion rate is:
$$ \displaystyle\frac{\mbox{Number of people who convert}}{\mbox{Total number of people who we market to}} $$
Once you have the conversion rate for English speakers, you can compare it to the overall conversion rate to gain a sense of how effective the marketing campaign was among this group compared to the overall population.
Cet exercice fait partie du cours
Analyzing Marketing Campaigns with pandas
Instructions
- Using the
marketing
DataFrame, include only the rows wherelanguage_displayed
is English. - Calculate the total number of users in the
english_speakers
DataFrame. - Calculate the number of conversions in the
english_speakers
DataFrame.
Exercice interactif pratique
Essayez cet exercice en complétant cet exemple de code.
# Isolate english speakers
english_speakers = marketing[____['____'] == '____']
# Calculate the total number of English speaking users
total = ____
# Calculate the number of English speakers who converted
subscribers = ___
# Calculate conversion rate
conversion_rate = subscribers/total
print('English speaker conversion rate:', round(conversion_rate*100,2), '%')