| assoc_gadm | R Documentation |
Intelligently bind together data with gadm IDs at all scales.
assoc_gadm(
df,
lonlat_names = c("Longitude", "Latitude"),
cache_location = NULL,
basereq = ad_basereq()
)
df |
the source data to bind gadm IDs to. This must contain decimal lonlat data! |
lonlat_names |
a vector containing the column names of the longitude and latitude columns IN THAT ORDER! |
cache_location |
path to cache location (defaults to a temporary user directory, or one set by |
basereq |
the url of the AREAdata database (usually generated by |
A matrix of the data with added gadm columns.
This will ALWAYS get and cache gid level 2 data sources. These files are about 80MB total, so if you are running on a metered connection do beware of this.
Francis Windram
vtdf <- search_hub("Aedes aegypti", "vt") |>
tail(20) |>
fetch() |>
glean(cols = c(
"DatasetID",
"Latitude",
"Longitude",
"Interactor1Genus",
"Interactor1Species"
), returnunique = TRUE) |>
assoc_gadm(lonlat_names = c("Longitude", "Latitude"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.