Creating an object containing a standardised trait definition according to the Ecological Traitdata Standard. Parameters correspond to the definition at http://ecologicaltraitdata.github.io/ETS/#terms-for-thesauri.

as.trait(trait, identifier = NA, broaderTerm = NA, narrowerTerm = NA,
  expectedUnit = NA, maxAllowedValue = NA, minAllowedValue = NA,
  factorLevels = NA, valueType = NA, traitDescription = NA,
  comments = NA, relationSource = NA, version = NA, author = NA,
  ...)

Arguments

trait

A character string, providing an intuitive, human-readable trait name.

identifier

Unique identifier for the trait, ideally unique and stable URI which identify the source of the trait definition.

broaderTerm

One or several terms that enclose the trait definition.

narrowerTerm

One or several terms that are enclosed by the trait definition.

expectedUnit

the unit expected for measurement entries.

maxAllowedValue

An upper boundary for accepted numerical values.

minAllowedValue

A lower boundary for accepted numerical values.

factorLevels

A comma separated list of terms comprising the constrained vocabulary for categorical traits or ordinal binary traits.

valueType

the type of trait values. Possible entries are 'numeric', 'integer', 'categorical', 'logical', or 'character'.

traitDescription

A short, unambiguous definition of the trait. May refer to a method of measurement.

comments

Details and Examples for clarification of the trait definition.

relationSource

A character string providing a full bibliographic reference to the trait definition (giving title, author, year and publication).

version

A character string containing the version number of the referenced definition (e.g. "v1.2"), if applicable.

author

A character string or object of class 'person' (as created by as.person()) attributing the author(s) of the trait definition.

...

other arguments, passed on to print function.

Examples

body_length <- as.trait("body_length", expectedUnit = "mm", valueType = "numeric", identifier = "http://t-sita.cesab.org/BETSI_vizInfo.jsp?trait=Body_length", traitDescription = "The known longest dimension of the physical structure of organisms", relationSource = "Maggenti and Maggenti, 2005", broaderTerm = "http://t-sita.cesab.org/BETSI_vizInfo.jsp?trait=Body_dimension" )