if (FALSE) {
# Get a single layer
agol_filter(
url = "https://hydro.nationalmap.gov/arcgis/rest/services/NHDPlus_HR/MapServer/",
layer_name = "WBDHU12",
geom = FedData::meve
)
# Can be returned as a list
agol_filter(
url = "https://hydro.nationalmap.gov/arcgis/rest/services/NHDPlus_HR/MapServer/",
layer_name = "WBDHU12",
geom = FedData::meve,
simplify = FALSE
)
# Get a list with all layers
agol_filter(
url = "https://hydro.nationalmap.gov/arcgis/rest/services/NHDPlus_HR/MapServer/",
geom = FedData::meve
)
# Or include a vector of layer names
# Note that missing layers are returned as `NULL` values
agol_filter(
url = "https://hydro.nationalmap.gov/arcgis/rest/services/NHDPlus_HR/MapServer/",
layer_name = c(
"NHDPoint",
"NetworkNHDFlowline",
"NonNetworkNHDFlowline",
"NHDLine",
"NHDArea",
"NHDWaterbody"
),
geom = FedData::meve
)
}
Run the code above in your browser using DataLab