Re: [R] Help transfrom R to C

2010-04-07 Thread Benilton Carvalho
maybe inc.freqy <- sapply(unit.dist, function(x) rowSums( test <= x)) suffices? b On Mon, Apr 5, 2010 at 5:31 PM, pinusan wrote: > > Dear R users, > > I would like to transform the following "for loop" from R-code to C-code > because it takes really long time to have inc.freqy table. > Unfortu

Re: [R] Help transfrom R to C

2010-04-05 Thread Thomas Lumley
On Mon, 5 Apr 2010, pinusan wrote: Dear R users, I would like to transform the following "for loop" from R-code to C-code because it takes really long time to have inc.freqy table. Unfortunately, I do not have experience to write C code. Plese, give me some example or advise to transfrom the R

[R] Help transfrom R to C

2010-04-05 Thread pinusan
Dear R users, I would like to transform the following "for loop" from R-code to C-code because it takes really long time to have inc.freqy table. Unfortunately, I do not have experience to write C code. Plese, give me some example or advise to transfrom the R to C code. I have attached the code