Re: [Rd] [R] which.na

2009-03-20 Thread Duncan Murdoch
Martin Maechler wrote: CAPE == Charles Annis, P E charles.an...@statisticalengineering.com on Thu, 19 Mar 2009 22:46:10 -0400 writes: ?is.na x - c(NA, 3, 4, 5, NA) which(is.na(x)) CAPE [1] 1 5 well, of course. But note that which.na(.) could be

Re: [Rd] using R with java

2009-03-20 Thread RMP
Hi, In order to do this you should use JRI (Java R Interface). Note, you should first download rJava package within which you can find the JRI library. Good luck! RMP Bilel Masmoudi wrote: Hi, I am a java programmer, an I want to use R from java. could so help me thanks for telling me

[Rd] v2.8.1 crashes on quit(save=yes) or just won't save (PR#13612)

2009-03-20 Thread anne . gilman
Full_Name: Anne Gilman Version: 2.8.1 OS: Mac OS X 10.4.11 Submission from: (NULL) (132.177.75.245) Dear R Team, Today I upgraded from R 2.2.2 to 2.8.1 ...then I restarted, did a bunch of work, and tried to quit. (Note that I have oodles of stuff saved in the work environment; took almost a

[Rd] sprintf causes a segfault (PR#13613)

2009-03-20 Thread waku
Full_Name: Wacek Kusnierczyk Version: 2.8.0 and 2.10.0 r48163 OS: Ubuntu 8.04 Linux 32bit Submission from: (NULL) (129.241.198.172) the following code illustrates a problem with sprintf which consistently causes a segfault when applied to certain type of arguments. it also shows inconsistent

Re: [Rd] [R] which.na

2009-03-20 Thread Stavros Macrakis
There are many other useful extensions one might imagine along these lines. For instance, we could have an argument for stopping the 'which' calculation at the first result (or the first N results), which is often useful (cf. any). But I think it would be much cleaner for things like this to be

Re: [Rd] v2.8.1 crashes on quit(save=yes) or just won't save (PR#13612)

2009-03-20 Thread Uwe Ligges
anne.gil...@gmail.com wrote: Full_Name: Anne Gilman Version: 2.8.1 OS: Mac OS X 10.4.11 Submission from: (NULL) (132.177.75.245) Dear R Team, Today I upgraded from R 2.2.2 to 2.8.1 ...then I restarted, did a bunch of work, and tried to quit. (Note that I have oodles of stuff saved in the

Re: [Rd] R does not compile any more on FreeBSD 8.0-CURRENT

2009-03-20 Thread Rainer Hurling
On 19.03.2009 10:37 (UTC+1), Hiroyuki Kawakatsu wrote: Rainer Hurling wrote: On a recent FreeBSD 8.0-CURRENT (i386) building R (any version) breaks with the following messages: [...] I run 7.1-RELEASE (amd64) so I cannot comment on any potential issues with 8.0-CURRENT. On my machine the

Re: [Rd] [R] which.na

2009-03-20 Thread William Dunlap
If you are considering emulating the S/S+ which.na, which.nan, etc., family of functions to save space you might also consider the related anyMissing function (I don't know why it isn't any.is.na to match the pattern). anyMissing(x) returns the same result as any(is.na(x)) or length(which.na(x))

[Rd] Why does the lexical analyzer drop comments ?

2009-03-20 Thread romain . francois
It happens in the token function in gram.c:     c = SkipSpace();     if (c == '#') c = SkipComment(); and then SkipComment goes like that: static int SkipComment(void) {     int c;     while ((c = xxgetc()) != '\n' c != R_EOF) ;     if (c == R_EOF) EndOfFile = 2;    

Re: [Rd] Why does the lexical analyzer drop comments ?

2009-03-20 Thread Duncan Murdoch
On 3/20/2009 2:56 PM, romain.franc...@dbmail.com wrote: It happens in the token function in gram.c: Â Â Â c = SkipSpace(); Â Â Â if (c == '#') c = SkipComment(); and then SkipComment goes like that: static int SkipComment(void) { Â Â Â int c; Â Â Â while ((c = xxgetc()) != '\n' c !=

Re: [Rd] Why does the lexical analyzer drop comments ?

2009-03-20 Thread Romain Francois
Peter Dalgaard wrote: Duncan Murdoch wrote: On 3/20/2009 2:56 PM, romain.franc...@dbmail.com wrote: It happens in the token function in gram.c: Â Â Â c = SkipSpace(); Â Â Â if (c == '#') c = SkipComment(); and then SkipComment goes like that: static int SkipComment(void) { Â Â Â int c; Â Â

[Rd] [SOLVED] Re: R does not compile any more on FreeBSD 8.0-CURRENT

2009-03-20 Thread Rainer Hurling
Todays (03/20/2009) update of FreeBSD 8.0-CURRENT solved the problem. The two pathes are resolving again. So building and installing R on CURRENT works again :-) Thanks for your patience, Rainer On 17.03.2009 16:11 (UTC+1), Rainer Hurling wrote: On a recent FreeBSD 8.0-CURRENT (i386)

Re: [Rd] Why does the lexical analyzer drop comments ?

2009-03-20 Thread Peter Dalgaard
Duncan Murdoch wrote: On 3/20/2009 2:56 PM, romain.franc...@dbmail.com wrote: It happens in the token function in gram.c: Â Â Â c = SkipSpace(); Â Â Â if (c == '#') c = SkipComment(); and then SkipComment goes like that: static int SkipComment(void) { Â Â Â int c; Â Â Â while ((c =

[Rd] throwing a condition when the current working directory changes

2009-03-20 Thread Romain Francois
Hi, Would it make sense to throw a condition when the working directory changes, so that interested parties (such as guis can act based on the change using an appropriate calling handler), and not interested parties can just ignore it. For example, something like this: setwd - function

Re: [Rd] sprintf causes a segfault (PR#13613)

2009-03-20 Thread Wacek Kusnierczyk
strangely enough, the way r handles the same sequence of expressions on different occasions varies: # fresh session 1 e = simpleError('foo') sprintf('%s', e) # segfault: address 0x202, cause memory not mapped # ^c sprintf('%s', e) # error in sprintf(%s, e) :