[R] Help on R performance using aov function

Francoise PFIFFELMANN francoise.pfiffelmann at st.com
Thu Aug 9 11:48:28 CEST 2007

I’m trying to replace some SAS statistical functions by R (batch calling).
But I’ve seen that calling R in a batch mode (under Unix) takes about 2or 3
times more than SAS software. So it’s a great problem of performance for me.
Here is an extract of the calculation:

for (i in 1:n) { 
aov_<-aov(A[,p]~ A[,"wafer"],data=A); 
if (!is.na(anova_[[1]][1,5]) & anova_[[1]][1,5]<=0.0001)
res_aov<-cbind(p,anova_[[1]][1,4],"<0.0001") else
cat(res_aov, file=stoutput, append = TRUE,sep = "|","\n"); 

A is a data.frame of about (400 lines and 1800 parameters).
I’m a new user of R and I don’t know if it’s a problem in my code or if
there are some tips that I can use to optimise my treatment.

Thanks a lot for your help.

Françoise Pfiffelmann
Engineering Data Analysis Group
Crolles2 Alliance
860 rue Jean Monnet
38920 Crolles, France
Tel: +33 438 92 29 84
Email: francoise.pfiffelmann at st.com

More information about the R-help mailing list