.buildRecord.RmbSpectraSet {RMassBank} | R Documentation |
Takes a spectra block for a compound, as returned from
analyzeMsMs
, and an aggregated cleaned peak table, together
with a MassBank information block, as stored in the infolists and loaded via
loadInfolist
/readMbdata
and processes them to a
MassBank record
compileRecord(spec, mbdata, aggregated, additionalPeaks = NULL, retrieval="standard")
mbdata |
The information data block for the record header, as stored in
|
additionalPeaks |
If present, a table with additional peaks to add into the spectra.
As loaded with |
spec |
A |
aggregated |
An aggregated peak data table containing information about refiltered spectra etc. |
retrieval |
A value that determines whether the files should be handled either as "standard", if the compoundlist is complete, "tentative", if at least a formula is present or "unknown" if the only know thing is the m/z |
compileRecord
calls gatherCompound
to create blocks of
spectrum data, and finally fills in the record title and accession number,
renames the "internal ID" comment field and removes dummy fields.
Returns a MassBank record in list format: e.g.
list("ACCESSION" = "XX123456", "RECORD_TITLE" = "Cubane", ...,
"CH\$LINK" = list( "CAS" = "12-345-6", "CHEMSPIDER" = 1111, ...))
Michael Stravs
MassBank record format: http://www.massbank.jp/manuals/MassBankRecord_en.pdf
mbWorkflow
, addPeaks
,
gatherCompound
, toMassbank
# ## Not run: myspec <- w@spectra[[2]] # after having loaded an infolist: ## Not run: mbdata <- mbdata_relisted[[which(mbdata_archive\$id == as.numeric(myspec\$id))]] ## Not run: compiled <- compileRecord(myspec, mbdata, w@aggregated)