intermediate.corr.CC {PoisBinNonNor} | R Documentation |
Computes an intermediate correlation matrix for continuous variables given the specified correlation matrix
Description
This function computes the intermediate correlation matrix for continuous-continuous combinations as formulated in Demirtas et al. (2012).
Usage
intermediate.corr.CC(n.P, n.B, n.C, coef.mat = NULL, corr.vec = NULL, corr.mat = NULL)
Arguments
n.P |
Number of Poisson variables. |
n.B |
Number of binary variables. |
n.C |
Number of continuous variables. |
coef.mat |
Matrix of coefficients produced from |
corr.vec |
Vector of elements below the diagonal of correlation matrix ordered column-wise. |
corr.mat |
Specified correlation matrix. |
Value
A correlation matrix of size n.C*n.C.
References
Demirtas, H., Hedeker, D., and Mermelstein, R.J. (2012). Simulation of massive public health data by power polynomials. Statistics in Medicine, 31(27), 3337-3346.
Vale, C.D. and Maurelli, V.A. (1983). Simulating multivariate nonnormal distributions. Psychometrika, 48(3), 465-471.
See Also
intermediate.corr.PC
, intermediate.corr.BC
Examples
## Not run:
n.P=2
n.C=4
coef.mat=matrix(c(
-0.31375, 0.00000, 0.10045, -0.10448,
0.82632, 1.08574, 1.10502, 0.98085,
0.31375, 0.00000, -0.10045, 0.10448,
0.02271, -0.02945, -0.04001, 0.00272),4,byrow=TRUE)
corr.vec = NULL
corr.mat=matrix(c(1.0,-0.3,-0.3,-0.3,-0.3,-0.3,
-0.3,1.0,-0.3,-0.3,-0.3,-0.3,
-0.3,-0.3,1.0,0.4,0.5,0.6,
-0.3,-0.3,0.4,1.0,0.7,0.8,
-0.3,-0.3,0.5,0.7,1.0,0.9,
-0.3,-0.3,0.6,0.8,0.9,1.0),6,byrow=TRUE)
intmatCC=intermediate.corr.CC(n.P,n.B=0,n.C,coef.mat,corr.vec=NULL,corr.mat)
intmatCC
## End(Not run)
[Package PoisBinNonNor version 1.3.3 Index]