This guide will walk you through the steps required to import data from DADA2 into MicrobiomeStat.
Download Necessary Files
Code to Import Data
# This function requires the `Biostrings` and `yaml` packages.# If you encounter issues when running the example code, please ensure that you have installed and loaded these packages.library(Biostrings)library(yaml)# Read the sequence table from the downloaded RDS fileseq_tab <-readRDS("path_to_your_downloaded_folder/dada2_seqtab.rds")# Read the taxonomy table from the downloaded RDS filetax_tab <-readRDS("path_to_your_downloaded_folder/dada2_taxtab.rds")# Read the sample metadata from the downloaded txt filesam_tab <-read.table("path_to_your_downloaded_folder/dada2_samdata.txt", sep ="\t", header =TRUE, row.names =1)# Convert DADA2 data into a MicrobiomeStat data objectdata_obj <-mStat_import_dada2_as_data_obj( seq_tab = seq_tab, tax_tab = tax_tab, sam_tab = sam_tab)
Note: Ensure to replace "path_to_your_downloaded_folder" with the actual path where you've saved the downloaded files.