Regression and diagnostics
Algorithms
- F-test for nested linear models
Compares a linear model with a nested smaller one by the drop in residual sum of squares per extra parameter over the residual variance. Exact F law under normal errors. One QR, O(n p^2).
1 languagesintro - Stepwise regression
Chooses the columns of a regression by adding or dropping one column at a time while a criterion such as AIC improves. It is fast and greedy, and it can miss the best subset.
1 languagesintro - Breusch-Pagan test
Tests for heteroscedasticity by regressing the squared residuals on the predictors; n times the R-squared of that regression is chi-squared under the null.
1 languagescore - Durbin-Watson test
Tests for first-order autocorrelation of regression residuals by the sum of squared successive differences over the sum of squares. Values near 2 mean none.
1 languagescore - Generalized least squares
Least squares after whitening by the error covariance, b = (X^T V^(-1) X)^(-1) X^T V^(-1) y. It is best linear unbiased for known V; with V estimated it is feasible GLS.
1 languagescore - Heteroscedasticity-consistent standard errors
Estimate the covariance of least squares as (X^T X)^(-1) X^T diag(e_i^2) X (X^T X)^(-1), which stays consistent when the error variance varies.
1 languagescore - Iteratively reweighted least squares
Solves a sequence of weighted least squares problems whose weights come from the current fit. It fits generalized linear models and robust M-estimators.
1 languagescore - Weighted least squares
Least squares with each squared residual weighted, usually by the inverse of its variance. It is the best linear unbiased estimator when the variances are known.
1 languagescore - Cluster-robust standard errors
A sandwich covariance that sums score contributions within clusters, so that inference stays valid when errors are correlated inside groups.
1 languagesadvanced - Henderson's mixed model equations
A linear system whose solution gives at once the GLS estimates of the fixed effects and the best linear unbiased predictions of the random effects.
1 languagesadvanced - Leaps and bounds algorithm
An exact branch and bound search for the subsets of each size with the smallest residual sum of squares. It cuts every branch whose bound shows that it cannot win.
1 languagesadvanced - Restricted maximum likelihood
Estimates variance components by maximizing the likelihood of error contrasts that do not depend on the fixed effects. It removes the downward bias of ML variance estimates.
1 languagesadvanced
Techniques
- Q-Q plot
Plots the ordered sample against the matching quantiles of a reference distribution. Points near a line mean the distributions agree up to location and scale.
intro - Box-Cox transformation
Transforms a positive response by (y^lambda - 1) / lambda, or log y at lambda = 0, choosing lambda by profile likelihood to make errors closer to normal with constant variance.
1 languagescore - Generalized estimating equations
Liang and Zeger's method for correlated responses: solve GLM-type score equations with a working correlation, and use the sandwich for valid standard errors.
1 languagesadvanced - Quasi-likelihood
Wedderburn's estimation that specifies only the mean and the variance function of the response. It gives GLM-like estimates and standard errors with overdispersion.
advanced
Concepts
- Heteroscedasticity
Errors whose variance changes with the predictors. Least squares stays unbiased but its usual standard errors are wrong.
intro - Post-selection inference
Valid tests and intervals for a model chosen from the same data, by conditioning on the selection event or by simultaneous inference over all models.
research
Definitions
- Coefficient of determination
The fraction of the variance of the response that the regression explains, one minus the residual sum of squares over the total sum of squares.
intro - Akaike information criterion
AIC = -2 log L + 2k. It estimates how well a fitted model will predict new data from the same source. Lower is better, and only differences on the same data mean anything.
core - Bayesian information criterion
BIC = -2 log L + k log n. It approximates -2 times the log marginal likelihood up to a bounded error, and it picks the true model among a fixed finite list as n grows.
core - Cook's distance
A measure of the influence of one observation: how far all fitted values move when it is deleted, scaled by p times the residual variance.
core - Deviance
Twice the log-likelihood gap between the saturated model and a fitted model. It plays the part of the residual sum of squares for a generalized linear model.
core - Hat matrix
The matrix H = X (X^T X)^(-1) X^T that maps the responses to the fitted values. It is a projection; its diagonal holds the leverages.
core - Leverage
The i-th diagonal entry of the hat matrix, which measures how far x_i lies from the other predictors and how much y_i pulls its own fitted value.
core - Studentized residual
A residual divided by an estimate of its standard deviation that accounts for its leverage. With the point left out of the variance estimate it has a t distribution.
core - Variance inflation factor
1 / (1 - R_j^2), where R_j^2 is from regressing predictor j on the others. It is the factor by which collinearity inflates the variance of coefficient j.
core
Theorems
- Gauss-Markov theorem
In a linear model with uncorrelated errors of equal variance, ordinary least squares has the least variance among all linear unbiased estimators.
core - Polyhedral lemma
The lasso selection event is a polyhedron in y, so a linear contrast of y given the event has a truncated normal law. This gives exact post-selection intervals.
1 languagesresearch
Models
- Linear mixed model
A linear model y = X b + Z u + e with fixed effects b and random effects u. It models grouped or repeated measures with correlated errors.
core - Errors-in-variables model
A regression model in which the predictors are observed with noise. Least squares is then biased toward zero, and Deming or orthogonal regression corrects it.
advanced