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]
st: RE: RE: RE: Reshaping data
From
Nick Cox <[email protected]>
To
"'[email protected]'" <[email protected]>
Subject
st: RE: RE: RE: Reshaping data
Date
Fri, 4 Feb 2011 15:11:29 +0000
Well OK, but you didn't tell us that and clearly Stata has its rules about variable names.
Nick
[email protected]
DE SOUZA Eric
My problem is that the first row is -regionid- -2000- -2001- ...
The years are not preceded by letters such as -var- in your example.
That's what got me stuck.
There are several files of this kind, each of which has to be converted into a long variable
Nick Cox
Assuming say -regionid- -var1980- ... -var2009- this is
reshape long var , i(regionid) j(year)
This is one of the basic kinds of -reshape- in the help. What explanation did you miss?
DE SOUZA Eric
I have a table in Excel (which, of course, I can convert to csv format and -insheet- into Stata). The table contains one variable. Each row corresponds to a region and each column to a year. Is there a way of converting the data into panel (long) format in Stata ?
I've hunted around and experimented but without success.
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/