liveBook · Manning

Parent-child relationship

As explained in D3.js in Action, Third Edition

A parent-child relationship is a directed association in which one hierarchical item is the parent of another item.

A parent-child relationship connects hierarchical items from a parent to its direct child. In tabular data, Child and Parent columns encode these links; the root item has no parent. section 11.1.1

Build a hierarchy from flat CSV data:

  • Represent each item in a row with its child identifier and parent identifier. section 11.1.1

How D3.js in Action, Third Edition covers it

How deep it goes
Explains column encoding and implements conversion with D3 stratify, then exposes roots, descendants, and leaves.
Examples
Uses Languages, language families, branches, and individual languages in a CSV table.
What it assumes
Starts with spreadsheet-style rows and introduces the required D3 hierarchy transformation.
What you can do after
Build it from scratch by encoding CSV relationships and converting them into a D3 hierarchy.
How it connects
Connects CSV data, hierarchical visualization, D3 stratify, roots, descendants, and leaves.

Also explained in

Compare how 2 books explain parent-child relationship →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of D3.js in Action, Third Edition. The section links point to the parts of the book it draws on.