ala_fields: Retrieves a list of all field names that can be used with...

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/ala_fields.R

Description

Retrieves a list of all field names that can be used with data retrieval functions

Usage

1
2
3
ala_fields(fields_type = "occurrence", as_is = FALSE)

field_info(field_id, maxrows = 50, record_count_only = FALSE)

Arguments

fields_type

text: one of the following

  • "general" - for searching taxa, datasets, layers, and collections metadata

  • "occurrence" - for searching species occurrence records

  • "layers" - fields associated with the environmental and contextual layers. For additional information on layers, including metadata and licensing, see search_layers

  • "assertions" - potential issues flagged on one or more occurrence record fields

as_is

logical: if FALSE, apply ALA4R's renaming of fields for consistency across functions. If TRUE, leave the field names as they are returned from the ALA web service

field_id

text: id of environmental/contextual layer field for which to look up information Prepend "el" for "environmental" (gridded) layers and "cl" for "contextual" (polygonal) layers

maxrows

integer: maximum number of records to download. Some contextual layers (those with field_ids starting with "cl") have a very large number of records and attempting to download the full set can cause R to crash. Specifying -1 for maxrows will download the full set of records for that field

record_count_only

logical: if TRUE, return just the count of records that would be downloaded, but don't download them. This really only makes sense for contextual layers, because environmental layers have only one record per layer

Value

If record_count_only is TRUE, the number of records is returned as numeric. Otherwise, a data frame containing the field name and various attributes; an empty data frame is returned if no match is found

Author(s)

Atlas of Living Australia support@ala.org.au

References

See Also

search_layers to search for spatial layers

Examples

1
2
3
4
5
6
7
8
l=ala_fields("layers")
l[,4]
o=ala_fields("occurrence")
o[1:13,]
a=ala_fields("assertions")
a[,5]
field_info("cl22")
field_info("el773")

jjvanderwal/ALA4R documentation built on May 19, 2019, 11:40 a.m.