Filtre pour un ensemble de valeurs Pandas DataFrame
df_filtered = df[df['Col1'].isin(allowed_values)]
HBE
df_filtered = df[df['Col1'].isin(allowed_values)]
df.loc[df['dollars_spent'] > 0, 'purchase'] = 1
df.loc[df['colA'] == 'a', 'newCol'] = value