Statalist The Stata Listserver


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: Re: Seed and time


From   SamL <saml@demog.berkeley.edu>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: Re: Seed and time
Date   Mon, 26 Feb 2007 11:45:01 -0800 (PST)

Thank you Sergiy for the clarificaton.

Take care.
Sam

On Mon, 26 Feb 2007, Sergiy Radyakin wrote:

> Hi, Sam!
>
>
> Setting seed is enough:
>
> . set seed 1
>
> . di uniform()
> .66818523
>
> . di uniform()
> .92796107
>
> . di uniform()
> .48448141
>
> . set seed 1
>
> . di uniform()
> .66818523
>
> However, if you initially set seed to be equal to current time (rather then
> the constant 1 here) than time matters.
>
> Regards, Sergiy
>
>
>
>
>
> ----- Original Message -----
> From: "SamL" <saml@demog.berkeley.edu>
> To: "Stata Listserve" <statalist@hsphsun2.harvard.edu>
> Cc: <SamL@demog.berkeley.edu>
> Sent: Monday, February 26, 2007 8:02 PM
> Subject: st: Seed and time
>
>
> > Just a clarification requested.  Nick Cox just seemed to indicate that to
> > replicate using seed one needs to also reference time.  Have I
> > misunderstood?  Or is time an alternative way to obtain a seed when one
> > does not care what it is?  I guess I just want to assure that setting seed
> > *sets* the seed so that it replicates any other run with the same seed,
> > regardless of the time.
> >
> > Thanks a bunch.
> > Sam
> >
> > *
> > *   For searches and help try:
> > *   http://www.stata.com/support/faqs/res/findit.html
> > *   http://www.stata.com/support/statalist/faq
> > *   http://www.ats.ucla.edu/stat/stata/
>
> *
> *   For searches and help try:
> *   http://www.stata.com/support/faqs/res/findit.html
> *   http://www.stata.com/support/statalist/faq
> *   http://www.ats.ucla.edu/stat/stata/
>
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index