get_edges function

Extract an adjacency matrix from a larger data frame