# Degree

Returns the degree of each node.

The *degree* of a node in an undirected networks counts the number of neighbours that node has. Its *weighted degree* counts the number of interactions each node has. Finally the *edge weight* counts the number of interactions which have happened across an edge.

For example, in the graph above with all edges aggregated between time $t_1$ and $t_3$, node $A$ has degree 2 (having neighbours $B$ and $C$) but weighted degree 3 (from the interactions at times $t_1$, $t_2$ and $t_3$). In the same way, edge $AB$ has weight 2.

## Implementation

- For each node, gets the indegree and outdegree

## Parameter

`path`

*(String)*: The path where the output will be written

## Returns

`ID`

*(Long)*: Vertex ID`indegree`

*(Long)*: The indegree of the node`outdegree`

*(Long)*: The outdegree of the node`total degree`

*(Long)*: The total degree