rgbif occ_download argument "establishmentMeans"

Tags: #<Tag:0x00007f0e9d155600> #<Tag:0x00007f0e9d1554e8>


Using the API to search occurrences.

According to GitHub post GBIF API feature: faceted search #215, establishmentMeans is included as an argument. However, it’s not included in the package pdf.

Here’s a simple example:

“taxonKey” = 2685383,
pred(“establishmentMeans”, “NATIVE”),

Where I’m getting this error:

Error: ‘key’ not in acceptable set of keys; see ?occ_download

Any insight would be greatly appreciated! Thank you!

1 Like

Thanks for your question @rkirsten

You’re right establishmentMeans is not supported but should be. I’ve just added it. Restart R, reinstall remotes::install_github("ropensci/rgbif"), and try again:

  pred("taxonKey", 2685383),
  pred("establishmentMeans", "NATIVE")

An unrelated thing to your question: recent versions of the package require that all queries in occ_download() be within pred calls. So “taxonKey” = 2685383 should instead be pred("taxonKey", 2685383)


@sckott Thanks! Worked like a charm. And yes, pred always.

great, glad it worked