Can somebody give a hint on how to speed-up the following loop:
for(j in 0:KM1) { k=j*60 for(i in 1:60) { dat$yvac[k+i]= rbinom(1,dat$nvac[k+i],dat$p.trt[j+i]) } } K1=999 -- -Tony [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.