Hello,
I am trying to use metaMS to analyse GC-MS data. On a test dataset I have already analysed manually, the runGC function detects around 1/3 of the peaks I found myself, which is not satisfactory at all. I am trying to figure out which stage of the work flow is limiting the overall sensitivity, so as to get an idea of which parameters I have to modify.
What I want to do is visualise the output of the peak picking stage. I expect something like a table giving for each sample and each m/z the retention times of all detected peaks. By comparing it with the output of runGC, I would then see if there are peaks that were detected at that stage but lost during pseudospectrum reconstruction or grouping of pseudospectra.
Here is what I tried. I run the peak picking function from metaMS package, using the recommended example settings.
>GCset <- peakDetection(cdffiles,settings = metaSetting(TSQXLS.GC, "PeakPicking"),convert2list = F, nSlaves = 2)
> GCset
$LC_11april2016_control
An "xcmsSet" object with 1 samples
Time range: 262-2240.4 seconds (4.4-37.3 minutes)
Mass range: 29.1-357.029 m/z
Peaks: 240 (about 240 per sample)
Peak Groups: 0
Sample classes: test_data_from_abioticvar
Peak picking was performed on MS1.
Profile settings: method = bin
step = 0.5
Memory usage: 0.146 MB
$LC_11april2016_H_Bra38
An "xcmsSet" object with 1 samples
...
From the metaMS manual, I understood that this command should produce a xcmsSet object. According to the xcms manual, xcmsSet objects are supposed to contain a slot "peaks", containing a matrix of peak data.
However, this is what I get when I try to call that particular slot:
> GCset$peaks NULL
The same happens when I run the equivalent function from xcms package:
> test=xcmsSet(cdffiles, method="matchedFilter",step=0.5,steps=2,mzdiff=0.5,fwhm=5,snthresh=2,max=500) > test An "xcmsSet" object with 24 samples Time range: 261.3-2240.7 seconds (4.4-37.3 minutes) Mass range: 29.1-358.0501 m/z Peaks: 7296 (about 304 per sample) Peak Groups: 0 Sample classes: test_data_from_abioticvar Peak picking was performed on MS1. Profile settings: method = bin step = 0.5 Memory usage: 3.52 MB > test$peaks NULL
Any idea how to visualise the output of peak picking?
Thank you in advance for your help
Lucie
Hi Ron,
thanks a lot for these details, it was really helpfull.
And indeed, all the tricks you suggested work for the output of the function xcmsSet, but not for that of peakDetection function.
I also found that the details can be obtained for single files using the findPeaks function, e.g.:
findPeaks.matchedFilter(xcmsRaw(file name))
All the best
Lucie