Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

chkSpectra

Verify the Integrity of a Spectra or Spectra2D Object


Description

Utility function to verify that the structure of a Spectra or Spectra2D object is internally consistent. This function should be used after manual editing of these objects. However, in most cases rather than directly editing these objects, one should modify them via:

Usage

chkSpectra(spectra, confirm = FALSE)

Arguments

spectra

An object of S3 class Spectra or Spectra2D.

confirm

Logical indicating whether or not to write the results to the console, as would be desirable for interactive use.

Value

None. When used at the console, and the object is OK, no message is written unless confirm = TRUE. At the console, if there is a problem, messages are issued regardless of the value of confirm.

Author(s)

Bryan A. Hanson, DePauw University.

Examples

if (checkForPackageWithVersion("ChemoSpec", "5.1")) {
  library("ChemoSpec")
  data(SrE.IR)
  chkSpectra(SrE.IR)
}

if (checkForPackageWithVersion("ChemoSpec2D", "0.3")) {
  library("ChemoSpec2D")
  data(MUD1)
  chkSpectra(MUD1)
}

ChemoSpecUtils

Functions Supporting Packages ChemoSpec and ChemoSpec2D

v0.4.96
GPL-3
Authors
Bryan A. Hanson [aut, cre] (<https://orcid.org/0000-0003-3536-8246>)
Initial release
2021-03-15

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.