Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | AGAOGLU Enes <s1236623@sms.ed.ac.uk> |
To | "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu> |
Subject | RE: st: Panel Data Construction |
Date | Tue, 18 Jun 2013 20:46:55 +0000 |
In Stata, Date GAR(P) GAR(MV) .... are copied as variable names to the data editor after I copy paste from Excel. If I do not keep them as variable names, then variable names will be var1 var2 ... as default and Date GAR(P) ... will be copied as values to the first cell. I don't know which one is easier to manipulate. ________________________________________ From: owner-statalist@hsphsun2.harvard.edu [owner-statalist@hsphsun2.harvard.edu] on behalf of Nick Cox [njcoxstata@gmail.com] Sent: 18 June 2013 21:43 To: statalist@hsphsun2.harvard.edu Subject: Re: st: Panel Data Construction Show us your variable names please. (NB "Stata" not "STATA".) Nick njcoxstata@gmail.com On 18 June 2013 21:34, Edward Crawley <edward.crwly@gmail.com> wrote: > I am trying to convert my dataset to panel data, but since I am new to > Stata I couldn't figure how to do it. My dataset is as follows; > > Date GAR(P) GAR(MV) GAR(MB) AKB(P) AKB(MV) AKB(MB) ISC(P) ISC(MV) ISC(MB) > Jan10 0.53 110 1.71 0.63 230 1.95 1.7 150 4.6 > Feb10 0.47 120 1.54 0.55 205 1.71 1.63 100 4.43 > > > GAR, AKB, ISC are the firms' names and P=price, MV=market value, > MB=market-to-book ratio. > > > At the end, I would like to have something like this; > > Firm Date P MV MB > GAR Jan10 0.53 110 1.71 > GAR Feb10 0.47 120 1.54 > AKB Jan10 0.63 230 1.95 > AKB Feb10 0.55 205 1.71 > ISC Jan10 1.7 150 4.6 > ISC Feb10 1.63 100 4.43 > * * 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/ -- The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336. * * 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/