Open ColinFay opened 6 years ago
The tidygraph package uses igraph on the backend and represents graph data as a node dataframe and an edge dataframe. It should be relatively easy to translate those to cypher statements. As I recall, using neo4j you create links and nodes seperately from each other.
This is a neat idea @RMHogervorst.
I've been working a neo4j -> igraph -> ggraph workflow for now, but it seems pretty interesting to implement the other way around : from tidygraph to cypher.
This would basically mean working on a way to translate the two tidy-graph dataframe into cypher. I've already worked on a dataframe to cypher-nodes example here, so this might be pretty straightforward for the node part.
I've struggled a little bit with the dataframe to cypher-relationship (as I first have to set a bunch of rules for what makes a "cypherizable" relationship dataframe), but I guess if we go for a "tidy graph first" approach, this would alleviate from a lot of complexity on this point.
Thanks for sharing this !
Feel free to leave any comment or question you might have here.