writeFeaturelist: Write feature information from list of 'MS2spectrum' objects

Description Usage Arguments Details Value Examples

View source: R/annotate.R

Description

writeFeaturelist uses featureList to generate a data.frame that contains feature ID, precurosur m/z and retention time for all features contained in a list of MS2spectrum objects as produced by extractMS2spectra and mergeSpecList and writes it to a csv file.

Usage

1
writeFeaturelist(featlist, filename = "pre_anno.csv")

Arguments

featlist

A list of MS2spectrum objects as produced by extractMS2spectra and mergeSpecList

filename

The desired file name of the csv file, default is "pre_anno.csv"

Details

Although originally designed for lists of MS2spectrum objects, the function also works with lists of pseudospectrum objects. In this case, NA is given for precursor m/z.

Value

A csv file that contains feature ID, precurosur m/z and retention time. The file has a header but no row names and is separated by ','.

Examples

1
2
3
4
5
load(file = system.file("extdata",
    "featlist.RData",
    package = "CluMSIDdata"))

writeFeaturelist(featlist, filename = "pre_anno.csv")

CluMSID documentation built on Nov. 8, 2020, 7:46 p.m.