Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: how to create panel id


From   Nick Cox <[email protected]>
To   "[email protected]" <[email protected]>
Subject   Re: st: how to create panel id
Date   Tue, 9 Jul 2013 21:11:27 +0100

Even better:

egen ID=group(Ticker), label

Nick
[email protected]


On 9 July 2013 20:10, Richard Goldstein <[email protected]> wrote:
> egen ID=group(Ticker)
>
> Rich
>
> On 7/9/13 3:03 PM, Xixi Lin wrote:
>> Hi,
>>
>> I have a very simple question: how can I create IDs for panel data? In
>> other words, I need a ID number to replace the ticker name.
>>
>> For example:
>> Ticker Date ID
>> A       1        1
>> A       2        1
>> A       3        1
>> A       4        1
>> B       1        2
>> B       2        2
>> B       3        2
>> B       4        2
>>
>> Thanks for any help.
>>
>> Best,
>> Xixi Lin
> *
> *   For searches and help try:
> *   http://www.stata.com/help.cgi?search
> *   http://www.stata.com/support/faqs/resources/statalist-faq/
> *   http://www.ats.ucla.edu/stat/stata/
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/faqs/resources/statalist-faq/
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index