How do i plot facet plots in pandas How do i plot facet plots in pandas pandas pandas

How do i plot facet plots in pandas


You need to unstack so type are columns, and then use the subplots parameter:

test.groupby(['week', 'type',               'type2']).agg('sum').unstack(1).plot(kind='bar', subplots=True)

Resulting plot