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

Add basic population layer from popgetter #10

Merged
merged 5 commits into from
Aug 16, 2024
Merged

Add basic population layer from popgetter #10

merged 5 commits into from
Aug 16, 2024

Conversation

dabreegster
Copy link
Contributor

#6

I've used https://github.com/Urban-Analytics-Technology-Platform/popgetter to generate a flatgeobuf file with total population count in 3 countries, and am starting to import/display it here. Try https://a-b-street.github.io/15m/ anywhere in England, USA, or Belgium, and use the top-right control:
image

Next steps are improving this display (coloring by population density) and incorporating in all of the tools. When there's an isochrone around a point or a network buffer around a route, intersect it with the census polygons and sum up population totals.

Right now it's just showing a total population count, but there's endless questions somebody might want to ask. Maybe there could be more direct integration with popgetter to show any metric, or maybe they should still be curated based on specific use cases.

CC @michaelkirk -- full circle, the fgb US census layer in A/B Street makes a reappearance :)

# You need to build https://github.com/Urban-Analytics-Technology-Platform/popgetter-cli
POPGETTER=/home/dabreegster/Downloads/popgetter-cli/target/release/popgetter

# The metrics and coordinate systems were figured out manually. In the future,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I wound up doing very ad-hoc things to figure out the most recent and granular "total population" metric (and am probably wrong for the US): googling, navigating the UK census page, opening the metrics parquet file and manually searching, etc

Choose a reason for hiding this comment

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

This is really helpful to hear the search process you went through, thank you!

Adding some info here for context, for each country in popgetter currently there are:

  1. Original census metrics: these are identical to their original source but may have required a transformation (e.g. pivoting) so the GEO_ID was the sole "index" for rows with any other column features concatenated into single metric columns (e.g. for NI)
  2. Derived metrics: where the derivation is specified through a transformation of the original (e.g. for NI)

I think the derived metrics in case 2) need to be more easily discoverable so readily accessible for common use cases (such as "Total individuals" here). The ones transformed in 1) should also be made more easy to find using e.g. the original census table name/metric name, the variables that were in the original metric/table, etc.

I'll add the option of listing only the "derived metrics" from the CLI to the ideas issue (Urban-Analytics-Technology-Platform/popgetter#81) while enabling metrics of type 1) to be discoverable at least requires adding some data currently missing for source_metric_id (https://github.com/Urban-Analytics-Technology-Platform/popgetter/issues/149)

mapshaper england_raw.geojson \
-rename-fields population='Residence type: Total; measures: Value' \
-each 'delete GEO_ID' \
-proj init=EPSG:27700 crs=wgs84 \
Copy link
Contributor Author

Choose a reason for hiding this comment

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

It'd be useful to have a column in the geometry parquet file with this. I found https://github.com/Urban-Analytics-Technology-Platform/popgetter-cli/blob/c4da85910e317b654ac4c5aa9a6de09abb985e1f/src/cli.rs#L61 as the only reference right now

Choose a reason for hiding this comment

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

Yes, thanks for mentioning, there is an issue https://github.com/Urban-Analytics-Technology-Platform/popgetter/issues/142 discussing this further and I've added it to the list of potential changes https://github.com/Urban-Analytics-Technology-Platform/popgetter/issues/149

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.

2 participants