![](/img/trans.png)
[英]pandas profiling import error : not able to import pandas_profiling package
[英]Juypter notebook pandas_profiling: cannot import name 'to_html' from 'pandas_profiling.report'
我正在尝试导入熊猫分析。
import pandas as pd
!pip install pandas_profiling
import pandas_profiling as pp
但是,有一条错误消息说 cannot import name to_html
from pandas_profiling.report
我使用 pip 遇到了同样的错误,但在使用 conda 安装后它就像一个魅力
conda install -c conda-forge pandas-profiling.
如果您不使用 Conda 环境,我建议使用以下命令直接从 github 安装:
pip 安装https://github.com/pandas-profiling/pandas-profiling/archive/master.zip
(base) C:\Users\saurabh>conda install -c conda-forge pandas-profiling
Collecting package metadata (repodata.json): done
Solving environment: |
这将在使用 conda 方法后出现......看起来这将解决你和我的问题
上述解决方案不适用于我的情况
在你的 anaconda 提示符上使用它
conda env create -n pandas-profiling
conda activate pandas-profiling
conda install -c conda-forge pandas-profiling
然后你可以在你的编辑器上使用个人资料报告
from pandas_profiling import ProfileReport
它肯定会起作用
我遇到了同样的错误,尝试conda install -c conda-forge pandas-profiling
并开始工作!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.