search for: origseed

Displaying 1 result from an estimated 1 matches for "origseed".

Did you mean: orig_end
2012 Jan 13
0
Example of "task seeds" with R parallel. Critique?
...on nReps <- 2000 streamsPerRep <- 2 ## projSeeds=list of lists of stream seeds projSeeds <- vector(mode="list", nReps) for (i in 1:nReps) projSeeds[[i]] <- vector(mode="list", streamsPerRep) runif(1) ##establishes .Random.seed ##Grab first seed s <- .Random.seed origSeed <- s x <- rnorm(4) ##will compare later x for (i in 1:nReps) { for (j in 1:streamsPerRep){ projSeeds[[i]][[j]] <- s s <- nextRNGStream(s) } } save(projSeeds, file="projSeeds.rda") rm(projSeeds) load("projSeeds.rda") ##Note that origSeed does match...