| ArrayParameter-class {oppr} | R Documentation |
Array parameter prototype
Description
This prototype is used to represent a parameter has multiple values. Each value is has a label to differentiate values. Only experts should interact directly with this prototype.
Fields
- $id
characteridentifier for parameter.- $name
charactername of parameter.- $value
numericvectorof values.- $label
charactervectorof names for each value.- $default
numericvectorof default values.- $length
integernumber of values.- $class
characterclass of values.- $lower_limit
numericvectorspecifying the minimum permitted values.- $upper_limit
numericvectorspecifying the maximum permitted values.- $widget
functionused to construct ashiny::shiny()interface for modifying values.
Usage
x$print()
x$show()
x$repr()
x$validate(tbl)
x$get()
x$set(tbl)
x$reset()
x$render(...)
Arguments
- tbl
data.frame()containing new parameter values with row names indicating the labels and a column called "values" containing the new parameter values.- ...
arguments passed to function in
widgetfield.
Details
print the object.
- show
show the object.
- repr
characterrepresentation of object.- validate
check if a proposed new set of parameters are valid.
- get
return a
base::data.frame()containing the parameter values.- set
update the parameter values using a
base::data.frame().- reset
update the parameter values to be the default values.
- render
create a
shiny::shiny()widget to modify parameter values.