the unobserved effect in the first regression, as well as identifying what variables affect Pi itself. The main purpose of my bachelor thesis is to isolate and show the value of Pi, i.e. On your last point, I think I should clarify what I am trying to achieve. To clarify, the reason that we perform this test rather than the Hausman test is that since we have both heteroscedasticity and autocorrelation in our data, meaning that we should use robust standard errors, we need to run another type of test as the Hausman test does not work for non default standard errors?Ģ. Sargan-Hansen statistic 1.888 Chi-sq(1) P-value = 0.1694As we get a P-value of 0.1694, I interpret this as meaning that I should use -fe- rather than -re- since the test does not reach statistical significance. Test of overidentifying restrictions: fixed vs random effectsĬross-section time-series model: xtreg re robust cluster(RIC_2) 85732453 (fraction of variance due to u_i) Random-effects GLS regression Number of obs = 44,751Ĭorr(u_i, X) = 0 (assumed) Prob > chi2 = 0.0008 *as the -test- outcome does not reach statistical significance, there's no evidence of model misspecification*Ĭode. 32885822 (fraction of variance due to u_i) adjusted for 4,434 clusters in idcode)Īge | Coef. Group variable: idcode Number of groups = 4,434Ĭorr(u_i, X) = 0 (assumed) Prob > chi2 =. Random-effects GLS regression Number of obs = 26,200 Time variable: year, 70 to 88, but with gaps I then ran the Hausman test which I understand as indicating that I should be using a fixed effect rather than random effect model: yield) as the dependent variable and only BIDASKSP (Liquidity) as the independent variable to isolate the fixed-effect estimator Pi (as outlined in the equation above)? Is it correct to run xtreg with YIELDDIFF (i.e. Am I interpreting this test correctly as saying that my fixed-effect estimator has an explanatory value for the yield of the bonds, as given by u_i=0: F(165, 44584) = 1130.58 - and that I should in fact use a fixed effect model? What does the large F value mean?Ģ. Group variable: RIC_2 Number of groups = 166 I have first run an F-test, with the following result:įixed-effects (within) regression Number of obs = 44,751 Y_i,t = P_i+Liquidity_i,t +e_i,t with e being the error term. Yield has variable name YIELDDIFF and Liquidity is BIDASKSP The regression I am trying to perform is: (Y is yield, P_i is the fixed-effect estimator, Liquidity is the variable for Liquidity). I am not sure if I am interpreting the results of these tests correctly and what my model choice should be going forward to perform regressions in stata. So far I have run various tests to check whether I should use a fixed or random effects model, as well as tests to check for autocorrelation and heteroskedasticity, as well as an F-test. More specifically, I am trying to run a regression of the yield on a measure of the bond's liquidity to find the unobserved effect that isn't explained by the variable liquidity. My goal is to run a regression that shows what variables have an effect on the bond's yield. I have about 54 000 observations of bond yields. I have a large set of panel data with information about 166 bonds, containing some of their characteristics (such as currency, issue date, etc.) followed by daily yield data over a five year period for each bond (although most of these values are missing).