# add country coverage meta data to a datasetkey. useful for finding checklist country coverages
addCountryCoverage = function(.data,key) {
arguments = as.list(match.call())
keys = eval(arguments$key, .data)
countryCoverage = keys %>%
map(~
GET("https://www.gbif.org/api/dataset/" %+% .x) %>%
content() %>%
pluck("countryCoverage")
) %>%
map_if(is_empty, ~ NA_character_) %>%
flatten_chr()
d = data.frame(countryCoverage)
d = cbind(.data,d)
return(d)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.