prioritizr / wdpar

Interface to the World Database on Protected Areas
https://prioritizr.github.io/wdpar
GNU General Public License v3.0
39 stars 5 forks source link

How to get and clean a global PA list? #12

Closed carbonmetrics closed 5 years ago

carbonmetrics commented 5 years ago

First, thank you for making this package available.

I am trying to download and clean a global PA data set. Following the fetch_wdpa documentation I arrive at 22 M km2 terrestrial PA, whereas I expected (through the protectedplanet summaries) to get 20.2 M km2. I think this is because I cleaned data and have not solved overlaps through a sf operation yet.

I have not been able to do this because wdpa_clean cannot allocate enough memory.

Is there a way to loop through the database continent-wise, or otherwise just get a cleaned up dataset?

jeffreyhanson commented 5 years ago

Hi,

Yeah, the raw WDPA data needs to be cleaned before you can obtain accurate protected area coverage statistics. Yeah, there's a lot of spatial overlaps in the WDPA dataset, so if you haven't erased the overlaps then the coverage statistics will be much higher than those reported on ProtectedPlanet.

Unfortunately, the wdpa_clean function just can't handle the global dataset. You could try looping through the dataset country-wise -- and this might work a bit faster if you manually fix the geometry issues using the repair geometry tool in ArcMap first (if you have access) -- but it will take a very long time unless you also use parallel processing with 20+ cores. You could also try using this software (https://github.com/jeffreyhanson/global-protected-areas) which does similar processing using Python + Arcpy + ArcMap, but it can be a bit annoying to set up. I'm sorry I don't have a more helpful answer.

jeffreyhanson commented 5 years ago

I'm going to close this issue because due to lack of activity. Please feel free to reopen it if you would like to discuss this more.