R/2_chemical_formula_funcitons.R
convert_precursor_mz2accurate_mass.Rd
This function computes the accurate mass from the given precursor m/z and adduct type. It uses specific rules to adjust the provided m/z based on the adduct type, and then calculates the accurate mass of the molecule.
convert_precursor_mz2accurate_mass(
precursor_mz = 805.559,
adduct = "(2M-2H+Na)-"
)
A numeric value representing the accurate mass of the molecule based on the precursor m/z and adduct type.
convert_precursor_mz2accurate_mass(805.559, "(2M-2H+Na)-")
#> [1] 826.5331
convert_precursor_mz2accurate_mass(805.559, "(M-H)-")
#> [1] 804.5512