Bootstrap results for regressions Compare 95% confidence intervals and P-values for the slope for least-squares and Theil`s regression with bootstrap P-values and bootstrap percentile confidence intervals for (i) bootraps of residuals (ii) bootraps of observations Initializing the uniform random-number generator at 12345678 Initializing the normal random-number generator at 12345678 (In MATLAB, rand() and randn() must both be seeded.) Five U(0,1)s: 0.0478904 0.996547 0.501069 0.617014 0.556112 Five N(0,1)s: -1.57019 -0.362043 0.47415 -0.245975 -1.20185 Generating (X,Y) for a normal regression with Y = 5 X + 10 + 100*N(0,1), n=30 pairs Data (n=30) (X then Y): 1. 2.96 20.64 16. 11.67 29.85 2. 18.86 37.82 17. 18.02 53.74 3. 19.14 231.35 18. 2.52 -16.71 4. 16.43 71.36 19. 15.57 226.43 5. 19.50 188.43 20. 2.08 82.18 6. 2.11 45.31 21. 16.59 238.19 7. 7.13 -18.91 22. 17.61 3.93 8. 5.63 67.92 23. 10.41 -121.86 9. 0.33 94.79 24. 6.68 181.14 10. 4.38 -33.16 25. 8.79 85.91 11. 18.16 56.48 26. 9.65 -109.22 12. 4.72 -25.45 27. 17.85 54.74 13. 9.44 98.89 28. 10.41 112.11 14. 1.21 -137.05 29. 16.95 115.14 15. 12.08 190.32 30. 4.58 100.24 Within-sample tie groups: X: 1 Y: 0 X(23)=X(28)=10.41 changed to 10.406 10.414 1 X tie(s) corrected. LEAST-SQUARES REGRESSION: Y = 6.21565 X + -0.379163 Normal-theory test of H_0:beta=0 (Student-t test) beta_hat=6.2156 T=2.3429 P=0.0265 (two-sided, df=28) 95% Conf.Int. for beta: (0.7812 6.2156 11.6501) For nb=10000 bootstrap replications: (LEAST SQUARES) BOOTSTRAP ON RESIDUALS (beta=6.21565) 95% Cred.Interval (1.2399 6.1236 11.0562) Bootstrap bias: 5148/10000 = 0.5148 Bootstrap P-value for H_0:beta=0: One-sided P: P=79/10000=0.00790 Two-sided P: P=0.01580 95% CI: (0.01233, 0.01927) (LEAST SQUARES) BOOTSTRAP ON OBSERVATIONS (beta=6.21565) 95% Cred.Interval (1.6223 6.1716 11.2460) Bootstrap bias: 5073/10000 = 0.5073 Bootstrap P-value for H_0:beta=0: One-sided P: P=26/10000=0.00260 Two-sided P: P=0.00520 95% CI: (0.00320, 0.00720) THEIL REGRESSION: Y = 5.6129 X + 6.38032 Theil`s 95% Confidence interval (with median of S-ratios): (-0.4472 5.6129 11.4823) with offsets 163 217.5 273 in sratio array (n=435) Theil`s test of H_0:beta=0 (same as Kendall`s test) (NOT assuming that X(i) are increasing) C=105 Z=1.8733 P=0.0610 (Assuming no ties) For nb=10000 bootstrap replications: (THEIL) BOOTSTRAP ON RESIDUALS (beta=5.6129) 95% Cred.Interval (0.4113 5.6129 10.8199) Bootstrap bias: 5536/10000 = 0.5536 Bootstrap P-value for H_0:beta=0: One-sided P: P=181/10000=0.01810 Two-sided P: P=0.03620 95% CI: (0.03097, 0.04143) (THEIL) BOOTSTRAP ON OBSERVATIONS (beta=5.6129) 95% Cred.Interval (0.4501 5.6129 11.4823) Bootstrap bias: 5034/10000 = 0.5034 Bootstrap P-value for H_0:beta=0: One-sided P: P=207/10000=0.02070 Two-sided P: P=0.04140 95% CI: (0.03582, 0.04698)