Skip to contents

This function sanitizes spectra

Usage

sanitize_spectra(
  spectra,
  cutoff = 0,
  dalton = 0.01,
  polarity = NA,
  ppm = 10,
  combine = TRUE
)

Arguments

spectra

Spectra object

cutoff

Absolute minimal intensity

dalton

Dalton tolerance

polarity

Polarity

ppm

PPM tolerance

combine

Flag indicating whether to combine Default TRUE

Value

The sanitized spectra

Examples

if (FALSE) { # \dontrun{
data.frame(
  FEATURE_ID = c("FT001", "FT002", "FT003"),
  mz = c(list(123.4567, 234.5678, 345.6789))
) |>
  Spectra::Spectra() |>
  sanitize_spectra()
} # }