align_comm_V: Create phylogenetic var-cov matrix based on phylogeny and...

Description Usage Arguments Value

View source: R/utils.R

Description

This function will remove species from community data that are not in the phylogeny. It will also remove tips from the phylogeny that are not in the community data. And then convert the phylogeny to a Var-cov matrix.

Usage

1
align_comm_V(comm, tree, prune.tree = FALSE, scale.vcv = TRUE)

Arguments

comm

A site by species data frame, with site names as row names.

tree

A phylogeny with "phylo" as class; or a phylogenetic var-covar matrix.

prune.tree

Whether to prune the tree first then use vcv.phylo function. Default is FALSE: use vcv.phylo first then subsetting the matrix.

scale.vcv

Whether to scale vcv to a correlation matrix.

Value

A list of the community data and the phylogenetic var-cov matrix.


phyr documentation built on Jan. 13, 2021, 5:40 p.m.