Skip to content

Instantly share code, notes, and snippets.

@coston
Last active May 4, 2018 18:48
Show Gist options
  • Save coston/6ae78a009e89cf717370b727804f5892 to your computer and use it in GitHub Desktop.
Save coston/6ae78a009e89cf717370b727804f5892 to your computer and use it in GitHub Desktop.
Sankey Demo Data Flow

Data structure:

{
  "nodes": [{
      "id": {string|number},
      "color": {optional color spec}
    }
  ],
  "links": [{
      "source": {string|number}, // ref to node id
      "target": {string|number}, // ref to node id
      "value": {number}
    }
  ]
}

Data for this chart does not support cyclic dependencies. For example, something like A —> A or A —> B —> C —> A will crash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment