processing_step
on a collection
objectR/processing_step.R
, R/processing_template.R
process.Rd
Applies a processing_step
on a collection
object
Process a collection
object
Applies a processing_template
on a collection
object
# S3 method for processing_step process(x, collection, ...) process(...) # S3 method for processing_template process(x, collection, verbose = FALSE, ...)
x | A |
---|---|
collection | a |
... | further arguments passed to or from other methods(not currenctly used). |
verbose | Set to TRUE to show progress |
library(tidySpectR) # Creating a masking step stp <- processing_step( fun = mask, arglist = list(from = 5, to = Inf), type = "masking", name = "masking") process(stp, fa_nmr)#> Spectra collection containing 6 entries. #> Number of bins: 1251 #> Limits: -2.123166e-05 5.003979 #> Labels: conventional organic #> #> Processing: #> Step 1 / 1 : masklibrary(tidySpectR) template <- processing_template() %>% new_step(mask, list(from = 5, to = Inf), name = "mask") %>% new_step(bucket_uniform, list(N = 10), name = "bucket") process(template, fa_nmr)#> Spectra collection containing 6 entries. #> Number of bins: 10 #> Limits: -2.123166e-05 5.003979 #> Labels: conventional organic #> #> Processing: #> Step 1 / 2 : mask #> Step 2 / 2 : uniform_binning