Reads mzXML files and extracts relevant MS2 spectra information.
read_mzxml(file, threads = 3, mode = c("inMemory", "onDisk"))A list containing processed MS2 spectra information for each provided mzXML file. Each element of the list contains two components:
info: A data frame with columns for the name (composed of m/z and retention time),
m/z, retention time, and file name.
spec: A data frame where each row represents a fragment ion peak,
with columns for m/z and intensity values.
# Locate the example mzXML file in the installed package
file_path <- system.file("extdata", "example.mzXML", package = "masstools")
# Then use it in your function
result <- read_mzxml(file_path)
#> Reading MS2 data...
#> Processing...