#plot data
fig, ax = plt.subplots(figsize=(15,7))
data.groupby(['date','type']).count()['amount'].plot(ax=ax)
df.groupby('year').case_status.value_counts().unstack(0).plot.barh()
df.groupby(['tags_0', 'gender']).gender.count().unstack().plot(kind='barh', legend=False, color=['r', 'g', 'b'])
# plot data
fig, ax = plt.subplots(figsize=(15,7))
# use unstack()
data.groupby(['date','type']).count()['amount'].unstack().plot(ax=ax)
# car_sales:> it is dataframe
# "Make" is column, or feature name
# operation is mean
car_sales.groupby(["Make"]).mean()