Sign in with Microsoft
Sign in or create an account.
Select a different account.
You have multiple accounts
Choose the account you want to sign in with.

numCoresToUse (and rxOptions, in general) is related only to setting up distributed computing for RevoScaleR functions. foreach and doParallel do not use it. To run your script in parallel mode, you will need to first register a parallel backend for your foreach command.  Instead of setting numCoresToUse, use

library(doParallel} registerDoParallel(cores=6)

getDoParWorkers() should return 6 at this point. This sets up a "compute cluster" across each core, each of which can run an R process and communicate over sockets with the others. 

Some additional resources on using foreach and doParallel that will explain more options on running in parallel:

Need more help?

Want more options?

Explore subscription benefits, browse training courses, learn how to secure your device, and more.

Communities help you ask and answer questions, give feedback, and hear from experts with rich knowledge.

Was this information helpful?

What affected your experience?
By pressing submit, your feedback will be used to improve Microsoft products and services. Your IT admin will be able to collect this data. Privacy Statement.

Thank you for your feedback!