Description Usage Arguments Details Value See Also Examples
View source: R/ExchMultinomial.R
Calculates the within- and between-outcome correlation coefficients for exchangeable correlated
multinomial data based on joint probability estimates calculated by the jointprobs
function. These determine the variance inflation due the cluster structure.
1 | multi.corr(jp, type = attr(jp, "type"))
|
jp |
the output of |
type |
one of c("averaged","cluster","mc") - the type of joint probability. By default,
the |
If R_i and R_j is the number of events of type i and j, respectively, in a cluster of size n, then
Var(R_i)= n p_i (1-p_i)(1 + (n-1)φ_{ii})
Cov(R_i,R_j)= -n p_i p_j (1 + (n-1)φ_{ij})
where p_i and p_j are the marginal event probabilities and φ_{ij} are the correlation
coefficients computed by multi.corr
.
a list of estimated correlation matrices by treatment group. If cluster-size specific
estimates were requested ((type="cluster")
), then each list elements are a list of
these matrices for each cluster size.
jointprobs
for calculating the joint probability arrays
1 2 3 | data(dehp)
tau <- jointprobs(dehp, type="averaged")
multi.corr(tau)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.