@graphty/algorithms / index / PriorityDeltaPageRank
Class: PriorityDeltaPageRank ​
Defined in: indexed/delta-pagerank.ts:381
Delta PageRank processed one node at a time, largest pending delta first, keeping its state between calls. A node is queued at most once: a delta that reaches a queued node raises its key instead of adding a second entry, so a pop always carries the node's whole pending delta. maxIterations counts processed nodes; every 1000 of them the run stops if no pending delta reaches tolerance. At the end each pending delta of at least deltaThreshold is added to its score (and stays pending), and the scores are normalised.
The starting deltas are the teleport share, so the scores converge to pageRank's and no teleport is added at the end. A dangling node's mass is dropped rather than spread; since pageRank spreads it by the same uniform distribution as the teleport, normalising gives the same answer. A delta is split by arc weight when weighted is true, evenly otherwise.
Constructors ​
Constructor ​
new PriorityDeltaPageRank(
s,o?):PriorityDeltaPageRank
Defined in: indexed/delta-pagerank.ts:395
Start every node at score 0 with a pending delta of 1 / n, queued in index order.
Parameters ​
s ​
GraphSnapshot
A DIRECTED snapshot
o? ​
DeltaPageRankEngineOptions = {}
The per-arc weight override
Returns ​
PriorityDeltaPageRank
Methods ​
computeWithPriority() ​
computeWithPriority(
o?):F64
Defined in: indexed/delta-pagerank.ts:416
Process queued nodes, largest pending delta first.
Parameters ​
o? ​
DeltaPageRankComputeOptions = {}
Algorithm options; personalization is ignored
Returns ​
F64
A copy of the scores per node index