> Is it possible to list all simple paths of length k between source and target 
> in igraph? networkx has a function 
> http://networkx.github.io/documentation/latest/_modules/networkx/algorithms/simple_paths.html#all_simple_paths
>  which might be a useful starting point but producing them all and filtering 
> by length seems very inefficient.
There is no such function but you can code it yourself quite easily. See this 
answer on Stack Overflow for a starting point (and also note my comment below 
it that tells you how to avoid constructing the adjacency list of the graph):

http://stackoverflow.com/a/3973287/156771

All that you need to ensure is that the function does not recurse into itself 
again if the incoming value of the `path` variable already contains four nodes. 
This is quite easy to ensure.

-- 
T.
_______________________________________________
igraph-help mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/igraph-help

Reply via email to