Hi, in order to define multivariate distribution functions with known marginals, you can also use the copula package, e.g.,
library(copula) x <- mvdc(normalCopula(0.75), c("gamma", "gamma"), list(list(shape = 2, rate = 3), list(shape = 3, rate = 2))) x.samp <- rmvdc(x, 100) dmvdc(x, x.samp) pmvdc(x, x.samp) contour(x, dmvdc, xlim = c(0, 2), ylim = c(0, 3)) Best, Dimitris ---- Dimitris Rizopoulos Ph.D. Student Biostatistical Centre School of Public Health Catholic University of Leuven Address: Kapucijnenvoer 35, Leuven, Belgium Tel: +32/(0)16/336899 Fax: +32/(0)16/337015 Web: http://med.kuleuven.be/biostat/ http://www.student.kuleuven.be/~m0390867/dimitris.htm ----- Original Message ----- From: "Robin Hankin" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Wednesday, October 10, 2007 9:11 AM Subject: Re: [R] Multivariate chi-square distribution function > Hello > > > If you want the multivariate t-distribution, > use rmvt() of the mvtnorm package. > > If you want the Wishart distribution, one > can write a little nonce function: > > library(mvtnorm) > > rwis <- function(n,sigma){ > crossprod(rmvnorm(n,sigma=sigma)) > } > > I'm not sure what you mean by the multivariate gamma > distribution, but a good candidate might be the > Dirichlet. This is implemented in several packages; > see ?rdiric of the VGAM package for one example. > > > HTH > > > rksh > > > > On 9 Oct 2007, at 18:39, [EMAIL PROTECTED] wrote: > >> Dear All, >> >> Is there any function in R for computing "multivariate chi-square >> distribution"? >> How about "multivariate gamma distribution"? >> I appreciate any comment on this subject. >> >> Thank you, >> >> Amin Zollanvari >> PhD student >> Department of Electrical and Computer Engineering, >> Texas A&M University, >> College Station, TX >> >> ______________________________________________ >> R-help@r-project.org mailing list >> https://stat.ethz.ch/mailman/listinfo/r-help >> PLEASE do read the posting guide http://www.R-project.org/posting- >> guide.html >> and provide commented, minimal, self-contained, reproducible code. > > -- > Robin Hankin > Uncertainty Analyst > National Oceanography Centre, Southampton > European Way, Southampton SO14 3ZH, UK > tel 023-8059-7743 > > ______________________________________________ > R-help@r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide > http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.