标签: pandas bar-chart percentage
我试图在条形图中以百分比表示以下数据, 我似乎做不到:
这是我的剧情代码:
counts = ds.groupby(['Age','Gender']).Gender.count().unstack()
print(counts) ax = counts.plot(kind='bar',stacked = False,rot=0, colormap = 'Paired')
plt.title('Gender distribution in Age group')