I need a function that takes an arbitrary number of arguments and stores them in a variable as an expression without evaluating them. I managed to do this with match.call , but it seems a bit "kludgy".
foo <- function(...) { expr <- match.call() expr[[1]] <- expression expr <- eval(expr)
Explanation
To clarify, I ask how to write a function that behaves like expression() . I cannot use expression() directly for reasons that explain too long.
source share