Commit f30d5201 authored by Romulo Pereira Goncalves's avatar Romulo Pereira Goncalves
Browse files

Let's use shiny busy with a modal.

parent de6d950c
Pipeline #22773 failed with stage
in 10 seconds
......@@ -157,8 +157,10 @@ sample_nb <- function(raster,
if (progress_bar) {
setTxtProgressBar(pb, k)
} else {
shiny::incProgress(1/(nb_mean + nrow(reference)),
detail = paste("Doing sampling for model", k))
shinybusy::update_modal_progress(
value = 1 / (nb_mean + nrow(reference)),
text = paste("Doing sampling for model", k)
)
}
}
}
......@@ -228,8 +230,10 @@ sample_nb <- function(raster,
}
m[l] <- max(dif[2,], na.rm = T)
if (!progress_bar) {
shiny::incProgress(1 / (nb_mean + nrow(reference)),
detail = paste("Doing prediction for class", jj))
shinybusy::update_modal_progress(
value = 1 / (nb_mean + nrow(reference)),
text = paste("Doing prediction for class", jj)
)
}
}
index <- which.max(dif[2,])
......
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