Hi Smith, I presume you are talking about this
http://www.bostongis.com/PrinterFriendly.aspx?content_name=postgis_nearest_n eighbor_generic As far as optimal slices go, it depends how your data is sparsed out. Unfortunately it's a bit of trial and error that I hadn't fleshed out and benchmarked enough to see. So lets say you set your max distance to 10000 meters, you want most of your results to hit the first span out and subsequent span outs are to catch outliers. So if max distance is 10000 and you think 70% would be within 10000/10 (1000, then you would use 10 for slices). But then if your data is very sparse out you want your max distance to be much bigger and slices to be greater. There is one bug that I was meaning to fix in this, which I guess I should now since people are using this. It deals with largish objects that don't fit a span box and I also need to revise to use the new naming conventions since it was a while ago I wrote this. Anyrate as Mark mentioned, if you give a specific example, maybe I could be a bit more useful in my answer. Thanks, Regina -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Mark Cave-Ayland Sent: Tuesday, March 17, 2009 6:09 AM To: [email protected]; PostGIS Users Discussion Subject: Re: [postgis-users] optimum no of slices in pgis_fn_nn() ? Smith Roman wrote: > Hi Everyone, > > What is the optimum no to use in the function pgis_fn_nn() ? An example on how this function is used in practice will be appreciated. > > Thanks, > > Smith Hi Smith, I think you'll have to help us a bit. I can't see any function called pgis_fn_nn() in either 1.3 or trunk. ATB, Mark. -- Mark Cave-Ayland - Senior Technical Architect PostgreSQL - PostGIS Sirius Corporation plc - control through freedom http://www.siriusit.co.uk t: +44 870 608 0063 _______________________________________________ postgis-users mailing list [email protected] http://postgis.refractions.net/mailman/listinfo/postgis-users _______________________________________________ postgis-users mailing list [email protected] http://postgis.refractions.net/mailman/listinfo/postgis-users
