Learn R Programming

distr6 (version 1.0.0)

parameters: Parameters Accessor

Description

Returns some or all the parameters in a distribution.

Usage

parameters(object, id = NULL, error = "warn")

Arguments

object

Distribution or ParameterSet.

id

character, see details.

error

character, value to pass to stopwarn

Value

An R6 object of class ParameterSet or a data.table.

R6 Usage

$parameters(id = NULL, error = "warn")

Details

If id is given and matches a parameter in the distribution, the parameter is returned with all details. If id is given but doesn't match a parameter, an empty data.frame is returned. Finally if id is not given, returns all parameters in the distribution.

stopwarn either breaks the code with an error if "error" is given or returns NULL with warning otherwise.

See Also

getParameterValue and setParameterValue