[R] foreach loop - rejection method

2009-10-07 Thread dunno87
Hi Everybody, Thanks in advance for your help. This is my first time using the foreach statement and I cant get it to work properly so here is what i have test<-function(){ repeat { cand2[l-1]<-rinvgamma(1,phi,lambda[l-1]) q2<-dinvgamma(cand2[l-1],phi,lambda[l-1]) p2<-cand2[l-1]^-1.5*exp(-y[l]^2

[R] multicore - no parallel

2009-10-03 Thread dunno87
Hi everyone, Thanks for the help in advance. I just want to know if there is absolutely any way of using multicore if my loop can't run in parallel as each iteration depends on the previous iteration. I have Windows R 2.9.2 and REvolution R Enterprise 2.0 for Windows 64 bit. I also have if necess