Skip to content

FlowBorderAbsolute

Defined in: network/glyphs.ts:391

The absolute flow-border mode (the default): the ring is scale(flow) wide.

FlowBorderSpec

optional color?: string | ((value, index, graph) => string)

Defined in: network/glyphs.ts:436

Ring colour: a single CSS colour, or a per-node (value, index, graph) => cssColour accessor so the ring colour can also encode the per-node metric (a bare d3 colour scale fits — value is the node’s flow metric). An LOD aggregate of a module or structural tree gets the value its ring draws (its module value, else its members’ sum) with index -1; a spatial-tree cell takes the highest-flow node’s colour. Omitted (default): a darker shade of each glyph’s own fill — so a module aggregate’s ring is a darker shade of its module colour, not one shared colour.

FlowBorderBase.color


optional flow?: Float32Array<ArrayBufferLike> | NodeMetric

Defined in: network/glyphs.ts:427

Per-node enter/exit flow driving the border width: a caller Float32Array (length nodeCount) or a built-in NodeMetric. Summed over members for module aggregates. In the share mode it is the exit flow, divided by the node’s flow.

Optional when moduleFlow is given (#471) — for input that has each module’s flow but no per-node value, such as an Infomap .ftree. Then a node draws no ring, a module draws its moduleFlow value, and a module without one draws none: nothing is summed from values that do not exist. One of flow and moduleFlow is required.

FlowBorderBase.flow


optional moduleFlow?: (path) => number | undefined

Defined in: network/glyphs.ts:446

A module’s own enter/exit flow, by its Infomap path (e.g. [2, 1] = sub-module 1 of top module 2; [] = the root). Read for the aggregates of a module hierarchy the engine holds (data(graph, { modules }), drawn by the default lod() source "modules"): a module with a value draws its ring from it instead of its members’ sum — which overstates a higher-level module, since it also counts the flow between its own submodules. Return undefined to keep the sum for a module. Aggregates that are not modules (the "structure" / "spatial" sources) always sum. Called once per module when the style is resolved against the tree, never per frame.

readonly number[]

number | undefined

FlowBorderBase.moduleFlow


scale: (value) => number

Defined in: network/glyphs.ts:394

Maps the (summed) flow → ring width in the active sizeMode’s units, e.g. scaleSqrt().range([0, 6]).

number

number


optional share?: false

Defined in: network/glyphs.ts:392