Compute the degree centrality for nodes.
The degree centrality for a node v is the fraction of nodes it is connected to.
Parameters: | G : graph
v : node, optional
|
---|---|
Returns: | nodes : dictionary
|
Notes
The degree centrality is normalized to the maximum possible degree in the graph G. That is, G.degree(v)/(G.order()-1).