diff --git a/R/SpectrumMethods.R b/R/SpectrumMethods.R index 1ada2e5..853c2a0 100644 --- a/R/SpectrumMethods.R +++ b/R/SpectrumMethods.R @@ -228,7 +228,11 @@ setMethod("normalize", c("RmbSpectrum2List"), function(object, ...) }) - +#' Add a mass shift to a spectrum +#' +#' @param e1 a `MSnbase::Spectrum` object +#' @param e2 a numeric mass shift +#' setMethod("+", c("Spectrum", "numeric"), function(e1, e2) { e1@mz <- e1@mz + e2 @@ -236,13 +240,26 @@ setMethod("+", c("Spectrum", "numeric"), function(e1, e2) }) - +#' Add a negative mass shift to a spectrum +#' +#' @param e1 a `MSnbase::Spectrum` object +#' @param e2 a numeric mass shift +#' setMethod("-", c("Spectrum", "numeric"), function(e1, e2) { e1@mz <- e1@mz - e2 return(e1) }) +#' Add a mass shift to a list of spectra +#' +#' Shifts both `parent` and `children` spectra of the `RmbSpectraSet` by the +#' same mass. +#' +#' @param e1 a `RmbSpectraSet` object containing zero or more `children` spectra +#' and a `parent` spectrum +#' @param e2 a numeric mass shift +#' setMethod("+", c("RmbSpectraSet", "ANY"), function(e1, e2) { e1@parent <- e1@parent + e2 @@ -251,6 +268,15 @@ setMethod("+", c("RmbSpectraSet", "ANY"), function(e1, e2) e1 }) +#' Add a negative mass shift to a list of spectra +#' +#' Shifts both `parent` and `children` spectra of the `RmbSpectraSet` by the +#' same mass. +#' +#' @param e1 a `RmbSpectraSet` object containing zero or more `children` spectra +#' and a `parent` spectrum +#' @param e2 a numeric mass shift +#' setMethod("-", c("RmbSpectraSet", "ANY"), function(e1, e2) { e1@parent <- e1@parent - e2 @@ -260,6 +286,13 @@ setMethod("-", c("RmbSpectraSet", "ANY"), function(e1, e2) }) +#' Add a mass shift to a list of spectra +#' +#' Shifts all spectra in a `RmbSpectrum2List` by the same mass +#' +#' @param e1 a `RmbSpectrum2List` object containing zero or more `RmbSpectrum2` spectra +#' @param e2 a numeric mass shift +#' setMethod("+", c("RmbSpectrum2List", "ANY"), function(e1, e2) { for(n in seq_len(length(e1))) @@ -268,6 +301,13 @@ setMethod("+", c("RmbSpectrum2List", "ANY"), function(e1, e2) }) +#' Add a negative mass shift to a list of spectra +#' +#' Shifts all spectra in a `RmbSpectrum2List` by the same mass +#' +#' @param e1 a `RmbSpectrum2List` object containing zero or more `RmbSpectrum2` spectra +#' @param e2 a numeric mass shift +#' setMethod("-", c("RmbSpectrum2List", "ANY"), function(e1, e2) { for(n in seq_len(length(e1))) diff --git a/R/buildRecord.R b/R/buildRecord.R index f8cedc1..ab723ea 100644 --- a/R/buildRecord.R +++ b/R/buildRecord.R @@ -29,6 +29,9 @@ #' @param mbdata list #' The information data block for the record header, as stored in #' \code{mbdata_relisted} after loading an infolist. +#' @param analyticalInfo A list containing information for the `AC$` section of +#' a MassBank record, with elements `ai, ac_lc, ac_ms` for general, LC and MS +#' info respectively. #' @param additionalPeaks data.frame #' If present, a table with additional peaks to add into the spectra. #' As loaded with \code{\link{addPeaks}}. diff --git a/R/createMassBank.R b/R/createMassBank.R index dcbfebe..5e69a9d 100755 --- a/R/createMassBank.R +++ b/R/createMassBank.R @@ -1488,12 +1488,25 @@ annotator.default <- function(annotation, formulaTag) #' @export setGeneric("toMassbank", function(o, ...) standardGeneric("toMassbank")) + +#' Convert spectra from a `RmbSpectraSet` object to MassBank records +#' +#' @param addAnnotation `logical`, whether to add peak annotations (putative formulas) to the record. +#' +#' @returns A list of character vectors with the MassBank records +#' #' @export setMethod("toMassbank", "RmbSpectraSet", function(o, addAnnotation = getOption("RMassBank")$add_annotation) { lapply(o@children, function(s) toMassbank(s, addAnnotation)) }) +#' Convert a `RmbSpectrum2` object to a MassBank record +#' +#' @param addAnnotation `logical`, whether to add peak annotations (putative formulas) to the record. +#' +#' @returns A character vector with the MassBank record +#' #' @export setMethod("toMassbank", "RmbSpectrum2", function(o, addAnnotation = getOption("RMassBank")$add_annotation) { diff --git a/R/leMsMs.r b/R/leMsMs.r index 3fc3f87..02c2280 100755 --- a/R/leMsMs.r +++ b/R/leMsMs.r @@ -57,6 +57,8 @@ archiveResults <- function(w, fileName, settings = getOption("RMassBank")) #' used to extract peaks. MassBank will read existing records, #' so that e.g. a recalibration can be performed, and "peaklist" #' just requires a CSV with two columns and the column header "mz", "int". +#' @param filetable If including step 1 (data extraction), a `filetable` argument +#' to be passed to \code{\link{msmsRead}}. #' @param findPeaksArgs A list of arguments that will be handed to the xcms-method findPeaks via do.call #' @param plots A parameter that determines whether the spectra should be plotted or not (This parameter is only used for the xcms-method) #' @param precursorscan.cf Whether to fill precursor scans. To be used with files which for @@ -1292,7 +1294,7 @@ setMethod("cleanElnoise", c("RmbSpectraSet", noise="numeric", width="numeric"), #' sp@@good <- c(TRUE, TRUE, TRUE, FALSE, FALSE) #' sp@@precursorMz <- 600 #' sp_checked <- problematicPeaks(sp) -#' stopifnot(sum(getData(sp_checked)$problematicPeaks) == 2)) +#' stopifnot(sum(getData(sp_checked)$problematicPeaks) == 2) #' @export problematicPeaks <- function(sp) { @@ -1330,7 +1332,6 @@ problematicPeaks <- function(sp) #' Generates a list of intense unmatched peaks for further review (the "failpeak list") and exports it if the archive name is given. #' #' @param w \code{msmsWorkspace} to analyze. -#' @param mode Processing mode (pH etc) #' @param archivename Base name of the archive to write to (for "abc" the exported failpeaks list will be "abc_Failpeaks.csv"). #' if the compoundlist is complete, "tentative", if at least a formula is present or "unknown" #' if the only know thing is the m/z @@ -1764,6 +1765,7 @@ filterPeakSatellites <- function(peaks, filterSettings = getOption("RMassBank")$ #' @param progressbar The progress bar callback to use. Only needed for specialized #' applications. Cf. the documentation of \code{\link{progressBarHook}} for usage. #' @param filterSettings Settings for filtering data. Refer to\code{\link{analyzeMsMs}} for settings. +#' @param mode for `reanalyzeFailpeak`, the `mode` (adduct) of the analyzed spectrum. #' @return The aggregate data frame extended by the columns: #' #' \item{reanalyzed.???}{If reanalysis (step 7) has already been processed: matching values from the reanalyzed peaks} #' \item{matchedReanalysis}{Whether reanalysis has matched (\code{TRUE}), not matched(\code{FALSE}) or has not been conducted for the peak(\code{NA}).} @@ -2150,7 +2152,7 @@ filterMultiplicity <- function(w, archivename=NA, mode="pH", recalcBest = TRUE, #' to the \code{spec$peaksMatched} table. However, only minimal information needed for #' recalibration is returned. #' -#' @usage recalibrate.addMS1data(spec,mode="pH", recalibrateMS1Window = +#' @usage recalibrate.addMS1data(spec, recalibrateMS1Window = #' getOption("RMassBank")$recalibrateMS1Window) #' @param spec A \code{msmsWorkspace} or \code{RmbSpectraSetList} containing spectra for which MS1 "peaks" should be "constructed". #' @param recalibrateMS1Window Window width to look for MS1 peaks to recalibrate (in ppm). diff --git a/R/leMsmsRaw.R b/R/leMsmsRaw.R index 186119e..21fe05c 100644 --- a/R/leMsmsRaw.R +++ b/R/leMsmsRaw.R @@ -29,18 +29,6 @@ NULL # This is required so that roxygen knows where the first manpage starts #' #' @note \code{findMsMs.direct} is deactivated #' -## # @usage findMsMsHR(fileName, cpdID, mode="pH",confirmMode =0, useRtLimit = TRUE, -## # ppmFine = getOption("RMassBank")$findMsMsRawSettings$ppmFine, -## # mzCoarse = getOption("RMassBank")$findMsMsRawSettings$mzCoarse, -## # fillPrecursorScan = getOption("RMassBank")$findMsMsRawSettings$fillPrecursorScan, -## # rtMargin = getOption("RMassBank")$rtMargin, -## # deprofile = getOption("RMassBank")$deprofile, -## # headerCache = NULL, -## # peaksCache = NULL) -## # -## # findMsMsHR.mass(msRaw, mz, limit.coarse, limit.fine, rtLimits = NA, maxCount = NA, -## # headerCache = NULL, fillPrecursorScan = FALSE, -## # deprofile = getOption("RMassBank")$deprofile, peaksCache = NULL, cpdID = NA) #' #' #' @aliases findMsMsHR.mass findMsMsHR @@ -85,6 +73,10 @@ NULL # This is required so that roxygen knows where the first manpage starts #' used (cf. \code{\link{deprofile}}) #' @param diaWindows A data frame with columns \code{precursorMz}, \code{mzMin}, \code{mzMax} which specifies the precursor and #' window size of each window for DIA acquisition. +#' @param enforcePolarity If TRUE, scans are filtered for the given `mode`'s polarity when +#' finding the target spectrum. +#' @param polarity If set (for ?findMsMsHR.mass), scans are filtered for the given `mode`'s polarity when +#' finding the target spectrum. #' @return An \code{RmbSpectraSet} (for \code{findMsMsHR}). Contains parent MS1 spectrum (\code{@@parent}), a block of dependent MS2 spectra ((\code{@@children}) #' and some metadata (\code{id},\code{mz},\code{name},\code{mode} in which the spectrum was acquired. #' @@ -106,7 +98,9 @@ NULL # This is required so that roxygen knows where the first manpage starts #' @author Michael A. Stravs, Eawag #' @seealso findEIC #' @export -findMsMsHR <- function(fileName = NULL, msRaw = NULL, cpdID, mode="pH",confirmMode =0, useRtLimit = TRUE, +findMsMsHR <- function( + fileName = NULL, msRaw = NULL, cpdID, mode="pH", + confirmMode = 0, useRtLimit = TRUE, ppmFine = getOption("RMassBank")$findMsMsRawSettings$ppmFine, mzCoarse = getOption("RMassBank")$findMsMsRawSettings$mzCoarse, fillPrecursorScan = getOption("RMassBank")$findMsMsRawSettings$fillPrecursorScan, @@ -969,6 +963,15 @@ read.msp <- function(file){ #' freshly from \code{msRaw} for every compound. #' @param peaksCache If present, the complete output of \code{mzR::peaks(msRaw)}. This speeds up the lookup #' if multiple compounds should be searched in the same file. +#' @param polarity If a value is given, scans are filtered to this polarity before EIC +#' extraction. Valid values are 1 for positive, 0 for negative (according to mzR), or a RMassBank +#' `mode` (e.g. `pH, pM, mH...`) from which the polarity can be derived. +#' @param msLevel Which MS level to target for EIC extraction. By default this is 1; level 2 +#' can be used to extract the EIC of fragments for a specific precursor or to extract EICs +#' from DIA data. +#' @param precursor Which precursor to target for EIC extraction. If `NULL`, the scans are not +#' filtered by precursor. Use this only for `msLevel != 1`. If a `precursor` filter is set for +#' `msLevel == 1`, all scans will be filtered out. #' @param floatingRecalibration #' A fitting function that \code{predict()}s a mass shift based on the retention time. Can be used #' if a lockmass calibration is known (however you have to build the calibration yourself.) diff --git a/R/log_wrapper.R b/R/log_wrapper.R index 95cfc5d..60cdb88 100644 --- a/R/log_wrapper.R +++ b/R/log_wrapper.R @@ -4,6 +4,9 @@ NULL #' Pass arguments to logger::log_info using custom RMassBank-logging settings #' #' The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} +#' +#' @param ... The log message, as for `logger::log_...` functions +#' #' @seealso logger::log_info #' @author pstahlhofen #' @export @@ -14,6 +17,9 @@ rmb_log_info <- function(...) { #' Pass arguments to logger::log_trace using custom RMassBank-logging settings #' #' The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} +#' +#' @param ... The log message, as for `logger::log_...` functions +#' #' @seealso logger::log_trace #' @author pstahlhofen #' @export @@ -24,6 +30,9 @@ rmb_log_trace <- function(...) { #' Pass arguments to logger::log_debug using custom RMassBank-logging settings #' #' The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} +#' +#' @param ... The log message, as for `logger::log_...` functions +#' #' @seealso logger::log_debug #' @author pstahlhofen #' @export @@ -34,6 +43,9 @@ rmb_log_debug <- function(...) { #' Pass arguments to logger::log_warn using custom RMassBank-logging settings #' #' The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} +#' +#' @param ... The log message, as for `logger::log_...` functions +#' #' @seealso logger::log_warn #' @author pstahlhofen #' @export @@ -44,6 +56,9 @@ rmb_log_warn <- function(...) { #' Pass arguments to logger::log_success using custom RMassBank-logging settings #' #' The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} +#' +#' @param ... The log message, as for `logger::log_...` functions +#' #' @seealso logger::log_success #' @author pstahlhofen #' @export @@ -54,6 +69,9 @@ rmb_log_success <- function(...) { #' Pass arguments to logger::log_error using custom RMassBank-logging settings #' #' The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} +#' +#' @param ... The log message, as for `logger::log_...` functions +#' #' @seealso logger::log_error #' @author pstahlhofen #' @export @@ -64,6 +82,9 @@ rmb_log_error <- function(...) { #' Pass arguments to logger::log_fatal using custom RMassBank-logging settings #' #' The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} +#' +#' @param ... The log message, as for `logger::log_...` functions +#' #' @seealso logger::log_fatal #' @author pstahlhofen #' @export diff --git a/man/RmbSpectraSet-ANY-method.Rd b/man/RmbSpectraSet-ANY-method.Rd new file mode 100644 index 0000000..cf46418 --- /dev/null +++ b/man/RmbSpectraSet-ANY-method.Rd @@ -0,0 +1,18 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/SpectrumMethods.R +\name{-,RmbSpectraSet,ANY-method} +\alias{-,RmbSpectraSet,ANY-method} +\title{Add a negative mass shift to a list of spectra} +\usage{ +\S4method{-}{RmbSpectraSet,ANY}(e1, e2) +} +\arguments{ +\item{e1}{a `RmbSpectraSet` object containing zero or more `children` spectra +and a `parent` spectrum} + +\item{e2}{a numeric mass shift} +} +\description{ +Shifts both `parent` and `children` spectra of the `RmbSpectraSet` by the +same mass. +} diff --git a/man/RmbSpectrum2List-ANY-method.Rd b/man/RmbSpectrum2List-ANY-method.Rd new file mode 100644 index 0000000..c9cd8fa --- /dev/null +++ b/man/RmbSpectrum2List-ANY-method.Rd @@ -0,0 +1,16 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/SpectrumMethods.R +\name{-,RmbSpectrum2List,ANY-method} +\alias{-,RmbSpectrum2List,ANY-method} +\title{Add a negative mass shift to a list of spectra} +\usage{ +\S4method{-}{RmbSpectrum2List,ANY}(e1, e2) +} +\arguments{ +\item{e1}{a `RmbSpectrum2List` object containing zero or more `RmbSpectrum2` spectra} + +\item{e2}{a numeric mass shift} +} +\description{ +Shifts all spectra in a `RmbSpectrum2List` by the same mass +} diff --git a/man/Spectrum-numeric-method.Rd b/man/Spectrum-numeric-method.Rd new file mode 100644 index 0000000..8afd098 --- /dev/null +++ b/man/Spectrum-numeric-method.Rd @@ -0,0 +1,16 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/SpectrumMethods.R +\name{-,Spectrum,numeric-method} +\alias{-,Spectrum,numeric-method} +\title{Add a negative mass shift to a spectrum} +\usage{ +\S4method{-}{Spectrum,numeric}(e1, e2) +} +\arguments{ +\item{e1}{a `MSnbase::Spectrum` object} + +\item{e2}{a numeric mass shift} +} +\description{ +Add a negative mass shift to a spectrum +} diff --git a/man/buildRecord.Rd b/man/buildRecord.Rd index 4c43316..8b31826 100644 --- a/man/buildRecord.Rd +++ b/man/buildRecord.Rd @@ -36,6 +36,10 @@ In case o is an \code{RmbSpectrum2}, this represents the \code{RmbSpectraSet} it The information data block for the record header, as stored in \code{mbdata_relisted} after loading an infolist.} +\item{analyticalInfo}{A list containing information for the `AC$` section of +a MassBank record, with elements `ai, ac_lc, ac_ms` for general, LC and MS +info respectively.} + \item{additionalPeaks}{data.frame If present, a table with additional peaks to add into the spectra. As loaded with \code{\link{addPeaks}}.} diff --git a/man/findEIC.Rd b/man/findEIC.Rd index 63a07e7..f5405b4 100755 --- a/man/findEIC.Rd +++ b/man/findEIC.Rd @@ -39,6 +39,18 @@ if a lockmass calibration is known (however you have to build the calibration yo \item{peaksCache}{If present, the complete output of \code{mzR::peaks(msRaw)}. This speeds up the lookup if multiple compounds should be searched in the same file.} + +\item{polarity}{If a value is given, scans are filtered to this polarity before EIC +extraction. Valid values are 1 for positive, 0 for negative (according to mzR), or a RMassBank +`mode` (e.g. `pH, pM, mH...`) from which the polarity can be derived.} + +\item{msLevel}{Which MS level to target for EIC extraction. By default this is 1; level 2 +can be used to extract the EIC of fragments for a specific precursor or to extract EICs +from DIA data.} + +\item{precursor}{Which precursor to target for EIC extraction. If `NULL`, the scans are not +filtered by precursor. Use this only for `msLevel != 1`. If a `precursor` filter is set for +`msLevel == 1`, all scans will be filtered out.} } \value{ A \code{[rt, intensity, scan]} matrix (\code{scan} being the scan number.) diff --git a/man/findMsMsHR.Rd b/man/findMsMsHR.Rd index 9afd5d8..f51fd95 100755 --- a/man/findMsMsHR.Rd +++ b/man/findMsMsHR.Rd @@ -80,6 +80,9 @@ freshly from \code{msRaw} for every compound.} \item{peaksCache}{If present, the complete output of \code{mzR::peaks(msRaw)}. This speeds up the lookup if multiple compounds should be searched in the same file.} +\item{enforcePolarity}{If TRUE, scans are filtered for the given `mode`'s polarity when +finding the target spectrum.} + \item{diaWindows}{A data frame with columns \code{precursorMz}, \code{mzMin}, \code{mzMax} which specifies the precursor and window size of each window for DIA acquisition.} @@ -99,6 +102,9 @@ when locating the MS2 scans.} \item{maxCount}{The maximal number of spectra groups to return. One spectra group consists of all data-dependent scans from the same precursor whose precursor mass matches the specified search mass.} + +\item{polarity}{If set (for ?findMsMsHR.mass), scans are filtered for the given `mode`'s polarity when +finding the target spectrum.} } \value{ An \code{RmbSpectraSet} (for \code{findMsMsHR}). Contains parent MS1 spectrum (\code{@parent}), a block of dependent MS2 spectra ((\code{@children}) diff --git a/man/msmsWorkflow.Rd b/man/msmsWorkflow.Rd index 8f20870..0d4a3ec 100755 --- a/man/msmsWorkflow.Rd +++ b/man/msmsWorkflow.Rd @@ -50,6 +50,9 @@ used to extract peaks. MassBank will read existing records, so that e.g. a recalibration can be performed, and "peaklist" just requires a CSV with two columns and the column header "mz", "int".} +\item{filetable}{If including step 1 (data extraction), a `filetable` argument +to be passed to \code{\link{msmsRead}}.} + \item{findPeaksArgs}{A list of arguments that will be handed to the xcms-method findPeaks via do.call} \item{plots}{A parameter that determines whether the spectra should be plotted or not (This parameter is only used for the xcms-method)} diff --git a/man/plus-RmbSpectraSet-ANY-method.Rd b/man/plus-RmbSpectraSet-ANY-method.Rd new file mode 100644 index 0000000..b01526e --- /dev/null +++ b/man/plus-RmbSpectraSet-ANY-method.Rd @@ -0,0 +1,18 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/SpectrumMethods.R +\name{+,RmbSpectraSet,ANY-method} +\alias{+,RmbSpectraSet,ANY-method} +\title{Add a mass shift to a list of spectra} +\usage{ +\S4method{+}{RmbSpectraSet,ANY}(e1, e2) +} +\arguments{ +\item{e1}{a `RmbSpectraSet` object containing zero or more `children` spectra +and a `parent` spectrum} + +\item{e2}{a numeric mass shift} +} +\description{ +Shifts both `parent` and `children` spectra of the `RmbSpectraSet` by the +same mass. +} diff --git a/man/plus-RmbSpectrum2List-ANY-method.Rd b/man/plus-RmbSpectrum2List-ANY-method.Rd new file mode 100644 index 0000000..9890c96 --- /dev/null +++ b/man/plus-RmbSpectrum2List-ANY-method.Rd @@ -0,0 +1,16 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/SpectrumMethods.R +\name{+,RmbSpectrum2List,ANY-method} +\alias{+,RmbSpectrum2List,ANY-method} +\title{Add a mass shift to a list of spectra} +\usage{ +\S4method{+}{RmbSpectrum2List,ANY}(e1, e2) +} +\arguments{ +\item{e1}{a `RmbSpectrum2List` object containing zero or more `RmbSpectrum2` spectra} + +\item{e2}{a numeric mass shift} +} +\description{ +Shifts all spectra in a `RmbSpectrum2List` by the same mass +} diff --git a/man/plus-Spectrum-numeric-method.Rd b/man/plus-Spectrum-numeric-method.Rd new file mode 100644 index 0000000..1c3cc21 --- /dev/null +++ b/man/plus-Spectrum-numeric-method.Rd @@ -0,0 +1,16 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/SpectrumMethods.R +\name{+,Spectrum,numeric-method} +\alias{+,Spectrum,numeric-method} +\title{Add a mass shift to a spectrum} +\usage{ +\S4method{+}{Spectrum,numeric}(e1, e2) +} +\arguments{ +\item{e1}{a `MSnbase::Spectrum` object} + +\item{e2}{a numeric mass shift} +} +\description{ +Add a mass shift to a spectrum +} diff --git a/man/problematicPeaks.Rd b/man/problematicPeaks.Rd index f93fcf6..b1f23dc 100755 --- a/man/problematicPeaks.Rd +++ b/man/problematicPeaks.Rd @@ -33,7 +33,7 @@ property(sp, "mzFound", addNew=TRUE) <- sp@mz sp@good <- c(TRUE, TRUE, TRUE, FALSE, FALSE) sp@precursorMz <- 600 sp_checked <- problematicPeaks(sp) -stopifnot(sum(getData(sp_checked)$problematicPeaks) == 2)) +stopifnot(sum(getData(sp_checked)$problematicPeaks) == 2) } \seealso{ \code{\link{msmsWorkflow}} diff --git a/man/processProblematicPeaks.Rd b/man/processProblematicPeaks.Rd index e0cffbd..321fb29 100644 --- a/man/processProblematicPeaks.Rd +++ b/man/processProblematicPeaks.Rd @@ -12,8 +12,6 @@ processProblematicPeaks(w, archivename = NA) \item{archivename}{Base name of the archive to write to (for "abc" the exported failpeaks list will be "abc_Failpeaks.csv"). if the compoundlist is complete, "tentative", if at least a formula is present or "unknown" if the only know thing is the m/z} - -\item{mode}{Processing mode (pH etc)} } \value{ Returns the aggregate data.frame with added column "\code{problematic}" (logical) which marks peaks which match the problematic criteria diff --git a/man/reanalyzeFailpeaks.Rd b/man/reanalyzeFailpeaks.Rd index 9d3f99c..e8ad198 100755 --- a/man/reanalyzeFailpeaks.Rd +++ b/man/reanalyzeFailpeaks.Rd @@ -30,6 +30,8 @@ indicator)} \item{pb}{A progressbar object to display progress on, as passed by \code{reanalyzeFailpeaks} to \code{reanalyzeFailpeak}. No progress is displayed if NULL.} + +\item{mode}{for `reanalyzeFailpeak`, the `mode` (adduct) of the analyzed spectrum.} } \value{ The aggregate data frame extended by the columns: diff --git a/man/recalibrate.addMS1data.Rd b/man/recalibrate.addMS1data.Rd index 07ff7f2..ec8f0db 100755 --- a/man/recalibrate.addMS1data.Rd +++ b/man/recalibrate.addMS1data.Rd @@ -4,7 +4,7 @@ \alias{recalibrate.addMS1data} \title{Return MS1 peaks to be used for recalibration} \usage{ -recalibrate.addMS1data(spec,mode="pH", recalibrateMS1Window = +recalibrate.addMS1data(spec, recalibrateMS1Window = getOption("RMassBank")$recalibrateMS1Window) } \arguments{ diff --git a/man/rmb_log_debug.Rd b/man/rmb_log_debug.Rd index f348ec5..3429d02 100644 --- a/man/rmb_log_debug.Rd +++ b/man/rmb_log_debug.Rd @@ -6,6 +6,9 @@ \usage{ rmb_log_debug(...) } +\arguments{ +\item{...}{The log message, as for `logger::log_...` functions} +} \description{ The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} } diff --git a/man/rmb_log_error.Rd b/man/rmb_log_error.Rd index 1a53ca9..281193f 100644 --- a/man/rmb_log_error.Rd +++ b/man/rmb_log_error.Rd @@ -6,6 +6,9 @@ \usage{ rmb_log_error(...) } +\arguments{ +\item{...}{The log message, as for `logger::log_...` functions} +} \description{ The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} } diff --git a/man/rmb_log_fatal.Rd b/man/rmb_log_fatal.Rd index 7738f8e..828c445 100644 --- a/man/rmb_log_fatal.Rd +++ b/man/rmb_log_fatal.Rd @@ -6,6 +6,9 @@ \usage{ rmb_log_fatal(...) } +\arguments{ +\item{...}{The log message, as for `logger::log_...` functions} +} \description{ The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} } diff --git a/man/rmb_log_info.Rd b/man/rmb_log_info.Rd index 7e06e64..1ece315 100644 --- a/man/rmb_log_info.Rd +++ b/man/rmb_log_info.Rd @@ -6,6 +6,9 @@ \usage{ rmb_log_info(...) } +\arguments{ +\item{...}{The log message, as for `logger::log_...` functions} +} \description{ The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} } diff --git a/man/rmb_log_success.Rd b/man/rmb_log_success.Rd index 3286519..c7fe7e6 100644 --- a/man/rmb_log_success.Rd +++ b/man/rmb_log_success.Rd @@ -6,6 +6,9 @@ \usage{ rmb_log_success(...) } +\arguments{ +\item{...}{The log message, as for `logger::log_...` functions} +} \description{ The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} } diff --git a/man/rmb_log_trace.Rd b/man/rmb_log_trace.Rd index fa0a8da..4bc51e9 100644 --- a/man/rmb_log_trace.Rd +++ b/man/rmb_log_trace.Rd @@ -6,6 +6,9 @@ \usage{ rmb_log_trace(...) } +\arguments{ +\item{...}{The log message, as for `logger::log_...` functions} +} \description{ The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} } diff --git a/man/rmb_log_warn.Rd b/man/rmb_log_warn.Rd index 7beff84..e3b41f2 100644 --- a/man/rmb_log_warn.Rd +++ b/man/rmb_log_warn.Rd @@ -6,6 +6,9 @@ \usage{ rmb_log_warn(...) } +\arguments{ +\item{...}{The log message, as for `logger::log_...` functions} +} \description{ The logging file to be used can be specified by the user in the \code{logging_file} field of \code{settings.ini} } diff --git a/man/toMassbank-RmbSpectraSet-method.Rd b/man/toMassbank-RmbSpectraSet-method.Rd new file mode 100644 index 0000000..4b39fca --- /dev/null +++ b/man/toMassbank-RmbSpectraSet-method.Rd @@ -0,0 +1,17 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/createMassBank.R +\name{toMassbank,RmbSpectraSet-method} +\alias{toMassbank,RmbSpectraSet-method} +\title{Convert spectra from a `RmbSpectraSet` object to MassBank records} +\usage{ +\S4method{toMassbank}{RmbSpectraSet}(o, addAnnotation = getOption("RMassBank")$add_annotation) +} +\arguments{ +\item{addAnnotation}{`logical`, whether to add peak annotations (putative formulas) to the record.} +} +\value{ +A list of character vectors with the MassBank records +} +\description{ +Convert spectra from a `RmbSpectraSet` object to MassBank records +} diff --git a/man/toMassbank-RmbSpectrum2-method.Rd b/man/toMassbank-RmbSpectrum2-method.Rd new file mode 100644 index 0000000..1072f33 --- /dev/null +++ b/man/toMassbank-RmbSpectrum2-method.Rd @@ -0,0 +1,17 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/createMassBank.R +\name{toMassbank,RmbSpectrum2-method} +\alias{toMassbank,RmbSpectrum2-method} +\title{Convert a `RmbSpectrum2` object to a MassBank record} +\usage{ +\S4method{toMassbank}{RmbSpectrum2}(o, addAnnotation = getOption("RMassBank")$add_annotation) +} +\arguments{ +\item{addAnnotation}{`logical`, whether to add peak annotations (putative formulas) to the record.} +} +\value{ +A character vector with the MassBank record +} +\description{ +Convert a `RmbSpectrum2` object to a MassBank record +}