Observed/Fitted Values and Residuals

Learn how to make conclusions from the results of a regression model with multiple input variables.

In this lesson, we’ll only compute the observed values, fitted values, and residuals for the interaction model, which we saved in score_model_interaction.

Say we have an instructor who identifies as female and is 36 years old. What fitted value y^=score^\hat y = \widehat{\texttt{score}} will our model yield? Say we have another instructor who identifies as male and is 59 years old. What will their fitted value y^\hat y be?

We answer this question visually first for the female instructor by finding the intersection of the red regression line and the vertical line at x=x = age =36= 36. We mark this value with a large red dot in the figure below. Similarly, we can identify the fitted value y^=\hat y = score for the male instructor by finding the intersection of the blue regression line and the vertical line at x=x = age =59= 59. We mark this value with a large blue dot in the figure below.

Get hands-on with 1200+ tech skills courses.