strippedExists: Test if a stripped gadm_sp object exists

Description Usage Arguments Value Note Author(s) References See Also Examples

View source: R/33_stripSP.R

Description

Test if a stripped gadm_sp object exists on the file system in the directory 'basefile'

Usage

1
strippedExists(name, level, basefile = './')

Arguments

name

Character vector of a named region. An ISO-3166-1 code or a custom name. You don't have to specify the suffix (admX) nor the file extension (.rds).

level

Integer the level of the administrative boundaries (0 is the country, higher values equal finer divisions)

basefile

Character vector the path of the directory where shapefiles are stored. Default is "./"

Value

Boolean TRUE if the file exists, FALSE if not

Note

—-

Author(s)

Jean Pierre Decorps <jp.decorps@epiconcept.fr>

References

—-

See Also

—-

Examples

1
2
3
4
5
# library(GADMTools)
# library(sp)
# if (strippedExists('BEL', level = 2) {
#   BE <- gadm_loadStripped("BEL", level=2)
# }

GADMTools documentation built on Aug. 5, 2021, 1:06 a.m.