On Thu, May 15, 2008 at 11:14 AM, Tamas Nepusz <
address@hidden> wrote:
Dear Alisa,
If you can afford calculating all shortest paths in your network, then try get.all.shortest.paths:
get.all.shortest.paths(graph, from, to = V(graph), mode = c("all", "out", "in"))
For get.all.shortest.paths a list is returned, each list element contains a shortest path from from to a vertex in to. The shortest paths to the same vertex are collected into consecutive elements of the list.
get.all.shortest.paths applies only for a single vertex, but of course you can run it for all vertices in a for loop. Of course you'll have to filter the list returned from get.all.shortest.paths based on their length.
--
Tamas
_______________________________________________
igraph-help mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/igraph-help