algorithms

algorithms.betweenness

betweenness(options: BetweennessOptions & AlgorithmWriteOptions): Promise<NodeScalarResult>

Compute betweenness-centrality scores for all nodes (or a subset).

Dispatched to the background worker. Emits the standard algorithm lifecycle events. When writeTo is supplied scores are written to node properties (recorded in history, undoable).

optionsBetweennessOptions & AlgorithmWriteOptionsBetweennessOptions merged with AlgorithmWriteOptions.

Returns: Promise<NodeScalarResult>