Delta method
Delta method is one of the most practical A/B testing applications. As a Data Scientist you are going to encounter cases where the user assignment per variant is based on user_id to create a consistent experience, while the unit of analysis is something more granular such as a page view or a session.
In this exercise you will analyze the difference in total order_value
per page_view
ratio metric between variants A and C. The checkout DataFrame is loaded for you along with pandas
, numpy
, and the pre-defined functions for estimating ratio metrics variance var_delta()
and ratio metrics z-test ztest_delta()
.
Diese Übung ist Teil des Kurses
A/B Testing in Python
Interaktive Übung
Versuche dich an dieser Übung, indem du diesen Beispielcode vervollständigst.
# Create DataFrames for per user metrics for variants A and C
A_per_user = pd.____({'order_value':checkout[checkout['checkout_page']=='A'].groupby('____')['order_value'].____()
,'page_view':checkout[checkout['checkout_page']=='A'].groupby('____')['user_id'].____()})
C_per_user = pd.____({'order_value':checkout[checkout['checkout_page']=='C'].groupby('____')['order_value'].____()
,'page_view':checkout[checkout['checkout_page']=='C'].groupby('____')['user_id'].____()})