foreach-package {foreach} | R Documentation |
The foreach package provides a new looping construct for executing R code repeatedly. The main reason for using the foreach package is that it supports parallel execution. The foreach package can be used with a variety of different parallel computing systems, include NetWorkSpaces and snow. In addition, foreach can be used with iterators, which allows the data to specified in a very flexible way.
Further information is available in the following help topics:
foreach | Specify the variables to iterate over |
%do% | Execute the R expression sequentially |
%dopar% | Execute the R expression using the currently registered backend |
For a complete list of functions with individual help pages,
use library(help="foreach")
.