Hi Cesar, > But, does this step ALSO remove THEIR CONNECTED VERTICES? No - quite unsurprisingly, delete.vertices() will delete only those vertices that you specify explicitly.
> If not, how can I achieve this? Use the ego() function to extract the list of vertices that are at most a given number of steps to a given seed vertex, followed by unlist() and unique(): vs <- c(1,2,3,4) unique(unlist(ego(g, 1, vs))) This gives you a numeric vector that contains the seed vertices (in vs) and all the vertices that are neighbors of at least one seed vertex. T. _______________________________________________ igraph-help mailing list [email protected] https://lists.nongnu.org/mailman/listinfo/igraph-help
