I have a graph in neo4j database. I want to extract a sub graph given a particular node and a particular depth.
I tried using the traversal framework, but it only returns a set of paths. It gives path up to a particular depth.
How can i construct a sub graph based on the set of paths that i get? Is there any other way to get the required result?
Asked
Active
Viewed 450 times
1

10land
- 195
- 7
-
1What do you mean exactly by "subgraph"? A list of nodes (and their relationships)? Which language/framework do you use? – Axel Morgner Mar 23 '13 at 21:29
1 Answers
1
In case that, by subgraph, you mean a list of nodes, and you've got the Path objects from the traversal already, you could just collect the end nodes of each path in a list.

Axel Morgner
- 2,292
- 16
- 15