rmixture {bayesm} | R Documentation |
Draw from Mixture of Normals
Description
rmixture
simulates iid draws from a Multivariate Mixture of Normals
Usage
rmixture(n, pvec, comps)
Arguments
n |
number of observations |
pvec |
|
comps |
list of mixture component parameters |
Details
comps
is a list of length ncomp
with ncomp = length(pvec)
.
comps[[j]][[1]]
is mean vector for the j
th component.
comps[[j]][[2]]
is the inverse of the cholesky root of \Sigma
for j
th component
Value
A list containing:
x: |
an |
z: |
an |
Warning
This routine is a utility routine that does not check the input arguments for proper dimensions and type.
Author(s)
Peter Rossi, Anderson School, UCLA, perossichi@gmail.com.
See Also
[Package bayesm version 3.1-6 Index]