bioEnv: Clarke and Ainsworth's BIO-ENV routine

View source: R/bioEnv.R

bioEnvR Documentation

Clarke and Ainsworth's BIO-ENV routine

Description

The bioEnv function performs Clarke and Ainsworth's (1993) "BIO-ENV" routine which compares (via a Mantel test) a fixed matrix of similarities to a variable one that test all possible variable combinations.

Usage

bioEnv(
  fix.mat,
  var.mat,
  fix.dist.method = "bray",
  var.dist.method = "euclidean",
  scale.fix = FALSE,
  scale.var = TRUE,
  output.best = 10,
  var.max = ncol(var.mat)
)

Arguments

fix.mat

The "fixed" matrix of community or environmental sample by variable values

var.mat

A "variable" matrix of community or environmental sample by variable values

fix.dist.method

The method of calculating dissimilarity indices bewteen samples in the fixed matrix (Uses the vegdist function from the vegan package to calculate distance matrices. See the documentation for available methods.). Defaults to Bray-Curtis dissimularity "bray".

var.dist.method

The method of calculating dissimilarity indices bewteen samples in the variable matrix. Defaults to Euclidean dissimularity "euclidean".

scale.fix

Logical. Should fixed matrix be centered and scaled (Defaults to FALSE, recommended for biologic data).

scale.var

Logical. Should fixed matrix be centered and scaled (Defaults to TRUE, recommended for environmental data to correct for differing units between variables).

output.best

Number of best combinations to return in the results object (Default=10).

var.max

Maximum number of variables to include. Defaults to all, var.max=ncol(var.mat).

Details

The R package "vegan" contains a version of Clarke and Ainsworth's (1993) BIOENV analysis (bioenv) which allows for the comparison of distance/similarity matrices between two sets of data having either samples or variables in common. The difference with bioEnv is that one has more flexibility with methods to apply to the fixed and variable multivariate matrices. The typical setup is in the exploration of environmental variables that best correlate to sample similarities of the biological community (e.g. species biomass or abundance), called "BIOENV". In this case, the similarity matrix of the community is fixed, while subsets of the environmental variables are used in the calculation of the environmental similarity matrix. A correlation coefficient (typically Spearman rank correlation coefficient, "rho") is then calculated between the two matrices and the best subset of environmental variables can then be identified and further subjected to a permutation test to determine significance. The vegan package's bioenv function assumes BIOENV setup, and the similarity matrix of environmental data is assumed to be based on normalized "euclidean" distances. This makes sense with environmental data where one normalizes the data to remove the effect of differing units between parameters, yet in cases where the variable matrix is biological, one might want more flexibility (a Bray-Curtis measure of similarity is common given its non-parametric nature). For example, beyond the typical biological to environmental comparison (BIOENV setup), one can also use the routine to explore other other types of relationships; e.g.:

ENVBIO: subset of biological variables that best correlate to the overall environmental pattern
BIOBIO: subset of biological variables that best correlate to the overall biological pattern
ENVENV: subset of environmental variables that best correlate to the overall environmental pattern

It is important to mention that one of the reasons why a variable biological similarity matrix is often less explored with the routine is that the number of possible subset combinations becomes computationally overwhelming when the number of species/groups is large - the total number of combinations being equal to 2^n - 1, where n is the total number of variables. For this reason, Clarke and Warwick (1998) presented a stepwise routine (BVSTEP) (see bvStep for more efficient exploration of the subset combinations).

References

Clarke, K. R & Ainsworth, M. 1993. A method of linking multivariate community structure to environmental variables. Marine Ecology Progress Series, 92, 205-219.

Clarke, K. R., Warwick, R. M., 2001. Changes in Marine Communities: An Approach to Statistical Analysis and Interpretation, 2nd edition. PRIMER-E Ltd, Plymouth, UK.

Examples


library(vegan)
data(varespec)
data(varechem)

res <- bioEnv(wisconsin(varespec), varechem, 
              fix.dist.method="bray", var.dist.method="euclidean",
              scale.fix=FALSE, scale.var=TRUE
)
res



marchtaylor/sinkr documentation built on July 4, 2022, 5:48 p.m.