Given a series of unique sequential nodes of certain types: LogIn->UpdateProfile
, LogIn->AddToCart->CheckOut
cypher example:
CREATE (e1:Event {type: 'LogIn', uuid: '...'}),
(e2:Event {type: 'UpdateProfile', uuid: '...'}),
(e3:Event {type: 'LogIn', uuid: '...'}),
(e4:Event {type: 'AddToCart', uuid: '...'}),
(e5:Event {type: 'CheckOut', uuid: '...'}),
(e1)-[:NEXT]->(e2)// e1 relates to e2
(e3)-[:NEXT]->(e4)
(e4)-[:NEXT]->(e5)// e3 relates to e4, and e4 to e5
How can I get a list of paths grouped by similar patterns and the number of times they appear.
Ex:
LogIn - UpdateProfile = 5 times
LogIn - AddToCart - CheckOut = 2 times
The :NEXT
relation represents the sequence and the type
property is the type of event.