onaio / gisida

JavaScript library that converts MapSpec layers to beautiful, interactive maps using Mapbox GL
http://gisida.onalabs.org/
Apache License 2.0
11 stars 3 forks source link

Heat map for Zimbabwe Idai recovery site #412

Closed akahure closed 4 years ago

akahure commented 4 years ago

On Zimbabwe recovery site, we would like to include a heat map that will be used to show concentration of sites as different colours based on floods damage and population density.

We would like to see it against population affected, with the latest population data against data from here https://data.humdata.org/dataset/highresolutionpopulationdensitymaps-zwe

The population should correlate to the damaged sites

This is tied to this issue:

cKellyDesign commented 4 years ago

@akahure Please specify which sites layers need heatmap layers.

cKellyDesign commented 4 years ago

This should be a matter of adding a heatmap type layer, which handles data very similarly to symbol layers. In this case we do not have scalable/categorical data on the severity of damage at each site, so these layers should simply show site density.

Given that both heatmap and raster layers are expected to be used at the same time, let's make sure each have partial opacity so we can more easily see the areas of overlap between the two layers.

cKellyDesign commented 4 years ago

As discussed with @ciremusyoka: When we have categorical data for heatmap layers (e.g. damage type is something like "collapsed" or "flooded") should be split into multiple heatmaps layers, one for each category.

The reason for this is because heatmaps are scalar visualizations (in both "density" and "color") which fluidly display a range of data (either by opacity or color) and do not visual categorical data very well. Instead we should should generate multiple heatmap layers with static colors and default density properties (which derive from point density).

Implementation Strategy

Ideally, the functionality to generate the Mapbox stylespec for heatmap layers (regardless of Gisida 1x vs Gisida Views), should: