[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
st: RE: Re: RE: Random number seed
That's correct. I overlooked the importance
of doing in it in batch mode. It follows
that you must change the seed within
your do file.
> -----Original Message-----
> From: firstname.lastname@example.org
> [mailto:email@example.com]On Behalf Of Subhankar
> Sent: 20 May 2004 15:41
> To: firstname.lastname@example.org
> Subject: st: Re: RE: Random number seed
> You are right.
> Once I open stata and generate random numbers, the seed keeps
> on changing
> and it is completely randomized.
> But since the program is long, I am running it without
> opening stata. I am
> running it in the batch mode giving the command
> stata -b do market.do
> This program opens stata each time and hence gets the same
> seed and the same
> set of random numbers each time.
> ----- Original Message -----
> From: "Nick Cox" <email@example.com>
> To: <firstname.lastname@example.org>
> Sent: Thursday, May 20, 2004 10:24 AM
> Subject: st: RE: Random number seed
> > Your premise is false. Just because
> > the seed remains the same does not
> > imply identical samples (of a given size).
> > Conversely, explicitly setting the seed to the
> > same number as before the last
> > call does ensure an identical sample.
> > However, you can indeed change the seed easily.
> > . search seed
> > points to ways of doing this.
> > More generally, there is a great
> > deal of help on-line, which will
> > save you time.
> > Nick
> > email@example.com
> > > -----Original Message-----
> > > From: firstname.lastname@example.org
> > > [mailto:email@example.com]On Behalf Of
> > > Nayak
> > > Sent: 20 May 2004 15:16
> > > To: firstname.lastname@example.org
> > > Subject: st: Random number seed
> > >
> > >
> > > Can the stata random number seed be itself randomized?
> > >
> > > I am running a program called "market.do" in the batch
> mode without
> > > invoking/opening stata. This program carries out an analysis
> > > based on a set
> > > of 1,000 uniform random numbers it generates.
> > >
> > > However, since the random seed is always the same
> everytime I run the
> > > program in batch mode, I get the same set of 1,000 random
> > > numbers each time
> > > I run this program in batch mode. Results are identical which
> > > defeats the purpose.
> > *
> > * 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: