dispRity.per.group: Disparity in different groups.

View source: R/dispRity.wrapper.R

dispRity.per.groupR Documentation

Disparity in different groups.


Performs a disparity analysis between groups.


dispRity.per.group(data, group, metric = c(median, centroids), ...)



An ordinated matrix.


A list of row numbers for each group.


A vector containing one to three functions (default = c(median, centroids)) (see dispRity for details).


Optional arguments to be passed to custom.subsets, boot.matrix and dispRity.


Note that this is a wrapper function that allows users to run a basic disparity among groups analysis without too much effort. As such it has a lot of defaults described in the functions that make up the analysis. See custom.subsets, boot.matrix, dispRity.metric, summary.dispRity, plot.dispRity for more details of the defaults used in each of these functions. Note that any of these defaults can be changed within the disparity.through.time function.


A dispRity object that can be passed to summary or plot.


Thomas Guillerme

See Also

custom.subsets, boot.matrix, dispRity.metric, summary.dispRity, plot.dispRity.


## Load the Beck & Lee 2014 data

## Run a simple disparity per group analysis comparing stem and crown mammals
result <- dispRity.per.group(BeckLee_mat50, list(crown = c(16, 19:41, 45:50),
                             stem = c(1:15, 17:18, 42:44)))
summary(result) ; plot(result)

## This is equivalent to run the following decomposed code
dispRity(boot.matrix(custom.subsets(BeckLee_mat50, list(crown = c(16, 19:41, 45:50),
                                                        stem = c(1:15, 17:18, 42:44))),
                     bootstraps = 100),
         metric = c(median, centroids))

dispRity documentation built on May 29, 2024, 9:40 a.m.