Learn R Programming

GADMTools (version 3.9-1)

gadm_remove: Remove one or more regions from a map

Description

Remove the polygons of one or more regions from a map.

Usage

gadm_remove(x, level=NULL, regions=NULL)

gadm.remove(x, level=NULL, regions=NULL) # deprecated

Arguments

x

Object gadm_sf or gadm_sp

level

Integer - level from which shapes are removed. If NULL, curent level is used.

regions

String - vector of regions to be removed

Value

Object - As input object, gadm_sf or gadm_sp.

See Also

listNames

Examples

Run this code
# NOT RUN {
library(GADMTools)
data("Corsica")

HCorse <- gadm_remove(Corsica, level=2, "Corse-du-Sud")
plotmap(HCorse)
# }

Run the code above in your browser using DataLab