在本文章,我们主要给大家介绍一些顶级的自动化EDA工具,并且通过实例来展示具体效果。
代码链接:https://www.kaggle.com/andreshg/automatic-eda-libraries-comparisson/notebook
📊 AutoViz 📚
AutoViz在众多免费软件Pythonic Rapid EDA Automation工具中脱颖而出,以非常快速的方式运行,这比其紧密的免费软件竞争对手SweetViz或Pandas Profiling更好
安装方式:
!pip install git+git://github.com/AutoViML/AutoViz.git
!pip install xlrd
from autoviz.AutoViz_Class import AutoViz_Class
AV = AutoViz_Class()
dftc = AV.AutoViz(
filename='',
sep='' ,
depVar='target',
dfte=df,
header=0,
verbose=1,
lowess=False,
chart_format='png',
max_rows_analyzed=300000,
max_cols_analyzed=30
)
![](https://i-blog.csdnimg.cn/blog_migrate/7a9e445219287a5bc0171f879a6f90f4.png)
![](https://i-blog.csdnimg.cn/blog_migrate/84b0061c668befdad28f0cae012435a0.png)
![](https://i-blog.csdnimg.cn/blog_migrate/59e51e11f212e71b4c20fcc802b5381f.png)
![](https://i-blog.csdnimg.cn/blog_migrate/391716b2b15b510c42d970e4d8f4a677.png)
![](https://i-blog.csdnimg.cn/blog_migrate/ca1aff50eedbf54c5eca887e4224b8b6.png)
![](https://i-blog.csdnimg.cn/blog_migrate/bfb439d499cba81b6f8c49b949e183db.png)
📊 Pandas Profiling 📚
from pandas_profiling import ProfileReport
df = pd.read_csv('/kaggle/input/titanic/train.csv')
report = ProfileReport(df)
# Start of Pandas Profiling process
start_time = dt.datetime.now()
print("Started at ", start_time)
report
![](https://i-blog.csdnimg.cn/blog_migrate/c77c9bc178fc6ef1ab711064d4714cfb.png)
📊 SweetViz 📚
!pip install sweetviz
import sweetviz as sv
df = pd.read_csv('/kaggle/input/credit-card-customers/BankChurners.csv').head(2000)
advert_report = sv.analyze([df, 'Data'])
advert_report.show_html()
print('SweetViz finished!!')
finish_time = dt.datetime.now()
print("Finished at ", finish_time)
elapsed = finish_time - start_time
print("Elapsed time: ", elapsed)
![](https://i-blog.csdnimg.cn/blog_migrate/823380c7160f402dc8f265a10c27c147.png)
📊 D-Tale 📚
安装
!pip install dtale
import dtale
dtale.show(df)
官方链接:https://github.com/man-group/dtale
📊 Dataprep 📚
!pip install -U dataprep
实例
from dataprep.eda import plot, plot_correlation
plot(df)
![](https://i-blog.csdnimg.cn/blog_migrate/02e4fb32f972a44422c0073d0c7c7d1b.png)
plot_correlation(df)
![](https://i-blog.csdnimg.cn/blog_migrate/3a147f63647b4b64faf34e00ac307d31.png)
plot(df, "Customer_Age")
![](https://i-blog.csdnimg.cn/blog_migrate/79e7a8f260f90e99308b9d5cbc0c2404.png)
plot(df, "Customer_Age", "Gender")
![](https://i-blog.csdnimg.cn/blog_migrate/fbecfb656b88f2ed3c29c1c4abe44a39.png)
参考链接
- Pandas Profiling GitHub - https://github.com/pandas-profiling/pandas-profiling
- Dan Roth, AutoViz: A New Tool for Automated Visualization - https://towardsdatascience.com/autoviz-a-new-tool-for-automated-visualization-ec9c1744a6ad
- George Vyshnya, PROs and CONs of Rapid EDA Tools - https://medium.com/sbc-group-blog/pros-and-cons-of-rapid-eda-tools-e1ccd159ab07
- SweetViz - https://towardsdatascience.com/sweetviz-automated-eda-in-python-a97e4cabacde
- DataPrep - https://sfu-db.github.io/dataprep/user_guide/eda/plot.html