Write a spectrum file in MSFinder format.
writeMSF(x, ...)# S3 method for default
writeMSF(
x,
precursormz,
precursortype = "[M+H]+",
name = "unknown",
ionmode = "Positive",
ms1spec = NULL,
retentiontime = NULL,
outfile = NULL,
...
)
# S3 method for findMAIN
writeMSF(x, rank = 1, ms2spec = NULL, outfile = NULL, ...)
Write spectrum to MAT file for evaluation in MSFinder
A matrix, 'findMAIN' or other object for which methods are defined.
Arguments passed to method writeMSF.findMAIN.
Precursor m/z
Precursor type
Give the spectrum a name
"Positive" or "Negative"
(Optional) MS1 spectrum.
(Optional) retention time of the spectrum that will be used by MSFinder for refined prediction.
Name of MAT file, or NULL
for 'stdout'.
Which rank from 'findMAIN' should be exported
If available you may provide the according MS2 spectrum
In the default case 'x' can be a matrix or data frame, where the first two columns are assumed to contain the 'mz' and 'intensity' values, respectively. Further arguments 'precursormz' and 'precursortype' are required in this case. Otherwise 'x' can be of class findMAIN
.