requireVariable {tinyProject} | R Documentation |
Ask user the value of a variable
Description
In interactive mode, this functions asks the user to type the value of a given variable. In non-interactive mode, it searchs the value in the command line arguments and it returns an error if the value does not exist.
Usage
requireVariable(name, desc = NULL, default = NULL,
what = character(), nmax = 1, alwaysAsk = TRUE, env = .GlobalEnv)
Arguments
name |
Name of the required variable |
desc |
Description to display |
default |
Default value for the variable |
what |
Type of data to read in interactive mode. |
nmax |
Number of values to read in interactive mode. |
alwaysAsk |
If the variable already exists, should the function ask a new value? |
env |
Environment where the variable should be defined |
Value
Used for side effects
[Package tinyProject version 0.6.1 Index]