plot_LCBD_pq: Plot and test local contributions to beta diversity (LCBD) of...

View source: R/beta_div_test.R

plot_LCBD_pqR Documentation

Plot and test local contributions to beta diversity (LCBD) of samples

Description

lifecycle-experimental

A wrapper for the adespatial::beta.div() function in the case of physeq object.

Usage

plot_LCBD_pq(
  physeq,
  p_adjust_method = "BH",
  pval = 0.05,
  sam_variables = NULL,
  only_plot_significant = TRUE,
  ...
)

Arguments

physeq

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

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

sam_variables

A vector of variable names present in the sam_data slot to plot alongside the LCBD value

only_plot_significant

(logical, default TRUE) Do we plot all LCBD values or only the significant ones

...

Additional arguments passed on to adespatial::beta.div() function

Details

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

Value

A ggplot2 object build with the package patchwork

Author(s)

Adrien Taudière

See Also

LCBD_pq, adespatial::beta.div()

Examples


if (requireNamespace("adespatial")) {
  plot_LCBD_pq(data_fungi_mini,
    nperm = 20, only_plot_significant = FALSE,
    pval = 0.2
  )
}


MiscMetabar documentation built on Nov. 16, 2026, 5:06 p.m.