Advertisement
Dodma

Untitled

Jun 19th, 2020
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. romi_s = new_for_romi.pivot_table(
  2. index='first_order_month',
  3. columns='source_id',
  4. values='romi',
  5. aggfunc='mean')
  6. romi_s.index = romi_s.index.strftime("%m/%Y")
  7. plt.figure(figsize=(13, 9))
  8. plt.title('ROMI')
  9. plt.xlabel('Месяц покупок')
  10. plt.ylabel('Месяц когорты')
  11. 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