Question: In this problem we will perform regression analysis on the sepal and petal measurements of the first 50 flowers in the Iris data. We want to use the sepal length and width and the petal length of a flower to predict its petal width. That is, the response variable is Y = iris[1:50,4] and the explanatory variables are X = (Xi | X2 | X3) = iris[1:50,1:3]. Assume a linear regression model that Y = β0 + Σ3 j=1 βjXj + ε, where ε is the error (residual) vector.
(a) Find the least square estimate of β = (β0.........β3) and the sum of squared residuals.
(b) If we want to use two of the three explanatory variables to predict Y, which two should we choose? Justify your answer.