View source: R/combinePeaksWithSameFormula.R
combinePeaksWithSameFormula | R Documentation |
If multiple peaks are mapped to the same mass formula it can cause problems
or inconsistencies when mapping data to a biological database. The
combinePeaksWithSameFormula
combines rows of ftmsObj$e_data
that map to the same mass formula:
* If data is abundance: values are summed for each column
* If data is log scale: data are converted to abundance, then values are summed for each columns and re-transformed to the original scale
* If data is presence/absence: 'or' function is applied to each column (if at least one peak is observed, the peak is denoted as observed)
combinePeaksWithSameFormula(ftmsObj)
ftmsObj |
data of type |
It is recommended to call the combinePeaksWithSameFormula
function
before using mapPeaksToCompounds
.
peakData
object where now two rows of e_data
map to the same mass formula
new_data <- combinePeaksWithSameFormula(exampleProcessedPeakData)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.