Re: [Rd] simple add error (PR#13699)

2009-05-14 Thread Petr Savicky
On Wed, May 13, 2009 at 02:35:12PM +0200, gos...@igmm.cnrs.fr wrote: I cannot explain why R seems to have problems adding two big numbers. sprintf(%f,10^4+10^19) gives 10010240.00 instead of 1001.00 problems seems to arrive when i'm

Re: [Rd] different results on linux and windows

2009-05-14 Thread Friedrich Leisch
On Tue, 12 May 2009 13:30:21 +0300, Klaus Nordhausen (KN) wrote: Dear R experts, we are preparing an R-package to compute the Oja Median which contains some C++ code in which random numbers are needed. To generate the random numbers we use the following Mersenne-Twister

Re: [Rd] different results on linux and windows

2009-05-14 Thread Kjell Konis
Hi Klaus, Why not just use R's random number generator? See section 6.3 of Writing R Extensions. It should give you the same sequence of pseudorandom numbers on all platforms. HTH, Kjell On 12 mai 09, at 12:30, Klaus Nordhausen wrote: Dear R experts, we are preparing an R-package to

Re: [Rd] different results on linux and windows

2009-05-14 Thread Ei-ji Nakama
Hi 2009/5/12 Klaus Nordhausen klaus.nordhau...@uta.fi: Our suspicion is that the reason is that some libraries are different implemented on linux and windows (XP) compilers. If useful. http://www.derkeiler.com/Newsgroups/sci.crypt/2004-10/1325.html I think that you do not like to use rand

Re: [Rd] different results on linux and windows

2009-05-14 Thread Paul Gilbert
I cannot say what the problem is in your code, but in general it is possible to get the same random sequences from Linux and Windows with R's Mersenne Twister generator. If you generate long sequences (say 10s of thousands) and then start doing comparisons involving remainders, like

[Rd] R Java

2009-05-14 Thread Philippe Lamote
Hey guys, I'm a (Java) integration architect. We are currently stuck with SAS but I'd be happy to switch that to R! (of course ;-). Now, a big argument for the latter, is that we can integrate it seamlessly with all our existing (java) apps. Therefore: has anyone heard of a java API (like SAS

Re: [Rd] R Java

2009-05-14 Thread spencerg
I don't have an answer, but I suspect that if you install.packages(RSiteSearch), you might find information relevant to your question from the following: library(RSiteSearch) java - RSiteSearch.function('Java') summary(java) # Reports that 136 help pages contained Java, 23 of which are

Re: [Rd] R Java

2009-05-14 Thread Dirk Eddelbuettel
On 14 May 2009 at 16:39, Philippe Lamote wrote: | I'm a (Java) integration architect. | We are currently stuck with SAS but I'd be happy to switch that to R! (of | course ;-). | Now, a big argument for the latter, is that we can integrate it seamlessly | with all our existing (java) apps. |

[Rd] using a third party DLL in my package

2009-05-14 Thread Seija SirkiƤ
Hello all, it seems my efforts in reading the manuals and help files aren't enough so here I am. The question is, how would I go about linking a pre-compiled DLL in to my package? I have previously successfully built packages with Fortran and C source code, but now I'd like to take this

[Rd] diag() has a bug (PR#13702)

2009-05-14 Thread michael . m . spiegel
Full_Name: Michael Spiegel Version: 2.9.0 OS: linux Submission from: (NULL) (204.111.252.142) The diag() function appears to reject the first argument when it is a matrix, and nrow and ncol arguments are also provided. foo - matrix(c(1:4),2,2) foo [,1] [,2] [1,]13 [2,]24

Re: [Rd] R Java

2009-05-14 Thread Alex D'Amour
I think you are looking for something like RServe. http://rosuda.org/Rserve/. It sets up R as a server which you talk to via TCP/IP. It has client APIs for Java and a number of other languages. Alex On Thu, May 14, 2009 at 10:39 AM, Philippe Lamote plam...@its.jnj.com wrote: Hey guys, I'm a

Re: [Rd] diag() has a bug (PR#13702)

2009-05-14 Thread Benilton Carvalho
My understanding is that providing nrow and ncol, you want to create a diagonal matrix with those dimensions. diag(pi, 6, 6) and that by diag(foo, 2, 2) you really meant diag(foo)[2] Apologies if I misunderstood. b On May 14, 2009, at 10:45 AM, michael.m.spie...@gmail.com wrote:

Re: [Rd] diag() has a bug (PR#13702)

2009-05-14 Thread Peter Dalgaard
Benilton Carvalho wrote: in that case, wouldn't diag(diag(foo)) suffice? Yes (beware the length 1 case, though). However, don't delete the bug report. That error message is just wrong: if (is.array(x) length(dim(x)) != 1L) stop(first argument is array, but not matrix.) b

[Rd] will one of you help me advocate a change in t.test (patch attached)

2009-05-14 Thread Paul Johnson
I wish the t.test function in stats would return the standard error. It would be nicer for students if R simply reported the standard error used to calculate the t value. I trolled for this in r-help and got no answers, which I interpreted to mean that this is boring but possibly not wrong.