Re: [Rd] Guidelines for S3 regression models

2015-06-30 Thread Stephen Milborrow
Venables and Ripley S programming book. On 26.06.2015 14:09, Stephen Milborrow wrote: > Once we have built a regression model, we typically want to use the > model for further processing, such as making predictions from the model > or plotting the residuals. Unfortunately, for many package

Re: [Rd] legitimate use of :::

2013-08-23 Thread Stephen Milborrow
To avoid the NOTEs (which often triggers a 'pls fix' upon submission to CRAN), I simply copied/pasted these functions to my package, but this seems wasteful. An issue is how one acknowledges the author of the cut and pasted code. Assume that for one reason or another the original function can't

[Rd] Postscript can be very slow in R 2.13-0

2011-04-14 Thread Stephen Milborrow
() function (or could one be added) that would sacrifice sRGB support for speed? Stephen Milborrow www.milbo.users.sonic.net Version info: I'm using GSview 4.9 and Ghostscript 8.64. R.version _ platform x86_64-pc-mingw32 arch x86_64 os mingw32 s

Re: [Rd] 0 ^ NaN == Inf, why?

2008-10-26 Thread Stephen Milborrow
doing a full test of incompatiblities between R math and IEEE 754, if people think time spent doing that is worth it. Steve www.milbo.users.sonic.net - Original Message - From: "John Chambers" <[EMAIL PROTECTED]> To: "Stephen Milborrow" <[EMAIL PROTECTE

[Rd] 0 ^ NaN == Inf, why?

2008-10-25 Thread Stephen Milborrow
In R, 0 ^ NaN yields Inf. I would have expected NaN or perhaps 0. Is this behaviour intended? >sessionInfo() R version 2.8.0 (2008-10-20) i386-pc-mingw32 locale: LC_COLLATE=English_United States.1252;LC_CTYPE=English_United States.1252;LC_MONETARY=English_United States.1252;LC_NUMERIC=C;LC_TI

Re: [Rd] HOW TO AVOID LOOPS

2008-04-14 Thread Stephen Milborrow
t 0.25# code is shown above, 7 secs with standard R 2.6.2> Stephen Milborrow www.milbo.users.sonic.net # cm-post.R: compare solutions to the following post to #r-devel from carlos martinez 12 apr 2008: # Looking for a simple, effective a minimum execution time solution. #

[Rd] Just-in-time compiler for R

2008-04-04 Thread Stephen Milborrow
There is a new version of the just-in-time compiler for R at www.milbo.users.sonic.net/ra/index.html With just-in-time compilation enabled, the convolution example from the "Extending R" manual now runs about 30 times faster. The web page has more information. Stephen

Re: [Rd] gctorture and proc.time (PR#10600)

2008-01-22 Thread Stephen Milborrow
I'm not sure if this is connected but in R2.6.1 do_proctime is missing some PROTECTs. The current code is SEXP ans = allocVector(REALSXP, 5), nm = allocVector(STRSXP, 5); and should be SEXP ans, nm; PROTECT(ans = allocVector(REALSXP, 5)); PROTECT(nm = allocVector(STRSXP, 5)); A goo

[Rd] Just-in-time compiler for R

2008-01-16 Thread Stephen Milborrow
+ j] + a[i] * b[j] The loop will run about 30% faster. That's not much of a speedup, but the code is still in early development and the figure will get much better. If you are interested there is more information at www.milbo.users.sonic.net/ra. Stephen Milborrow www.milbo.users.s

[Rd] Modifying R_CheckStack for a speed increase

2007-08-29 Thread Stephen Milborrow
Greetings R developers, R will run a little faster when executing "pure R" code if the function R_CheckStack() is modified. With the modification, the following code for example runs 15% faster (compared to a virgin R-2.5.1 on my Windows XP machine): N = 1e7 foo <- function(x)