Betweenness is a medial measure of the structural importance of nodes in a network. It assigns higher values to those nodes that are in a position to control the indirect linkages of others.
For each pair of nodes and , the dependency on a particular node is defined as the fraction all shortest -paths that contain as an inner node. The betweenness score of is the sum over all pair-dependencies,
where is the number of shortest path between and , and the number of those containing as an inner node. That is, under the assumption that information, traffic, resources, trust, etc. spread along shortest paths only, nodes are ranked according to the amount of information, traffic etc. that passes by them. In link-valued graphs, the notion of a shortest path depends on the interpretation of those values. For instance, the attribute might represent a length, and a the length of a path is the sum over the lengths of its links.