progress
progress copied to clipboard
replicate function with a progressbar
Hi there,
I often use base::replicate for simulations but not knowing when my replication will end was killing me.
Therefore, here is a simple rewriting of base::replicate that can use your progress bars.
For instance:
library(dplyr)
replicate_pb(50000, {rnorm(1)>1.65}) %>% {paste(mean(.), " - ", sd(.))}
This might need some rewriting to conform to your standards, naming, etc but I thought it could be interesting.
Kudos for this wonderful package! Dan