Skip to content

@graphty/layout / index / ForceAtlas2SimulationOptions

Type Alias: ForceAtlas2SimulationOptions ​

ForceAtlas2SimulationOptions = ForceAtlas2Options & object

Defined in: simulation/forceatlas2.ts:47

The options of the ForceAtlas2Simulation constructor: every ForceAtlas2Options field, plus compat.

Type Declaration ​

compat? ​

readonly optional compat?: "paper" | "networkx"

Which ForceAtlas2 variant to run. "paper" (the default) is the published algorithm: gravity pulls toward the centroid and the swing and traction sums are recomputed every iteration. "networkx" reproduces NetworkX 3.4.2's forceatlas2_layout, so positions match a NetworkX run on the same input.