random_attachment#
- random_attachment(g, nodes_to_add, edges_per_step, seed=None)#
Generates a graph using the random attachment model
This function is a graph generation model based upon: Callaway, Duncan S., et al. “Are randomly grown graphs really random?.” Physical Review E 64.4 (2001): 041902.
- Parameters:
g – The graph you wish to add nodes and edges to
nodes_to_add – The amount of nodes you wish to add to the graph (steps)
edges_per_step – The amount of edges a joining node should add to the graph
seed – The seed used in rng, an array of length 32 containing ints (ints must have a max size of u8)
- Returns:
None