Contents
Backfitting algorithm
In statistics, the backfitting algorithm is a simple iterative procedure used to fit a generalized additive model. It was introduced in 1985 by Leo Breiman and Jerome Friedman along with generalized additive models. In most cases, the backfitting algorithm is equivalent to the Gauss–Seidel method, an algorithm used for solving a certain linear system of equations.
Algorithm
Additive models are a class of non-parametric regression models of the form: where each is a variable in our p-dimensional predictor X, and Y is our outcome variable. \epsilon represents our inherent error, which is assumed to have mean zero. The f_j represent unspecified smooth functions of a single X_j. Given the flexibility in the f_j, we typically do not have a unique solution: \alpha is left unidentifiable as one can add any constants to any of the f_j and subtract this value from \alpha. It is common to rectify this by constraining leaving necessarily. The backfitting algorithm is then: Initialize ,\forall j Do until \hat{f_j} converge: For each predictor j: (a) (backfitting step) (b) (mean centering of estimated function) where is our smoothing operator. This is typically chosen to be a cubic spline smoother but can be any other appropriate fitting operation, such as: In theory, step (b) in the algorithm is not needed as the function estimates are constrained to sum to zero. However, due to numerical issues this might become a problem in practice.
Motivation
If we consider the problem of minimizing the expected squared error: There exists a unique solution by the theory of projections given by: for i = 1, 2, ..., p. This gives the matrix interpretation: where. In this context we can imagine a smoother matrix, S_i, which approximates our P_i and gives an estimate, S_i Y, of E(Y|X) or in abbreviated form An exact solution of this is infeasible to calculate for large np, so the iterative technique of backfitting is used. We take initial guesses f_j^{(0)} and update each in turn to be the smoothed fit for the residuals of all the others: Looking at the abbreviated form it is easy to see the backfitting algorithm as equivalent to the Gauss–Seidel method for linear smoothing operators S.
Explicit derivation for two dimensions
Following, we can formulate the backfitting algorithm explicitly for the two dimensional case. We have: If we denote as the estimate of f_1 in the ith updating step, the backfitting steps are By induction we get and If we set then we get Where we have solved for by directly plugging out from. We have convergence if. In this case, letting : We can check this is a solution to the problem, i.e. that and converge to f_1 and f_2 correspondingly, by plugging these expressions into the original equations.
Issues
The choice of when to stop the algorithm is arbitrary and it is hard to know a priori how long reaching a specific convergence threshold will take. Also, the final model depends on the order in which the predictor variables X_i are fit. As well, the solution found by the backfitting procedure is non-unique. If b is a vector such that from above, then if \hat{f} is a solution then so is is also a solution for any. A modification of the backfitting algorithm involving projections onto the eigenspace of S can remedy this problem.
Modified algorithm
We can modify the backfitting algorithm to make it easier to provide a unique solution. Let be the space spanned by all the eigenvectors of Si that correspond to eigenvalue 1. Then any b satisfying has and Now if we take A to be a matrix that projects orthogonally onto, we get the following modified backfitting algorithm: Initialize ,, Do until \hat{f_j} converge: Regress onto the space, setting For each predictor j: Apply backfitting update to (Y - a) using the smoothing operator, yielding new estimates for \hat{f_j}
This article is derived from Wikipedia and licensed under CC BY-SA 4.0. View the original article.
Wikipedia® is a registered trademark of the
Wikimedia Foundation, Inc.
Bliptext is not
affiliated with or endorsed by Wikipedia or the
Wikimedia Foundation.