Warning

This documents an unmaintained version of NetworkX. Please upgrade to a maintained version and see the current NetworkX documentation.

SwapΒΆ

Swap edges in a graph.

double_edge_swap(G[, nswap, max_tries]) Swap two edges in the graph while keeping the node degrees fixed.
connected_double_edge_swap(G[, nswap]) Attempt nswap double-edge swaps in the graph G.