我以以下为例
x <- 1:12
sample(x)
每当我重新启动 RStudio 或 Rgui 并运行该代码时,我总是得到相同的结果:
[1] 7 3 10 8 2 9 11 4 12 5 1 6
有没有办法改变这种烦人的行为?
> sessionInfo()
R version 3.1.0 (2014-04-10)
Platform: x86_64-w64-mingw32/x64 (64-bit)
locale:
[1] LC_COLLATE=Greek_Greece.1253 LC_CTYPE=Greek_Greece.1253
[3] LC_MONETARY=Greek_Greece.1253 LC_NUMERIC=C
[5] LC_TIME=Greek_Greece.1253
attached base packages:
[1] stats graphics grDevices utils datasets methods base