Re: [R] Reading in a value of .Random.seed in .Rprofile

From: Charles C. Berry <>
Date: Wed, 20 Aug 2008 15:21:36 -0700

On Thu, 21 Aug 2008, Rolf Turner wrote:

> For reasons that are best known to myself [ ;-) ] I have a value of
> .Random.seed
> saved (via dput()) in a file ``''.
> In my .Rprofile I have the lines:
> .Random.seed <- dget("")
> Junk <- dget("")
> print(all.equal(.Random.seed,dget("")))
> print(all.equal(Junk,dget("")))
> The two calls to all.equal() both return TRUE.
> However when I repeat the calls from the command line after the
> R session has started, I get TRUE from the second (``Junk'') call
> but
> [1] "Mean relative difference: 0.1"
> from the first.

Not on my computer.

I get TRUE twice whether at start up, source()ing .Rprofile, or C-c C-n'ing the lines from emacs ESS.

I have to type


_after_ startup to get behavior like you describe.

Perhaps, you have something later in your .Rprofile that specifically load()'s your old .RData?



> sessionInfo()

R version 2.7.1 (2008-06-23)


attached base packages:
[1] stats graphics grDevices utils datasets methods base


Charles C. Berry                            (858) 534-2098
                                             Dept of Family/Preventive Medicine
E	            UC San Diego  La Jolla, San Diego 92093-0901

______________________________________________ mailing list
PLEASE do read the posting guide
and provide commented, minimal, self-contained, reproducible code.
Received on Wed 20 Aug 2008 - 22:26:01 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 20 Aug 2008 - 23:34:02 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.

list of date sections of archive