Py2neo graph traversals


(pckrt) #1

I have created a graph database. How can I perform graph traversals using py2neo? Can I apply traversal algorithms such as BFS and DFS in py2neo?
Also how can I write a cypher query which gives all the relationships and nodes existing between two nodes when two nodes are given as input. ex: a-r1>b-r2>c-r3>d...and if I give a and d as input nodes, I want the output as set of relations: r1,r2,r3 and set of nodes: b,c..
How can I write a cypher query for this?