netneurotools.networks.randmio_und
- netneurotools.networks.randmio_und(W, itr)[source]
Optimized version of randmio_und.
This function randomizes an undirected network, while preserving the degree distribution. The function does not preserve the strength distribution in weighted networks.
This function is significantly faster if numba is enabled, because the main overhead is np.random.randint, see here
- Parameters:
W ((N, N) array-like) – Undirected binary/weighted connection matrix
itr (int) – rewiring parameter. Each edge is rewired approximately itr times.
- Returns:
W ((N, N) array-like) – Randomized network
eff (int) – number of actual rewirings carried out