[R] Simulating from a Multivariate Normal Distribution Using a Correlation Matrix
Matthew David Sylvester
msylvest at uclink.berkeley.edu
Fri Jun 25 09:48:51 CEST 2004
Hello,
I would like to simulate randomly from a multivariate normal distribution using a correlation
matrix, rho. I do not have sigma. I have searched the help archive and the R documentation as
well as doing a standard google search. What I have seen is that one can either use rmvnorm in
the package: mvtnorm or mvrnorm in the package: MASS. I believe I read somewhere that the latter
was more robust. I have seen conflicting (or at least seemingly conflicting to me, a relative
statistics novice), views on whether one can use the correlation matrix with these commands
instead of the covariance matrix. I thought that if the commands standardized the covariance
matrix, then it would not matter, but I end up with larger values when I test the covariance
matrix versus when I test rho. So, my question is, if one does not know sigma, can they use rho?
And, if so, which command (or is there another) is better to use? I gather that both use eigen
decomposition? Thank you so much in advance for your help.
Best,
Matt
More information about the R-help
mailing list