Learn R Programming

GADMTools (version 3.9-1)

gadm_crop: crop a region to a specific rectangle

Description

crop a region to a specific rectangle

Usage

gadm_crop(x, xmin, ymin, xmax, ymax)

Arguments

x

gadm_sp or gadm_sf Object containing regions.

xmin

numeric Longitude min

ymin

numeric Latitude min

xmax

numeric Longitude max

ymax

numeric Latitude max

Value

Object gadm_sf or gadm_sp

Examples

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

area <- gadm_crop(Corsica, xmin=9.3, ymin=42.96, xmax=9.566, ymax=43.02819)
plotmap(area)
# }

Run the code above in your browser using DataLab