R/spc_io_postprocess_optional.R
dot-spc_io_postprocess_optional.Rd
This function provides two ways of post-processing imported spectra:
.spc_io_postprocess_optional(
spc,
filename,
...,
file.remove.emptyspc = hy_get_option("file.remove.emptyspc"),
file.keep.name = hy_get_option("file.keep.name"),
tolerance = hy_get_option("tolerance")
)
hyperSpec
object for file import post-processing.
filename(s) to become extra data column of spc
.
(ignored).
should empty (all NA
or all 0
) spectra be
removed?
should file names be kept and put into spc$filename
?
intensities in +/- tolerance
are considered 0
for
file.remove.emptyspc = TRUE
.
hyperSpec
object.
optionally remove empty spectra (some spectrograph software will produce empty spectra when measurements are cancelled)
optionally keep the filenames in column spc$filename
The desired overall behavior can be set by options via hy_set_options()
.
All file import filters should call .spc_io_postprocess_optional()
to
ensure the same behavior.