pandas.tools在哪里 [英] Where is pandas.tools
问题描述
安装pandas
后:
idf:~/Documents/python/plot$ pip3 install pandas --user
Collecting pandas
Using cached https://files.pythonhosted.org/packages/f9/e1/4a63ed31e1b1362d40ce845a5735c717a959bda992669468dae3420af2cd/pandas-0.24.0-cp36-cp36m-manylinux1_x86_64.whl
Requirement already satisfied: numpy>=1.12.0 in /home/idf/.local/lib/python3.6/site-packages (from pandas) (1.15.4)
Requirement already satisfied: pytz>=2011k in /home/idf/.local/lib/python3.6/site-packages (from pandas) (2018.7)
Requirement already satisfied: python-dateutil>=2.5.0 in /home/idf/.local/lib/python3.6/site-packages (from pandas) (2.7.5)
Requirement already satisfied: six>=1.5 in /home/idf/.local/lib/python3.6/site-packages (from python-dateutil>=2.5.0->pandas) (1.12.0)
zipline 1.3.0 has requirement pandas<=0.22,>=0.18.1, but you'll have pandas 0.24.0 which is incompatible.
Installing collected packages: pandas
Successfully installed pandas-0.24.0
idf:~/Documents/python/plot$
我尝试加载pandas.tools
,
from pandas.tools.plotting import autocorrelation_plot
ModuleNotFoundError Traceback (most recent call last)
<ipython-input-52-e11ce94b8d5d> in <module>
----> 1 from pandas.tools.plotting import autocorrelation_plot
ModuleNotFoundError: No module named 'pandas.tools'
如何访问pandas.tools
?
推荐答案
程序包pandas.tools.plotting
已移动到此提交,作为#16005 和#12548 在熊猫0.20.0
中.
Package pandas.tools.plotting
was moved to pandas.plotting
in this commit, as part of #16005 and #12548 in Pandas 0.20.0
.
最近,在熊猫此提交中://github.com/pandas-dev/pandas/pull/23376"rel =" noreferrer>#23376 在Pandas 0.24.0
中发布,这是已弃用的pandas.tools
程序包,该程序包以前允许pandas.tools.plotting
为了继续工作,已被删除.
More recently, in this commit in Pandas #23376 released in Pandas 0.24.0
, the deprecated pandas.tools
package, which was previously allowing pandas.tools.plotting
to keep working, was removed.
Ergo,一旦允许Pandas升级到0.24.0
或更高版本,您将需要替换从pandas.tools.plotting
导入的内容,而不是从pandas.plotting
导入的内容.
Ergo, once you allow Pandas to upgrade to 0.24.0
or later, you will need to replace imports from pandas.tools.plotting
to be instead from pandas.plotting
.
这篇关于pandas.tools在哪里的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!