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

ISO codes missing for France and Norway #77

Closed
eteitelbaum opened this issue May 7, 2023 · 1 comment
Closed

ISO codes missing for France and Norway #77

eteitelbaum opened this issue May 7, 2023 · 1 comment

Comments

@eteitelbaum
Copy link

eteitelbaum commented May 7, 2023

Earlier it was noted that France was missing from rnaturalearth.

Now, France is there, but its iso_a2 and iso_a3 codes are missing.

library(dplyr)
library(rnaturalearth)

ne_countries(scale = "medium", returnclass = "sf") |>
  filter(name == "France") |>
  select(iso_a2, iso_a3)

This is a known issue that has been flagged on the natural earth github repo, but is probably worth noting here in case people have issues merging data in based on these ISO codes. Personally, I have had some embarrassing experiences presenting maps in class with a missing France. "Uh...uhh...Where's France you ask? Must of, uh...sunk into the Atlantic?"

One solution is to be merge based on iso_a3_eh, which is available. But I am not sure what "eh" stands for and could not find it in the documentation. This makes it harder to use in a classroom setting.

ALL of the ISO codes appear to be missing for Norway including iso_a2, iso_a3, iso_a3_eh, iso_n3, un_a3, wb_a2 and wb_a3.

ne_countries(scale = "medium", returnclass = "sf") |>
  filter(name == "Norway") |>
  select(iso_a2, iso_a3, iso_a3_eh, iso_n3, un_a3, wb_a2, wb_a3)

Thus Norway always ends up getting greyed out in any global choropleth maps I am making (unless of course I manually code in the missing ISO code).

There is a note about missing iso_a2 codes for Norway on the Natural Earth github repo. But I couldn't find an explanation for the other missing codes.

Thanks.

@eteitelbaum
Copy link
Author

Seems like this issue has been fixed. Thanks.

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

No branches or pull requests

1 participant