Skip to main content
Topic: rector() function error troubleshoot (Read 102 times) previous topic - next topic

rector() function error troubleshoot

Hello everyone,

I have encountered an issue when using xcms to analyze qTOF data. The R version I m using is 3.5.1 and the xcms version I have been using is 3.4.4.

Below are the steps I have taken to get this error with rector()...
- First I converted the Agilent qTOF data using MSConvert to mzXML file
- Next I extracted the mzXML file as following:
xset <- xcmsSet (mzmlfiles,
                 method = 'centWave',
                 ppm = 20,
                 mzdiff = -0.001,
                 peakwidth = c(5, 30))
xset <- group(xset)
xset_retcor <- retcor(xset)

The first two steps were passed, this error shows up with the third step:
xset_rector <- group(xset_retcor)

Performing retention time correction using 12250 peak groups.
Error in if (any(rtdevsmorange/rtdevrange > 2)) warn.overcorrect <- TRUE :
  missing value where TRUE/FALSE needed

traceback() gives the following:
8: do_adjustRtime_peakGroups(peaks = peakmat, peakIndex = object@groupidx,
       rtime = rtcor, minFraction = minFr, extraPeaks = extra, smooth = smooth,
       span = span, family = family)
7: .local(object, ...)
6: retcor.peakgroups(object, ...)
5: retcor.peakgroups(object, ...)
4:, alist(object, ...))
3: .local(object, ...)
2: retcor(xset)
1: retcor(xset)

Not sure if I am providing enough info to troubleshoot the problem, would really appreciate any suggetion why this error could happen!!


Re: rector() function error troubleshoot

Reply #1
Here is an update to this topic - it seems that the steps in this question is a bit outdated...I eventually tried to use the most updated xcms package (3.10.2) and peak grouping worked fine with readMSData() and chromatogram()!!