Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

snow-parallel

Higher Level SNOW Functions


Description

Parallel versions of apply and related functions.

Usage

parLapply(cl, x, fun, ...)
parSapply(cl, X, FUN, ..., simplify = TRUE, USE.NAMES = TRUE) 
parApply(cl, X, MARGIN, FUN, ...)
parRapply(cl, x, fun, ...)
parCapply(cl, x, fun, ...)
parMM(cl, A, B)

Arguments

cl

cluster object

fun

function or character string naming a function

X

array to be used

x

matrix to be used

FUN

function or character string naming a function

MARGIN

vector specifying the dimensions to use.

simplify

logical; see sapply

USE.NAMES

logical; see sapply

...

additional arguments to pass to standard function

A

matrix

B

matrix

Details

parLapply, parSapply, and parApply are parallel versions of lapply, sapply, and apply.

parRapply and parCapply are parallel row and column apply functions for a matrix x; they may be slightly more efficient than parApply.

parMM is a very simple(minded) parallel matrix multiply; it is intended as an illustration.

Examples

## Not run: 
cl <- makeSOCKcluster(c("localhost","localhost"))
parSapply(cl, 1:20, get("+"), 3)
  
## End(Not run)

snow

Simple Network of Workstations

v0.4-3
GPL
Authors
Luke Tierney, A. J. Rossini, Na Li, H. Sevcikova
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.