Generic (top level) ProcessingStep class and methods
Source:R/class_ProcessingStep.R
ProcessingStep.Rd
The ProcessingStep
class is used to define a processing step within a Workflow. It contains information about the data type, method, algorithm, parameters, and other relevant metadata for the processing step. The ProcessingStep
is the parent class of all processing methods in StreamFind.
Usage
ProcessingStep(
type = NA_character_,
method = NA_character_,
required = NA_character_,
algorithm = NA_character_,
input_class = NA_character_,
output_class = NA_character_,
parameters = list(),
number_permitted = NA_real_,
version = NA_character_,
software = NA_character_,
developer = NA_character_,
contact = NA_character_,
link = NA_character_,
doi = NA_character_
)
# S3 method for class 'ProcessingStep'
validate_object(x)
as.ProcessingStep(value)
# S3 method for class 'ProcessingStep'
save(x, file = "settings.json")
# S3 method for class 'ProcessingStep'
read(x, file)
# S3 method for class 'ProcessingStep'
show(x, ...)
Arguments
- type
A character string representing the data type (e.g., "MassSpec", "Raman").
- method
A character string representing the method used (e.g., "BaselineCorrection").
- required
A character vector of required preceding methods.
- algorithm
A character string representing the algorithm used (e.g., "baseline_als").
- input_class
A character string representing the class of the input data.
- output_class
A character string representing the class of the output data.
- parameters
A list of parameters for the processing step.
- number_permitted
A numeric value indicating the number of permitted instances.
- version
A character string representing the version of the processing step.
- software
A character string representing the original software.
- developer
A character string representing the developer of the processing step.
- contact
A character string representing the contact information for the developer.
- link
A character string representing the link to the origin of the algorithm or link to additional information.
- doi
A character string representing the DOI of the algorithm or additional information.
- x
A
ProcessingStep
object.- value
A list or JSON object containing the parameters for the processing step.
- file
A character string specifying the file path to read the object from. The file extension should be
.json
or.rds
.- ...
Additional arguments (not used).
Value
A ProcessingStep
object. Fundamentally, it is a list with class ProcessingStep
and a data specific method class (e.g., RamanMethod_AverageSpectra_native
) with the following elements:
type
: The data type (e.g., "MassSpec", "Raman").method
: The method used (e.g., "BaselineCorrection").required
: A character vector of required preceding methods.algorithm
: The algorithm used (e.g., "baseline_als").input_class
: The class of the input data.output_class
: The class of the output data.parameters
: A list of parameters for the processing step.number_permitted
: The number of permitted instances.version
: The version of the processing step.software
: The original software used.developer
: The developer of the processing step.contact
: The contact information for the developer.link
: A link to the origin of the algorithm or additional information.doi
: The DOI of the algorithm or additional information.
Methods (by generic)
validate_object(ProcessingStep)
: Validate theProcessingStep
object, returnsNULL
if valid.save(ProcessingStep)
: Save aProcessingStep
object to a file in JSON or RDS format.read(ProcessingStep)
: Read aProcessingStep
object from a file in JSON or RDS format, returning the updated object.show(ProcessingStep)
: Show the details of aProcessingStep
object.