Skip to contents

The get_option() function is a helper for retrieving the value of parabar options. If the option requested is not available in the session base::.Options list, the corresponding default value set by the Options R6::R6 class is returned instead.

The set_option() function is a helper for setting parabar options. The function adjusts the fields of the Options instance stored in the base::.Options list. If no Options instance is present in the base::.Options list, a new one is created.

The set_default_options() function is used to set the default options values for the parabar package. The function is automatically called at package load and the entry created can be retrieved via getOption("parabar"). Specific package options can be retrieved using the helper function get_option().



set_option(option, value)




A character string representing the name of the option to retrieve or adjust. See the public fields of R6::R6 class Options for the list of available parabar options.


The value to set the option to.


The get_option() function returns the value of the requested option present in the base::.Options list, or its corresponding default value (i.e., see Options). If the requested option is not known, an error is thrown.

The set_option() function returns void. It throws an error if the requested option to be adjusted is not known.

The set_default_options() function returns void. The options set can be consulted via the base::.Options

list. See the Options

R6::R6 class for more information on the default values set by this function.

See also

Options, set_default_options(), base::options(), and base::getOption().


# Get the status of progress tracking.
#> [1] TRUE

# Set the status of progress tracking to `FALSE`.
set_option("progress_track", FALSE)

# Get the status of progress tracking again.
#> [1] FALSE

# Restore default options.

# Get the status of progress tracking yet again.
#> [1] TRUE