project-seldon / intake

Ideas, bug reports, questions and any other type of feedback.
https://projectseldon.org
1 stars 0 forks source link

Explore / Integrate regional "Demographics" population maps per country #33

Open skipjack opened 1 year ago

skipjack commented 1 year ago

So this would be a new visualization with "Demographics" and only on the country-specific pages. It would set us up for a third-level of "Explore" depth (right now we have "Worldwide" => "[Country]").

skipjack commented 1 year ago

We'll need two types of data to bring this to life...

JeydenP commented 1 year ago

Countries to focus on:

skipjack commented 1 year ago

Sources we're seeing for US Population data...

And regarding country subdivisions more broadly...

JeydenP commented 1 year ago

Sources that can be used for UK(Great Britain) population data...

skipjack commented 1 year ago

To start, since it looks like we'll need to do this on a per-country basis, we can use the enrichCountry methods in the [country_code]/index.js modules. So for the US that would be src/us/index.js. We'll break that up into multiple functions after you have it working and submit the PR.

skipjack commented 1 year ago

To store the data, for now something like this should work...

country.attributes.statistics[year].populationBySubdivision = {
  'US-NY': 2392302,
  // ...
}
skipjack commented 11 months ago

@JeydenP here's that package we were discussing...

Looks like that iso3166.subdivision("US", "Indiana") call would be the easiest based on our conversation.