Learn R Programming

funrar (version 1.5.0)

distinctiveness_dimensions: Distinctiveness across combinations of traits

Description

From a trait data.frame and a site-species matrix compute Distinctiveness (average pairwise functional distance) for each species in each community on each provided trait and on all traits taken altogether.

Usage

distinctiveness_dimensions(pres_matrix, traits_table, ...)

Value

a list of site-species matrix with functional distinctiveness values per species per site, with elements Di_X for distinctiveness computed on trait X and Di_all for distinctiveness computed on all traits.

Arguments

pres_matrix

a site-species matrix, with species in rows and sites in columns, containing presence-absence, relative abundances or abundances values

traits_table

a data.frame of traits with species in row and traits in columns, row names should be species names,

...

additional arguments supplied to compute_dist_matrix()

See Also

uniqueness_dimensions(), distinctiveness(), distinctiveness_stack() and compute_dist_matrix() for additional arguments

Examples

Run this code
data("aravo", package = "ade4")

# Site-species matrix
mat = as.matrix(aravo$spe)
rel_mat = make_relative(mat)

# Example of trait table
tra = aravo$traits[, c("Height", "SLA", "N_mass")]

di_dim = distinctiveness_dimensions(rel_mat, tra)

Run the code above in your browser using DataLab