# grinpy.functions.degree_sequence¶

grinpy.functions.degree_sequence(G)

Return the degree sequence of G.

The degree sequence of a graph is the sequence of degrees of the nodes in the graph.

G : graph
A NetworkX graph.
degSeq : list
The degree sequence of the graph.
>>> G = nx.path_graph(3) # Path on 3 nodes
>>> nx.degree_sequence(G)
[2, 1, 1]