networkx.algorithms.centrality.edge_load_centrality

edge_load_centrality(G, cutoff=False)[source]

Compute edge load.

WARNING: This concept of edge load has not been analysed or discussed outside of NetworkX that we know of. It is based loosely on load_centrality in the sense that it counts the number of shortest paths which cross each edge. This function is for demonstration and testing purposes.

Parameters
  • G (graph) – A networkx graph

  • cutoff (bool, optional (default=False)) – If specified, only consider paths of length <= cutoff.

Returns

  • A dict keyed by edge 2-tuple to the number of shortest paths

  • which use that edge. Where more than one path is shortest

  • the count is divided equally among paths.