Check validity of spectral objects

Description

Check that an R object contains the expected data members.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
check_spct(x, byref, strict.range, ...)

## Default S3 method:
check_spct(x, byref = FALSE, strict.range = NA, ...)

## S3 method for class 'generic_spct'
check_spct(x, byref = TRUE, strict.range = NA,
  multiple.wl = getMultipleWl(x), ...)

## S3 method for class 'raw_spct'
check_spct(x, byref = TRUE,
  strict.range = getOption("photobiology.strict.range", default = FALSE),
  multiple.wl = getMultipleWl(x), ...)

## S3 method for class 'cps_spct'
check_spct(x, byref = TRUE,
  strict.range = getOption("photobiology.strict.range", default = FALSE),
  multiple.wl = getMultipleWl(x), ...)

## S3 method for class 'filter_spct'
check_spct(x, byref = TRUE,
  strict.range = getOption("photobiology.strict.range", default = FALSE),
  multiple.wl = getMultipleWl(x), ...)

## S3 method for class 'reflector_spct'
check_spct(x, byref = TRUE,
  strict.range = getOption("photobiology.strict.range", default = FALSE),
  multiple.wl = getMultipleWl(x), ...)

## S3 method for class 'object_spct'
check_spct(x, byref = TRUE,
  strict.range = getOption("photobiology.strict.range", default = FALSE),
  multiple.wl = getMultipleWl(x), ...)

## S3 method for class 'response_spct'
check_spct(x, byref = TRUE, strict.range = NA,
  multiple.wl = getMultipleWl(x), ...)

## S3 method for class 'source_spct'
check_spct(x, byref = TRUE,
  strict.range = getOption("photobiology.strict.range", default = FALSE),
  multiple.wl = getMultipleWl(x), ...)

## S3 method for class 'chroma_spct'
check_spct(x, byref = TRUE,
  strict.range = getOption("photobiology.strict.range", default = FALSE),
  multiple.wl = getMultipleWl(x), ...)

Arguments

x

An R object

byref

logical indicating if new object will be created by reference or by copy of x

strict.range

logical indicating whether off-range values result in an error instead of a warning, NA disables the test.

...

additional param possible in derived methods

multiple.wl

numeric Maximum number of repeated w.length entries with same value.

Methods (by class)

  • default: Default for generic function.

  • generic_spct: Specialization for generic_spct.

  • raw_spct: Specialization for cps_spct.

  • cps_spct: Specialization for cps_spct.

  • filter_spct: Specialization for filter_spct.

  • reflector_spct: Specialization for reflector_spct.

  • object_spct: Specialization for object_spct.

  • response_spct: Specialization for response_spct.

  • source_spct: Specialization for source_spct.

  • chroma_spct: Specialization for chroma_spct.

See Also

Other data validity check functions: check_spectrum, check_w.length

Examples

1

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.