Reading the vignette for doparallel.
Are the following two code blocks one and the same?
library(doparallel)
no_cores <- 8
cl <- makeCluster(no_cores)
registerDoParallel(cl)
pieces <- foreach(i = seq_len(length(pieces))) %dopar% { # do stuff}
Is above just the same as this:
library(doparallel)
registerDoParallel(cores = 8)
pieces <- foreach(i = seq_len(length(pieces))) %dopar% { # do stuff}
Must I makeCluster() when using doparallel if I want to use multiple cores? or is the single line enough registerDoParallel(cores = 8)