liveBook · Manning

Node

As explained in D3.js in Action, Third Edition

A node is an entity or vertex in a network or graph that can participate in connections to other nodes.

A node is an entity or vertex in a network or graph. It participates in connections to other nodes, or represents an item in a hierarchy. Hierarchical nodes form parent-child structures; network nodes can have many-to-many relationships. section 11.0 section 12.0

Use nodes differently depending on the visualization:

  • In a circle pack, treemap, or tree chart, nodes occupy hierarchical levels from a single root through branches to leaf nodes. section 11.0
  • In a network, nodes represent connected things, while edges or links represent relationships between them. section 12.0
  • A node dataset can store relevant attributes such as a name, group, description, and numeric value. section 12.1

Romeo and Juliet character network

Represent each character as a node with fields such as name, house, description, and number of lines. Add an undirected edge whenever two characters share a scene, and use its weight to record how many scenes they share. A visualization can then show both the characters and their relationships. section 12.1

Figure 12.2 Network edges have a source and a target. In directed networks, the direction of the connection is meaningful and often represented by an arrow. In undirected networks, there’s no specific direction to the relationship.
figure

Compare directed and undirected connections: directed edges have meaningful source-to-target direction, while undirected edges represent relationships valid in both directions. section 12.1

How D3.js in Action, Third Edition covers it

How deep it goes
Defines nodes, separates them from edges, and shows node data preparation, but defers detailed force-simulation implementation.
Examples
Uses language hierarchies and Romeo and Juliet characters to demonstrate root, leaf, attributed, connected, and weighted nodes.
What you can do after
Build network visualizations by separating node data from edge data and attaching attributes to each node.
How it connects
Connects nodes with graphs, edges, links, hierarchies, adjacency matrices, arc diagrams, and force-directed layouts.

Also explained in

Compare how 19 books explain node →

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.