Function to trim the "instr.desc" attribute of an existing generic_spct object, discarding all fields except for `spectrometer.name`, `spectrometer.sn`, `bench.grating`, `bench.slit`, and calibration name.
trimInstrDesc(x, fields = c("time", "spectrometer.name",
"spectrometer.sn", "bench.grating", "bench.slit"))a generic_spct object
a character vector with the names of the fields to keep, or if first member is `"-"`, the names of fields to delete; "*" as first member of the vector makes the function a no-op, leaving the spectrum object unaltered.
x
Other measurement metadata functions: getInstrDesc,
getInstrSettings,
getWhatMeasured,
getWhenMeasured,
getWhereMeasured,
get_attributes,
isValidInstrDesc,
isValidInstrSettings,
setInstrDesc,
setInstrSettings,
setWhatMeasured,
setWhenMeasured,
setWhereMeasured,
trimInstrSettings