phyloseq_sep_pairwise: Split phyloseq-class object for pairwise comparisons by...

View source: R/phyloseq_sep_pairwise.R

phyloseq_sep_pairwiseR Documentation

Split phyloseq-class object for pairwise comparisons by sample-level variable.

Description

Split phyloseq-class object for pairwise comparisons by sample-level variable.

Usage

phyloseq_sep_pairwise(phys, group, comparis = "all", drop_zeroes = TRUE)

Arguments

phys

A phyloseq-class object

group

Variable name (contained in sample_data)

comparis

Character "all" for all possible pairwise comparisons (default), or a matrix with comparison names to use (similar to the output of combn with m=2)

drop_zeroes

Logical, indicating weather OTUs with zero abundance or samples with zero total abundance should be removed

Value

List with phyloseq objects (each with only two groups based on selected variable).

Examples

data(enterotype)

# Split enterotype data for pairwise comparisons by sequencing technology
ent <- phyloseq_sep_pairwise(enterotype, group = "SeqTech", drop_zeroes = TRUE)
ent

# Perform differential abundance testing for each of the pairwise comparisons


vmikk/metagMisc documentation built on June 20, 2024, 7:20 a.m.