correct_chem_formula: Correct chemical formulas

Description Usage Arguments Value Examples

View source: R/correct_chem_formula.R

Description

Orders elements in chemical formulas alphabetically and adds 1 for elements that occur only once.

Usage

1
correct_chem_formula(chem.forms, isotopes)

Arguments

chem.forms

Vector of character strings with chemical formulas.

isotopes

dataframe with stable isotopes (see isotopes)

Value

Vector of character strings with corrected chemical formulas

Examples

1
2
3
4
5
library(enviPat)
data("isotopes")

correct_chem_formula(chem.forms = c("C44H92NO6P", "C6H12O6"),
                     isotopes = isotopes)

szymczak-lab/preprocessHighResMS documentation built on Oct. 6, 2020, 12:50 a.m.