Emacs Speaks Statistics 能否像真正的调试器一样通过 R for 循环进行循环?
我很高兴使用 ESS 来编码和调试 R 代码。我最近在几个 for 循环和 ifs 结构的深处发现了一个难以捉摸的错误。
有没有办法让 ESS 有选择地遍历 if/else 结构或循环 for 循环中的所有值?
R 或 ESS 是否具有调试器模式,您可以在其中跳过 else 子句、循环值并单步执行、单步执行、返回等?
[更新]
感谢@jubba提供有关R 语言调试工具。最后,这是我真正的问题。另一个线程提供了我想了解的有关当前 R 中调试方式的链接。
- R-debug-tools.pdf
- debuggingR
- 和用于使用 ESS 进行调试的一个, ess-tracebug
I am a happy user of ESS for coding and debugging R code. I have found a elusive bug recently deeply inside several for loops and ifs structures.
Is there any way of having ESS selectively travel the if/else structures or loop for all the values in a for loop?.
Does R or ESS have debugger mode where you can skip else clauses, loop the values and step into, step through, return etc?
[UPDATE]
Thanks @jubba for the link to the other SO question about debugging tools for R-language. At the end this was my real question. This other thread give the links for the kind of things that I wanted to know about the way of doing debugging in the current R.
- R-debug-tools.pdf
- debuggingR
- and the one for debugging with ESS, ess-tracebug
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Stackoverflow 上有一个关于 R 调试的更普遍的问题:
R 语言的调试工具
Davor Cubranic 的一个回答指向
ess-tracebug
,根据其网站,它是“用于 ESS 中交互式调试和错误跟踪的 emacs 包”。我自己从未使用过它,但它可能对您有用:http://code .google.com/p/ess-tracebug/
There has been a more general question about debugging in R on Stackoverflow :
Debugging tools for the R language
One answer by Davor Cubranic points to
ess-tracebug
which is, according to its website, "An emacs package for interactive debugging and error tracing in ESS". I've never used it myself, but it may be useful to you :http://code.google.com/p/ess-tracebug/