run | R Documentation |
Evaluate character strings as an expression in the appropriate frame so the function can be used in a function and use variables in the environment of the function.
run(
...,
envir = parent.frame(),
enclos = if (is.list(envir) || is.pairlist(envir)) parent.frame() else baseenv(),
try = TRUE
)
... |
expressions that can evaluate to character strings to paste. |
envir |
(default = parent.frame()) see |
enclos |
(default same as |
try |
(default: TRUE) enclose the expression in |
the result of evaluating paste0(...)
as an expression
run('ls()')
for(nam in c('ls','search')) print(run(nam,"()")) # very unimaginative example
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.