Description Usage Arguments Details References Examples
Simulatenously estimates of multinomial cell probabilities.
1 | est_multinom(x, n = NULL, prior = NULL, groups = c("test", "control"))
|
x |
A numeric vector of success counts OR a 2x2 table. |
n |
A numeric vector of totals. |
prior |
A matrix of hyper-parameters. |
The model assumes no margins are fixed. Two random binary outcomes are measured on N individuals, resulting in four possible combined outcomes with probabilities p_{11}, p_{12}, p_{21}, p_{22}.
Fienberg, S.E. and Holland, P.W. (1973) Simultaneous estimation of multinomial cell probabilities. Journal of the American Statistical Association, 68, 683-691. doi:10.1080/01621459.1973.10481405
1 2 3 4 5 6 7 8 9 | fake_data <- matrix(c(200, 150, 250, 300), nrow = 2, byrow = TRUE)
colnames(fake_data) <- c('Safe' ,'Dangerous')
rownames(fake_data) <- c('Animals', 'Plants')
est_multinom(fake_data)
est_multinom(x = c(200, 250), n = c(350, 550))
hyperparams <- matrix(c(0.25, 0.2, 0.15, 0.4), nrow = 2, byrow = TRUE)
est_multinom(fake_data, prior = hyperparams)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.