merge & only bring over certain columns from one dataframe

PHOTO EMBED

Thu Jan 20 2022 09:47:59 GMT+0000 (Coordinated Universal Time)

Saved by @CaoimhedeFrein #python

monthly_sales = pd.merge(prediction_df[['category', 'distributorid', 'segment']], monthly_sales, on = ['category', 'distributorid'])
content_copyCOPY