Re: [R] foreach {parallel} nested with for loop to update data.frame column

2016-08-08 Thread Alexander.Herr
Actually, you'll need to identify the values of the foreach loop in the for loop for it to work... require(doParallel) require(foreach) set.seed(666) xyz<-as.data.frame(cbind(x=rep(rpois(5,10),2)+1, y=rep(rpois(5,10),2)+1,z=round(runif(10, min=-3, max=40),2))) xyz$mins<-rep(NA,

Re: [R] foreach {parallel} nested with for loop to update data.frame column

2016-08-04 Thread Alexander.Herr
; From: R-help [mailto:[hidden email]] On Behalf Of [hidden email] > Sent: Thursday, August 4, 2016 3:32 AM > To: [hidden email] > Subject: [R] foreach {parallel} nested with for loop to update > data.frame column > > Hi List, > > Trying to update a data.frame column wi

Re: [R] foreach {parallel} nested with for loop to update data.frame column

2016-08-04 Thread Alexander.Herr
> Sent: Thursday, August 4, 2016 3:32 AM > To: [hidden email] > Subject: [R] foreach {parallel} nested with for loop to update data.frame > column > > Hi List, > > Trying to update a data.frame column within a foreach nested for loop > > ### trial data > s

Re: [R] foreach {parallel} nested with for loop to update data.frame column

2016-08-04 Thread PIKAL Petr
12 0.12 0.12 6 19 11 7.91 7.91 > Cheers Petr > -Original Message- > From: R-help [mailto:r-help-boun...@r-project.org] On Behalf Of > alexander.h...@csiro.au > Sent: Thursday, August 4, 2016 3:32 AM > To: r-h...@stat.math.ethz.ch > Subject: [R] foreach {para

[R] foreach {parallel} nested with for loop to update data.frame column

2016-08-03 Thread Alexander.Herr
Hi List, Trying to update a data.frame column within a foreach nested for loop ### trial data set.seed(666) xyz<-as.data.frame(cbind(x=rep(rpois(5000,10),2)+1, y=rep(rpois(5000,10),2)+1,z=round(runif(1, min=-3, max=40),2))) xyz$mins<-rep(NA, nrow(xyz)) cl<-makeCluster(16) #adjust to your