View source: R/plyr_progress_progressr.R
progress_progressr | R Documentation |
A "progress bar" for plyr's .progress
argument.
progress_progressr(...)
... |
Not used. |
A named base::list that can be passed as argument .progress
to any of plyr function accepting that argument.
One can use use doFuture::registerDoFuture()
to run plyr functions
in parallel, e.g. plyr::l_ply(..., .parallel = TRUE)
. Unfortunately,
using .parallel = TRUE
disables progress updates because, internally,
plyr forces .progress = "none"
whenever .parallel = TRUE
.
Thus, despite the future ecosystem and progressr would support
it, it is not possible to run dplyr in parallel and get progress
updates at the same time.
if (requireNamespace("plyr", quietly=TRUE)) {
with_progress({
y <- plyr::llply(1:10, function(x) {
Sys.sleep(0.1)
sqrt(x)
}, .progress = "progressr")
})
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.