output_MetaData: Printing metadata as CSV files for MetaboAnalystR.

Description Usage Arguments Value Examples

View source: R/formatting-functions.R

Description

This function prints the metabolite and sample metadata to CSV files.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
output_MetaData(mSetObj, Peak.list, Sample.df, Sample.data)

## S3 method for class 'pktable'
output_MetaData(mSetObj, Peak.list, Sample.df, Sample.data)

## S3 method for class 'mass_all'
output_MetaData(mSetObj, Peak.list, Sample.df, Sample.data)

## Default S3 method:
output_MetaData(mSetObj, Peak.list, Sample.df, Sample.data)

Arguments

mSetObj

NULL

Peak.list

data frame containing combined ion mode peaklist with ion mode duplicates removed.

Sample.df

data frame with class info as columns. Must contain a separate row entry for each unique sex/class combination. Must contain the columns 'Sex','Class','n','Endogenous'.

Sample.data

data frame with phenotype data as columns and a row for each study sample. First column must be a unique sample identifier with the header 'CT-ID'. Phenotype columns may vary, but must include two columns called 'Plate Number' and 'Plate Position' for determining run order.

Value

mSetObj

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
## Not run: 
library(LUMA)
file <- system.file("extdata","Sample_Class.txt", package = "LUMA") # is case sensitive on Linux
Sample.df <- read.table(file, header = TRUE, sep = "\t")
file2 <- system.file("extdata","Sample_Data.csv", package = "LUMA") # is case sensitive on Linux
Sample.data <- read.table(file2, header = TRUE, sep = ",")
Peak.list <- Peaklist_db$Peaklist_Normalized
mSetObj <- NULL
output_MetaData(mSetObj = mSetObj, Peak.list =
Peak.list, Sample.df = Sample.df, Sample.data = Sample.data)

## End(Not run)

USEPA/LUMA documentation built on Aug. 29, 2020, 1:40 p.m.