Energy sankey¶
Download this notebook from GitHub (right-click to download).
In [1]:
import pandas as pd
import holoviews as hv
hv.extension('bokeh')
Declare data¶
In [2]:
edges = pd.read_csv('../../../assets/energy.csv')
edges.head(5)
Out[2]:
Plot¶
In [3]:
sankey = hv.Sankey(edges, label='Energy Diagram')
sankey.opts(label_position='left', edge_color='target', node_color='index', cmap='tab20')
Out[3]:
Download this notebook from GitHub (right-click to download).