WeightedDegree(weightProperty: String = "weight")

compute the weighted degree (i.e. strength)

This algorithm returns the weighted degree (i.e., strength) of a node, defined by the weighted sum of incoming, outgoing or total edges to that node. If an edge has a numerical weight property, the name of this property can be specified as a parameter – default is “weight”. In this case, the sum of edge weights for respectively incoming and outgoing edges respectively is returned, as well as the total of these. Otherwise, the number of incoming and outgoing edges (including multiple edges between the same node pairs) is returned, as well as the sum of these.


weightProperty: String = "weight"

the property (if any) containing a numerical weight value for each edge, defaults to “weight”.


inWeight: Double

Sum of weighted incoming edges

outWeight: Double

Sum of weighted outgoing edges

totWeight: Double

Sum of the above


vertex name

total incoming weight

total outgoing weight

total weight

name: String

inWeight: Double

outWeight: Double

totWeight: Double

See also