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

st: First difference in multidimensional panel

Subject   st: First difference in multidimensional panel
Date   Fri, 24 Apr 2009 11:29:46 -0400

Dear stata list members,

I have a panel data of share of intra-firm imports (s_{ict}) where observations vary over industry (i), country (c) and time (t). I need to calculate the first difference of s_{ict}:
I am not sure how to do this since I do not have a unique panel variable.
Also when using tsset how do I create unique id for each industry-country pair (where both industry and country are string variables). Any help would be appreciated.

My data is of the following form: Industry(Ind) and Country (Cty) are both string variables
Ind Cty Yr
1 A 2000
1 B 2000
1 C 2000
1 A 2001
1 B 2001
1 C 2001
1 A 2002
2 A 2000
2 B 2000
2 D 2000
2X B 2001
2X A 2002
2X B 2002

Thanks in advance,

*   For searches and help try:

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