I am trying to subset a igraph graph by an edge characteristics (like its label). In the reproducible example I have shamelessly stolen from another post with a little modif
how about:
gfam <- subgraph.edges(graph=g, eids=which(E(g)$label=="FAM"), delete.vertices = TRUE) gbf <- subgraph.edges(graph=g, eids=which(E(g)$label=="BF"), delete.vertices = TRUE)
Suggestion for igraph/network analysis tutorial/shameless plug: http://sna.stanford.edu/rlabs.php