Learn R Programming

spaa (version 0.2.2)

data2mat: Convert species list data to species matrix

Description

This function can be used to convert the species list to species matrix. The rows of the output matrix are plots, or sites. The columns are the species.

Usage

data2mat(data = data)

Arguments

data
The input data

Value

Return a species matrix with each row for each plot, and each column for species.

Details

The input data will have to include :species,plots or sites, abundance, specifically, a column named "abundance" must be specified.

References

None

Examples

Run this code
data(testdata)
spmatrix <- data2mat(testdata)

Run the code above in your browser using DataLab