Learn R Programming

photobiology (version 0.11.3)

subset_attributes: Subset 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 each attribute when a generic_spct object with multiple spectra in long form is subset.

Usage

subset_attributes(x, to.keep, ...)

# S3 method for default subset_attributes(x, to.keep, ...)

# S3 method for generic_spct subset_attributes( x, to.keep = character(), target.attributes = spct_attributes(class(x)[1]), ... )

Value

Named list of attribute values.

Arguments

x

a generic_spct object.

to.keep

character vector Indices to the spectra for which attributes are to be extracted and retained.

...

currently ignored

target.attributes

character vector Names of attributes to be subset using which.

Methods (by class)

  • subset_attributes(default): default

  • subset_attributes(generic_spct): generic_spct

Details

The values in which are passed as argument to the extract operator only if the value of the attribute is a list of the same length as the logical vector passed as argument to which.

See Also

select_spct_attributes

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