python-3.x - 如何在macos Mojave上修复python中的错误13?
问题描述
我无法执行简单的 python 代码。
错误信息:
(Traceback (most recent call last):
File "/Users/vervit/Desktop/python/new1.py", line 1, in <module>
import pandas as pd
ModuleNotFoundError: No module named 'pandas')
pandas
, matplotlib
,numpy
已经安装了。pip
, conda
,python
更新到最新版本
我已经尝试过的代码
1) sudo python your_python_script.py
2) sudo chmod a+rw /path/to/folder/that/you/want/to/write/to
3) python3 -m venv env
source ./env/bin/activate
python -m pip install google-assistant-sdk[samples]
4) 将包安装到用户文件夹:
python -m pip install --user google-assistant-sdk[samples]
没有任何工作
import pandas as pd
import Quandl
df = Quandl.get('WIKI/GOOGL')
print(df.head())
应该显示股票价格。
解决方案
推荐阅读
- oracle - TOAD Automation Designer Export to Excel utilizing Variables
- asp.net-mvc - How do I allow/deny users based on their Identity in a simple MVC application?
- c# - 需要帮助理解 MVVM 模型 WPF DataGrid
- java - I want to edit my recyclerview data on edit text changes and update in model which I am getting from service in json format
- python - 行右端标记的旋转和翻转
- firebase - 无法在控制台中运行 firebase 命令:错误(`@grpc/grpc-js 仅适用于节点 ${supportedNodeVersions}`)
- java - 从方法中断线程
- vue.js - 如何以可重用的方法使用 vue-router
- jquery - 根据在 jquery 中选中的单选按钮执行不同的事件
- kubernetes - 在我的 3 节点 K8S 设置上安装了 Calico。跨节点的 PODS 无法通信