cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

How turn this into a "CALL gds.pagerank.stream(...)"sentences?

:param label => ('Person');
:param relationshipType => ('HAS_EMAILED');
:param limit => ( 100);
:param config => ({concurrency: 8, direction: 'Outgoing', weightProperty: null, defaultValue: 1, dampingFactor: 0.85, iterations: 25, writeProperty: 'pagerank'});

//then we calculate pagerank with one simple command
CALL algo.pageRank($label, $relationshipType, $config);

Source:https://blog.bruggen.com/2019/12/part-23-revisiting-hillary-clintons.html

How turn this into a "CALL gds.pagerank.stream(...)"sentences?

1 REPLY 1

My solutions

:param label => ('Person'); :param relationshipType => ('HAS_EMAILED'); :param limit => ( 100); :param config => ({concurrency: 8, direction: 'Outgoing', weightProperty: null, defaultValue: 1, dampingFactor: 0.85, iterations: 25, writeProperty: 'pagerank'});

CALL gds.graph.create(
    'myGraph332',
    'Person',    { HAS_EMAILED:{orientation:'UNDIRECTED'}    })

Then

CALL gds.pageRank.stream('myGraph332')

YIELD nodeId, score

RETURN gds.util.asNode(nodeId).alias AS alias, score

ORDER BY score DESC, alias ASC
Nodes 2022
Nodes
NODES 2022, Neo4j Online Education Summit

All the sessions of the conference are now available online