subset_dist: Subset Distance Matrix

Description Usage Arguments Details Value References

View source: R/subset_dist.R

Description

Subsets a distance matrix.

Usage

1
subset_dist(physeq, d.matrix)

Arguments

physeq

An experiment level phyloseq object.

d.matrix

A distance matrix.

Details

Some distance matrices take a long time to calculate for large data sets. This is especially true of unifrac and generalized unifrac distances calculated by GUniFracs. If distances are first calculated from data in a large experiment level phyloseq object and then it is desired to perform PERMANOVA (with adonis) on a subset of that object, this function provides a means of sub-setting the distance matrix so that it does not have to be calculated again for the subset data. The arguments are the distance matrix for the original phyloseq object and the smaller phyloseq object subset from the original.

Value

A distance matrix of smaller dimensions.

References

Chen J, Bittinger K, Charlson ES et al. (2012) Associating microbiome composition with environmental covariates using generalized UniFrac distances. Bioinformatics, 28, 2106-2113.


jfq3/QsRutils documentation built on Jan. 18, 2021, 12:40 a.m.