Description Usage Arguments Value References See Also Examples
View source: R/intermediate.corr.PC.R
This function computes the pairwise entries of the intermediate normal correlation matrix for all Poisson-continuous combinations given the specified correlation matrix as formulated in Amatya and Demirtas (2015).
1 2 |
n.P |
Number of Poisson variables. |
n.B |
Number of binary variables. |
n.C |
Number of continuous variables. |
lambda.vec |
Rate vector for Poisson variables. |
prop.vec |
Proportion vector for binary 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. |
A correlation matrix of size n.P*n.C.
Amatya, A. and Demirtas, H. (2015). Simultaneous generation of multivariate mixed data with Poisson and normal marginals. Journal of Statistical Computation and Simulation, (85)15, 3129-3139.
intermediate.corr.PP
, intermediate.corr.CC
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | ## Not run:
n.P=2
n.C=4
lambda.vec=c(2,3)
coef.mat=matrix(rep(c(0,1,0,0),each=4),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)
intmatPC=intermediate.corr.PC(n.P,n.B=0,n.C,lambda.vec,prop.vec=NULL,
coef.mat,corr.vec=NULL,corr.mat)
intmatPC
#See also cmat.star in R package PoisNor
#cmat.star(no.pois=2,no.norm=4,corMat=corr.mat,lamvec=lambda.vec)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.