Main function to process the input MS1 mzML files. It accesses the files with mzR and processes them with RHermes internal functions. For each file a PL object is generated inside the object_data_PL slot.

processMS1(struct, files, labelled = FALSE)

# S4 method for RHermesExp,character
processMS1(struct, files, labelled = FALSE)

Arguments

struct

RHermesExp S4 object to update with the processed data. Important: The objects needs to have the experimental parameters already set before calling this function.

files

Character vector of all the paths to the files to be processed.

labelled

Logical, whether to check for all 13C isotopic signals. Defaults to FALSE

Value

An RHermesExp object with the processed PLs.

Examples

struct <- readRDS(system.file("extdata", "exampleObject.rds", package = "RHermes")) MS1file <- system.file("extdata", "MS1TestData.mzML", package = "RHermes") processMS1(struct, MS1file, FALSE) #For regular use
#> Preprocessing steps, calculating possible ionic formulas and isotopic distributions
#> Starting Envipat isotope distribution calculation:
#> done.
#>
#> Calculating isotopes given the instrumental resolution:
#> Starting file processing...
#> Now processing: C:/Users/Roger G/AppData/Local/Temp/Rtmp8WkHmm/temp_libpath367c63bb2640/RHermes/extdata/MS1TestData.mzML
#> This process can take quite a bit of time, depending on the processing power and RAM your computer has
#> Warning: data length is not a multiple of split variable
#> Experimental parameters info:
#> ppm error: 5
#> Mass resolution: 60000
#> Mass range: 80-1000
#> Noise cutoff value: 1000
#> Ionization mode: +
#> Number of compounds: 7
#> Number of unique formulas: 6
#> Number of adducts: 3
#> Adduct list: M+H, M+Na, M+K
#>
#> Number of processed MS1 files: 2
#> C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> C:/Users/Roger G/AppData/Local/Temp/Rtmp8WkHmm/temp_libpath367c63bb2640/RHermes/extdata/MS1TestData.mzML
#> [[1]]
#> Info about this PeakList:
#> Original filename: C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> Number of raw data points: 0
#> Number of PL points: 1142
#> Redundance quotient: (Number of redundancies per unique entry) 1
#> Number of scans 124
#> Average scan time: 0.318s
#> Labelled processing: FALSE
#> #> [[2]]
#> Info about this PeakList:
#> Original filename: C:/Users/Roger G/AppData/Local/Temp/Rtmp8WkHmm/temp_libpath367c63bb2640/RHermes/extdata/MS1TestData.mzML
#> Number of raw data points: 40040
#> Number of PL points: 1142
#> Redundance quotient: (Number of redundancies per unique entry) 1
#> Number of scans 124
#> Average scan time: 0.318s
#> Labelled processing: FALSE
#> #> [[1]]
#> Info about this SOI list:
#> Original file name: C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> Number of SOIs: 9
#> SOI parameters info:
#> Bins used:
#> binwidth minscan shift #> 1 5 0.3 0.0 #> 2 5 0.3 2.5
#> Max SOI length: 30
#> Min data point intensity: 1000
#> Blank substraction performed: FALSE
#> Blank filename: None
#> #> [[1]]
#> Info about this MS2Exp object:
#> Info about the IL:
#> IL entries: 3
#> SOI index: 1
#> Number of covered entries: 1
#> Number of superspectra: 7
#> Identified superspectra: 0
#>
#> Processing Timestamps ---------------------------------------
#> System info: Windows/10 x64/build 19041/LAPTOP-CFQ0D7GG/x86-64/Roger G/Roger G/Roger G
#> RHermes version: 0.99.0
#> Thu Mar 25 21:14:33 2021 - Added the hmdb formula database and an adduct list with charge 1 and multiplicity 1
#> Thu Mar 25 21:14:59 2021 - Started file processing into PL
#> Thu Mar 25 21:15:00 2021 - Ended file processing. The following files were successfully processed: C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> Thu Mar 25 21:15:04 2021 - Generated SOI list from C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> Thu Mar 25 21:18:50 2021 - Processed MS2Exp object 1 and generated superspectra but didn't perform matching
#> Sat Apr 10 23:42:50 2021 - Started file processing into PL
#> Sat Apr 10 23:43:33 2021 - Ended file processing. The following files were successfully processed: C:/Users/Roger G/AppData/Local/Temp/Rtmp8WkHmm/temp_libpath367c63bb2640/RHermes/extdata/MS1TestData.mzML
#>
processMS1(struct, MS1file, TRUE) #For labelled data
#> Preprocessing steps, calculating possible ionic formulas and isotopic distributions
#> Starting Envipat isotope distribution calculation:
#> done.
#>
#> Calculating isotopes given the instrumental resolution:
#> Starting file processing...
#> Now processing: C:/Users/Roger G/AppData/Local/Temp/Rtmp8WkHmm/temp_libpath367c63bb2640/RHermes/extdata/MS1TestData.mzML
#> This process can take quite a bit of time, depending on the processing power and RAM your computer has
#> Warning: data length is not a multiple of split variable
#> Experimental parameters info:
#> ppm error: 5
#> Mass resolution: 60000
#> Mass range: 80-1000
#> Noise cutoff value: 1000
#> Ionization mode: +
#> Number of compounds: 7
#> Number of unique formulas: 6
#> Number of adducts: 3
#> Adduct list: M+H, M+Na, M+K
#>
#> Number of processed MS1 files: 2
#> C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> C:/Users/Roger G/AppData/Local/Temp/Rtmp8WkHmm/temp_libpath367c63bb2640/RHermes/extdata/MS1TestData.mzML
#> [[1]]
#> Info about this PeakList:
#> Original filename: C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> Number of raw data points: 0
#> Number of PL points: 1142
#> Redundance quotient: (Number of redundancies per unique entry) 1
#> Number of scans 124
#> Average scan time: 0.318s
#> Labelled processing: FALSE
#> #> [[2]]
#> Info about this PeakList:
#> Original filename: C:/Users/Roger G/AppData/Local/Temp/Rtmp8WkHmm/temp_libpath367c63bb2640/RHermes/extdata/MS1TestData.mzML
#> Number of raw data points: 40040
#> Number of PL points: 1534
#> Redundance quotient: (Number of redundancies per unique entry) 1.23
#> Number of scans 124
#> Average scan time: 0.318s
#> Labelled processing: TRUE
#> #> [[1]]
#> Info about this SOI list:
#> Original file name: C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> Number of SOIs: 9
#> SOI parameters info:
#> Bins used:
#> binwidth minscan shift #> 1 5 0.3 0.0 #> 2 5 0.3 2.5
#> Max SOI length: 30
#> Min data point intensity: 1000
#> Blank substraction performed: FALSE
#> Blank filename: None
#> #> [[1]]
#> Info about this MS2Exp object:
#> Info about the IL:
#> IL entries: 3
#> SOI index: 1
#> Number of covered entries: 1
#> Number of superspectra: 7
#> Identified superspectra: 0
#>
#> Processing Timestamps ---------------------------------------
#> System info: Windows/10 x64/build 19041/LAPTOP-CFQ0D7GG/x86-64/Roger G/Roger G/Roger G
#> RHermes version: 0.99.0
#> Thu Mar 25 21:14:33 2021 - Added the hmdb formula database and an adduct list with charge 1 and multiplicity 1
#> Thu Mar 25 21:14:59 2021 - Started file processing into PL
#> Thu Mar 25 21:15:00 2021 - Ended file processing. The following files were successfully processed: C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> Thu Mar 25 21:15:04 2021 - Generated SOI list from C:/Users/Roger G/Documents/GitHub/RHermes/inst/extdata/MS1TestData.mzML
#> Thu Mar 25 21:18:50 2021 - Processed MS2Exp object 1 and generated superspectra but didn't perform matching
#> Sat Apr 10 23:43:55 2021 - Started file processing into PL
#> Sat Apr 10 23:44:40 2021 - Ended file processing. The following files were successfully processed: C:/Users/Roger G/AppData/Local/Temp/Rtmp8WkHmm/temp_libpath367c63bb2640/RHermes/extdata/MS1TestData.mzML
#>