Given a stacked data.frame and a distance matrix compute the functional
distinctiveness for a single community. Functional distinctiveness relates to
the functional "originality" of a species in a community. The closer to 1 the
more the species is functionally distinct from the rest of the community. See
distinctiveness()
function or the functional rarity
indices vignette included in the package
(type vignette("rarity_indices", package = "funrar")
), for more details
on the metric. IMPORTANT NOTE: in order to get functional rarity indices
between 0 and 1, the distance metric has to be scaled between 0 and 1.
distinctiveness_com(
com_df,
sp_col,
abund = NULL,
dist_matrix,
relative = FALSE
)
the same data.frame with the additional Di column giving functional distinctiveness values for each species
a stacked (= tidy) data.frame from a single community with each row representing a species in a community
a character vector, the name of the species column in com_df
a character vector, the name of the column containing relative abundances values
a functional distance matrix as given by
compute_dist_matrix()
, with species name as row and column names
a logical indicating if distinctiveness should be scaled relatively to the community (scaled by max functional distance among the species of the targeted community)
This function is meant for internal uses mostly, thus it does not include any
tests on inputs and may fail unexpectedly. Please use
distinctiveness_stack()
to avoid input errors.
scarcity_com()
,
vignette("rarity_indices", package = "funrar")
and
distinctiveness()
Details section for detail on the index