Datapane:Python 数据分析报告生成库


Datapane:Python 数据分析报告生成库

Datapane is a Python library which makes it simple to build reports from the common objects in your data analysis, such as pandas DataFrames, plots from Python visualisation libraries, and Markdown.

Reports can be exported as standalone HTML documents, with rich components which allow data to be explored and visualisations to be used interactively.

For example, if you wanted to create a report with a table viewer and an interactive plot:

import pandas as pd
import altair as alt
import datapane as dp
df = pd.read_csv('')
chart = alt.Chart(df).encode(
r = dp.Report(dp.Table(df), dp.Plot(chart))'report.html', open=True)

This would package a standalone HTML report such as the following, with an searchable Table and Plot component.

Getting Started


Datapane currently contains the following components. Need something different? Open an issue (or make a PR!)

Component Description Supported Formats Example
Table A searchable, sortable table component for datasets. Supports up to 10m cells. Pandas DataFrames, JSON documents, Local CSV files Table(df)
Plot A wrapper for plots from Python visualisation libraries. Altair, Bokeh, Matplotlib, SVG Plot(altair_chart)
Markdown A simple Markdown component to document your report. Markdown, Text Markdown("# My fun title")

In addition to the this local library, provides an API and hosted platform which allows you to:

  1. Upload Jupyter Notebooks and Python scripts, so that other people can run them in their browser with parameters to generate reports dynamically
  2. Share and embed reports online — either publicly, or privately within your team

Joining the community

Looking to get answers to questions or engage with us and the wider community? Our community is most active on our Discourse Forum. Submit requests, issues, and bug reports on this GitHub repo, or join us by contributing on some good first issues on this repo.

We look forward to building an amazing open source community with you!






Datapane:Python 数据分析报告生成库