metagMisc is an R package that provides a suite of functions for metabarcoding and microbiome data analysis (also suitable for processed metagenomic data), with particular focus on handling data in phyloseq format (McMurdie and Holmes 2013). The package helps with common workflows including data filtering, normalization, rarefaction, diversity estimation, and comparative analysis. It offers both traditional and cutting-edge approaches for handling amplicon sequencing data, making it an essential toolkit for microbial ecologists and bioinformaticians.
The package includes two vignettes that guide through typical metabarcoding workflows:
- Introduction to metagMisc: Data exploration, filtering, sample operations, and basic analysis workflows
- Rarefaction and diversity estimation: Guide to rarefaction methods, sample coverage, and diversity estimation
Pairwise dissimilarity analysis

Diversity profiles with Hill numbers

Taxonomic filtering and abundance analysis

Taxonomic annotation quality assessment

- Data exploration and quality control: Taxonomic resolution assessment, prevalence analysis, and comprehensive filtering options
- Standardization and normalization: Multiple rarefaction, coverage-based rarefaction, and SRS (Scaling with Ranked Subsampling) normalization
- Diversity estimation: Hill numbers, phylogenetic diversity, and rarefaction/extrapolation with iNEXT integration
- Comparative analysis: Sample grouping, shared/unique taxa identification, and beta-diversity visualization
- Data transformation: CLR, CSS, VST transformations and compositional data analysis workflows
- File format support: Parsers for USEARCH, BLAST, SILVA, QIIME, and other common formats
Install the development version from GitHub:
# Install from GitHub
if (!requireNamespace("remotes", quietly = TRUE)){
install.packages("remotes")
}
remotes::install_github("vmikk/metagMisc")Most dependencies will be installed automatically. For Bioconductor packages, ensure you have BiocManager installed:
# Install BiocManager if needed
if (!requireNamespace("BiocManager", quietly = TRUE)){
install.packages("BiocManager")
}
# Core Bioconductor dependencies
BiocManager::install(c("phyloseq", "DESeq2", "ALDEx2", "metagenomeSeq"))
# Additional dependencies (installed automatically with metagMisc)
install.packages(c("vegan", "data.table", "ggplot2", "plyr", "iNEXT", "SRS"))
# Optional packages for specific analyses
remotes::install_github("cran/PhyloMeasures") # for phylogenetic diversity
remotes::install_github("mikemc/speedyseq") # for faster phyloseq operations
BiocManager::install("GenomicAlignments") # for CIGAR string expansionmetagMisc builds upon the excellent work of the R community, particularly the vegan, phyloseq, and data.table packages. We are grateful to all package developers who make reproducible microbiome research possible.
When using metagMisc, please also cite the underlying methods and packages used in your analysis. The package vignettes provide guidance on appropriate citations for specific functions.
The development of this software was supported by RFBR grants 16-04-01259 and 15-29-02765.

