Sankey Diagram

A Sankey diagram is a chart used to visualize the flow of resources such as energy, money, or materials between different nodes. It uses bandwidth to represent flow magnitude, with nodes and flow lines intuitively showing the direction and distribution of each part. It is commonly used in energy flow, fund flow, user path analysis, and other scenarios.

Use Cases

  • Suitable for showing flow distribution and direction relationships, such as energy flow, fund flow, user behavior paths, supply chain flow, etc.
  • Highlight the distribution structure and flow paths of traffic.

Visual Examples

Global energy flow from primary sources to end use.

User behavior path analysis from homepage to payment completion, custom colors

Supply chain fund flow from raw materials to consumers, custom palette

Options

Configuration Options

PropertyTypeRequiredDescription
typestringrequiredValue must be "sankey".
dataObject[]requiredSankey diagram data.
data.sourcestringrequiredSource node name.
data.targetstringrequiredTarget node name.
data.valuenumberrequiredFlow value.
nodeAlign'left' | 'center' | 'right' | 'justify'optionalNode alignment, default is "center".
titlestringoptionalChart title.
theme'default' | 'dark' | 'academy'optionalChart theme, default is "default".
styleObjectoptionalChart style.
style.palettestring[]optionalMust be an array of valid color values.
style.backgroundColorstringoptionalMust be a valid color value.