Standard error
Previously we observed how to calculate the standard deviation using the .std() method. In this exercise, you will explore how to calculate standard deviation for a conversion rate, which requires a slightly different procedure. You will calculate this step by step in this exercise.
Loaded for you is our inner merged dataset purchase_data as well as the computed conversion_rate value.
Deze oefening maakt deel uit van de cursus
Customer Analytics and A/B Testing in Python
Oefeninstructies
- Find the number of paywall views in the dataset using
.count(). Store this inn. - Calculate a quantity we will call
vby finding theconversion_ratetimes the rate of not converting. - Now find our variance,
var, by dividingvbyn. This is the variance of our conversion rate estimate. - Finally the square root of
varhas been taken and stored as the variablesefor you. This is the standard error of our estimate.
Praktische interactieve oefening
Probeer deze oefening eens door deze voorbeeldcode in te vullen.
# Find the number of paywall views
n = purchase_data.purchase._____
# Calculate the quantitiy "v"
v = _____ * (1 - conversion_rate)
# Calculate the variance and standard error of the estimate
var = _____ / _____
se = var**0.5
print(var)
print(se)