#single sample
library(CAMERA)
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)
an <- findIsotopes(an)
isolist <- getIsotopeCluster(an)
isolist[[10]] #get IsotopeCluster 10
#multiple sample
library(faahKO)
xs <- group(faahko)
xs <- fillPeaks(xs)
an <- xsAnnotate(xs)
an <- groupFWHM(an)
an <- findIsotopes(an)
isolist <- getIsotopeCluster(an)
#Select from multiple samples
isolist <- getIsotopeCluster(an, sampleIndex=c(1,2,5))
##Interaction with Rdisop
## Not run:
# library(Rdisop)
# isotopes.decomposed <- lapply(isolist,function(x) {
# decomposeIsotopes(x$peaks[,1],x$peaks[,2],z=x$charge);
# }) #decomposed isotope cluster, filter steps are recommended
# ## End(Not run)
Run the code above in your browser using DataLab