msn2xcms: Helper function to create a normal xcmsRaw from MSn data

Description Usage Arguments Value Examples

Description

Helper function to create a normal xcmsRaw from MSn data. Copy xrawMSn@env$msnmz and xrawMSn@env$msnintensities and all metadata from xrawMSn to xraw.

Usage

1
msn2xcms(xmsn)

Arguments

xmsn

Value

An xcmsRaw object, where the converted MSn data appears as normal MS1 data. This can be passed to findPeaks().

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.

## The function is currently defined as
function(xmsn) {
    x <- xmsn
                                        # BROKEN
    x@tic <- x@msnAcquisitionNum
                                        # Fake time in secs
    x@scantime <- x@msnRt
    x@acquisitionNum <- x@msnAcquisitionNum
    x@scanindex <- x@msnScanindex

    x@env$mz <- x@env$msnMz
    x@env$intensity <- x@env$msnIntensity
    invisible(x)
  }

sneumann/MetShot documentation built on May 30, 2019, 5:05 a.m.