R/which_uy.R
which_uy.Rd
This function allows to add to an 'sf' object its spatial coincidence with one or more administrative units in Uruguay, generating the corresponding variables.
An 'sf' object with the same crs as the homonym parameter
Define the geometries to download: may be: "Departamentos", "Secciones", "Zonas", etc. View(metadata) for details.
A vector who determines the variables to be added, with three options: "cod", "name", or "full". Default c("cod", "name").
sf object with the x geometries, with d variables requested from c added
Other service:
add_geom()
,
geocode_ide_uy()
,
load_geouy()
,
reverse_ide_uy()
,
tiles_geouy()
,
where_uy()
# \donttest{
x <- load_geouy("Peajes")
#> Reading layer `peajes' from data source
#> `https://geoservicios.mtop.gub.uy/geoserver/inf_tte_ttelog_terrestre/peajes/ows?service=WFS&request=GetFeature&typeName=peajes'
#> using driver `GML'
#> Simple feature collection with 18 features and 4 fields
#> Geometry type: MULTIPOINT
#> Dimension: XY
#> Bounding box: xmin: -58.24649 ymin: -34.78446 xmax: -54.42373 ymax: -31.54664
#> Geodetic CRS: WGS 84
x1 <- which_uy(x, c = "Deptos")
#> Reading layer `ine_depto' from data source
#> `C:\Users\Usuario\AppData\Local\Temp\RtmponKV2U\ine_depto.shp'
#> using driver `ESRI Shapefile'
#> Simple feature collection with 20 features and 6 fields
#> Geometry type: MULTIPOLYGON
#> Dimension: XY
#> Bounding box: xmin: 366582.2 ymin: 6127919 xmax: 858252.1 ymax: 6671738
#> Projected CRS: WGS 84 / UTM zone 21S
# }