Hi All,
I am trying to replicate Michael Klein' s 1996 paper, "Timing Is All: Elections and the Duration of United States Business Cycles", published in Journal of Money, Credit and Banking, pp.84-101. The author mentions that "The relatively small number of business cycles, especially in the subsamples makes inference based upon standard asymptotic suspect. Therefore we use boot-strap techniques. The point estimates presented in Tables 4 through 8 represent the mean value of the respective estimates for five hundred resamples from the original data. We resample "clusters" of observations from the original data set choosing the set of observations corresponding to an entire business cycle as one "draw." Each resample therefore has the same number of business cycles as the original sample."
I tried to follow the same bootstrap method, however, the results I generarted are very different from the ones reported in the paper. therefore, I would to seek for your help to understand what i did wrong. My Stata code are
and my dataset looks like this :
Error message:
Any advice on how to solve the error is highly appreciated
I am trying to replicate Michael Klein' s 1996 paper, "Timing Is All: Elections and the Duration of United States Business Cycles", published in Journal of Money, Credit and Banking, pp.84-101. The author mentions that "The relatively small number of business cycles, especially in the subsamples makes inference based upon standard asymptotic suspect. Therefore we use boot-strap techniques. The point estimates presented in Tables 4 through 8 represent the mean value of the respective estimates for five hundred resamples from the original data. We resample "clusters" of observations from the original data set choosing the set of observations corresponding to an entire business cycle as one "draw." Each resample therefore has the same number of business cycles as the original sample."
I tried to follow the same bootstrap method, however, the results I generarted are very different from the ones reported in the paper. therefore, I would to seek for your help to understand what i did wrong. My Stata code are
Code:
stset time, fail(event) id(phaseid) bootstrap _b[a24], cluster(cycleid) idcluster(newcycleid): stcox a24 if phase==1 & pww2==1
Code:
input byte cycleid int(phaseid time) byte(a9 a12 a24 event a9_d a12_d a24_d a9_r a12_r a24_r pww1 pww2 phase _st _d) int(_t _t0) float newcycleid 1 101 23 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 23 0 1 1 101 32 1 1 1 0 1 1 1 0 0 0 0 0 1 1 0 32 23 1 1 101 35 0 1 1 0 0 1 1 0 0 0 0 0 1 1 0 35 32 1 1 101 44 0 0 1 1 0 0 1 0 0 0 0 0 1 1 1 44 35 1 1 102 3 0 0 1 0 0 0 1 0 0 0 0 0 2 1 0 3 0 1 1 102 7 0 0 0 1 0 0 0 0 0 0 0 0 2 1 1 7 3 1 2 201 10 0 0 0 1 0 0 0 0 0 0 1 0 1 1 1 10 0 2 2 202 10 0 0 0 0 0 0 0 0 0 0 1 0 2 1 0 10 0 2 2 202 18 1 1 1 1 0 0 0 1 1 1 1 0 2 1 1 18 10 2 3 301 1 1 1 1 0 0 0 0 1 1 1 1 0 1 1 0 1 0 3 3 301 4 0 1 1 0 0 0 0 0 1 1 1 0 1 1 0 4 1 3 3 301 16 0 0 1 0 0 0 0 0 0 1 1 0 1 1 0 16 4 3 3 301 32 0 0 0 1 0 0 0 0 0 0 1 0 1 1 1 32 16 3 3 302 14 0 0 0 1 0 0 0 0 0 0 1 0 2 1 1 14 0 3 4 401 4 0 0 0 0 0 0 0 0 0 0 1 0 1 1 0 4 0 4 4 401 13 1 1 1 0 0 0 0 1 1 1 1 0 1 1 0 13 4 4 4 401 16 0 1 1 0 0 0 0 0 1 1 1 0 1 1 0 16 13 4 4 401 27 0 0 1 1 0 0 0 0 0 1 1 0 1 1 1 27 16 4 4 402 1 0 0 1 0 0 0 0 0 0 1 1 0 2 1 0 1 0 4 4 402 13 0 0 0 1 0 0 0 0 0 0 1 0 2 1 1 13 1 4 5 501 12 0 0 0 0 0 0 0 0 0 0 1 0 1 1 0 12 0 5 5 501 21 1 1 1 1 0 0 0 1 1 1 1 0 1 1 1 21 12 5 5 502 3 1 1 1 0 0 0 0 1 1 1 1 0 2 1 0 3 0 5 5 502 15 0 1 1 0 0 0 0 0 1 1 1 0 2 1 0 15 3 5 5 502 39 0 0 1 0 0 0 0 0 0 1 1 0 2 1 0 39 15 5 5 502 43 1 1 1 1 1 1 1 0 0 0 1 0 2 1 1 43 39 5 end
Code:
Note: One or more parameters could not be estimated in 2 bootstrap replicates;
standard-error estimates include only complete replications.

Comment