serhii.net

In the middle of the desert you can say anything you want

15 May 2023

Pandas seaborn plotting groupby can be used without reset_index

Both things below work! Seaborn is smart and parses pd groupby-s as-is

sns.histplot(data=gbc,
            x='items_available', 
            hue="item.item_category",
            )
sns.histplot(data=gbc.reset_index(),
	x='items_available', 
	hue="item.item_category",
	)
Nel mezzo del deserto posso dire tutto quello che voglio.