In: Statistics and Probability
Using the statistical model, ? = ?? + ?, where ?~?(0,?2?) and
the data in Table1.dat
a) Compute ?T? matrix and ?T?
b) Compute the inverse of ?T?
c) Compute the least square estimate. Compare to results in
exercise 1.
d)Compute ?̂? = ?? − ?? ̂ = ?? − (?1 + ?2??) and use the least
square estimator ?2 = ∑ ?̂? ? ?=1 ?−2
to compute and estimate of ?2
e) Compute an estimate of the variance and covariance expressions for ?1 and ?2
input X | Output Y |
1 | 0.58 |
2 | 1.1 |
3 | 1.2 |
4 | 1.3 |
5 | 1.95 |
6 | 2.55 |
7 | 2.6 |
8 | 2.9 |
9 | 3.45 |
10 | 3.5 |
11 | 3.6 |
12 | 4.1 |
13 | 4.35 |
14 | 4.4 |
15 | 4.5 |
The matrix X is a) XIX = 15 120 120 1240 42.08 418.53 XTy=
0.295238 -0.02857 -0.02857 0.003571 b) inverse of XIX = 0.465619 c) Now the OLS estimate -x*x x y= 0.292454 the intercept is bi=0.465619 and regression coefficient is bz= 0.292464 the model is j = 0.465619 +0.292464x -0.34 2.51 y y pred Error(e) 0.58 0.76 -0.18 1.1 1.05 0.05 1.2 1.34 -0.14 1.3 1.64 1.95 1.93 2.55 2.22 0.33 0.09 2.9 2.81 0.09 3.45 3.10 3.39 0.11 3.6 3.68 -0.08 4.1 3.98 0.12 4.35 4.27 0.08 4.4 4.56 -0.16 4.5 4.85 -0.35 0.35 3.5