Description Usage Arguments Value Author(s) See Also Examples
View source: R/countsToBinomial.R
Convert a contingency table of wins to a four-column data frame containing the number of wins and losses for each pair of players.
1 | 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
1 2 3 4 5 6 7 8 9 10 | ########################################################
## 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
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.