FUNCTION REFERENCE
dsearchn
Nearest data point to each query point.
Nearest data point to each query point.
Syntax
k = dsearchn(X, XI)Syntax
[k, d] = dsearchn(X, T, XI)Syntax
k = dsearchn(X, T, XI, outval)k holds the row of X nearest to each row of XI and d the distance. With a triangulation T and outval, query points outside the triangulation get outval.
Example
dsearchn([0 0; 1 0; 0 1], [0.9 0.2]) % 2Differences from MATLAB: Exact ties go to the first point without a triangulation and to the last with one, matching MATLAB.
These are the engine’s help pages. Each page keeps its compatibility notes. File operations are unavailable in the browser.