[R] Python and R

Esmail Bonakdarian esmail.js at gmail.com
Wed Feb 18 13:27:16 CET 2009


Gabor Grothendieck wrote:
> 
> 
> See ?Rprof for profiling your R code.
> 
> If lm is the culprit, rewriting your lm calls using lm.fit might help.

Yes, based on my informal benchmarking, lm is the main "bottleneck", the rest
of the code consists mostly of vector manipulations and control structures.

I am not familiar with lm.fit, I'll definitely look it up. I hope it's similar
enough to make it easy to substitute one for the other.

Thanks for the suggestion, much appreciated. (My runs now take sometimes
several hours, it would be great to cut that time down by any amount :-)

Esmail




More information about the R-help mailing list