0th

Percentile

##### Change Argument to a Function Interactively

Ask allows you to change the argument to a function interactively. It is meant to be used, in lieu of a graphical control such as a slidebar, to adjust plotting parameters, which are most naturally passed as the argument to an anonymous function that sets up the plot.

Keywords
misc, iplot
##### Usage
Ask(arg, fun, ...)
##### Arguments
arg
argument to fun to change. By specifying a vector of values, you can change several parameters via an argument to an anonymous function.
fun
function to call; often an anonymous function that sets up a call to plotting functions.
...
other arguments to fun; not necessary if fun is an anonymous function.
##### Details

Ask repeatedly prompts in the R Console for the value of arg. To exit, enter a blank line.

##### Value

• Ask returns invisibly the value of the last call to fun; usually this will be NULL, and in any event is probably not of interest. If it is, use print(Ask(arg, fun, ...)).

##### Examples
data(UN)
attach(UN)

# enter the power-transformation parameter
ylab=paste("transformed gdp, power =",p)))

# enter an expression that evaluates to a 2-vector
labels=rownames(UN)))