Dear Austin,
Here is the code that I am using for sorting and
taking 5 year avarages. I hope this part would be
enough to tell if there is anyting wrong.
ifscode is unique for each country in my data file and
year is between 1960-2002.
Thank you very much.
Regards,
ilker
sort ifscode year;
iis ifscode;
tsset ifscode year;
*** Creates 5-year period indicator;
gen indpd = . ;
label var indpd "Indicates the period number of 5-year
increments" ;
replace indpd = 1 if year == 1960 ;
replace indpd = 1 if indpd[_n-5] == 1 & ifscode[_n-5]
== ifscode ;
sort ifscode indpd year ;
replace indpd = indpd[_n-1] + 1 if indpd == 1 &
ifscode == ifscode[_n-1];
sort name year ;
replace indpd = indpd[_n-1] if indpd == . & ifscode ==
ifscode[_n-1];
**** Creates 5-year averages ;
collapse (min) year ifscode (mean) tot_exp cap_exp
curr_exp odanet2 real_gdp_pc mor_inf agr_gdp lag_agr
litadu_pop system allhouse yrcurnt exelec exconst
legelec pr military state yrsoffc oda_yr oda_sys
oda_house oda_ex oda_leg oda_pr oda_mil oda_const
oda_st oda_offc , by(name indpd);
--- Austin Nichols <[email protected]> wrote:
> Ilker,
> Hard to know what is going on w/o more detail on the
> problem ("I
> checked the do file and it seems everthing is fine"
> is not enough
> detail) but I am guessing that it has something to
> do with your sort
> order when constructing five-year averages. What
> sequence of commands
> are you using?
> --Austin
>
> On 4/26/06, ilker kaya <[email protected]> wrote:
> > Dear All,
> >
> > I have a panel data-time series data set between
> years
> > 1960-2002. I am taking 5 yaer avarages and running
> the
> > FE regreession. However each time the result is
> > changing. I checked the do file and it seems
> everthing
> > is fine. When I run the same regressions with
> yearly
> > data there is no such problem. Is any of you
> > experienced a similar problem previously. Thank
> you in
> > advance.
> > Regards,
> >
> > ilker Kaya
>
> *
> * 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/
>
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
*
* 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/