ropensci / rnaturalearth

An R package to hold and facilitate interaction with natural earth map data :earth_africa:
http://ropensci.github.io/rnaturalearth/
Other
214 stars 24 forks source link

Switzerland map - typo on the postal field? #32

Closed RamiKrispin closed 1 year ago

RamiKrispin commented 4 years ago

Hi, I am trying to use the ne_states function to pull the Switzerland map information and to merge it with canton data I have. I am using the postal field and I think there is a typo with the value of Canton of Obwalden that should be OW as oppose of NW which represents Canton of Nidwalden:

rnaturalearth::ne_states(country = "Switzerland", returnclass = "sf") %>% 
  dplyr::filter(postal == "NW") %>% dplyr::select(postal,woe_label, woe_name, gn_a1_code)

Simple feature collection with 2 features and 4 fields
geometry type:  MULTIPOLYGON
dimension:      XY
bbox:           xmin: 8.0437264 ymin: 46.758774 xmax: 8.5632296 ymax: 47.011291
epsg (SRID):    4326
proj4string:    +proj=longlat +datum=WGS84 +no_defs
  postal                            woe_label  woe_name
1     NW Canton of Nidwalden, CH, Switzerland Nidwalden
2     NW  Canton of Obwalden, CH, Switzerland  Obwalden
  gn_a1_code                       geometry
1      CH.NW MULTIPOLYGON (((8.4651477 4...
2      CH.OW MULTIPOLYGON (((8.3681511 4... 

Thanks, Rami

PMassicotte commented 1 year ago

rnaturalearth only provides an interface to https://www.naturalearthdata.com/. We invite you to contact them if you find any data error (https://github.com/nvkelso/natural-earth-vector).