Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: data set reshape


From   "Pedro Martins" <[email protected]>
To   <[email protected]>
Subject   st: data set reshape
Date   Mon, 15 Jul 2002 13:48:57 +0100

hi
my data is shaped in the following way:
          c       d
a        1        2
b        3        4

and i would like to have it in this way:
x     a   b   c   d
1     1   0   1   0
2     1   0    0   1
3     0   1   1   0
4      0   1   0   1

that is, to transform both the variables and the cross-section observations
into dummies
any suggestions?
thank you

pedro martins


-------------------------------------------------
Pedro Martins
Department of Economics
University of Warwick
Coventry CV4 7AL
United Kingdom

email: [email protected]
web: www.warwick.ac.uk/staff/P.Martins
phone: +44/0 2476528240
fax: +44/0 2476523032
-------------------------------------------------



*
*   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/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index