Jupyter(IPython)笔记本没有密谋 [英] Jupyter (IPython) notebook not plotting

查看:310
本文介绍了Jupyter(IPython)笔记本没有密谋的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我安装了anaconda来使用pandas和scipy。我阅读和观看熊猫教程,他们都说使用

I installed anaconda to use pandas and scipy. I reading and watching pandas tutorials and they all say to open the ipython notebook using

 ipython notebook --pylab==inline

但是当我这样做时,我收到一条消息说

but when I do that I get a message saying

"Support for specifying --pylab on the command line has been removed. Please use '%pylab = inline' or '%matplotlib =inline' in the notebook itself"

但这不起作用。然后,当我尝试plot(arange(10))时,我收到一条消息,说名称'情节'没有定义。我尝试从.csv文件中绘制数据并获得

But that does not work. Then when I try "plot(arange(10))" I get a message saying "name 'plot' is not defined." I trying plotting data from a .csv file and got

"matplotlib.axes._subplots.AxesSubplot at 0xebf8b70".

我该怎么办?

推荐答案

我相信当他们从IPython转换到更普通的Jupyter笔记本时,pylab魔法被移除了。

I believe the pylab magic was removed when they transitioned from IPython to a more general Jupyter notebook.

尝试:

%matplotlib inline

此外,当您收到如下消息时:

Also when you get a message like:

"matplotlib.axes._subplots.AxesSubplot at 0xebf8b70".

这只是显示对象的IPython。你需要指定IPython显示它。因此matplotlib内联魔术。

That's just IPython displaying the object. You need to specify IPython display it. Hence the matplotlib inline magic.

这篇关于Jupyter(IPython)笔记本没有密谋的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆