SANKEY Experiment
A Sankey diagram visualizes the flow of claims between categories and time steps, with node widths and link thicknesses proportional to values. It reads external CSV data containing source, target, and count columns, then constructs the graph using d3.sankey with d3.csv and d3.nest to aggregate duplicate nodes. The SVG rendering includes draggable nodes via d3.drag, hover tooltips showing formatted values, and uses d3.scaleOrdinal with schemeCategory20 for node coloring.
AI-generated descriptionThis is a sankey diagram used as an example in the book D3 Tips and Tricks. It is based on a simpler version here.
It demonstrates the construction of a sankey diagram using d3.js from external csv data that is formatted using just link data and named values. It should be taken in context with the text of the book which can be downloaded for free from Leanpub.
forked from <a href='http://bl.ocks.org/d3noob/'>d3noob</a>'s block: <a href='http://bl.ocks.org/d3noob/c9b90689c1438f57d649'>Sankey from csv with d3.js</a>
forked from <a href='http://bl.ocks.org/anonymous/'>anonymous</a>'s block: <a href='http://bl.ocks.org/anonymous/649b7a2a2d90b430dcb45eee1cdb1d49'>Sankey from csv with d3.js</a>
forked from <a href='http://bl.ocks.org/SpaceActuary/'>SpaceActuary</a>'s block: <a href='http://bl.ocks.org/SpaceActuary/b91f25d80a103736b14477dc8a3a7c76'>Sankey from csv with d3.js v4</a>