Learn R Programming

EcoVirtual (version 1.1)

rich: Number of Species

Description

Count the number of species (species richness) from a vector with a species list.

Usage

rich(x)

Arguments

x

a vector with names.

Value

returns the number of species (species richness).

Details

This function is used internally in the functions 'simHub1', simHub2', and 'simHub3'.

Examples

Run this code
# NOT RUN {
lsp <- sample(LETTERS,50,replace=TRUE)
lsp
rich(lsp)

# }

Run the code above in your browser using DataLab