create.matrix {fossil}R Documentation

Creating species locality matrices

Description

Create a matrix with taxa as rows and occurrences or samples as columns

Usage

  create.matrix(x,tax.name="genus",locality="locality",time.col=NULL,time=NULL,abund=FALSE,abund.col="abundance")

Arguments

x a table arranged in columnar format, with at least one column indicating name of taxa and another giving location or sample
tax.name the name or number of the column giving the taxonomic names to be used (the rows of the matrix to be created)
locality the name or number of the column giving the locations of the samples (the columns of the matrix to be created)
time.col what is the column name or number containing the time periods; if left null, filtering for time willbe ignored
time what time periods to keep for the matrix; if left null, filtering for time willbe ignored
abund whether to record abundances of taxa; if left FALSE, a binary (presence/absence) matrix is created
abund.col column name or number containing abundance values

Details

This is a helper function to convert large lists of data into matrices of species (rows) and locations (columns). The parameters can be adjusted to create either a binary (presence/absence) or abundance matrix. The setup of the table is largely flexible; simply input the column names or numbers containing the pertinent information. To filter data according to time, both the time column and the time period must be specified. For abundance, the default title for the abundance column is simply "abundance"; the function will not work if you have chosen to include abundances (abund = TRUE but the name of the abundance column is incorrect.

Value

A

Author(s)

Matthew Vavrek

References

~put references to the literature/web site here ~

See Also

create.lats

Examples

##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--    or do  help(data=index)  for the standard data sets.

## The function is currently defined as


[Package fossil version 0.2.0 Index]