bcoov {simba}R Documentation

Calculate Bray-Curtis distance for only one variable

Description

Calculates Bray-Curtis distance for only one variable: How dissimilar are the units regarding for instance pH?

Usage

bcoov(x, names, listout = FALSE)

Arguments

x numeric vector with quantitative data from sampling-units, standardization may be applied before
names where should the names be taken from, must be a vector of the same length as x and should give the names of the sampling-units
listout Shall the result given in list-format (data.frame)? Defaults to FALSE

Details

It is just a simple way to calculate similarity based on only one variable. In the future there might be a possibility to choose from some functions. However, you could also use the difference in the data-values instead (which is the Euclidean distance in one dimensional space).

Value

Returns a dist object or a data.frame (in the case of listout = TRUE) with

NBX one of the compared sampling units
NBY the other part of the pair
x The returned distance value. It is named like the tested variable

Author(s)

Gerald Jurasinski

See Also

vegdist, dist.quant, dsvdis

Examples

data(abis)
names(abis.env) ##take a look at the data
##calculate the similarity (Bray-Curtis) between the plots 
##regarding pH
pH.dist <- bcoov(abis.env$pH, names=rownames(abis.env))

## directly give it as a list (data.frame)
pH.dist.ls <- bcoov(abis.env$pH, names=rownames(abis.env)
, listout=TRUE)


[Package simba version 0.2-5 Index]