Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/293.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 伊皮顿罐头';t绘制三维散点图_Python_Matplotlib_Pyqt - Fatal编程技术网

Python 伊皮顿罐头';t绘制三维散点图

Python 伊皮顿罐头';t绘制三维散点图,python,matplotlib,pyqt,Python,Matplotlib,Pyqt,当我尝试绘制三维散点图时,会出现以下错误: In [10]: Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/matplotlib/backends/backend_qt5agg.py", line 176, in __draw_idle_agg FigureCanvasAgg.draw(self) File "/usr/local/lib/python2.7/dist

当我尝试绘制三维散点图时,会出现以下错误:

In [10]: Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/matplotlib/backends/backend_qt5agg.py", line 176, in __draw_idle_agg
    FigureCanvasAgg.draw(self)
  File "/usr/local/lib/python2.7/dist-packages/matplotlib/backends/backend_agg.py", line 474, in draw
    self.figure.draw(self.renderer)
  File "/usr/local/lib/python2.7/dist-packages/matplotlib/artist.py", line 61, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/matplotlib/figure.py", line 1159, in draw
    func(*args)
  File "/usr/local/lib/python2.7/dist-packages/mpl_toolkits/mplot3d/axes3d.py", line 271, in draw
    for col in self.collections]
  File "/usr/local/lib/python2.7/dist-packages/mpl_toolkits/mplot3d/art3d.py", line 455, in do_3d_projection
    xs, ys, zs = self._offsets3d
AttributeError: 'Path3DCollection' object has no attribute '_offsets3d'

If you suspect this is an IPython bug, please report it at:
    https://github.com/ipython/ipython/issues
or send an email to the mailing list at ipython-dev@scipy.org

You can print a more detailed traceback right now with "%tb", or use "%debug"
to interactively debug it.

Extra-detailed tracebacks for bug-reporting purposes can be enabled via:
    %config Application.verbose_crash=True
之前我在使用PyQt4时遇到了这个错误。我花了几个小时安装PyQt5(在我的Ubuntu版本上很难)。从现在开始,伊普顿

ipython --pylab='qt5'
我希望它能工作,但在尝试绘图时再次收到相同的错误消息

请注意,当我调用
scatter
方法时会发生这种情况。然后,在我关闭图形之前,每次我在ipython中按enter键时,它都会继续给出相同的回溯


你知道我做错了什么吗?

看来我发现了问题所在。不带
**
的到
scatter()


啊。

看来我找到问题了。不带
**
的到
scatter()


Argh.

您是否使用了mpl_toolkits.mplot3d导入Axes3D中的
ax=fig.add_子图(111,projection='3d')
?(如果您显示了导致错误的所有命令,这将很有帮助。)您是否使用了mpl_toolkits.mplot3d导入Axes3D和
ax=fig.add_子图(111,projection='3d')
?(如果显示导致错误的所有命令,这将非常有用。)