Set arguments of a CallableFunction
set_args.Rd
Usage
set_args(x, args)
# S3 method for CallableFunction
set_args(x, args)
# S3 method for CallableCode
set_args(x, args)
# S3 method for TealDatasetConnector
set_args(x, args)
Arguments
- x
CallableFunction
orTealDatasetConnector
)- args
(
NULL
or namedlist
) dynamic arguments to function
Examples
## Using CallableFunction
fun <- callable_function(example_cdisc_data)
set_args(fun, list(dataname = "ADSL"))
## Using CallableCode
code <- callable_code("example_cdisc_data()")
set_args(code, list(df = "adsl"))
#> Warning: 'CallableCode' is unchangable. Ignoring arguments set by 'set_args'
## Using TealDatasetConnector
ds <- dataset_connector("x", pull_callable = callable_function(data.frame))
set_args(ds, list(x = 1:5, y = letters[1:5]))