Simulate N = 103 outcomes from the model
Y = -2 + X + ε
where X ~ U[0, 1] and ε ~ N(0, 0.12) independently. From your simulated outcomes of (X, Y ), βt a linear regression model to increasing numbers of outcomes (from N = 2 to N = 104) as y = β0 + β1x, by using the solution to the normal equations to obtain estimates for ^β = ( ^β0, ^β1)T , via solving
(ATA)β^ = ATy
where y = (y1 , . . . , yN)T , and
Plot your estimates for β0 and β1 as N increases, together with a line indicating their true values. Supply your code.