get_pd_alpha: calculate alpha phylogenetic diversity

Description Usage Arguments Value

View source: R/pd.R

Description

A function to calculate a bunch of phylo diversity: Faith's PD, MPD, VPD (variance of pairwise distance), MNTD, PSV/PSE. Results of MPD/MNTD from PhyloMeasures are equal with those from Phylocom/Picante with abundance.weight = FALSE Results of PD from PhyloMeasures are unrooted; PD from Phylocom are rooted.

Usage

1
2
3
4
5
get_pd_alpha(samp_wide, tree, samp_long, null.model.pd.root = FALSE,
  null.model.phylomeasures = TRUE, null.model.phylocom = FALSE,
  null.type.phylomeasures = "uniform", null.type.phylocom = 0,
  null.type.picante = "taxa.labels", n.item = 999, abund.weight = FALSE,
  verbose = TRUE, vpd = FALSE, ...)

Arguments

samp_wide

wide version of samp_long, row.names are sites, colnames are species

tree

a phylogeny with class of 'phylo'

samp_long

a 3-column data frame, site, freq, sp

null.model.pd.root

whether to run null models for rooted PD?

null.type.phylomeasures

if null.model is TRUE, which null model to use for PhyloMeasure?

null.type.phylocom

if null.model is TRUE, which null model to use for Phylocom? - 0: phylogeny shuffle. - 1: maintain site richness and draw from species actually observed in sites. - 2: maintain site richness and draw from the phylogeny - 3: independent swap. See ?phylocomr::ph_comstruct for details

null.type.picante

if null.model is TRUE, which null model to use for Picante? Not used yet.

n.item

the number of randomization

abund.weight

should abundance information used when calculating pd with Phylocom/Picante? Default is FALSE

verbose

do you want to see relevant information?

vpd

to calculate vpd (varance of pairwise distance) or not?

Value

a data frame


daijiang/dli55 documentation built on Jan. 28, 2018, 3:48 a.m.