Created
February 3, 2025 11:27
-
-
Save Taresin/fbda8c26e88d89d2e5312acd644f1c32 to your computer and use it in GitHub Desktop.
Calculating the betweenness centrality property of Sydney Trains nodes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CALL gds.graph.project.cypher( | |
'projection_trains', | |
'MATCH (s:Stop) RETURN id(s) AS id', | |
'MATCH (s:Stop)-[:NEXT_STOP]->(t:Stop) RETURN id(s) AS source, id(t) AS target, "NEXT_STOP" AS type' | |
); | |
CALL gds.betweenness.write('projection_trains', { | |
writeProperty: 'betweennessCentrality' | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment