| mclapply {parallel} | R Documentation |
Serial versions of mclapply and pvec
Description
These are simple serial versions of mclapply and pvec
for Windows where forking is not available.
Usage
mclapply(X, FUN, ..., mc.preschedule = TRUE, mc.set.seed = TRUE,
mc.silent = FALSE, mc.cores = 1L,
mc.cleanup = TRUE, mc.allow.recursive = TRUE)
pvec(v, FUN, ..., mc.set.seed = TRUE, mc.silent = FALSE,
mc.cores = 1L, mc.cleanup = TRUE)
Arguments
X |
a vector (atomic or list) or an expressions vector. Other
objects (including classed objects) will be coerced by
|
v |
vector to operate on |
FUN |
the function to be applied to each element of |
... |
optional arguments to |
mc.preschedule, mc.set.seed, mc.silent, mc.cleanup, mc.allow.recursive |
Ignored on Windows. |
mc.cores |
The number of cores to use, i.e. at most how many child processes will be run simultaneously. Must be exactly 1 on Windows (which uses the master process). |
Details
mclapply calls lapply and pvec makes a
single call FUN(v, ...). On Unix-alikes mc.cores > 1
is allowed and uses parallel operations.
Value
For mclapply, a list of the same length as X and named
by X.
For pvec, a vector of the same length as v.
See Also
parLapply.