nimnet/generators/stochastic

Search:
Group by:

Stochastic graph generator

Procs

proc stochasticGraph[N](g: Graph[N]; weighted: bool = false): Graph[N]
Create a stochastic graph (row-normalize adjacency). Each row sums to 1.0. If weighted=true, normalize weighted adjacency.