link.neighbor Function (GPL)
Syntax
link.neighbor(<algebra>, neighborCount(<integer>))
or
link.neighbor(<binning function>, neighborCount(<integer>))
or
link.neighbor(<statistic function>, neighborCount(<integer>))
<algebra>. Graph algebra, such as x*y.
Refer to Brief Overview of GPL Algebra for an introduction to graph algebra.
<integer>. An integer defining the number of neighboring values to connect to a value.
<binning function>. A binning function.
<statistic function>. Another statistic function.
The result of the embedded statistic is used to calculate link.neighbor.
Description
Calculates the nearest neighbor graph for the values. This function is typically used with the edge graphic element. The nearest neighbor graph connects a value p to the specified number of values with the shortest distance to p.
Examples
ELEMENT: edge(position(link.neighbor(x*y, neighborCount(3))))
Statistic Functions
See GPL Functions .