[Rd] Varying results of package checks due to random seed
Radford Neal
radford at cs.toronto.edu
Sat Mar 22 18:32:37 CET 2014
> From: Philippe GROSJEAN <Philippe.GROSJEAN at umons.ac.be>
>
> ... for latest CRAN version, we have successfully installed 4999
> packages among the 5321 CRAN package on our platform. ... It is
> strange that a large portion of R CMD check errors on CRAN occur and
> disappear *without any version update* of a package or any of its
> direct or indirect dependencies! That is, a fraction of errors or
> warnings seem to appear and disappear without any code update.
Some of these are likely the result of packages running tests using
random number generation without setting the random numbers seed, in
which case the seed is set based on the current time and process id,
with an obvious possibility of results varying from run to run.
In the current development version of pqR (in branch 19-mods, found at
https://github.com/radfordneal/pqR/tree/19-mods), I have implemented a
change so that if the R_SEED environment variable is set, the random
seed is initialized to its value, rather than from the time and
process id. This was motivated by exactly this problem - I can now
just set R_SEED to something before running all the package checks.
Radford Neal
More information about the R-devel
mailing list