Parallel random forest with ranger function in R: How to combine results for prediction?
<p>I am trying to fit a random forest classification model using parallel computing with the ranger() function under a foreach() parallelization. If I use 7 cores to process, I get a list of results, from which I can extract 7 individual rangers, however I cannot combine the results in order to create a model for prediction. </p>

<pre><code>    rf&lt;-foreach(num.tree=rep(80,7), .multicombine=TRUE, .verbose=TRUE,
        .packages=c('ranger', 'randomForest', 'methods')) %dopar% {
 ranger(hotel_cluster~. , as.data.frame(train_s01[(1:10000),]), num.tree=num.tree, write.forest=TRUE) 
}
</code></pre>

<p>I have tried using the .combine=combine function but it throws an error, and I am not sure where to go from there. Any suggestions on how to combine these would be great. </p>

<p>As a sidenote, my full dataset is very large (37 million rows) and has 100 classes, so I will not be able to use the randomForest package due to factor limitations and I do not want to have to cluster these classes any further. </p>

<p>Cheers</p>