egen six=seq(), from(1) to(6)
Daniel
> -----Original Message-----
> From: [email protected]
> [mailto:[email protected]] On Behalf Of
> FEIVESON, ALAN H. (AL) (JSC-SK) (NASA)
> Sent: Tuesday, January 06, 2004 6:41 PM
> To: '[email protected]'
> Subject: st: RE: how to generate a variable as follow
>
>
> Here's one way:
>
> gen x=1+mod(_n-1,6)
>
> Al Feiveson
>
> -----Original Message-----
> From: rghuang [mailto:[email protected]]
> Sent: Tuesday, January 06, 2004 11:32 AM
> To: [email protected]
> Subject: st: how to generate a variable as follow
>
>
> x
> 1
> 2
> 3
> 4
> 5
> 6
> 1
> 2
> 3
> 4
> 5
> 6
> 1
> 2
> 3
> 4
> 5
> 6
>
> how can i get it.thank you!
>
> *
> * 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/