library(data.table)
data <- data.table(
pepseq = c("DDREDMLVYQAK", "EAAENSLVAYK", "IEAELQDICNDVLELLDK"),
modification = c("-0.984016 (10), 15.994915 (13)", NA, "15.994915 (12)"),
Condition1 = c("A", "B", "B"),
Condition2 = c("C", "C", "D")
)
PTM_table <- data.table(
PTM_mass = c(-0.984016, 15.994915),
PTM_type = c("Amid", "Ox")
)
mod_column <- "modification"
seq_column <- "pepseq"
converted_data <- obtain_mod_mzIdenML(
data,
mod_column,
seq_column,
PTM_table,
PTM_annotation = TRUE,
PTM_mass_column = "PTM_mass"
)
Run the code above in your browser using DataLab