The R Project SVN R

Rev

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

Rev 67806 Rev 72133
Line 19... Line 19...
19
 
19
 
20
## PR14898
20
## PR14898
21
parSapply(cl, 1, identity)
21
parSapply(cl, 1, identity)
22
 
22
 
23
if(require(boot)) {
23
if(require(boot)) {
-
 
24
    set.seed(11)
24
    ## A bootstrapping example, which can be done in many ways:
25
    ## A bootstrapping example, which can be done in many ways:
25
    clusterEvalQ(cl, {
26
    clusterEvalQ(cl, {
26
        ## set up each worker.  Could also use clusterExport()
27
        ## set up each worker.  Could also use clusterExport()
27
        library(boot)
28
        library(boot)
28
        cd4.rg <- function(data, mle) MASS::mvrnorm(nrow(data), mle$m, mle$v)
29
        cd4.rg <- function(data, mle) MASS::mvrnorm(nrow(data), mle$m, mle$v)