Re: [R] debug only top level function

2019-06-06 Thread Martin Maechler
;blurred" for byte compiled functions, and as the default JIT level is high, I had occasionallz wanted an easy way to revert the byte compilation before debugging or another way to get rid of this drawback.. Martin >> >> Best regards >> Petr >>

Re: [R] debug only top level function

2019-06-06 Thread Duncan Murdoch
11 AM To: PIKAL Petr ; r-help@r-project.org Subject: Re: [R] debug only top level function On 06/06/2019 4:55 a.m., PIKAL Petr wrote: Dear all I have a question about debug function. I did not use it for long time but my vague memory tell me, that when I used debug(myfunction) in past, only

Re: [R] debug only top level function

2019-06-06 Thread PIKAL Petr
d be worth considering to add something about it to debug help page. Best regards Petr > -Original Message- > From: Duncan Murdoch > Sent: Thursday, June 6, 2019 11:11 AM > To: PIKAL Petr ; r-help@r-project.org > Subject: Re: [R] debug only top level function > > On 0

Re: [R] debug only top level function

2019-06-06 Thread Duncan Murdoch
On 06/06/2019 4:55 a.m., PIKAL Petr wrote: Dear all I have a question about debug function. I did not use it for long time but my vague memory tell me, that when I used debug(myfunction) in past, only myfunction was debugged and browser ignored any embedded function. example (simple) fff <-

[R] debug only top level function

2019-06-06 Thread PIKAL Petr
Dear all I have a question about debug function. I did not use it for long time but my vague memory tell me, that when I used debug(myfunction) in past, only myfunction was debugged and browser ignored any embedded function. example (simple) fff <- function(x) mean(x, na.rm=T) when I issue >

Re: [R] Debug package options

2015-03-31 Thread Keith S Weintraub
Duncan, Thanks for the help. Since I am the only person using this machine and I couldn’t figure out where to put the option statement aside from: C:\Program Files\R\R-3.1.2\etc In the file Rprofile.site The option that I wanted was: options(debug.font = "Consolas 12”) Which allowed me to h

Re: [R] Debug package options

2015-03-30 Thread Duncan Murdoch
On 30/03/2015 1:50 PM, Keith S Weintraub wrote: > Folks, > > I would like change some of the options for the Tk window that pops up when > using the debug package. > > I know how to change the options: e.g. options(debug.font = "Courier 12 > italic”). > > Is there a way to “preset” these in my

[R] Debug package options

2015-03-30 Thread Keith S Weintraub
Folks, I would like change some of the options for the Tk window that pops up when using the debug package. I know how to change the options: e.g. options(debug.font = "Courier 12 italic”). Is there a way to “preset” these in my environment so when debug starts up I have all the options set u

Re: [R] debug on lapply

2012-12-11 Thread Duncan Murdoch
On 11/12/2012 1:17 PM, Asis Hallab wrote: Dear R experts, recently I tried to debug a R function with an internal lapply call. When debugging I seem not to be able to use the "n" command to debug the inner function called by lapply. How could I achieve this? Jim gave you one solution. Another

Re: [R] debug on lapply

2012-12-11 Thread jim holtman
Typically when I am debugging an 'lapply', I put a browser call inside the lapply function that is being called and then make sure I 'source' in the code instead of copy/paste -- the copy/paste will use any trailing statements after the lapply call as commands to the "browser" function. Here is th

[R] debug on lapply

2012-12-11 Thread Asis Hallab
Dear R experts, recently I tried to debug a R function with an internal lapply call. When debugging I seem not to be able to use the "n" command to debug the inner function called by lapply. How could I achieve this? *For example:* test <- function( ) { lapply( 1:3, function( x ) x + 1 ) } debu

[R] Debug newbie

2012-10-03 Thread Ana Richardson
Hi! I'm trying to debug the cosmo R package because I'm trying to find out where all the motifs are. I display some of them printing the "motif" variable but I don't know how to show all of the found motifs in one run. http://www.bioconductor.org/packages/2.10/bioc/html/cosmo.html I think that th

Re: [R] debug vs regular mode

2012-08-10 Thread Zhang, Peng
If you read my bug report, I just ran the same thing on both regular mode and debug mode. That is why I think it is related with R base, though there might be some other bugs related with glmulti or rJava. Peng On 08/10/2012 04:03 PM, peter dalgaard wrote: > On Aug 10, 2012, at 21:23 , Zhang, P

Re: [R] debug vs regular mode

2012-08-10 Thread Zhang, Peng
Ok. I will stop here. I have just created a bug report. https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15013 If anyone is interested, please see if you can reproduce it. Thanks, Peng On 08/10/2012 03:04 PM, peter dalgaard wrote: > Not to spoil your fun, but this is getting a bit off-topic

Re: [R] debug vs regular mode

2012-08-10 Thread peter dalgaard
On Aug 10, 2012, at 21:23 , Zhang, Peng wrote: > Ok. I will stop here. I have just created a bug report. > > https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15013 ...which is exactly what you should NOT do, if the bug is likely to live in a contributed package!! -pd > > If anyone is i

Re: [R] debug vs regular mode

2012-08-10 Thread peter dalgaard
Not to spoil your fun, but this is getting a bit off-topic for R-help. If you wish to continue the debugging process in public, I think you should move to R-devel. Also, it sounds like the problem is in the glmulti package, so you might want to involve its maintainer at some point. -pd On A

Re: [R] debug vs regular mode

2012-08-10 Thread Zhang, Peng
Thanks! It is interesting that Windows has pointed the problem to Java. So it is probable that how I did my debug led me to the wrong direction. Since I was unsure how to debug S4 class, I copied the source implement R function from glmulti package into my testing program. The segmentation faul

Re: [R] debug vs regular mode

2012-08-10 Thread Henric (Nilsson) Winell
On 2012-08-10 15:42, Zhang, Peng wrote: You are right. I am running Arch Linux. However, I obtained a segmentation directly, so didn't know where to find the bug?? > library("glmulti") Loading required package: rJava > testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol =

Re: [R] debug vs regular mode

2012-08-10 Thread Zhang, Peng
You are right. I am running Arch Linux. However, I obtained a segmentation directly, so didn't know where to find the bug?? > library("glmulti") Loading required package: rJava > testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol = 50))) > glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8

Re: [R] debug vs regular mode

2012-08-10 Thread Henric (Nilsson) Winell
On 2012-08-10 06:10, Zhang, Peng wrote: Thanks to both for your reply. library(glmulti) testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol = 50))) glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16, data = testdata, level = 2) This is reproducible to get a seg

Re: [R] debug vs regular mode

2012-08-09 Thread Zhang, Peng
Thanks to both for your reply. library(glmulti) testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol = 50))) glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16, data = testdata, level = 2) This is reproducible to get a segmentation fault. But I have troubles to e

Re: [R] debug vs regular mode

2012-08-09 Thread R. Michael Weylandt
On Aug 9, 2012, at 9:14 PM, David Winsemius wrote: > > On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote: > >> Dear all, >> >> I had a R segmentation fault, and then invoked debug mode and ran step >> by step. > > >> 2. Why does the same function behave differently under debug and regular >> m

Re: [R] debug vs regular mode

2012-08-09 Thread David Winsemius
On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote: Dear all, I had a R segmentation fault, and then invoked debug mode and ran step by step. When I reached "terms(Y~X1*X2*...*X16)", I would then have "segmentation" fault. However, if I just ran this under regular "R interactive" mode, it would be

[R] debug vs regular mode

2012-08-09 Thread Zhang, Peng
Dear all, I had a R segmentation fault, and then invoked debug mode and ran step by step. When I reached "terms(Y~X1*X2*...*X16)", I would then have "segmentation" fault. However, if I just ran this under regular "R interactive" mode, it would be fine though taking long time. My questions are

Re: [R] debug in a loop

2012-02-11 Thread Duncan Murdoch
On 12-02-10 12:48 PM, Justin Haynes wrote: You can add if(is.na(tab[i])) browser() or if(is.na(tab[i])) break see inline You can also do this temporarily. Supposing that you used source("foo.R") to enter a function with that code in it, and you want the check on line 10, you'd enter se

Re: [R] debug in a loop

2012-02-10 Thread Justin Haynes
You can add if(is.na(tab[i])) browser() or if(is.na(tab[i])) break see inline On Fri, Feb 10, 2012 at 7:22 AM, ikuzar wrote: > Hi, > > I'd like to debug in a loop (using debug() and browser() etc but not > print() > ). I'am looking for the first occurence of NA. > For instance: > > tab = c(1

[R] debug in a loop

2012-02-10 Thread ikuzar
Hi, I'd like to debug in a loop (using debug() and browser() etc but not print() ). I'am looking for the first occurence of NA. For instance: tab = c(1:300) tab[250] = NA len = length(tab) for (i in 1:len){ if(i != len){ tab[i] = tab[i]+tab[i+1] } } I do not want to do "Browse[2]> n"

Re: [R] debug package: mtrace fails

2012-01-24 Thread deivit
I'll try, Here is a piece of code it fails for me, the error I get is always the same, and it happens in most of my functions. The problem is always the same trying to execute 'mtrace'. Thanks! --- execution -- > mtrace(index_remap) Error in x[[i]] : subscript out of

Re: [R] debug package: mtrace fails

2012-01-24 Thread Tal Galili
Hi Deivit, Can you offer a self contained example of r code when the function fails for you? Contact Details:--- Contact me: tal.gal...@gmail.com | 972-52-7275845 Read me: www.talgalili.com (Hebrew) | www.biostatistics.co.il (He

[R] debug package: mtrace fails

2012-01-24 Thread deivit
Hi all, Since three month ago I started working with R professionally, I never did it before, so I am such a newbie. I am having some problems using the 'debug' package. I love this package, but most of the times I wanna use it it just fails :P When typing at prompt 'mtrace(myfunct)' most of the

Re: [R] debug R code

2011-06-03 Thread Duncan Murdoch
On 11-06-03 4:49 PM, Hui Du wrote: Hi List, I have a question regarding debug R code. I know I can use debug(fuction_name) and when code runs to that point, it will go to debugger. My question is inside debugger, how to stop a code at a specified line. For example, in C (gdb or

[R] debug R code

2011-06-03 Thread Hui Du
Hi List, I have a question regarding debug R code. I know I can use debug(fuction_name) and when code runs to that point, it will go to debugger. My question is inside debugger, how to stop a code at a specified line. For example, in C (gdb or dbx debugger) I can run "stop at 123

Re: [R] debug R device plot

2011-05-23 Thread Sharpie
cameron.bracken wrote: > > You need to look for a file (it may not be in your project directory) that > contains "___LOCK" in its file name and delete it. > Specifically, the rogue lockfile should be in the same directory as options('tikzMetricsDictionary'). Or, if you haven't set a permanent l

Re: [R] debug R device plot

2011-05-23 Thread cameron.bracken
Not sure if you ever figured this out, but I was just directed to this post. You need to look for a file (it may not be in your project directory) that contains "___LOCK" in its file name and delete it. filehash creates this to prevent multiple writes to the same file at the same time and somehow

[R] debug R device plot

2011-03-24 Thread Michael Bach
Hi there, I was doing great with R, ggplot and tikzDevice, when suddenly it stopped working. I can do a plot just fine on the R online graphics device. I can also open a tikzdevice via tikz(). However, the plot (both ggplot and R graphics plot) call leads to the error: "createLockFile(lockname):

Re: [R] debug biglm response error on bigglm model

2011-01-12 Thread Mike Harwood
h.D. > Statistical Data Center > Intermountain Healthcare > greg.s...@imail.org > 801.408.8111 > > > > > > > -Original Message- > > From: r-help-boun...@r-project.org [mailto:r-help-boun...@r- > > project.org] On Behalf Of Mike Harwood > > Se

Re: [R] debug biglm response error on bigglm model

2011-01-10 Thread Greg Snow
f Of Mike Harwood > Sent: Monday, January 10, 2011 6:29 AM > To: r-help@r-project.org > Subject: [R] debug biglm response error on bigglm model > > G'morning > > What does the error message "Error in x %*% coef(object) : non- > conformable arguments" indicate when

[R] debug biglm response error on bigglm model

2011-01-10 Thread Mike Harwood
G'morning What does the error message "Error in x %*% coef(object) : non- conformable arguments" indicate when calculating the response values for newdata with a model from bigglm (in package biglm), and how can I debug it? I am attempting to do Monte Carlo simulations, which may explain the loop

Re: [R] debug an error that incapacitates R?

2009-12-14 Thread Brian Diggs
> -Original Message- > From: Rolf Turner [mailto:r.tur...@auckland.ac.nz] > Sent: Monday, December 14, 2009 2:07 PM > To: Brian Diggs > Cc: r-help@r-project.org Help > Subject: Re: [R] debug an error that incapacitates R? > > > Wouldn't sink.number() gi

Re: [R] debug an error that incapacitates R?

2009-12-14 Thread Rolf Turner
uncan Murdoch Cc: r-help@r-project.org Help Subject: Re: [R] debug an error that incapacitates R? Hello And thank you for the quick answer. On 12/13/09, Duncan Murdoch wrote: I think you need to go back to old-fashioned debugging methods. Identify the line the triggers the error, by using debug(

Re: [R] debug an error that incapacitates R?

2009-12-14 Thread Brian Diggs
> -Original Message- > From: Liviu Andronic [mailto:landronim...@gmail.com] > Sent: Sunday, December 13, 2009 4:05 AM > To: Duncan Murdoch > Cc: r-help@r-project.org Help > Subject: Re: [R] debug an error that incapacitates R? > > Hello > And thank you for the

Re: [R] debug an error that incapacitates R?

2009-12-13 Thread Liviu Andronic
Hello And thank you for the quick answer. On 12/13/09, Duncan Murdoch wrote: > I think you need to go back to old-fashioned debugging methods. Identify > the line the triggers the error, by using debug() and single stepping > through sosInit(), or by adding print() or cat() statements to it (or

Re: [R] debug an error that incapacitates R?

2009-12-13 Thread Duncan Murdoch
On 13/12/2009 5:31 AM, Liviu Andronic wrote: Dear all How should I attempt debugging this error? sosInit() Error: invalid connection When this happens R refuses to run anything: 2+2 Error: invalid connection sessionInfo () Error in stdout() : invalid connection Debugging it seems impossi

[R] debug an error that incapacitates R?

2009-12-13 Thread Liviu Andronic
Dear all How should I attempt debugging this error? > sosInit() Error: invalid connection When this happens R refuses to run anything: > 2+2 Error: invalid connection > sessionInfo () Error in stdout() : invalid connection Debugging it seems impossible. > options(error=recover) > sosInit() Error

Re: [R] debug(sum) error

2009-10-10 Thread Duncan Murdoch
On 10/10/2009 7:00 PM, Another Oneforyou wrote: Hi, I'm working through "R-debug-tools.pdf" and on page 7 it describes doing: Browse[1]> debug(sum) ## Flag sum for debugging however, when I try this, I get: Browse[1]> debug(sum)Error in debug(fun) : argument must be a clo

[R] debug(sum) error

2009-10-10 Thread Another Oneforyou
Hi, I'm working through "R-debug-tools.pdf" and on page 7 it describes doing: Browse[1]> debug(sum) ## Flag sum for debugging however, when I try this, I get: Browse[1]> debug(sum)Error in debug(fun) : argument must be a closure Does anyone know why I get this error, and

Re: [R] Debug

2009-10-03 Thread David Winsemius
On Oct 1, 2009, at 11:04 AM, Tammy Ma wrote: provide commented, minimal, self-contained, reproducible code. David Winsemius, MD Heritage Laboratories West Hartford, CT __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-hel

Re: [R] Debug

2009-10-01 Thread Steve Lianoglou
Hi Tammy, On Oct 1, 2009, at 11:04 AM, Tammy Ma wrote: Hi, R-Users,' I have written a programe to process the bunch of files in one folder. But there is a error came out; How can I know which file returns error when being processed? I have tested the first 1-10th files, no any problem. But the

Re: [R] Debug

2009-10-01 Thread Tammy Ma
From: metal_lical...@live.com To: r-help@r-project.org Subject: Debug Date: Thu, 1 Oct 2009 15:21:42 +0300 Hi, R-Users,' I have written a programe to process the bunch of files in one folder. But there is a error came out; How can I know which file returns error when being processed? I

[R] debug/mtrace problem

2009-04-13 Thread Cuvelier Etienne
Hello, In the past I have used intensively the mtrace function from the debug package, but now with my actual version of R(2.8.1) , it is impossible to use it anymore. I've updated all my packages, and I don't understand how solve this problem... Here is an example code : > foo<-function(){

Re: [R] debug

2009-03-12 Thread Duncan Murdoch
Tammy Ma wrote: Hi, All I have so many files in my directory. I got the following error. At this time, I couldn't use debug() to check error one by one because so many files getting invloved. How can I get some idea about my error?? The usual advice: simplify the problem until it's obvio

[R] debug

2009-03-12 Thread Tammy Ma
Hi, All I have so many files in my directory. I got the following error. At this time, I couldn't use debug() to check error one by one because so many files getting invloved. How can I get some idea about my error?? . Skipping book_log-20060222T143612.txt Skipping book_log-20060222T162

Re: [R] Debug help

2009-02-04 Thread Eduard Pieterse (Macquarie Securities)
, Eduard -Original Message- From: Duncan Murdoch [mailto:murd...@stats.uwo.ca] Sent: 04 February 2009 14:04 To: Eduard Pieterse (Macquarie Securities) Cc: r-help@r-project.org Subject: Re: [R] Debug help On 2/4/2009 6:28 AM, ehxpieterse wrote: > Hi, > > I am getting the follow

Re: [R] Debug help

2009-02-04 Thread Duncan Murdoch
On 2/4/2009 6:28 AM, ehxpieterse wrote: Hi, I am getting the following error: argument is of length zero My code: temp <- 0 for (j in 1 : 3) { for (k in 1 : 12) { temp <- temp + as.double(C[k, (q - 1) * 3 + j]) * as.double(m_ret_reb[i + k - 1, j+1]) } } Why would R handle my temp variable as

[R] Debug help

2009-02-04 Thread ehxpieterse
Hi, I am getting the following error: argument is of length zero My code: temp <- 0 for (j in 1 : 3) { for (k in 1 : 12) { temp <- temp + as.double(C[k, (q - 1) * 3 + j]) * as.double(m_ret_reb[i + k - 1, j+1]) } } Why would R handle my temp variable as numeric(0)? Thanks -- View this messag

Re: [R] Debug command-how to use

2008-11-11 Thread Rahul-A.Agarwal
Thanks a lot...I realised where I was going wrongif I declare debug = F then my problem is getting solved. -Original Message- From: jim holtman [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 12, 2008 9:12 AM To: Agarwal, Rahul-A Cc: r-help@r-project.org Subject: Re: [R

Re: [R] Debug command-how to use

2008-11-11 Thread jim holtman
What is 'debug' defined as? Include at least the assignment or 'str(debug)'. If you have not assigned anything to it, then 'debug' is a function in the basic set of R functions and may be giving you a message like: > if (debug) 1 Error in if (debug) 1 : argument is not interpretable as logical >

[R] Debug command-how to use

2008-11-11 Thread Rahul-A.Agarwal
I am getting this error could any one tell me why? if(debug) cat("rahul") Error in if (debug) cat("rahul") : argument is not interpretable as logical __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the