parts: Pick out parts by name

Description Usage Arguments Value Examples

Description

This suite of functions act on taxon or taxonref objects, and pick out object elements by the name of the function.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
name(x, unname = TRUE)

## S3 method for class 'taxon'
name(x, unname = TRUE)

## S3 method for class 'taxonref'
name(x, unname = TRUE)

uri(x, unname = TRUE)

## S3 method for class 'taxon'
uri(x, unname = TRUE)

## S3 method for class 'taxonref'
uri(x, unname = TRUE)

rank(x, unname = TRUE)

## S3 method for class 'taxon'
rank(x, unname = TRUE)

## S3 method for class 'taxonref'
rank(x, unname = TRUE)

taxonid(x, unname = TRUE)

## S3 method for class 'taxon'
taxonid(x, unname = TRUE)

## S3 method for class 'taxonref'
taxonid(x, unname = TRUE)

Arguments

x

Input, object of class taxon or taxonref

unname

(logical) Unname output elements? Ignored when input is of class taxonref. Default: TRUE

Value

For taxon inputs, gives back a taxonref object. For taxondf inputs, gives back taxondf.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
# operating on `taxon` objects
out <- make_taxon(genus="Poa", epithet="annua", authority="L.",
   family='Poaceae', clazz='Poales', kingdom='Plantae', variety='annua')

out %>% name()
out %>% uri()
out %>% rank()
out %>% taxonid()

## or don't unname the output
out %>% name(unname = FALSE)

# operating on `taxonref` objects
res <- taxonref("genus", "Poa", 56, "http://scottchamberlain.info/")
res %>% name()
res %>% uri()
res %>% rank()
res %>% taxonid()

binomen documentation built on May 30, 2017, 7:38 a.m.