Skip to contents

Check if conversion to UniMod-format of identified modifications is successful.

Usage

get_unknown_mods(input_string, pattern_start, pattern_end)

Arguments

input_string

character column traceR_precursor as string.

pattern_start

character of software-dependent beginning of representation of modifications.

pattern_end

character of software-dependent end of representation of modifications.

Value

This function returns vector with logical values. This function is incorporated in the functions convert_precursor and convert_modified_peptides; used to generate the unknownMods column : if TRUE: a modification is detected, which is not converted to a standardized text.

Details

After conversion to standardized format by convert_precursor or convert_modified_peptides, entries with modifications are checked for a successful conversion. Conversion of modifications is currently only available for UniMod:35 and UniMod:4. Other modifications will not be converted to standardized format.

Author

Oliver Kardell

Examples

# Load libraries
library(dplyr)
library(stringr)
library(tibble)

# Generate data
data <- tibble::tibble(
  "traceR_precursor" = c("AACLLPK",
   "ALTDM(UniMod:35)PQM(UniMod:35)R2",
   "ALTDM(DummyModification)PQMK3")
)

# Unknown modifications present?
get_unknown_mods(input_string = data$traceR_precursor, pattern_start= "(", pattern_end = ")")
#> [1] FALSE FALSE  TRUE