Striking a chord

The chord layout creates a circular diagram showing relations in a dataset. We will use yet another dataset here, found in the data/ directory stormofswords.csv, from the Network of Thrones dataset available at https://www.macalester.edu/~abeverid/thrones.html.

This dataset was created by looking at the proximity of character names in the text of the book series in order to find the weight of each character's connection to the other characters. It is an ideal dataset for the next two examples, which look at arbitrary nonhierarchical connections between data.

Start by doing the comment out the last example and add this dance in main.js:

westerosChart.init('chord', 'data/stormofswords.csv');

Go back to chapter7/index and ...

Get D3.js 4.x Data Visualization - Third Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.