Commit 8cea425c authored by Romulo Pereira Goncalves's avatar Romulo Pereira Goncalves
Browse files

Since we have removed all the NaNs from the raster, we do not need to omit the NaNs

parent 59f66cab
...@@ -71,7 +71,6 @@ model_opt_r <- function(k, ...@@ -71,7 +71,6 @@ model_opt_r <- function(k,
if (model == "rf") { if (model == "rf") {
model1 <- model1 <-
randomForest::randomForest(as.factor(classes) ~ ., randomForest::randomForest(as.factor(classes) ~ .,
na.action = na.omit,
data = data, data = data,
mtry = mtry) mtry = mtry)
if (is.na(mean(model1$err.rate[, 1])) == TRUE) { if (is.na(mean(model1$err.rate[, 1])) == TRUE) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment