R: Query class of spectrum objects

is.generic_spct {photobiology} | R Documentation

## Query class of spectrum objects

### Description

Functions to check if an object is of a given type of spectrum, or coerce it if possible.

### Usage

    is.generic_spct(x)

    is.raw_spct(x)

    is.calibration_spct(x)

    is.cps_spct(x)

    is.source_spct(x)

    is.response_spct(x)

    is.filter_spct(x)

    is.reflector_spct(x)

    is.object_spct(x)

    is.chroma_spct(x)

    is.any_spct(x)

### Arguments

`x` | an R object.

### Value

These functions return `TRUE` if its argument is a of the queried type of spectrum and `FALSE` otherwise.

### Note

Derived types also return TRUE for a query for a base type such as `generic_spct`.

### Examples

    is.source_spct(sun.spct)
    is.filter_spct(sun.spct)
    is.generic_spct(sun.spct)
    is.generic_spct(sun.spct)

    is.source_spct(sun.spct)
    is.filter_spct(sun.spct)
    is.generic_spct(sun.spct)
    is.generic_spct(sun.spct)

[Package photobiology version 0.9.21 Index]