![Distances between observations in two groups](https://blogs.sas.com/content/iml/files/2016/09/nearestgroup1.png)
Last week I showed how to find the nearest neighbors for a set of d-dimensional points. A SAS user wrote to ask whether something similar could be done when you have two distinct groups of points and you want to find the elements in the second group that are closest