On Tue, 04 May 2004 11:21:37 -0400 Sung Kim wrote:

> Dear expert,
> 
> I have two coefficients and covariance matrix. 
> 
> My objective is sampling 1000 times from the mean and covariance
> matrix.
> 
> In order to get that, what kind of commend should I use?
> 
> If you do not mind, could you tell me the comment in detail about
> parameter used in that commend also? 
> 

Look at rmvnorm in package mvtnorm:

library(mvtnorm)
help(rmvnorm)

m <- c(10, 40)
S <- matrix(c(10, 80, 80, 30), ncol = 2)
x <- rmvnorm(n = 1000, mean = m, sigma = S)
plot(x)

hth
Z
  
> 
> Thank you.
> 
>  
> 
> Sung.
> 
> 
>       [[alternative HTML version deleted]]
> 
> ______________________________________________
> [EMAIL PROTECTED] mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
>

______________________________________________
[EMAIL PROTECTED] mailing list
https://www.stat.math.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to