Notes

relTypes Parameter

All procedures that accept a relTypes parameter use comma-separated relationship type names. To traverse all relationship types, pass an empty string '' or omit the parameter where it is optional:

CALL algo.pagerank()               -- all types (parameter omitted)
CALL algo.wcc('')                  -- all types (empty string)
CALL algo.wcc('KNOWS,FOLLOWS')     -- only KNOWS and FOLLOWS edges

direction Parameter

Where supported, the direction parameter controls which edges are considered:

  • "OUT" — only outgoing edges from each vertex

  • "IN" — only incoming edges to each vertex

  • "BOTH" — edges in either direction (default for most algorithms)

Config Map Parameters

Several algorithms (PageRank, Louvain, Betweenness, LabelPropagation) accept an optional configuration map as their first argument:

CALL algo.pagerank({dampingFactor: 0.9, maxIterations: 50})
YIELD node, score

Memory Considerations

Algorithms marked CPU+RAM build in-memory data structures that scale with V² or E²:

Algorithm Memory Usage

algo.apsp

O(V²) distance matrix

algo.maxFlow

O(V²) capacity matrix

algo.kShortestPaths

O(V²) weight matrix

algo.simRank

O(V²) similarity matrix

algo.hierarchicalClustering

O(V²) similarity pairs

For graphs with more than a few thousand vertices, these algorithms may require significant heap space.