Re: [R] qmvnorm function

2012-03-14 Thread Rui Barradas
Hello, > > Thanks Rui. > > Sorry I forgot to mention what is the "var" in the previous message. It > seems > that when the correlation is small, it does not work. > See below. > It works in my system: (your first example) var <- matrix(c(1,0.05,0.05,1), nrow=2, ncol=2, byrow=T) var [,1] [

Re: [R] qmvnorm function

2012-03-14 Thread li li
Thanks Rui. Sorry I forgot to mention what is the "var" in the previous message. It seems that when the correlation is small, it does not work. See below. > var <- matrix(c(1,0.05,0.05,1), nrow=2, ncol=2, byrow=T) > var [,1] [,2] [1,] 1.00 0.05 [2,] 0.05 1.00 > qmvnorm(0.05, tail="upper", s

Re: [R] qmvnorm function

2012-03-14 Thread Rui Barradas
Hello, li li-13 wrote > > Dear all, >I need to use the "qmvnorm" function in mtvnorm package. > > Here is the error message I got >> qmvnorm(0.05, tail="upper", sigma=var)$quantile > Error in uniroot(pfct, interval = interval) : > f() values at end points not of opposite sign > > There is

[R] qmvnorm function

2012-03-14 Thread li li
Dear all, I need to use the "qmvnorm" function in mtvnorm package. Here is the error message I got > qmvnorm(0.05, tail="upper", sigma=var)$quantile Error in uniroot(pfct, interval = interval) : f() values at end points not of opposite sign There is no problem for 50th quantile. > qmvnorm(0.