# Adjacency matrix for undirected network with 3 nodes
A <- matrix(c(0, 1, 2,
1, 2, 1,
2, 1, 2), nrow=3, ncol=3)
# If A represents a graph
get_degree_seq(adj = A, type = 'graph')
# If A represents a multigraph
get_degree_seq(adj = A, type = 'multigraph')
Run the code above in your browser using DataLab