Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bag chokes on regression #34

Open
tobigithub opened this issue Jul 17, 2016 · 0 comments
Open

bag chokes on regression #34

tobigithub opened this issue Jul 17, 2016 · 0 comments

Comments

@tobigithub
Copy link
Owner

caret_6.0-70 and R version 3.3.1

method <- c( "bag")

# -------------------------------------------------------------------------
# FIRST sequential code (not parallel one CPU core):
# ------------------------------------------------------------------------- 

require(caret); data(BloodBrain); set.seed(123)
fit1 <- train(bbbDescr, logBBB, method); fit1

# ------------------------------------------------------------------------- 
# SECOND parallel register 4 cores (no worries if you only have 2)
# train the caret model in parallel 
# -------------------------------------------------------------------------

library(doParallel); cl <- makeCluster(4); registerDoParallel(cl) 
  require(caret); data(BloodBrain); set.seed(123)
  fit1 <- train(bbbDescr, logBBB, method); fit1
stopCluster(cl); registerDoSEQ();

### END
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant