glmmPQL.control {BradleyTerry2} | R Documentation |

## Control Aspects of the glmmPQL Algorithm

### Description

Set control variables for the glmmPQL algorithm.

### Usage

```
glmmPQL.control(maxiter = 50, IWLSiter = 10, tol = 1e-06, trace = FALSE)
```

### Arguments

`maxiter` |
the maximum number of outer iterations. |

`IWLSiter` |
the maximum number of iterated weighted least squares iterations used to estimate the fixed effects, given the standard deviation of the random effects. |

`tol` |
the tolerance used to determine convergence in the IWLS iterations and over all (see details). |

`trace` |
logical: whether or not to print the score for the random effects variance at the end of each iteration. |

### Details

This function provides an interface to control the PQL algorithm used by
`BTm()`

for fitting Bradley Terry models with random effects.

The algorithm iterates between a series of iterated weighted least squares iterations to update the fixed effects and a single Fisher scoring iteration to update the standard deviation of the random effects.

Convergence of both the inner and outer iterations are judged by comparing
the squared components of the relevant score vector with corresponding
elements of the diagonal of the Fisher information matrix. If, for all
components of the relevant score vector, the ratio is less than
`tolerance^2`

, or the corresponding diagonal element of the Fisher
information matrix is less than 1e-20, iterations cease.

### Value

A list with the arguments as components.

### Author(s)

Heather Turner

### References

Breslow, N. E. and Clayton, D. G. (1993), Approximate inference
in Generalized Linear Mixed Models. *Journal of the American
Statistical Association* **88**(421), 9–25.

### See Also

### Examples

```
## Variation on example(flatlizards)
result <- rep(1, nrow(flatlizards$contests))
## BTm passes arguments on to glmmPQL.control()
args(BTm)
BTmodel <- BTm(result, winner, loser, ~ throat.PC1[..] + throat.PC3[..] +
head.length[..] + SVL[..] + (1|..),
data = flatlizards, tol = 1e-3, trace = TRUE)
summary(BTmodel)
```

*BradleyTerry2*version 1.1-2 Index]