The R Project SVN R

Rev

Rev 57404 | Rev 72133 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 57404 Rev 59272
Line 15... Line 15...
15
          c(a =  1, b = 2, c = 3), c(A = 10, B = 0, C = -10))
15
          c(a =  1, b = 2, c = 3), c(A = 10, B = 0, C = -10))
16
 
16
 
17
 
17
 
18
parSapply(cl, 1:20, get("+"), 3)
18
parSapply(cl, 1:20, get("+"), 3)
19
 
19
 
-
 
20
## PR14898
-
 
21
parSapply(cl, 1, identity)
-
 
22
 
-
 
23
 
20
## A bootstrapping example, which can be done in many ways:
24
## A bootstrapping example, which can be done in many ways:
21
clusterEvalQ(cl, {
25
clusterEvalQ(cl, {
22
  ## set up each worker.  Could also use clusterExport()
26
  ## set up each worker.  Could also use clusterExport()
23
  library(boot)
27
  library(boot)
24
  cd4.rg <- function(data, mle) MASS::mvrnorm(nrow(data), mle$m, mle$v)
28
  cd4.rg <- function(data, mle) MASS::mvrnorm(nrow(data), mle$m, mle$v)