If f is long then you can get some savings like this:
do.call(f, mtcars) # note: used f rather than f
Unfortunately, my f is a character vector containing the function I
want to call. Thanks for the idea though.
Hadley
__
On Mon, 20 Feb 2006, hadley wickham wrote:
A problem that I've encountered when using do.call a lot is very large
stack traces, eg:
f - function(x) stop()
do.call(error, mtcars)
traceback()
f - function(x) browser()
do.call(f, mtcars)
Did you mean that? Both are errors. Perhaps
f -
Did you mean that? Both are errors. Perhaps
f - function(...) browser()
do.call(f, mtcars)
Sorry, yes, that is what I meant.
What is being used is
Rprintf(Called from: );
PrintValueRec(cptr-call,rho);
in src/main/main.c. We could certainly allow an option to limit
A problem that I've encountered when using do.call a lot is very large
stack traces, eg:
f - function(x) stop()
do.call(error, mtcars)
traceback()
f - function(x) browser()
do.call(f, mtcars)
I have hacked together my own version of traceback to fix this by
limiting the length of each line to 80
If f is long then you can get some savings like this:
do.call(f, mtcars) # note: used f rather than f
This does not solve the whole problem but its a step.
On 2/20/06, hadley wickham [EMAIL PROTECTED] wrote:
A problem that I've encountered when using do.call a lot is very large
stack