reap
function is the central function to harvest
.
It takes an object, x
, extracts the previous seed, ie. state of
the random number generator, sets the seed, and continues any evaluation.
This creates a continuous random number stream, that is completly
reproducible.
reap(x, fun, ..., hash = digest(list(x, fun, ..., source = "harvestr::reap"), "md5"), cache = getOption("harvestr.use.cache", defaults$cache()), cache.dir = getOption("harvestr.cache.dir", defaults$cache.dir()), time = getOption("harvestr.time", defaults$time()), use.try = getOption("harvestr.use.try", !interactive()))
harvestr
withseed
, harvest
, and with