Learn R Programming

Emcdf (version 0.1.2)

coreNum: CPU core number

Description

This function reports the total core number in CPU on the machine.

Usage

coreNum()

Arguments

Value

an integer indicating the total number of cores in CPU.

Details

This function is a wrapper for the C++ function std::thread::hardware_concurrency(); If core number is not detected, 0 will be returned. See "See Also" for details.

See Also

http://www.cplusplus.com/reference/thread/thread/hardware_concurrency/

Examples

Run this code
# NOT RUN {
num = coreNum()

# }

Run the code above in your browser using DataLab