unicef / magicbox-maps

Map mobility data in a NodeJS + React front-end application with data served by magicbox-open-api
http://magicbox-maps.azurewebsites.net
BSD 3-Clause "New" or "Revised" License
11 stars 11 forks source link

Add linear interpolation function to aggregate indexes #82

Closed carloscdias closed 6 years ago

carloscdias commented 6 years ago

Summary

This PR adds a linear interpolation function that allows a value in the range [0, 1] to be mapped to a color [lowerColor, higherColor] respectively. Thus, allowing multiple colors (right now, only 2) to be used while aggregating indexes, also setting the general layer opacity to 0.5, allowing the user to read the region's name independently of the aggregation value.

Images are shown as example, not representing the current values set for colors.

screenshot from 2018-04-04 15-34-46 screenshot from 2018-04-04 15-35-29 screenshot from 2018-04-04 15-36-35

mikefab commented 6 years ago

AwesooOOOoOOoome

mikefab commented 6 years ago

AwesoOOooOooommee