traits: Get trait data from WST.

Description Usage Arguments Details Value References Examples

View source: R/spidR.R

Description

Downloads the most recent data from the World Spider Trait database.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
traits(
  tax,
  trait = NULL,
  sex = NULL,
  life = NULL,
  country = NULL,
  habitat = NULL,
  user = "",
  key = "",
  order = FALSE
)

Arguments

tax

A taxon name or vector with taxa names.

trait

A vector with required trait(s) as abbreviations. Valid values can be found at: https://spidertraits.sci.muni.cz/traits

sex

A vector with required sex(es).

life

A vector with required life stage(s).

country

A vector with required country(ies) ISO3 code(s).

habitat

A vector with required habitat(s).

user

To obtain restricted data get a user name from https://spidertraits.sci.muni.cz/api.

key

To obtain restricted data get an api key from https://spidertraits.sci.muni.cz/api.

order

Order taxa names alphabetically or keep as in tax.

Details

The World Spider Trait database (Pekar et al. 2021) has been designed to contain trait data in a broad sense, from morphological traits to ecological characteristics, ecophysiology, behavioural habits, and more (Lowe et al. 2020). This function will download everything available for the taxa given, possibly filtered to the traits given in parameter trait. Some data might be restricted access, in which case a user name and api key are needed (https://spidertraits.sci.muni.cz/api), otherwise the value will show as NA.

Value

A matrix with trait data.

References

Lowe, E., Wolff, J.O., Aceves-Aparicio, A., Birkhofer, K., Branco, V.V., Cardoso, P., Chichorro, F., Fukushima, C.S., Goncalves-Souza, T., Haddad, C.R., Isaia, M., Krehenwinkel, H., Audisio, T.L., Macias-Hernandez, N., Malumbres-Olarte, J., Mammola, S., McLean, D.J., Michalko, R., Nentwig, W., Pekar, S., Petillon, J., Privet, K., Scott, C., Uhl, G., Urbano-Tenorio, F., Wong, B.H. & Herbestein, M.E. (2020). Towards establishment of a centralized spider traits database. Journal of Arachnology, 48: 103-109. https://doi.org/10.1636/0161-8202-48.2.103

Pekar, S., Cernecka, L., Wolff, J., Mammola, S., Cardoso, P., Lowe, E., Fukushima, C.S., Birkhofer, K. & Herberstein, M.E. (2021). The world spider trait database. Masaryk University, Brno, URL: https://spidertraits.sci.muni.cz

Examples

1
2
3
4
5
6
7
8
## Not run: 
traits("Atypus affinis")
traits("Atypus", order = TRUE)
traits("Atypidae", country = c("PRT", "CZE"), order = TRUE)
traits(c("Zodarion costapratae", "Zodarion alacre"))
traits(c("Iberesia machadoi", "Zodarion costapratae"), trait = c("balo", "bole"))

## End(Not run)

spidR documentation built on Oct. 18, 2021, 9:08 a.m.

Related to traits in spidR...