MetReport(
inputData,
singleFile = FALSE,
AmdisReport,
ionLib,
save = TRUE,
output = "metab_data",
TimeWindow = 2.5,
Remove,
abundance = "recalculate",
folder)
When singleFile = FALSE, MetReport requires CDF files organised in a mainFolder with subfolders for each experimental condition. Metab's functions were developed to automatically identify the experimental condition associated with each sample. For this, the CDF files to be analysed by MetReport must be organised in subfolders according to their experimental condition, as follows: ------------------------ mainFolder ------Condition1 -----------Sample1_1.cdf -----------Sample1_2.cdf -----------Sample1_3.cdf ------Condition2 -----------Sample2_1.cdf -----------Sample2_2.cdf -----------Sample2_3.cdf ------Condition3 -----------Sample3_1.cdf -----------Sample3_2.cdf -----------Sample3_3.cdf --------------------------
One mainFolder containing one subfolder for each experimental condition. Each subfolder contains the CDF files associated with this specific experimental condition. Alternatively, all the CDF files can be placed in a single folder and MetReport will analyse every sample as belonging to the same experimental condition.
- Amdis report in batch mode. It is a text file containing the results for a batch of samples and can be obtained in AMDIS through: File > Batch Job > Create and Run Job.... Select the Analysis Type to be used, generally Simple, click on Generate Report and Report all hits. Click on Add.., select the files to be analysed, click on Save As..., select the folder where the report will be generated and a name for this report (any name you desire). Finally, click on Run. A new .TXT file with the name specified will be generated in the folder specified.
- ion library in the specific format required by Metab. The ion library is a data frame containing the name and the reference ion mass fragment to quantify each metabolite present in the mass spectral library used by AMDIS when generating the batch report. To facilitate the process, MetReport accepts the .msl file used by AMDIS. An AMDIS library is stored in two files, a file with extension .CID and a file with extension .msl. Metab requires only the .msl file.
To see an example of an ion library from AMDIS converted to the format required by Metab, simply enter the following code in the R console:
library(Metab)
data(exampleIonLib)
print(exampleIonLib)
When all the requirements described above are ready and available, MetReport can be applied. If an essential argument is missing, a dialog box will pop up allowing the user to point and click on the main folder to be analysed, the AMDIS report to be used or the ion library. Thus, MetReport can be applied by simply entering
MetReport()
at the R console. In this case, the user will be prompted to point to the required files while the arguments save, output, TimeWindow and Remove will receive their default values. The default value of save is TRUE, which indicates that the report generated by MetReport must be saved into a CSV file with the name specified in the argument output. The argument TimeWindow defines, in minutes, the accepted difference between expected and observed retention times to consider a true identification. Expected retention time is the retention time defined in the spectral library, while the observed retention time is the retention time where AMDIS actually identified each metabolite. For example, if TimeWindow = 0.5, every metabolite showing more than half minute difference between expected and observed retention times will be removed from the analysis. The argument Remove is used to remove specific compounds from the analysis. For example, if Remove = "Ethanol", every observation of Ethanol in the AMDIS report will not be considered in the analysis. It may receive as many names of metabolites as desired, for example, Remove = c("Ethanol", "Alanine", "Pyridine").
As a result, MetReport generates a data frame containing the metabolites identified in the first column and their abundances in the different samples analysed in the following columns. To see an example, enter the following code at the R console:
library(Metab)
data(exampleMetReport)
print(exampleMetReport)
htest
,
MetReportNames
,
normalizeByBiomass
,
normalizeByInternalStandard
,
removeFalsePositives
,
buildLib
library(Metab)
###### Load exampleAMDISReport ######
data(exampleAMDISReport)
###### Analyse a single file ########
test <- MetReport(
inputData = unzip(system.file("extdata/130513_REF_SOL2_2_50_50_1.CDF.zip", package = "Metab")),
singleFile = TRUE,
AmdisReport = exampleAMDISReport,
abundance = "Area",
save = FALSE)
###### Show results #################
print(test)
Run the code above in your browser using DataLab