[R] Modern Symbolic debugger for R programmes?

Gabor Grothendieck ggrothendieck at gmail.com
Tue Oct 9 06:43:21 CEST 2012


On Tue, Oct 9, 2012 at 12:12 AM, Worik R <worikr at gmail.com> wrote:
> I think I am whistling in the wind, but is there a modern symbolic
> debugger for R programmes?
>
> I am working through some  one else's code, thousands of lines, that
> has the occasional bug in it, and a lot in my understanding of it.
>
> I cannot make setBreakpoint or findLineNum  work.  I get "No source
> refs found.".  I am starting to loose my mind!
>
> A debugger where I could set breakpoints with a little more
> granularity than the function level and a little more accessible than
> the trace function.  What I ideally want is GDB for R.
>


trace("f", quote(browser()), 3)

will set a breakpoint at line 3 of function f and

body(f)

will list the body of f showing where the browser command was added.

Of course you could also edit the source of f and just insert a
browser() command yourself.

-- 
Statistics & Software Consulting
GKX Group, GKX Associates Inc.
tel: 1-877-GKX-GROUP
email: ggrothendieck at gmail.com




More information about the R-help mailing list