LoslegenKostenlos loslegen

Merging on different sets of fields

As you saw in the previous exercise, both customer_data and app_purchases have a common 'uid' column that you can use to combine them. If you explored them further, you would discover that they also have a common date column that is named 'date' in app_purchases and 'reg_date' in customer_data.

In this exercise you will explore merging on both of these columns and looking at how this impacts your final results.

The two datasets from the previous exercise - customer_data and app_purchases- have been loaded for you, with 'reg_date' in customer_data renamed to 'date'.

Diese Übung ist Teil des Kurses

Customer Analytics and A/B Testing in Python

Kurs anzeigen

Interaktive Übung

Versuche dich an dieser Übung, indem du diesen Beispielcode vervollständigst.

# Merge on the 'uid' field
uid_combined_data = app_purchases.merge(____, on=['____'], how='inner')

# Examine the results 
print(uid_combined_data.head())
print(len(uid_combined_data))
Code bearbeiten und ausführen