countsToBinomial {BradleyTerry2} | R Documentation |
Convert a contingency table of wins to a four-column data frame containing the number of wins and losses for each pair of players.
countsToBinomial(xtab)
xtab |
a contingency table of wins cross-classified by “winner” and “loser” |
A data frame with four columns
player1 |
the first player in the contest. |
player2 |
the second player in the contest. |
win1 |
the number of times |
win2 |
the number of times |
Heather Turner
######################################################## ## Statistics journal citation data from Stigler (1994) ## -- see also Agresti (2002, p448) ######################################################## citations ## Convert frequencies to success/failure data citations.sf <- countsToBinomial(citations) names(citations.sf)[1:2] <- c("journal1", "journal2") citations.sf