An R6 class representing a factor in a design of experiments (DOE).
Public fields
low
Numeric value specifying the lower bound of the factor. Default is `-1`.
high
Numeric value specifying the upper bound of the factor. Default is `1`.
name
Character string specifying the name of the factor. Default is an empty string ``.
unit
Character string specifying the unit of measurement for the factor. Default is an empty string ``.
type
Character string specifying the type of the factor. Can be either `numeric` or `categorical`. Default is `numeric`.
Methods
Get the attributes of the factor.
Method .low()
Get and set the lower bound for the factor.
Arguments
value
Numeric value to set as the lower bound. If missing, the current lower bound is returned.
Method .high()
Get and set the upper bound for the factor.
Arguments
value
Numeric value to set as the upper bound. If missing, the current upper bound is returned.
Method .type()
Get and set the type of the factor.
Arguments
value
Character string specifying the type of the factor. Can be `"numeric"` or `"categorical"`. If missing, the current type is returned.
Method .unit()
Get and set the unit of measurement for the factor.
Arguments
value
Character string specifying the unit of measurement. If missing, the current unit is returned.
Get and set the name of the factor.
Arguments
value
Character string specifying the name of the factor. If missing, the current name is returned.
Print the characteristics of the factors.
Method clone()
The objects of this class are cloneable with this method.
Usage
doeFactor$clone(deep = FALSE)
Arguments
deep
Whether to make a deep clone.