Interactive applications
The ydata-profiling
report, through several of its interfaces, can be
integrated in interactive data applications such as those developed with
Streamlit or Panel.
Streamlit
Streamlit is an open-source Python library made to build web-apps for machine learning and data science.
Note
This feature is only available for versions previous to ydata-profiling (<=3.6.2).
You can install the ydata-profiling component for Streamlit with pip.
Dash
Dash is a Python framework for
building machine learning & data science web apps, built on top of
Plotly.js, React and Flask. It is commonly used for interactive data
exploration, precisely where ydata-profiling
also focuses. Inline
access to the insights provided by ydata-profiling
can help guide the
exploratory work allowed by Dash. To integrate a Profiling Report inside
a Dash app, two options exist:
Load HTML version of report as an asset
Assuming the HTML version of the report is in report.html
, move it to
a folder called assets
. The snippet below shows a simple Dash app,
app.py
, embedding this report:
Create a Dash dashboard with ydata-profiling integrated | |
---|---|
When running python app.py
, a Dash app with the report embedded will
be available on http://127.0.0.1:8050.
Directly embed the raw HTML
A more unorthodox option requiring no explicit file handling involves
using the dash-dangerously-set-inner-html
library to directly embed
the HTML raw text (thus requiring no HTML export). Install the library
through pip
:
And configure the Dash app as in the following snippet:
When running python app.py
, a Dash app with the report embedded will
be available on
<http://127.0.0.1:8050>`_. While this option is somewhat more direct, **the embedded report will not be fully interactive, with some buttons unclickable**. Panel ----- For more information on how to use
ydata-profiling`[
in Panel, see `this GitHub issue
\<https://github.com/ydataai/ydata-profiling/issues/491>]{.title-ref}_
and this integration
example.