edm_nearest calculates the shortest euclidean distance found for
every point of one matrix among those of a second. In other words, if
m1, m2 have
n rows, the result will be the shortest distance
for the first point of
m1 to any point of
m2 and so on,
n times. This function is used internally but may be of interest for
So far this function is quite time consumming since it performs n \times n euclidean distance computation. If one wishes to align two (or more shapes) Procrustes surimposition may provide a better solution.
TRUE, returns a
list with two
d which is for every point of
m1 the shortest
distance found between it and any point in
m2) row indices of these points. Otherwise returns
d as a
numeric vector of the shortest distances.
ed, edm, dist.
1 2 3