[英]Juypter notebook pandas_profiling: cannot import name 'to_html' from 'pandas_profiling.report'
I am trying to import pandas profiling.我正在尝试导入熊猫分析。
import pandas as pd
!pip install pandas_profiling
import pandas_profiling as pp
However, there is a error message saying that cannot import name to_html
from pandas_profiling.report
但是,有一条错误消息说 cannot import name
to_html
from pandas_profiling.report
I got the same error using pip, but it worked like a charm after using the conda install我使用 pip 遇到了同样的错误,但在使用 conda 安装后它就像一个魅力
conda install -c conda-forge pandas-profiling. conda install -c conda-forge pandas-profiling.
If you're not using Conda environment, i'd suggest install directly from the github using:如果您不使用 Conda 环境,我建议使用以下命令直接从 github 安装:
pip install https://github.com/pandas-profiling/pandas-profiling/archive/master.zip 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: |
This will come after using conda method ... looks like this will solve your problem and mine too这将在使用 conda 方法后出现......看起来这将解决你和我的问题
the above solution was not working in my case上述解决方案不适用于我的情况
use this on your anaconda prompt在你的 anaconda 提示符上使用它
conda env create -n pandas-profiling
conda activate pandas-profiling
conda install -c conda-forge pandas-profiling
then you can use profile report on your editor然后你可以在你的编辑器上使用个人资料报告
from pandas_profiling import ProfileReport
it will work for sure它肯定会起作用
我遇到了同样的错误,尝试conda install -c conda-forge pandas-profiling
并开始工作!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.