Re: Targeted Peak Picking
Reply #1 –
It seems you are generally able to write R scripts so here is just a small hint:
in your xcmsSet object you have the mass for each feature in:
xset@groups[,"mzmed"]
Simple make a loop that runs through each mass in your target list and mark which feature gives a hit.
Something like:
(abs(xset@groups[,"mzmed"]-mass[i])/mass[i])*1E6 < ppm_tol
would give you a logical vector for each target mass giving you the possible location of the target.
I didn't test this but that would be the general easy way.
If you only have a single sample you could use xset@peaks instead that have additional columns you could use for filtering:
into
integrated peak intensity
intb
baseline corrected integrated peak intensity
maxo
maximum peak intensity
sn
Signal/Noise ratio, defined as (maxo - baseline)/sd, where
maxo is the maximum peak intensity,
baseline the estimated baseline value and
sd the standard deviation of local chromatographic noise.