powered by
This function samples one matrix IW matrix.
sim_iw(mat_scale, shape)
One k x k matrix following IW distribution
Scale matrix
Shape
Consider Σ∼IW(Ψ,ν).
Upper triangular Bartlett decomposition: k x k matrix Q=[qij] upper triangular with
qii2χν−i+12
qij∼N(0,1) with i < j (upper triangular)
Lower triangular Cholesky decomposition: Ψ=LLT
A=L(Q−1)T
Σ=AAT∼IW(Ψ,ν)