multipatt_pq: Test and plot multipatt result

View source: R/beta_div_test.R

multipatt_pqR Documentation

Test and plot multipatt result

Description

lifecycle-experimental

A wrapper for the indicspecies::multipatt() function in the case of physeq object.

Usage

multipatt_pq(
  physeq,
  fact,
  p_adjust_method = "BH",
  pval = 0.05,
  control = permute::how(nperm = 999),
  ...
)

Arguments

physeq

(required): a phyloseq-class object obtained using the phyloseq package.

fact

(required) Name of the factor in physeq@sam_data used to plot different lines

p_adjust_method

(chr, default "BH"): the method used to adjust p-value

pval

(int, default 0.05): the value to determine the significance of LCBD

control

see ?indicspecies::multipatt()

...

Other arguments passed on to indicspecies::multipatt() function

Details

This function is mainly a wrapper of the work of others. Please make a reference to indicspecies::multipatt() if you use this function.

Value

A ggplot2 object

Author(s)

Adrien Taudière

Examples


if (requireNamespace("indicspecies")) {
  data(data_fungi)
  data_fungi_ab <- subset_taxa_pq(data_fungi, taxa_sums(data_fungi) > 10000)
  multipatt_pq(subset_samples(data_fungi_ab, !is.na(Time)), fact = "Time")
}

if (requireNamespace("indicspecies")) {
  multipatt_pq(subset_samples(data_fungi_ab, !is.na(Time)),
    fact = "Time",
    max.order = 1, control = permute::how(nperm = 99)
  )
}



MiscMetabar documentation built on Oct. 8, 2024, 1:07 a.m.