MicrobiomeStat Tutorial
  • Track, Analyze, Visualize: Unravel Your Microbiome's Temporal Pattern with MicrobiomeStat.
  • INTRODUCTION
    • Exploring MicrobiomeStat: A Consideration for Your Research Toolkit
  • Setting Up MicrobiomeStat: Installation and Data Preparation
    • Installation Guide
    • Creating the MicrobiomeStat Data Object
      • Building MicrobiomeStat from Matrix and Data.frame
      • Converting Data from Phyloseq into MicrobiomeStat
      • Importing Data from QIIME2 into MicrobiomeStat
      • Importing Data from BIOM into MicrobiomeStat
      • Converting SummarizedExperiment into MicrobiomeStat
      • Converting DGEList Data into MicrobiomeStat
      • Converting DESeqDataSet into MicrobiomeStat
      • Importing Data from DADA2 into MicrobiomeStat
      • Importing Data from Mothur into MicrobiomeStat
  • Single-Point Analysis
    • Introduction
    • Alpha Diversity Analysis
    • Beta Diversity Analysis
    • Feature-level Analysis
    • One-Click Reports Generation
  • Paired Samples Analysis
    • Introduction
    • Alpha Diversity Analysis
    • Beta Diversity Analysis
    • Feature-level Analysis
    • One-Click Reports Generation
  • Longitudinal Analysis
    • Introduction
    • Alpha Diversity Analysis
    • Beta Diversity Analysis
    • Feature-level Analysis
    • One-Click Reports Generation
  • Data Manipulation and Transformation
    • Data Summary
    • Data Aggregation
    • Data Normalization
    • Data Filtering
    • Data Validation
    • Data Combination
    • Metadata Management
    • Color Palette
  • Frequently Asked Questions (FAQ)
    • General FAQs
Powered by GitBook
On this page

Was this helpful?

Edit on GitHub
  1. Setting Up MicrobiomeStat: Installation and Data Preparation
  2. Creating the MicrobiomeStat Data Object

Importing Data from Mothur into MicrobiomeStat

Steps for importing Mothur-generated data into the MicrobiomeStat framework.

PreviousImporting Data from DADA2 into MicrobiomeStatNextIntroduction

Last updated 1 year ago

Was this helpful?

This guide details the procedure to seamlessly import data generated by Mothur into the MicrobiomeStat environment.

# Make sure the plyr package is installed
if (!require(plyr)) {
    install.packages("plyr")
    library(plyr)
} else {
    library(plyr)
}

# Specify the paths to your Mothur files
path_to_list_file <- "/path_to_your_files/esophagus.fn.list.gz"
path_to_group_file <- "/path_to_your_files/esophagus.good.groups.gz"
path_to_tree_file <- "/path_to_your_files/esophagus.tree.gz"
path_to_shared_file <- "/path_to_your_files/esophagus.fn.shared.gz"

# Import Mothur data into a MicrobiomeStat data object
data_obj <- mStat_import_mothur_as_data_obj(
    mothur_list_file = path_to_list_file,
    mothur_group_file = path_to_group_file,
    mothur_tree_file = path_to_tree_file,
    mothur_shared_file = path_to_shared_file
)

# After constructing data_obj, detach the plyr package to avoid conflicts with dplyr
if ("package:plyr" %in% search()) {
    detach("package:plyr", unload = TRUE)
    message("Detached plyr package to avoid potential conflicts with dplyr.")
}

The mStat_import_mothur_as_data_obj function facilitates the conversion of the Mothur dataset to the basic MicrobiomeStat data objects. Here are the key components:

  • mothur_list_file (Optional): Mothur-generated list file.

  • mothur_group_file (Optional): Group designation file from Mothur.

  • mothur_tree_file (Optional): Phylogenetic tree representation.

  • mothur_shared_file (Optional): OTU Abundance data across samples.

  • mothur_constaxonomy_file (Optional): Classification of OTUs at various taxonomic levels.

  • parseFunction (Optional): Custom function for taxonomy parsing, with 'parse_taxonomy_default' as an available option.

4KB
esophagus.fn.list.gz
This compressed file contains the list file from Mothur, which typically encompasses OTU clustering information for various thresholds.
2KB
esophagus.fn.shared.gz
The shared file provides a breakdown of the abundance of OTUs in each sample.
1KB
esophagus.good.groups.gz
Group file indicating the sample assignment for each sequence.
5KB
esophagus.tree.gz
Phylogenetic tree file representing the evolutionary relationships among OTUs.
Structural overview of the `data_obj` generated after importing Mothur datasets into MicrobiomeStat.