mpd: Mean pairwise distance

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/phylodiversity.R

Description

Calculates mean pairwise distance separating taxa in a community

Usage

1
mpd(samp, dis, abundance.weighted=FALSE)

Arguments

samp

Community data matrix

dis

Interspecific distance matrix

abundance.weighted

Should mean pairwise distances be weighted by species abundance? (default = FALSE)

Value

Vector of MPD values for each community

Author(s)

Steven Kembel <steve.kembel@gmail.com>

References

Webb, C., D. Ackerly, M. McPeek, and M. Donoghue. 2002. Phylogenies and community ecology. Annual Review of Ecology and Systematics 33:475-505.

See Also

ses.mpd

Examples

1
2
data(phylocom)
mpd(phylocom$sample, cophenetic(phylocom$phylo), abundance.weighted=TRUE)

Example output

Loading required package: ape
Loading required package: vegan
Loading required package: permute
Loading required package: lattice
This is vegan 2.4-4
Loading required package: nlme
[1] 4.250000 4.944444 5.833333 6.944444 7.750000 7.109375

picante documentation built on July 1, 2020, 10:57 p.m.