【发布时间】:2019-05-15 21:27:02
【问题描述】:
我希望我使用 matplotlib 创建的饼图显示实际值,而不仅仅是百分比。这是我的代码:
pie_shares= [i for i in mean.values()]
positions = [i for i in mean.keys()]
plt.pie(pie_shares,labels=positions, autopct='%1.1f%%', )
plt.show()
【问题讨论】:
-
只需删除“autopct=”部分。
标签: python matplotlib