Database Reference
In-Depth Information
Figure 6.10
Residuals with nonconstant variance
Evaluating the Normality Assumption
The residual plots are useful for confirming that the residuals were centered on
zero and have a constant variance. However, the normality assumption still has to
be validated. As shown in
Figure 6.11
,
the following R code provides a histogram
plot of the residuals from
results2
, the output from the
Income
example:
hist(results2$residuals, main="")
Figure 6.11
Histogram of normally distributed residuals
From the histogram, it is seen that the residuals are centered on zero and appear to
be symmetric about zero, as one would expect for a normally distributed random
variable. Another option is to examine a Q-Q plot that compares the observed data
against the quantiles (Q) of the assumed distribution. In R, the following code
generates the Q-Q plot shown in
Figure 6.12
for the residuals from the
Income