We’ve been asked to analyze the online ad-click data collected by our buddy Fred. His advertising data table monitors ad clicks across 30 different colors. Our aim is to discover an ad color that generates significantly more clicks than blue. We will do so by following these steps:
- Load and clean our advertising data using Pandas.
- Run a permutation test between blue and the other recorded colors.
- Check the computed p-values for statistical significance using a properly determined significance level.
Warning
Let’s begin by loading our ad-click table into Pandas. Then we check the number of rows and columns in the table.
Listing 9.1 Loading the ad-click table into Pandas
df = pd.read_csv('colored_ad_click_table.csv') num_rows, num_cols = df.shape print(f"Table contains {num_rows} rows and {num_cols} columns") Table contains 30 rows and 41 columns