library(CAMERA)
#Single sample
file <- system.file('mzdata/MM14.mzdata', package = "CAMERA")
xs <- xcmsSet(file, method="centWave", ppm=30, peakwidth=c(5,10))
an <- xsAnnotate(xs)
an <- groupFWHM(an)
#Multiple sample
library(faahKO)
xs <- group(faahko)
#With specific selected sample
xs.anno <- xsAnnotate(xs, sample=1)
xs.group <- groupFWHM(xs.anno)
#With automatic selection
xs.anno.auto <- xsAnnotate(xs)
xs.group.auto <- groupFWHM(xs.anno.auto)
Run the code above in your browser using DataLab