You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi!
I'd like to share some issues I have encountered when loading and operating with the level 2 polygons, with R. I'm not an expert on R or GIS, or anything, sorry if I ask silly questions.
Is there any issue with the projection of the polygons? I have downloaded the files from here, but when I load the polygons into R as simple features (sf::read_sf()), the polygons have no CRS. I have assigned the polygons the same CRS as the WorldClim v1.4 rasters: +proj=longlat +datum=WGS84 +no_defs.
The bounding box exceeds |180|: not a big deal, but might hint that something is off?
Issues when intersecting with points: I tried performing an intersection between the polygons and some coordinates (sf::st_intersection()), and got an error message:
Error in s2_geography_from_wkb(x, oriented = oriented, check = check) :
Evaluation error: Found 1 feature with invalid spherical geometry.
[1] Loop 222 is not valid: Edge 7469 has duplicate vertex with edge 7480.
Nevertheless, I could perform the intersection (and the result appear OK) after setting: sf::sf_use_s2(FALSE).
None of these are major problems, as I am able to perform the GIS opeartions I need. Some of these issues might be the result of inexperience and not issues per se, but I thought it best to share them than just ignoring them.
Thank you for your time! :)
Hi!
I'd like to share some issues I have encountered when loading and operating with the level 2 polygons, with R. I'm not an expert on R or GIS, or anything, sorry if I ask silly questions.
Is there any issue with the projection of the polygons? I have downloaded the files from here, but when I load the polygons into R as simple features (
sf::read_sf()
), the polygons have no CRS. I have assigned the polygons the same CRS as the WorldClim v1.4 rasters:+proj=longlat +datum=WGS84 +no_defs
.The bounding box exceeds |180|: not a big deal, but might hint that something is off?
sf::st_intersection()
), and got an error message:Nevertheless, I could perform the intersection (and the result appear OK) after setting:
sf::sf_use_s2(FALSE)
.None of these are major problems, as I am able to perform the GIS opeartions I need. Some of these issues might be the result of inexperience and not issues per se, but I thought it best to share them than just ignoring them.
Thank you for your time! :)
The text was updated successfully, but these errors were encountered: