You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -72,18 +72,20 @@ A kNN search finds the `k` nearest neighbors to a given point or points. This is
72
72
```julia
73
73
knn(tree, point[s], k [, skip=Returns(false)]) -> idxs, dists
74
74
knn!(idxs, dists, tree, point, k [, skip=Returns(false)])
75
+
allknn(tree, k [, skip=Returns(false)]) -> idxs, dists
75
76
```
76
77
77
78
*`tree`: The tree instance.
78
79
*`point[s]`: A vector or matrix of points to find the `k` nearest neighbors for. A vector of numbers represents a single point; a matrix means the `k` nearest neighbors for each point (column) will be computed. `points` can also be a vector of vectors.
79
80
*`k`: Number of nearest neighbors to find.
80
81
*`skip` (optional): A predicate function to skip certain points, e.g., points already visited.
81
-
82
+
*`allknn`: Finds the `k` nearest neighbors for every point stored in the tree itself, automatically excluding the point being queried.
82
83
83
84
For the single closest neighbor, you can use `nn`:
0 commit comments