Re: [R] Loop overwrite and data output problems

2010-03-01 Thread RCulloch
HI Ivan, thanks for your post, I really appreciate the time you've taken over my problem! if (I==1) Sample.dat<-tmp[sample(1:max,1),] else { Sample.dat<-rbind(Sample.dat,tmp[sample(1:max,1),]) This part of the script works - I appreciate that it may not be the best option and I'm perhaps paper

Re: [R] Loop overwrite and data output problems

2010-02-26 Thread Ivan Calandra
Hi, Since I'm not an expert, I still have problems understanding when it's not my own work, but I have something that might help you. if (I==1) Sample.dat<-tmp[sample(1:max,1),] else { Sample.dat<-rbind(Sample.dat,tmp[sample(1:max,1),]) This part might not be the best. I would do something lik