Learn R Programming

photobiology (version 0.11.4)

get_attributes: Get the metadata attributes

Description

Method returning attributes of an object of class generic_spct or derived, or of class waveband. Only attributes defined and/or set by package 'photobiology' for objects of the corresponding class are returned. Parameter which can be used to subset the list of attributes.

Usage

get_attributes(x, which, ...)

# S3 method for generic_spct get_attributes(x, which = NULL, allowed = all.attributes, ...)

# S3 method for source_spct get_attributes(x, which = NULL, ...)

# S3 method for filter_spct get_attributes(x, which = NULL, ...)

# S3 method for reflector_spct get_attributes(x, which = NULL, ...)

# S3 method for object_spct get_attributes(x, which = NULL, ...)

# S3 method for solute_spct get_attributes(x, which = NULL, ...)

# S3 method for waveband get_attributes(x, which = NULL, ...)

Value

Named list of attribute values.

Arguments

x

a generic_spct object.

which

character vector Names of attributes to retrieve.

...

currently ignored

allowed

character vector Names of attributes accepted by which.

Methods (by class)

  • get_attributes(generic_spct): generic_spct

  • get_attributes(source_spct): source_spct

  • get_attributes(filter_spct): filter_spct

  • get_attributes(reflector_spct): reflector_spct

  • get_attributes(object_spct): object_spct

  • get_attributes(solute_spct): solute_spct

  • get_attributes(waveband): waveband

Details

Vectors of character strings passed as argument to which are parsed so that if the first member string is "-" the remaining members are removed from the allowed; and if it is "=" the remaining members are used if in allowed. If the first member is none of these three strings, the behaviour is the same as if the first string is "=". If which is NULL all the attributes in allowed are used. The string "" means no attributes, and has precedence over any other values in the character vector. The order of the names of annotations has no meaning: the vector is interpreted as a set except for the three possible "operators" at position 1.

See Also

select_spct_attributes

Other measurement metadata functions: add_attr2tb(), getFilterProperties(), getHowMeasured(), getInstrDesc(), getInstrSettings(), getSoluteProperties(), getWhatMeasured(), getWhenMeasured(), getWhereMeasured(), isValidInstrDesc(), isValidInstrSettings(), select_spct_attributes(), setFilterProperties(), setHowMeasured(), setInstrDesc(), setInstrSettings(), setSoluteProperties(), setWhatMeasured(), setWhenMeasured(), setWhereMeasured(), spct_attr2tb(), spct_metadata(), subset_attributes(), trimInstrDesc(), trimInstrSettings()