Residual plot意思
A residual plot is a graphical representation of the residuals (deviations) of a data set from the fitted values of a statistical model, such as a linear regression model. The plot is used to assess the goodness of fit of the model and to look for patterns or anomalies in the residuals that might indicate that the model is not appropriate or that there are outliers or influential points in the data.
In a residual plot, the vertical axis represents the residuals (usually standardized to have a mean of 0 and a standard deviation of 1) and the horizontal axis represents the independent variable (or a function of the independent variable). A good model should have residuals that are randomly distributed around 0 with no discernible pattern, indicating that the model is capturing the relationship between the dependent and independent variables well.
Common types of residual plots include:
-
Residuals vs. Fitted Values Plot: This plot shows the residuals on the vertical axis against the fitted values of the model on the horizontal axis. A good fit should show no pattern, such as a horizontal line or a random scatter around zero.
-
Normal Q-Q Plot: This plot compares the quantiles of the residuals to the quantiles of a normal distribution. A straight line through the origin indicates that the residuals are normally distributed, which is a common assumption for many statistical tests and models.
-
Residuals vs. Leverage Plot: This plot shows the residuals on the vertical axis against a measure of leverage (such as the hat matrix) on the horizontal axis. It helps identify outliers or influential points in the data.
-
Residuals vs. Predicted Values Plot: This plot is similar to the residuals vs. fitted values plot but uses the predicted values instead of the fitted values.
Residual plots are an important tool in model diagnostics and can help identify issues with the model, such as heteroscedasticity (unequal variance), autocorrelation, or non-linearity. By addressing these issues, you can improve the accuracy and reliability of your model.