-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Create integration of demographic data sets as Choropleth layers #12
Comments
See good (if slightly more full featured that we would aim for) example here: http://climate.globalforestwatch.org/map/3/15.00/27.00/ALL/dark/biomass_loss?begin=2001-11-10&end=2015-01-01&threshold=30 with code deposited here: or this one, with code here: https://github.com/Vizzuality/gfw-climate |
progress |
So here's what needs to be done, I think: (1) Calculate bounding box for current leaflet map instance displayed onscreen using (1b) Set variables to pass to postgis query based on above bounds (?) (1c) Set max/min zoom to prevent map from loading too much data at high zoom levels. Basically, > zoom level 4 we should not display any data; between zoom levels 4-8 display a simplified set of polygons ...there are UX considerations here as zoom level will impact the size of data in the query. Options: we could (i) auto-set zoom to minimum if user clicks on an analysis layer or (ii) display light-touch error message to warn them that polygons won't display until zoom level is close enough or (iii) simplify geometries for high zoom levels (see here http://strk.kbt.io/blog/2013/03/08/on-the-fly-simplification-of-topologically-defined-geometries/) or (iv) use alternative data set for high zoom levels. (2) Query 'demographics' PostGIS database for any objects inside/intersected by this bounding box, something like this I think:
see here: https://gis.stackexchange.com/questions/25797/select-bounding-box-using-postgis?rq=1 (3) Display these objects as polygons in a new layer on the leaflet map An alternative for (1-2) would be to pre-cache all the images using a tileserver like mapnik. I'm pretty sure what these guys here are doing: http://simd.scot/2016/#/simd2016. I think this option may be overly server-heavy and not the most programmatically elegant solution... |
Just checked DVF library works on its own with the map but struggles with the marker cluster need to look into this more would it be an option to have a separate map with these layers? |
I'm thinking here of the 2011 UK Census, Scottish Index of Multiple Deprivation, and UR 6 fold scale. Once these are integrated then we can start to fill in data in the pane/D3 viz.
The text was updated successfully, but these errors were encountered: