R/RepParallel.R

## Copyright (C) 2010-2015 Gray Calhoun; MIT license

    RepParallel <- function(n, expr, simplify = "array",...) {
      answer <-
        mclapply(integer(n), eval.parent(substitute(function(...) expr)),...)
      if (!identical(simplify, FALSE) && length(answer)) 
        return(simplify2array(answer, higher = (simplify == "array")))
      else return(answer)
    }
grayclhn/dbframe-R-library documentation built on May 17, 2019, 8:33 a.m.