parse {base} | R Documentation |
Parse Expressions
Description
parse
returns the parsed but unevaluated expressions in a
list. Each element of the list is of mode expression
.
Usage
parse(file = "", n = NULL, text = NULL, prompt = NULL, white = FALSE)
Arguments
file |
the name of a file to read the expressions from. Note
that the ASCII file must end with a newline ( |
n |
the number of statements to parse. If |
text |
character. The text to parse, quoted. |
prompt |
the prompt to print when parsing from the keyboard. The
default, |
white |
if |
See Also
scan
, source
, eval
,
deparse
.
Examples
cat("x <- c(1,4)\n x ^ 3 -10 ; outer(1:7,5:9)\n", file="xyz.Rdmped")
# parse 3 statements from the file "xyz.Rdmped"
parse(file = "xyz.Rdmped", n = 3)
unlink("xyz.Rdmped")