Skip to contents

Set the number of parallel threads to use. mcATAC uses the R function doMC::registerDoMC to register the parallelization. By default, mcATAC uses 80% of the number of available cores. The options are saved under 'mcatac.parallel' (should we use parallelization, logical) and 'mcatac.parallel.nc' (number of cores to use, integer).

Usage

set_parallel(thread_num = max(1, round(parallel::detectCores() * 0.8)))

Arguments

thread_num

number of threads. use '1' for non parallel behavior

Value

None

Examples

# \donttest{
set_parallel(8)
#>  Parallelization enabled. Using 8 threads.
# }