brat(refgp = "last", refvalue = 1, init.alpha = 1)
"vglmff"
(see vglmff-class
).
The object is used by modelling functions such as vglm
.multinomial
and
binomialff
.bratt
if there are ties).
The probability that Competitor $i$ beats Competitor $j$ is
$\alpha_i / (\alpha_i+\alpha_j)$,
where all the $\alpha$s are positive.
Loosely, the $\alpha$s can be thought of as the
competitors' `abilities'.
For identifiability, one of the $\alpha_i$ is set to a
known value refvalue
, e.g., 1.
By default, this function chooses the last competitor to
have this reference value.
The data can be represented in the form of a
$M+1$ by $M+1$ matrix of counts,
where winners are the rows and losers are the columns.
However, this is not the way the data should be inputted (see below).Excluding the reference value/group, this function chooses $\log(\alpha_j)$ as the $M$ linear predictors. The log link ensures that the $\alpha$s are positive.
The Bradley Terry model can be fitted by logistic regression, but this approach is not taken here. The Bradley Terry model can be fitted with covariates, e.g., a home advantage variable, but unfortunately, this lies outside the VGLM theoretical framework and therefore cannot be handled with this code.
Stigler, S. (1994) Citation patterns in the journals of statistics and probability. Statistical Science, 9, 94--108.
The BradleyTerry
package has more comprehensive capabilities
than this function.
bratt
,
Brat
,
multinomial
,
binomialff
.# citation statistics: being cited is a 'win'; citing is a 'loss'
journal = c("Biometrika", "Comm Statist", "JASA", "JRSS-B")
m = matrix(c( NA, 33, 320, 284,
730, NA, 813, 276,
498, 68, NA, 325,
221, 17, 142, NA), 4,4)
dimnames(m) = list(winner = journal, loser = journal)
fit = vglm(Brat(m) ~ 1, brat(refgp=1), trace=TRUE)
fit = vglm(Brat(m) ~ 1, brat(refgp=1), trace=TRUE, cri="c")
summary(fit)
c(0, coef(fit)) # log-abilities (in order of "journal")
c(1, Coef(fit)) # abilities (in order of "journal")
fitted(fit) # probabilities of winning in awkward form
(check = InverseBrat(fitted(fit))) # probabilities of winning
check + t(check) # Should be 1's in the off-diagonals
Run the code above in your browser using DataLab