Package: foreach 1.5.2

Folashade Daniel

foreach: Provides Foreach Looping Construct

Support for the foreach looping construct. Foreach is an idiom that allows for iterating over elements in a collection, without the use of an explicit loop counter. This package in particular is intended to be used for its return value, rather than for its side effects. In that sense, it is similar to the standard lapply function, but doesn't require the evaluation of a function. Using foreach without side effects also facilitates executing the loop in parallel.

Authors:Folashade Daniel [cre], Hong Ooi [ctb], Rich Calaway [ctb], Microsoft [aut, cph], Steve Weston [aut]

foreach_1.5.2.tar.gz
foreach_1.5.2.zip(r-4.7)foreach_1.5.2.zip(r-4.6)foreach_1.5.2.zip(r-4.5)
foreach_1.5.2.tgz(r-4.6-any)foreach_1.5.2.tgz(r-4.5-any)
foreach_1.5.2.tar.gz(r-4.7-any)foreach_1.5.2.tar.gz(r-4.6-any)
foreach_1.5.2.tgz(r-4.6-emscripten)
manual.pdf |manual.html
card.svg |card.png
foreach/json (API)
NEWS

# Install 'foreach' in R:
install.packages('foreach', repos = c('https://revolutionanalytics.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/revolutionanalytics/foreach/issues

On CRAN:

Conda:

foreachparallel-computing

17.41 score 56 stars 3.0k packages 53k scripts 323k downloads 50 mentions 23 exports 2 dependencies

Last updated from:59176c0c37. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-x86_64OK244
source / vignettesOK239
linux-release-x86_64OK244
macos-release-arm64OK134
macos-oldrel-arm64OK134
windows-develOK111
windows-releaseOK109
windows-oldrelOK102
wasm-releaseOK110

Exports:%:%%do%%dopar%accumulateforeachgetDoParNamegetDoParRegisteredgetDoParVersiongetDoParWorkersgetDoSeqNamegetDoSeqRegisteredgetDoSeqVersiongetDoSeqWorkersgetErrorIndexgetErrorValuegetexportsgetResultmakeAccumregisterDoSEQsetDoParsetDoSeqtimeswhen

Dependencies:codetoolsiterators

Using the foreach package

Rendered fromforeach.Rmdusingknitr::rmarkdownon May 09 2026.

Last update: 2020-02-19
Started: 2020-02-19

Nesting foreach loops

Rendered fromnested.Rmdusingknitr::rmarkdownon May 09 2026.

Last update: 2020-02-19
Started: 2020-02-19

Readme and manuals

Help Manual

Help pageTopics
foreach%:% %do% %dopar% foreach times when
foreach extension functionsaccumulate accumulate.ifilteredforeach accumulate.iforeach accumulate.ixforeach foreach-ext getErrorIndex getErrorIndex.ifilteredforeach getErrorIndex.iforeach getErrorIndex.ixforeach getErrorValue getErrorValue.ifilteredforeach getErrorValue.iforeach getErrorValue.ixforeach getexports getResult getResult.ifilteredforeach getResult.iforeach getResult.ixforeach makeAccum
Functions Providing Information on the doPar BackendgetDoParName getDoParRegistered getDoParVersion getDoParWorkers
Functions Providing Information on the doSeq BackendgetDoSeqName getDoSeqRegistered getDoSeqVersion getDoSeqWorkers
registerDoSEQregisterDoSEQ
setDoParsetDoPar
setDoSeqsetDoSeq