I am using quantregForest with parallel computation and I have noticed that the mean squared error values are not getting calculated when using the parallel option. I am not sure why this is happening, looking at the parallelRandomForest code it looks like mse should be part of the output of the function.
qrf <- quantregForest(x=Xtrain, y=Ytrain, keep.inbag = TRUE, importance=TRUE, nthreads=10)
qrf$mse
NULL
plot(qrf)
Error in array(x, c(length(x), 1L), if (!is.null(names(x))) list(names(x), :'data' must be of a vector type, was 'NULL'
I am using quantregForest with parallel computation and I have noticed that the mean squared error values are not getting calculated when using the parallel option. I am not sure why this is happening, looking at the parallelRandomForest code it looks like mse should be part of the output of the function.
Following the example in the documentation:
library("randomForest") library("quantregForest") library("parallel")
data(airquality) set.seed(1) airquality <- airquality[ !apply(is.na(airquality), 1,any), ] n <- nrow(airquality) indextrain <- sample(1:n,round(0.6*n),replace=FALSE) Xtrain <- airquality[ indextrain,2:6] Ytrain <- airquality[ indextrain,1]
qrf <- quantregForest(x=Xtrain, y=Ytrain, keep.inbag = TRUE, importance=TRUE) qrf$mse plot(qrf)
qrf <- quantregForest(x=Xtrain, y=Ytrain, keep.inbag = TRUE, importance=TRUE, nthreads=10) qrf$mse NULL plot(qrf) Error in array(x, c(length(x), 1L), if (!is.null(names(x))) list(names(x), :'data' must be of a vector type, was 'NULL'