Package datapane.client.api

API docs for Datapane Client

These docs describe the Python API for building Datapane Reports, along with additional information on the Datapane Teams API.

Usage docs for Datapane can be found at https://docs.datapane.com

These objects are all available under the datapane module, via import datapane as dp (they are re-exported from datapane.client.api).

Datapane Reports API

The core reporting APIs are available on both the public and teams plans, these are found in datapane.client.api.report, including,

Datapane Teams

Additional API docs for teams and enterprise features are found in datapane.client.api.teams that provide automation and sharing of data analytics workflows

Note: These docs describe the latest version of the datapane API available on pypi

Latest release

Sub-modules

datapane.client.api.common

Common objects …

datapane.client.api.dp_object

Base classes …

datapane.client.api.files

Creating charts. …

datapane.client.api.report

Main Reporting API module, includes both the core Report object, and the blocks in …

datapane.client.api.runtime

Script runtime API …

datapane.client.api.teams

Datapane Teams API …

datapane.client.api.templates

Datapane helper functions to make creating your reports a bit simpler and reduce common tasks …

datapane.client.api.user

Datapane User API …

Classes

class Markdown (*a, **kw)

Markdown objects store Markdown text that can be displayed as formatted text when viewing your report.

Note: This object is also available as dp.Text, and any strings provided directly to the Report/Group object are converted automatically to Markdown blocks

Tip: You can also insert a dataframe in a Markdown block as a table by using df.to_markdown(), or use dp.Table or dp.DataTable for dedicated dataframe tables.

Args:te text: The markdown formatted text, use triple-quotes, ("""# My Title""") to create multi-line markdown text file: Path to a file containing markdown text id: A unique id for the block to aid querying (optional)

Ancestors

Class variables

var content : str
var id : Union[str, NoneType]

Inherited from: Text.id

dummy

Methods

def format(self, *args: Union[ForwardRef('Group'), ForwardRef('Select'), ForwardRef('DataBlock'), Any], **kwargs: Union[ForwardRef('Group'), ForwardRef('Select'), ForwardRef('DataBlock'), Any]) ‑> Group

Inherited from: Text.format

Format the markdown text template, using the supplied context to insert blocks into {{}} markers in the template …

class Blocks (*a, **kw)

Groups act as a container that hold a list of nested Blocks object, such as Tables, Plots, etc.. - they may even hold Group themselves recursively.

Group are used to provide a grouping for blocks can have layout options applied to them

Note: Group expects a list of Blocks, e.g. a Plot or Table, but also including Select or Groups themselves,

but if a Python object is passed, e.g. a Dataframe, Datapane will attempt to convert it automatically.

Args

*arg_blocks
Group to add to report
blocks
Allows providing the report blocks as a single list
id
A unique id for the blocks to aid querying (optional)
label
A label used when displaying the block (optional)
rows
Display the contained blocks, e.g. Plots, using n rows (set to 0 to autofill)
columns
Display the contained blocks, e.g. Plots, using n columns (set to 0 to autofill)

Tip: Group can be passed using either arg parameters or the blocks kwarg, e.g.

dp.Group(plot, table, columns=2) or dp.Group(blocks=[plot, table], columns=2)

Ancestors

Class variables

var blocks : List[Union[GroupSelectDataBlock]]
var id : Union[str, NoneType]

Inherited from: Group.id

dummy