parcellfun_set_nproc (parallel_doc)

Previous: pararrayfun, Up: Local execution [Index]

### 2.3 Function parcellfun_set_nproc

Loadable Function: nproc = parcellfun_set_nproc (nproc_arg)

  Set current number of background processes for parcellfun.

  The number of used background processes is determined by the first argument to `parcellfun`. If necessary, `parcellfun` will spawn new background processes, but it will never remove any of them, even if it does not use all of them. `parcellfun_set_nproc` can be used to set the number of currently spawned processes to nproc_arg. This may be used to remove all background processes between calls to `parcellfun` by specifying an nproc_arg of zero.

  The real number of spawned processes will be limited to the available processor cores and is returned.

  See also: parcellfun.