voptions: Set or get options globally or per object.

Description Usage Arguments Value Options for the validate package Details Examples

Description

Set or get options globally or per object.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
voptions(x = NULL, ...)

## S4 method for signature 'ANY'
voptions(x = NULL, ...)

validate_options(...)

reset(x = NULL)

## S4 method for signature 'ANY'
reset(x = NULL)

## S4 method for signature 'expressionset'
voptions(x = NULL, ...)

## S4 method for signature 'expressionset'
reset(x = NULL)

Arguments

x

(optional) an object inheriting from expressionset such as validator or indicator.

...

Name of an option (character) to retrieve options or option = value pairs to set options.

Value

When requesting option settings: a list. When setting options, the whole options list is returned silently.

Options for the validate package

Currently the following options are supported.

Details

There are three ways in which options can be specified.

To set options in a file, use voptions(option1=value1,option2=value2,...) without the where argument. This will invoke a local setting in the object created when the file is parsed.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# the default allowed validation symbols.
voptions('validator_symbols')

# set an option, local to a validator object:
v <- validator(x + y > z)
voptions(v,raise='all')
# check that local option was set:
voptions(v,'raise')
# check that global options have not changed:
voptions('raise')

validate documentation built on Aug. 8, 2017, 1:06 a.m.