Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- romi_s = new_for_romi.pivot_table(
- index='first_order_month',
- columns='source_id',
- values='romi',
- aggfunc='mean')
- romi_s.index = romi_s.index.strftime("%m/%Y")
- plt.figure(figsize=(13, 9))
- plt.title('ROMI')
- plt.xlabel('Месяц покупок')
- plt.ylabel('Месяц когорты')
- sns.heatmap(romi_s.cumsum(axis=1), annot=True, fmt='.2f', linewidths=1, linecolor='gray')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement