Learn R Programming

patPRO (version 1.1.0)

mergeMapMetaData: Merge Mapping and Data Files

Description

This function merges mapping file metadate (mapping file information formatted according to Qiime specifications) with dataset output from Qiime, including alpha diversity, bacterial relative abundance, and bacterial load (this must be aquired outside of standard Qiime sequencing methods). Merge the necessary mapping file columns (subject ID and time point which could be days, etc) into the datasets for alpha diversity, bacterial load, and taxa relative abundance.

Usage

mergeMapMetaData(map.file, merging.file, map.sub.id="SubjectID", map.tmpt="Time_point", map.smpl.id="SampleID", merge.smpl.id, sample.id.col="SampleID", subject.id.col="SubjectID", tmpt.id.col="Time_point")

Arguments

map.file
The mapping file data.frame used for upfront Qiime analyses and formatted according to Qiime specifications.
merging.file
The data.frame containing the alpha diversity, bacterial load, or relative abundance information that will be merged with the mapping file metadata.
map.sub.id
Name of the subject ID column found in the Qiime mapping file. Default is "SubjectID".
map.tmpt
Name of the time point column found in the Qiime mapping file. Default is "Time_point".
map.smpl.id
Name os the sample ID column found in the Qiime mapping file. Default is "SampleID".
sample.id.col
Desired name of the Sample ID column for the final merged data.frame. Default is "SampleID".
subject.id.col
Desired name of the Subject ID column for the final merged data.frame. Default is "SubjectID".
tmpt.id.col
Desired name of the Time Point column for the final merged data.frame. Default is "Time_point".
merge.smpl.id
Desired name of the sample ID column in the file to be merged with. This has no default.

Details

Package:
patPRO
Type:
Package
Version:
1.0.0
Date:
2015-09-18
License:
GPLv3
An overview of how to use the package, including the most important functions, is included in the supplemental R notebook patPROExampleWorkflow.html.

References

patPRO: An R package for the visualization of longitudinal microbiome data. Hannigan GD, Loesche MA, Hodkinson BP, Mehta S, Grice EA.

Examples

Run this code
library("patPRO")
data("PatProOTU",package="patPRO")
data("PatProMap",package="patPRO")
transTestRelAbund <- transposeRelAbund(PatProOTU)
mergedMapTransRA <- mergeMapMetaData(map.file=PatProMap, 
	merging.file=transTestRelAbund, 
	map.sub.id="SubjectID", 
	map.tmpt="Time_point", 
	map.smpl.id="SampleID", 
	sample.id.col="SampleID")

Run the code above in your browser using DataLab