ricklupton / ipysankeywidget

IPython / Jupyter Sankey diagram widget
MIT License
174 stars 24 forks source link

IPython Sankey diagram widget Binder Conda Version

Display Sankey diagrams in IPython / Jupyter notebook using d3-sankey-diagram.

Installation

To install use pip:

$ pip install ipysankeywidget

Alternatively, to install using conda:

$ conda install -c conda-forge ipysankeywidget

For a development install, see DEVELOPING.md.

Browser support

Tested in Firefox and Chrome. There have been reports that it's not working in Safari.

Documentation

See the d3-sankey-diagram API docs: the attributes of the SankeyWidget are the same as the properties of the sankey object described there.

To change the figure size, use the ipywidgets Layout object:

layout = Layout(width="1000", height="1200")
SankeyWidget(links=data, layout=layout)

Examples

See notebooks in examples folder for usage examples. You can try these online using

Binder, or follow the links to static versions on nbviewer:

Changelog

v0.5.0 (16 December 2022)

v0.4.2 (29 April 2022)

v0.4.1 (18 February 2021)

v0.4.0 (19 November 2020)

v0.3.0

v0.2.5

v0.2.4

Contributors