Skip to content
This repository has been archived by the owner on Mar 3, 2023. It is now read-only.

Missing IDs for several features #23

Closed
curran opened this issue Sep 26, 2018 · 11 comments
Closed

Missing IDs for several features #23

curran opened this issue Sep 26, 2018 · 11 comments

Comments

@curran
Copy link

curran commented Sep 26, 2018

Greetings,

I noticed there are several instances where the id is -99, and wanted to share this visualization of missing IDs.

image

Perhaps it's a problem with the upstream data in Natural Earth, but nonetheless it's surprising that the UAE has this value as its ID.

The Natural Earth Changelog indicates the latest release was 2018-05-21.

Maybe a fresh run of npm version patch and npm publish would fix the issue? I see the world-atlas package has not seen a fresh release for some time now.

Many thanks.

@curran
Copy link
Author

curran commented Sep 26, 2018

Related #25

@curran
Copy link
Author

curran commented Sep 26, 2018

It appears these have been solved in https://github.com/fil/visionscarto-world-atlas by @Fil

@mbostock
Copy link
Member

In general, I don’t have the bandwidth to maintain manual patches to the Natural Earth Data. But it does seem pretty egregious that Norway’s country code is missing. Here’s my own visualization as of Natural Earth Data version 4.1.0 (world-atlas 2.0.0)

map (4)

Let me take a look at some patches…

@mbostock
Copy link
Member

mbostock commented Aug 31, 2019

The features with missing identifiers are:

  • Somaliland - no defined ISO-3166-1 code (numeric or alpha)
  • Norway - 578
  • Kosovo - no defined ISO-3166-1 code (numeric or alpha)
  • Northern Cyprus - no defined ISO-3166-1 code (numeric or alpha)
  • Indian Ocean Ter. - unsure (separate from British Indian Ocean Territory)
  • Siachen Glacier - unsure

The name property was added in world-atlas 2.0.0, so that can be used as a fallback to identify countries with no ISO-3166-1 numeric code.

I will patch Norway in 2.0.1.

@mbostock
Copy link
Member

Fixed Norway in 2.0.1. I don’t know what to do for the other cases. Related #19 we could include the ISO alpha codes, but that would not help in this case.

@Fil
Copy link

Fil commented Sep 1, 2019

In https://github.com/nvkelso/natural-earth-vector/blob/master/50m_cultural/ne_50m_admin_0_countries.dbf some codes are used:

  • KAS (for Kashmir / Siachen)
  • KOS (Kosovo)
  • CYN (N. Cyprus)
  • SOL (Somaliland)
  • IOA (Indian Ocean Territory)

I've extracted the lines for convenience:
https://gist.github.com/Fil/401928df84ef0a16346ddfc37fd739dd

@mbostock
Copy link
Member

mbostock commented Sep 1, 2019

@Fil Yes, but those aren’t the ISO-3166-1 numeric codes, which we’re using as identifiers here. And they aren’t the ISO alpha codes either; I believe they’re essentially made-up by Natural Earth Data with no standardized meaning.

@Fil
Copy link

Fil commented Sep 1, 2019 via email

@mbostock
Copy link
Member

mbostock commented Sep 1, 2019

But unless your data happens to use Natural Earth Data’s identifiers (and I haven’t seen any examples of this in public datasets), you’re going to have to map the data manually anyway. In this recent world choropleth for example, the WHO keys the data by name. Many of these names match the Natural Earth Data, but about 30 of them I had to map manually due to discrepancies in naming.

https://observablehq.com/@d3/world-choropleth

@Fil
Copy link

Fil commented Sep 1, 2019 via email

@mbostock
Copy link
Member

mbostock commented Sep 1, 2019

That‘s fair, but I still don’t think it makes sense for Natural Earth Data’s SOV_A3 to be the primary identifier, since it is just a convention used by Natural Earth Data and not a standard (as I understand it from this comment: “The following 4 columns are unique to the Natural Earth administrative-0 coding system, but somewhat follow the ISO 3 digit alpha codes”). #19 discusses adding additional identifiers as properties.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants