Re: [Rd] Issue when calling deparse(substitute(x)) from C with anonymous R vectors ?

2009-11-19 Thread Peter Dalgaard
Laurent Gautier wrote: Dear list, When calling R from C, what appears like a spurious error can be triggered during the execution of chisq.test(x, y). This is happening when the following conditions are met: - x and y are anonymous C-level R vectors (they do not have a symbol), but

Re: [Rd] Issue when calling deparse(substitute(x)) from C with anonymous R vectors ?

2009-11-19 Thread Prof Brian Ripley
This is easy to reproduce in R: chisq.test(c(1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009, 1010, 1011), c(1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009, 1010, 1011)) The simple answer is: don't do that. It is unclear what is a reasonable label to give in such a

Re: [Rd] bug in '...' of constrOptim (PR#14071)

2009-11-19 Thread Elizabeth Purdom
Hi Ravi, I just briefly looked at the code (and haven't run it). But it seems like there is still the underlying problem that '...' argument is sent to both optim and f. The documentation says that ... arguments are sent to optim, so at least based on this the ... should only appear in optim.

[Rd] Wishlist: In documentation, say that `+.Date`(Date, difftime) should be called directly or remove 'or an object of class difftime' (PR#14072)

2009-11-19 Thread suharto_anggono
Full_Name: Suharto Anggono Version: 2.8.1 OS: Windows Submission from: (NULL) (125.161.134.206) About PR#14067, now I understand why (Date + difftime) does not use '+.Date'. But, before I understand, it was surprising. The surprise is also reflected in the post Problem with +(POSIXt, difftime)

Re: [Rd] Issue when calling deparse(substitute(x)) from C with anonymous R vectors ?

2009-11-19 Thread Laurent Gautier
Thanks to you and Peter for the quick answer. I should definitely have tried I R. It just seemed to me so unlikely that no one ever reported that anonymous vectors would fail with chisq.test(). Having a label that would be x or y is along the lines of something I was thinking of, and this

Re: [Rd] Issue when calling deparse(substitute(x)) from C with anonymous R vectors ?

2009-11-19 Thread Prof Brian Ripley
On Thu, 19 Nov 2009, Laurent Gautier wrote: Thanks to you and Peter for the quick answer. I should definitely have tried I R. It just seemed to me so unlikely that no one ever reported that anonymous vectors would fail with chisq.test(). Having a label that would be x or y is along the

[Rd] In the documentation of 'Ops.Date', please remove mention about difftime, like in the documentation of 'DateTimeClasses' (PR#14072)

2009-11-19 Thread suharto_anggono
I am sorry to reply. But I need to clarify things.=0A=0AFrom searching over= the internet, I know that, before R 2.5.0, in the documentation of 'DateTi= meClasses', in 'date + x', in the explanation about 'x', there is also ment= ion that 'x' can be a 'difftime' object. Now, it has been

Re: [Rd] Issue when calling deparse(substitute(x)) from C with anonymous R vectors ?

2009-11-19 Thread Duncan Murdoch
Can you put together a minimal, self contained example, not requiring an external system? This has the symptoms of a bug in the external code (e.g. a missing PROTECT), but it is possible it's a bug in R. Duncan Murdoch On 19/11/2009 2:40 AM, Laurent Gautier wrote: Dear list, When calling

Re: [Rd] Issue when calling deparse(substitute(x)) from C with anonymous R vectors ?

2009-11-19 Thread Duncan Murdoch
On 19/11/2009 6:32 AM, Duncan Murdoch wrote: Can you put together a minimal, self contained example, not requiring an external system? This has the symptoms of a bug in the external code (e.g. a missing PROTECT), but it is possible it's a bug in R. And I should have read the followups before

[Rd] strange crashes caused by 'cairoDevice' and 'tcltk' dialogues

2009-11-19 Thread Liviu Andronic
Dear developers I get some strange crashes when 'cairoDevice' and 'tcltk' are both loaded in the same R vanilla session. When executing the following in that order require(relimp) require(cairoDevice) showData (iris) I get a crash with the following message (see R-relimp-cairoDevice.txt): The

Re: [Rd] combine UserDefinedDatabase and regular environments

2009-11-19 Thread Michael Lawrence
On Thu, Nov 5, 2009 at 9:58 AM, Romain Francois romain.franc...@dbmail.comwrote: Hello, Is it possible to have the effect of UserDefinedDatabase outside of attached environments ? Can I disguise an environment of the sys.frames() as a UserDefinedDatabase ? This seems to suggest that it

[Rd] R Usage Statistics

2009-11-19 Thread Kevin R. Coombes
Hi, I got the following comment from the reviewer of a paper (describing an algorithm implemented in R) that I submitted to BMC Bioinformatics: Finally, which useful for exploratory work and some prototyping, neither R nor S-Plus are appropriate environments for deploying user applications

Re: [Rd] combine UserDefinedDatabase and regular environments

2009-11-19 Thread Romain Francois
On 11/19/2009 06:14 PM, Michael Lawrence wrote: On Thu, Nov 5, 2009 at 9:58 AM, Romain Francois romain.franc...@dbmail.com mailto:romain.franc...@dbmail.com wrote: Hello, Is it possible to have the effect of UserDefinedDatabase outside of attached environments ? Can I disguise an

Re: [Rd] R Usage Statistics

2009-11-19 Thread Charles C. Berry
On Thu, 19 Nov 2009, Kevin R. Coombes wrote: Hi, I got the following comment from the reviewer of a paper (describing an algorithm implemented in R) that I submitted to BMC Bioinformatics: Finally, which useful for exploratory work and some prototyping, neither R nor S-Plus are appropriate

Re: [Rd] R Usage Statistics

2009-11-19 Thread Steven McKinney
Hi Kevin, What a surprising comment from a reviewer for BMC Bioinformatics. I just did a PubMed search for limma and aroma.affymetrix, just two methods for which I use R software regularly. limma yields 28 hits, several of which are published in BMC Bioinformatics. Bengtsson's aroma.affymetrix

Re: [Rd] R Usage Statistics

2009-11-19 Thread Marc Schwartz
On Nov 19, 2009, at 4:09 PM, Charles C. Berry wrote: On Thu, 19 Nov 2009, Kevin R. Coombes wrote: Hi, I got the following comment from the reviewer of a paper (describing an algorithm implemented in R) that I submitted to BMC Bioinformatics: Finally, which useful for exploratory work

[Rd] Surprising length() of POSIXlt vector (PR#14073)

2009-11-19 Thread mark
Arrays of POSIXlt dates always return a length of 9. This is correct (they're really lists of vectors of seconds, hours, and so forth), but other methods disguise them as flat vectors, giving superficially surprising behaviour: strings - paste('2009-1-', 1:31, sep='') dates -

Re: [Rd] Surprising length() of POSIXlt vector (PR#14073)

2009-11-19 Thread Benilton Carvalho
Check the documentation and the archives. Not a bug. b On Nov 19, 2009, at 8:30 PM, m...@celos.net wrote: Arrays of POSIXlt dates always return a length of 9. This is correct (they're really lists of vectors of seconds, hours, and so forth), but other methods disguise them as flat vectors,

Re: [Rd] Surprising length() of POSIXlt vector (PR#14073)

2009-11-19 Thread Steven McKinney
I've checked the archives, and this problem crops up every few months going back for years. What I was not able to find was an explanation of why a function such as length.POSIXlt - function(x) { length(x$sec) } is a Bad Idea, or what it would break. listserv threads seem to end without

[Rd] rounding the time: significant 0 does not appear (PR#14074)

2009-11-19 Thread gus1201
Full_Name: Gustavo Lacerda Version: 2.9.1 OS: Windows Submission from: (NULL) (137.82.157.97) I obtained 'time' by subtracting the results of two calls to sys.Time(). round(time,0) Time difference of 1 mins round(time,1) Time difference of 1 mins round(time,2) Time difference of 1.03 mins

Re: [Rd] Surprising length() of POSIXlt vector (PR#14073)

2009-11-19 Thread Benilton Carvalho
Steve, I'm no expert on this, but my understanding is that the choice was to stick to the definition. The help file for length() [1] says: For vectors (including lists) and factors the length is the number of elements. The help file for POSIXlt [2] (for example) says: Class ‘POSIXlt’

Re: [Rd] Surprising length() of POSIXlt vector (PR#14073)

2009-11-19 Thread Steven McKinney
-Original Message- From: Benilton Carvalho [mailto:bcarv...@jhsph.edu] Sent: Thursday, November 19, 2009 6:59 PM To: Steven McKinney Cc: 'm...@celos.net'; 'r-de...@stat.math.ethz.ch' Subject: Re: [Rd] Surprising length() of POSIXlt vector (PR#14073) Steve, I'm no expert on

Re: [Rd] rounding the time: significant 0 does not appear (PR#14074)

2009-11-19 Thread Don MacQueen
This is not a bug, and has nothing to do with times. For example: round(1.03,1) [1] 1 Formatting is not the same as rounding. Perhaps you are assuming R formats numbers according to the concept of significant digits, but it doesn't. See the help page for the format function to get started

Re: [Rd] rounding the time: significant 0 does not appear (PR#14075)

2009-11-19 Thread macq
This is not a bug, and has nothing to do with times. For example: round(1.03,1) [1] 1 Formatting is not the same as rounding. Perhaps you are assuming R formats numbers according to the concept of significant digits, but it doesn't. See the help page for the format function to get started

Re: [Rd] Surprising length() of POSIXlt vector (PR#14073)

2009-11-19 Thread William Dunlap
-Original Message- From: r-devel-boun...@r-project.org [mailto:r-devel-boun...@r-project.org] On Behalf Of Benilton Carvalho Sent: Thursday, November 19, 2009 6:59 PM To: Steven McKinney Cc: 'm...@celos.net'; 'r-de...@stat.math.ethz.ch' Subject: Re: [Rd] Surprising length() of

[Rd] structure of SYMSXP values.

2009-11-19 Thread Guillaume Yziquel
Hello. I've now added some support to OCaml-R in order to investigate low-level structures. See below for an output, concerning 'str'. But I'm having an issue concerning SEXPs with type SYMSXP. lazy {content = SYMSXP {pname = lazy {content = NILSXP};