[postgis-users] ST_ClusterDBSCAN for "geography" data type?

Giuseppe Broccolo g.broccolo.7 at gmail.com
Mon Dec 21 03:15:06 PST 2020

Hi Marco,

Il giorno dom 20 dic 2020 alle ore 10:03 Marco Boeringa <
marco at boeringa.demon.nl> ha scritto:

> Hi,
> Reading through the PostGIS documentation, I noticed the
> "ST_ClusterDBSCAN" function takes a distance as one of the inputs. Now
> the docs suggest the current algorithm only takes in "geometry" type
> data. Is that true? Based on the distance input variable, it would seem
> logical to have a "geography" variant as well, even if that is a
> considerably slower variant considering the more complex distance
> calculation.

Yes, ST_ClusterDBSCAN takes just the geometry type in input. This is
because most of the algorithm
is implemented using utilities already existing in GEOS for planar

Adding the support for the geography type would mean to re-implement the
algorithm specifically for
spherical objects, as you mentioned.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20201221/f547fa8e/attachment.html>

More information about the postgis-users mailing list