options memory=30 crt limwarn=0 ; ? ? ========================= SIMOLSHS =============================== ? ? One Variable Time Series Process Using Panel Data. ? Use simulated data to investigate testing methodology. ? DGPs are based on the process for log R&D in the U.S. ? This version has heteroskedastic disturbances. ? ? SUR test for unit root (t-test on rho, consistent under ? the null), as suggested by Bond, Nuage,and Windmeijer (2001). ? ? Bronwyn H. Hall - Hall and Mairesse 2001 (for Munich). ? Revised Sept. 2001. ? supres @covoc @smpl ; const nob 200 t 12 ndraw 1000 ; set nobt = nob*t ; set t1 = t-1 ; smpl 1 nobt ; random (seedin=29345) e ; ? Initialize seed. ? ? Set up id and trend. ? trend(pstart=1,period=t) trend ; select trend=1 ; trend id ; select trend>1 ; id = id(-1) ; select trend>0 ; dummy trend yrdum ; list dylist dy79-dy89 ; ? List of differenced series. date startime ; do imod = 1 to 8 ; ? Simulate all 8 models (see labels below). do isim = 1 to ndraw ; smpl 1 nobt ; input simhsprcs ; msd (silent) y ; set ymean(isim) = @mean(1) ; set yvar(isim) = @var(1) ; mmake ymat y ; mform (nrow=t,ncol=nob) ymat ; mat ymat=ymat' ; select trend>1 ; dy = y-y(-1) ; mmake dymat dy ; mform (nrow=t1,ncol=nob) dymat ; mat dymat=dymat' ; smpl 1 nob ; unmake dymat dy79-dy89 ; unmake ymat y78-y89 ; ? msd (corr) dy79-dy89 ; ? msd (corr) y78-y89 ; frml eq89 dy89-a89-phi*y88 ; frml eq88 dy88-a88-phi*y87 ; frml eq87 dy87-a87-phi*y86 ; frml eq86 dy86-a86-phi*y85 ; frml eq85 dy85-a85-phi*y84 ; frml eq84 dy84-a84-phi*y83 ; frml eq83 dy83-a83-phi*y82 ; frml eq82 dy82-a82-phi*y81 ; frml eq81 dy81-a81-phi*y80 ; frml eq80 dy80-a80-phi*y79 ; frml eq79 dy79-a79-phi*y78 ; param a79-a89 phi ; sur (silent,robust) eq79-eq89 ; set phimat(isim) = phi+1 ; set tstat(isim) = @t(2) ; set reject(isim) = tstat(isim)<-1.65 ; enddo ; smpl 1 ndraw ; list stats ymean yvar phimat tstat reject ; dot stats ; unmake . . ; enddot ; msd stats ; enddo ;