geo spatial clustering based on another feature


I have data about houses for sale, that I present over a map.

Each house has coordinates ([lat,lng]) and other features. The data is only for one country, so no need to address the 180deg world wrap.

I want to cluster neighbourhoods, out of those houses, and base the the neighbourhood borders on prices (sqm price).

It's really easy to see those clusters when I paint the houses with gradient color - from cheap to expensive, but I can't find a trivial way to do it mathematically.

Basically, what I want is price clustering, but with a limitation on the clustering algorithm so there won't be any geo-location overlap.

Another way to look at it - I want to blur the data points and create low-resolution areas.

Not sure where to go with this, any help will be appreciated.


Posted 2019-07-21T10:53:34.577

Reputation: 101



There are many such approaches, for example spatial autocorrelation, Lisa, etc.

In the clustering domain, GDBSCAN is a generalization of DBSCAN where you could easily define neighbors as points being within a certain distance and having a similar price.

Nevertheless it is probably a good idea to look into actual geostatistics and beyond the limitations of sklearn.

Has QUIT--Anony-Mousse

Posted 2019-07-21T10:53:34.577

Reputation: 7 331

Thanks. I will try it out. can GDBSCAN guarantee that there won't be a geo overlap between clusters or just limit the geo distance? I'm not bound at all to sklearn, can you recommend any geostatistics tools? – yonatanmn – 2019-07-23T07:38:17.963

Depending how you set things up with your definitions, they may overlap. – Has QUIT--Anony-Mousse – 2019-07-23T20:18:17.210