On Tue, Oct 9, 2012 at 12:12 AM, Worik R <wor...@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

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to