# rCholWishart: Cholesky Factor of Random Wishart Distributed Matrices In CholWishart: Cholesky Decomposition of the Wishart Distribution

## Description

Generate n random matrices, distributed according to the Cholesky factorization of a Wishart distribution with parameters `Sigma` and `df`, W_p(Sigma, df) (known as the Bartlett decomposition in the context of Wishart random matrices).

## Usage

 `1` ```rCholWishart(n, df, Sigma) ```

## Arguments

 `n` integer sample size. `df` numeric parameter, "degrees of freedom". `Sigma` positive definite (p * p) "scale" matrix, the matrix parameter of the distribution.

## Value

a numeric array, say `R`, of dimension p * p * n, where each `R[,,i]` is a Cholesky decomposition of a sample from the Wishart distribution W_p(Sigma, df). Based on a modification of the existing code for the `rWishart` function.

## References

Anderson, T. W. (2003). An Introduction to Multivariate Statistical Analysis (3rd ed.). Hoboken, N. J.: Wiley Interscience.

Mardia, K. V., J. T. Kent, and J. M. Bibby (1979) Multivariate Analysis, London: Academic Press.

A. K. Gupta and D. K. Nagar 1999. Matrix variate distributions. Chapman and Hall.

## See Also

`rWishart`, `rInvCholWishart`

## Examples

 ``` 1 2 3 4 5 6 7 8 9 10 11 12``` ```# How it is parameterized: set.seed(20180211) A <- rCholWishart(1L, 10, 3 * diag(5L))[, , 1] A set.seed(20180211) B <- rInvCholWishart(1L, 10, 1 / 3 * diag(5L))[, , 1] B crossprod(A) %*% crossprod(B) set.seed(20180211) C <- chol(stats::rWishart(1L, 10, 3 * diag(5L))[, , 1]) C ```

CholWishart documentation built on Oct. 8, 2021, 9:09 a.m.