Skip to content

Instantly share code, notes, and snippets.

View nickeubank's full-sized avatar

Nick Eubank nickeubank

View GitHub Profile
@nickeubank
nickeubank / functions.R
Last active September 12, 2017 18:39
modifications to functions.R to get reciprocal graph
stripAttributes <- function(g) {
for (a in list.graph.attributes(g)) {
g <- delete_graph_attr(g, a)
}
for (a in list.edge.attributes(g)) {
g <- delete_edge_attr(g, a)
}
for (a in list.vertex.attributes(g)) {
if (a != "name") {
g <- delete_vertex_attr(g, a)