Hi All,

I've been looking through the GeoTools documentation and search, but
haven't been able to find much on a k-NearestNeighbor algorithm.  I'm
really hoping someone can point me in the right direction.

What I need to do is find the k nearest features in a feature collection to
a point.  For instance, find the 5 closest features in a shapefile to a
single point.  Even better would be a way to find the 5 closest features in
a shapefile to each point in a different shapefile.  Is there anything in
GeoTools that can help do this?  It would need to work Point-Point,
Point-Line, and Point-Polygon.  I'm hoping there is something already and
that it leverages a spatial index to make the query faster since I have to
run this operation a large number of times.

Thanks very much for you help!  Hope all is well.

Cheers,
Brett

Sorry if this got posted twice



*Brett Antonides*
703-673-9526 ext 760 <http://www.lmnsolutions.com/>
------------------------------------------------------------------------------
Want fast and easy access to all the code in your enterprise? Index and
search up to 200,000 lines of code with a free copy of Black Duck
Code Sight - the same software that powers the world's largest code
search on Ohloh, the Black Duck Open Hub! Try it now.
http://p.sf.net/sfu/bds
_______________________________________________
GeoTools-GT2-Users mailing list
GeoTools-GT2-Users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to