Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

rmvnorm

Simulate from a Multivariate Normal Distribution


Description

Simulate from a multiviate normal distribution

Usage

rmvnorm(n, mu=NULL, sigma=NULL)

Arguments

n

Number of vectors to simulate

mu

mean vector

sigma

covariance matrix, assumed symmetric and nonnegative definite

Details

This function uses an eigen decomposition assuming sigma is symmetric. In particular, the upper triangle of sigma is ignored.

Value

An n x d matrix in which each row is an independently generated realization from the desired multivariate normal distribution

See Also


mixtools

Tools for Analyzing Finite Mixture Models

v1.2.0
GPL (>= 2)
Authors
Derek Young [aut, cre] (<https://orcid.org/0000-0002-3048-3803>), Tatiana Benaglia [aut], Didier Chauveau [aut], David Hunter [aut], Ryan Elmore [ctb], Thomas Hettmansperger [ctb], Hoben Thomas [ctb], Fengjuan Xuan [ctb]
Initial release
2020-02-05

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.