How to get MS spectrum from features extracted with findChromPeaks ?
1
1
Entering edit mode
@julienkermorvant-23634
Last seen 3.8 years ago

Hello,

I'm trying to create a GC-MS database of standard by using XCMS. I'm using findChromPeaks (with centWave method) to search for my standard peak followed by refineChromPeaks and groupChromPeaks.

I can get the value of each feature with featureValues, but I would like to get the mz (or mz range) corresponding to each of these features in order to build my standard spectrum.

Thank you in advance.

Best regards, Julien

xcms • 813 views
ADD COMMENT
2
Entering edit mode
Johannes Rainer ★ 2.0k
@johannes-rainer-6987
Last seen 15 days ago
Italy

Have a look at what featureDefinitions returns you - you will get a DataFrame. In columns "mzmed", "mzmin" and "mzmax" you'll have the median m/z value and the range (calculated from all chromatographic peaks assigned to that feature).

Alternatively, you could get the m/z of each individual feature in each individual file by using featureValues function with parameter value = "mz"". This parameter lets you choose which column from the chromPeaks matrix should be returned.

Hope this helps.

ADD COMMENT
0
Entering edit mode

Thank you Joahnnes.

That's exactly what I needed.

Best regards, Julien

ADD REPLY

Login before adding your answer.

Traffic: 984 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6