Ordinary Least Squares Regression Residuals

Overview


The following provides a derivation of the computed residuals, following the dicussion found in Ahlawat

The assumed form of the equation relating {% \vec{y} %} to {% \textbf{X} %} is
{% \vec{y} = \textbf{X}\vec{\beta} + \vec{\epsilon} %}
However, the true value of {% \vec{\beta} %} is unknown. Instead, a estimate {% \hat{ \vec{\beta}} %} is computed.
{% \vec{y} = \textbf{X} \hat{\vec{\beta}} + \hat{\vec{\epsilon}} %}
Here, {% \hat{\vec{\epsilon}} %}, is the vector of computed residuals.
{% \hat{\vec{\epsilon}} = \vec{y} - \textbf{X} \vec{\beta} %}
{% = (\textbf{I} - \textbf{H})\vec{y} %}
where we define
{% \textbf{H} = \textbf{X}(\textbf{X}^T \textbf{X})^{-1} \textbf{X} ^T %}
then we have
{% (\textbf{I} - \textbf{H})(\textbf{X} \vec{\beta} + \vec{\epsilon}) %}
{% (\textbf{X} - \textbf{X}(\textbf{X}^T \textbf{X})^{-1} \textbf{X}^T \textbf{X}) \vec{\beta} + (\textbf{I} - \textbf{H})\vec{\epsilon} %}
{% = (\textbf{I} -\textbf{H}) \vec{\epsilon} %}

Topics


  • Standardized Residuals