[R] do.call(), browser() and large arguments

Duncan Murdoch murdoch.duncan at gmail.com
Fri Jun 8 13:13:53 CEST 2012


On 12-06-08 7:06 AM, Jannis wrote:
> Hi R users,
>
>
> i use do.call() to run some functions on large datasets. For debugging
> purposes I occasionally use browser. In the case of large datasets
> supplied to do.call, this however results in R printing huge amounts of
> numbers on the screen. Is there any way to reduce this output?
>
> I found a similar discussion here:
>
> http://tolstoy.newcastle.edu.au/R/help/06/02/21727.html
>
> but it stopped before giving me any hint on how to solve the problem or
> whether there is a solution at all.
>
> Any ideas?
>

browser() prints the call on entry.  do.call() constructs a call 
containing the values, so you see that, unless you ask browser() not to 
report the call, using its skipCalls argument.

This is documented in ?browser.

Duncan Murdoch



More information about the R-help mailing list