TSTOOL home page | TSTOOL documentation page | TSTOOL installation page | TSTOOL link page |
nn_search does exact or approximate k-nearest neighbor queries to one or more query points. These query points can be given explicitly or taken from the data set of points (see below).
Before one can use nn_search, one has to call nn_prepare to compute the preprocessing information. However, as long as the input point set isn't modified, the preprocessing information is valid and can be re-used for multiple calls to nn_search or range_search.
Syntax:
[index, distance] = nn_search(pointset, atria, query_points, k)
[index, distance] = nn_search(pointset, atria, query_points, k, epsilon)
[index, distance] = nn_search(pointset, atria, query_indices, k, exclude)
[index, distance] = nn_search(pointset, atria, query_indices, k, exclude, epsilon)
Input arguments:
Output arguments: