Returns global composite files for the requested ADM level. Files are clipped to international boundaries, with gaps between borders filled.
Attribution is required whenever these data are used.
Usage
gb_get_world(
country = "all",
adm_lvl = "adm0",
quiet = TRUE,
overwrite = FALSE,
cache_dir = NULL
)Arguments
- country
A character vector of country names or ISO 3166-1 alpha-3 country codes. Use
"all"to return data for all countries. See alsocountrycode::countrycode().- adm_lvl
ADM level. Accepted values are levels 0, 1 and 2 (
"adm0"is the country boundary,"adm1"is the first level of subnational boundaries and"adm2"is the second level). Uppercase versions ("ADM1") and level numbers (0,1,2) are also accepted.- quiet
Logical. If
TRUE, suppress informational messages.- overwrite
Logical. If
TRUE, force a fresh download of the source.ziparchive.- cache_dir
A path to a cache directory. If not set (the default
NULL), the data will be stored in the default cache directory (seegb_set_cache_dir()). If no cache directory has been set, files are stored in a temporary cache directory. Seebase::tempdir()and the cache strategies ingb_set_cache_dir().
Value
An sf object containing the requested boundaries.
Details
Comprehensive Global Administrative Zones (CGAZ) are global composites for administrative boundaries. Compared with individual country files, the global composite files use extensive simplification so file sizes are small enough for most desktop software. They remove disputed areas, replace them with polygons following US Department of State definitions and fill gaps between borders.
References
Runfola et al. (2020) geoBoundaries: A global database of political administrative boundaries. PLOS ONE 15(4), e0231866. doi:10.1371/journal.pone.0231866 .
See also
API functions:
gb_get(),
gb_get_adm

