Statalist


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

st: Re: Coding question: transactions panel dataset


From   "Martin Weiss" <[email protected]>
To   <[email protected]>
Subject   st: Re: Coding question: transactions panel dataset
Date   Fri, 24 Apr 2009 23:40:57 +0200

<>

I do not quite get what you are asking for. Can you give an example for say, a "black-white" transaction in your example data?
Which "difference" are you referring to?

Very generally, you want to use the fact that the -by- prefix allows you access to each "id" separately, as described in Nick`s canonical http://www.stata-journal.com/sjpdf.html?articlenum=pr0004



HTH
Martin
_______________________
----- Original Message ----- From: "Marcus Casey" <[email protected]>
To: <[email protected]>
Sent: Friday, April 24, 2009 7:46 PM
Subject: st: Coding question: transactions panel dataset


Hi,

I have a question about an efficient coding scheme to calculate the
types of transactions over time in an unbalanced panel and
would appreciate a little help here.

My dataset has the following structure:


id year tract price white black hispanic
1      1997 1 123 1 0 0
1 2000 1 145         0              1             0
2 1998 1 230         0              1             0
2 2001 1 236         0 1 0
2 2006 1 300 0 0 1
3 2002 3 250 1 0 0
3 2006 3 275 1 0 0
4 1998 2 235 0 0 1
4 2002 2 220 1 0 0
4 2006 2 245 0 1 0


I would code the following quantities for each id and,

(1) a separate indicator for each transaction that labels whether it
is white-white, white-black, black-white, hisp-white, etc. and
temporal ordering.

(2) the difference in transaction price for each type of transaction
described above.

Thank you in advance for any assistance you can give me with this
problem.

Regards,
Marcus


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


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



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