phyloseq_inext: Estimate interpolated and extrapolated Hill numbers and...

View source: R/phyloseq_inext.R

phyloseq_inextR Documentation

Estimate interpolated and extrapolated Hill numbers and sample coverage and construct rarefaction curve.

Description

Estimate interpolated and extrapolated Hill numbers and sample coverage and construct rarefaction curve.

Usage

phyloseq_inext(
  physeq,
  Q = 0,
  curve_type = "diversity",
  correct_singletons = FALSE,
  endpoint = NULL,
  knots = 40,
  multithread = FALSE,
  show_CI = TRUE,
  show_sample_labels = TRUE,
  show_plot = TRUE,
  justDF = FALSE,
  add_raw_data = TRUE,
  ...
)

Arguments

physeq

A phyloseq-class object

Q

Diversity order of Hill number; 0 for species richness (default), 1 for Shannon diversity; 2 for Simpson diversity

curve_type

Which data to show on the plot: "diversity" (default) or sample "coverage"

correct_singletons

Logical; apply Good-Turing correction for singleon counts

endpoint

Sample size for extrapolation (default = NULL, which corresponds to a double reference sample size for each sample)

knots

Number of equally-spaced sample sizes (x-axis) to analyze (default, 40)

multithread

Logical; if TRUE, attempts to run the function on multiple cores

show_CI

Logical; show bootstap confidence interval on the plot

show_sample_labels

Logical; add sample labels to the plot

show_plot

Logical; show plot on screen

justDF

Logical; return table with rarefaction results and do not show the plot

add_raw_data

Logical; add attributes with iNEXT results to the output (see iNEXT)

...

Additional arguments may be passed to iNEXT (e.g., conf = 0.95, nboot = 100)

Value

Plot of class 'ggplot' or 'data.frame' (if 'justDF = TRUE')

References

Chao A, Gotelli NJ, Hsieh TC, Sander EL, Ma KH, Colwell RK, Ellison AM (2014) Rarefaction and extrapolation with Hill numbers: a framework for sampling and estimation in species diversity studies. Ecological Monographs, 84: 45-67. DOI: 10.1890/13-0133.1

Hsieh TC, Ma KH, Chao A (2016) iNEXT: An R package for interpolation and extrapolation of species diversity (Hill numbers). Methods in Ecology and Evolution, 7: 1451-1456. DOI: 10.1111/2041-210X.12613

See Also

iNEXT, prepare_inext

Examples

data("esophagus")
phyloseq_inext(esophagus)
phyloseq_inext(esophagus, curve_type = "coverage")
phyloseq_inext(esophagus, justDF = T)


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