plt.yscale不显示所有项目

时间:2020-04-03 08:32:19

标签: python python-3.x matplotlib

我有一个数据框。 当我按原样绘制数据时,使用以下命令:

data.plot.scatter(x='a', y='b', legend=False)

我正在得到这个情节:

enter image description here

当我添加

plt.xscale('log')

数据看起来更加线性(这就是我想要做的)。 enter image description here

但是当我添加

plt.yscale('log')

情节看起来很奇怪: enter image description here

我还尝试将Y的最小值和最大值赋予

plt.ylim((0, 100000))

但是我的数据看起来仍然很奇怪

enter image description here

我在做什么错?为什么yscale不能用作xscale?

0 个答案:

没有答案
相关问题