nbrOfWorkers {future}R Documentation

Gets the number of workers available

Description

Gets the number of workers available

Usage

nbrOfWorkers(evaluator = NULL)

Arguments

evaluator

A future evaluator function. If NULL (default), the current evaluator as returned by plan() is used.

Value

A number in [1, Inf].

Examples

plan(multiprocess)
nbrOfWorkers()  ## == availableCores()

plan(sequential)
nbrOfWorkers()  ## == 1

[Package future version 1.12.0 Index]