Hat Matrix For Simple Linear Regression
These estimates will be approximately normal in general.
Hat matrix for simple linear regression. We will call H as the hat matrix and it has some important uses. Fy fy y0 Hy y0. All the models we have considered so far can be written in this general form.
Though it might seem nomore ecient to use matrices with simple linear regression it will become clear that withmultiple linear regression matrices can be very powerful. Example of simple linear regression in matrix form An auto part is manufactured by a company once a month in lots that vary in size as demand uctuates. Chapter 5 contains a lot of matrixtheory.
Matrix Approaches to Simple Linear Regression Linear functions can be written by matrix operations such as addition and multiplication. Suppose that you need to t the simple regression model y i 0 1x i i where. I tried rearranging the terms so nj 1x2j nˉxxi nx2i nˉxxi but I cant seem to get to the answer.
Thus H ijis the rate at which the ith tted value changes as we vary. Here β represents a vector of regression coefficients intercepts group means etc X is an n k design matrix for the model more on this later and where ϵ N. For things to be true the terms inside the parenthesis can be rearranged to be Sxx nxi ˉx2.
In these lecture notes. Where H XXT X 1XT is an n nmatrix which puts the hat on y and is therefore referred to as the hat matrix. Now we move on to formulation of linear regression into matrices.
However I am unable to work this out myself. Everything weve done so far can be written in matrix form. This shows that the tted values are in fact a linear function of the observed values such that for any yy02Rn we have letting by.