Skip to content
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

feat(frontend): aggregated risk map layer (risk hotspots) #39

Merged
merged 1 commit into from
Nov 5, 2024

Conversation

eatyourgreens
Copy link
Contributor

@eatyourgreens eatyourgreens commented Jun 13, 2024

New raster layer showing aggregated risk values for:

  • variables: "exposure value", "population affected", "loss GDP", "demand affected".

Includes:

  • New aggregated risk map layer and params in src/state/layers/modules/risks.
  • New config in src/config/risks. Parameters defined in src/config/risks/domains.
  • New sidebar controls in src/sidebar/risks.
  • New legends and tooltips in src/config/risks.
  • Makes a start on generic formats for data values eg. financial or population.
  • towards Add hotspots visualisation layer #8.

@eatyourgreens eatyourgreens force-pushed the hotspots-layer branch 14 times, most recently from d320042 to eaecf97 Compare June 18, 2024 14:47
Comment on lines 24 to 25
...HAZARD_DOMAINS,
...RISK_DOMAINS,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This overwrites hazard params, when RISK_DOMAINS keys are the same as HAZARD_DOMAINS keys.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For now, I've simplified RISKS_DOMAINS to a single risks parameter group.

@eatyourgreens eatyourgreens force-pushed the hotspots-layer branch 10 times, most recently from 838ddb4 to a217931 Compare June 19, 2024 15:17
@eatyourgreens eatyourgreens force-pushed the hotspots-layer branch 3 times, most recently from ea9c6ed to 9531af2 Compare August 13, 2024 16:02
@eatyourgreens eatyourgreens force-pushed the hotspots-layer branch 2 times, most recently from 4454c8f to e3867a3 Compare September 11, 2024 15:12
@eatyourgreens eatyourgreens force-pushed the hotspots-layer branch 10 times, most recently from 21b8a08 to 7d032b7 Compare September 18, 2024 12:36
@eatyourgreens eatyourgreens force-pushed the hotspots-layer branch 2 times, most recently from 8b39970 to da7b617 Compare October 10, 2024 14:38
@eatyourgreens
Copy link
Contributor Author

With the new code here, to format map values with units, the tooltip popups look good but the values in the map legend still need to be updated. Currently, legend units can be either omitted or duplicated.

A map legend and popup. The popup has the correct units for values, but the legend is missing a unit for GDP, and duplicates the $ symbol for damages.

@eatyourgreens eatyourgreens force-pushed the hotspots-layer branch 2 times, most recently from 36a1f36 to 5d36ecb Compare November 5, 2024 10:40
@eatyourgreens
Copy link
Contributor Author

Map legend units are fixed.

A map legend and popup. Both the popup and legend now agree on units for GDP and damages.

@eatyourgreens eatyourgreens marked this pull request as ready for review November 5, 2024 10:53
New raster layer showing aggregated risk values for:
- variables: "exposure value", "population affected", "loss GDP", "demand affected".
- hazards: "none", cyclone, "all flooding".

Includes:
- New aggregated risk map layer and params in `src/state/layers/modules/risks`.
- New config in `src/config/risks`. Parameters defined in `src/config/risks/domains`.
- New sidebar controls in `src/sidebar/risks`.
- New legends and tooltips in `src/config/risks`.
- Makes a start on generic formats for data values eg. financial or population.
@eatyourgreens eatyourgreens merged commit 06cba8a into main Nov 5, 2024
2 checks passed
@eatyourgreens eatyourgreens deleted the hotspots-layer branch November 5, 2024 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant