Defined in File KatzIndex.hpp
public NetworKit::LinkPredictor
(Class LinkPredictor)
Implementation of the Katz index. Katz index assigns a pair of nodes a similarity score that is based on the sum of the weighted number of paths of length l where l is smaller than a given limit.
Public Functions
maxPathLength – Maximal length of the paths to consider
dampingValue – Used to exponentially damp every addend of the sum. Should be in (0, 1]
G – The graph to operate on
maxPathLength – Maximal length of the paths to consider
dampingValue – Used to exponentially damp every addend of the sum. Should be in (0, 1]
Executes the run-method on al given nodePairs and returns a vector of predictions. The result is a vector of pairs where the first element is the node-pair and it’s second element the corresponding score generated by the run-method. The method makes use of parallelization.
nodePairs – Node-pairs to run the predictor on
a vector of pairs containing the given node-pair as the first element and it’s corresponding score as the second element. The vector is sorted ascendingly by node-pair