导入熊猫,python 2.7,pip 19.1.1时出现问题

时间:2019-07-29 20:17:21

标签: python pandas python-2.7 installation

我在Mac上使用python 2.7,无法安装熊猫。如果我激活Conda基本环境,则熊猫可以正常工作,但不能正常工作。

我尝试过:

pip install pandas  
pip2 install pandas  
sudo pip install pandas  
pip easy_install pandas  

我尝试pip install pandas时的确切错误如下所示:

错误:由于环境错误而无法安装软件包:[('/ System / Library / Frameworks / Python.framework / Versions / 2.7 / Extras / lib / python / dateutil / parser.pyc','/ private / var /folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/parser.pyc',“ [Errno 1]不允许的操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-unpar-Di .pyc'“),('/ System / Library / Frameworks / Python.framework / Versions / 2.7 / Extras / lib / python / dateutil / relativedelta.py','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / relativedelta.py',“ [错误1]不允许的操作:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/relativedelta.py'”),('/系统/库/框架/Python.framework/版本/2.7/Extras/lib/python/dateutil/zoneinfo/zoneinfo-2010g.tar.gz'、'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall -EPDiEt / zoneinfo / zoneinfo-2010g.tar.gz',“ [[Errno 1]不允许的操作:'/ priva te / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / zoneinfo / zoneinfo-2010g.tar.gz'“),('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/ lib / python / dateutil / zoneinfo / init .py','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / zoneinfo / init .py',“ [Errno 1]不允许的操作:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/zoneinfo/init.py'”),( '/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/zoneinfo/init.pyc','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / zoneinfo / init .pyc',“ [Errno 1]不允许的操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt /zoneinfo/init.pyc'“),('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/zoneinfo','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / zoneinfo',“ [Errno 1]不允许的操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt ),('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/tz.py','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall- EPDiEt / tz.py',“ [错误1]不允许操作:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/tz.py'”),('/ System / Library / Frameworks / Python.framework / Versions / 2.7 / Extras / lib / python / dateutil / relativedelta.pyc','/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/relativedelta.pyc',“ [ Errno 1]不允许操作:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/relativedelta.pyc'“),('/System/Library/Frameworks/Python.framework/Versions/2.7 /Extras/lib/python/dateutil/rrule.pyc','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj330 0000gn / T / pip-uninstall-EPDiEt / rrule.pyc',“ [Errno 1]不允许的操作:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/rrule.pyc'”) ,('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/init.py','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / init .py',“ [Errno 1]不允许的操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / < strong> init .py'“))('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/parser.py','/ private / var / folders /ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/parser.py',“ [Errno 1]不允许的操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / par。 '''),('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/tzwin.py','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj33000 00gn / T / pip-uninstall-EPDiEt / tzwin.py',“ [Errno 1]不允许的操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / tzwin.py'”) ,('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/rrule.py','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt /rrule.py',“ [Errno 1]不允许的操作:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/rrule.py'”),('/ System / Library / Frameworks /Python.framework/Versions/2.7/Extras/lib/python/dateutil/init.pyc','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / < strong> init .pyc”,“ [Errno 1]不允许操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / init .pyc '''),('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/easter.py','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000g n / T / pip-uninstall-EPDiEt / easter.py',“ [Errno 1]不允许的操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt / easter.py'”) ,('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/dateutil/easter.pyc','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt /easter.pyc',“ [Errno 1]不允许的操作:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/easter.pyc'”),('/ System / Library / Frameworks /Python.framework/Versions/2.7/Extras/lib/python/dateutil/tz.pyc','/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/tz.pyc',“ [Errno 1]不允许操作:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/tz.pyc'“),('/System/Library/Frameworks/Python.framework/Versions/2.7/ Extras / lib / python / dateutil / tzwin.pyc','/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/tzwin.pyc',“ [Errno 1]操作不允许的位置:'/private/var/folders/ll/2w2bypwj1r72871bd71cj3300000gn/T/pip-uninstall-EPDiEt/tzwin.pyc'“),('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/ lib / python / dateutil','/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt',“ [Errno 1]不允许的操作:'/ private / var / folders / ll / 2w2bypwj1r72871bd71cj3300000gn / T / pip-uninstall-EPDiEt'“)]

1 个答案:

答案 0 :(得分:0)

尝试使用pip install pandas --user

通过这种方式,您可以将其安装在用户目录中,并在其中拥有所有必需的权限。