weight (None or string, optional (default=None)) – If None, all edge weights are considered equal.
Otherwise holds the name of the edge attribute used as weight.
sources (None or nodes list, optional (default=None)) – If None, all nodes are considered.
Otherwise,the set of source vertices to consider when calculating shortest paths.
normalized (bool, optional) – If True the betweenness values are normalized by 2/((n-1)(n-2))
for graphs, and 1/((n-1)(n-2)) for directed graphs where n
is the number of nodes in G.
endpoints (bool, optional) – If True include the endpoints in the shortest basic counts.
Returns:
nodes (dictionary) – Dictionary of nodes with betweenness centrality as the value.
Notice that the closeness distance function computes the
outcoming distance to u for directed graphs. To use
incoming distance, act on G.reverse().
Parameters:
G (graph) – A easygraph graph
weight (None or string, optional (default=None)) – If None, all edge weights are considered equal.
Otherwise holds the name of the edge attribute used as weight.
sources (None or nodes list, optional (default=None)) – If None, all nodes are returned
Otherwise,the set of source vertices to creturn.
Returns:
nodes – Dictionary of nodes with closeness centrality as the value.
ego networks are networks consisting of a single actor (ego) together with the actors they are connected to (alters) and all the links among those alters.[1]
Burt (1992), in his book Structural Holes, provides ample evidence that having high betweenness centrality, which is highly correlated with having many structural holes, can bring benefits to ego.[1]
Returns the betweenness centrality of a ego network whose ego is set
Parameters:
G (graph)
node (int)
Returns:
sum – the betweenness centrality of a ego network whose ego is set