You are here

mxAlgebra Wishlist

The following algebras would be nice to have. They are currently scheduled for completion after the 2.0 release:

ceiling, floor, trunk, round
dim
rowMeans, colMeans
qnorm, pnorm
qr

Reporter: 
Created: 
Wed, 08/20/2014 - 12:46
Updated: 
Wed, 10/15/2014 - 15:30

Comments

I have some changes ready to commit that will implement qnorm() and the log-gamma function, lgamma(). I consider these two functions to be a relatively high priority in this wishlist, because they will enable a lot more custom-written likelihood functions to be written as mxAlgebras.

I can probably churn out trunc() and round() soon, too.

Also, note that we already have pnorm(). It's called omxMnor().

I agree with your prioritization. Is your qnorm mxAlgebra also multivariate?

The mnemonic for omxMnor is Multivariate NORmal integration.

Nope, it's univariate only. Quantiles from multivariate distributions are not necessarily unique. For instance, load the mvtnorm package and try

pmvnorm(lower = c(-Inf,-Inf), upper = c(1,0), mean = c(0,0), sigma = matrix(c(1,0.5,0.5,1),nrow=2))
pmvnorm(lower = c(-Inf,-Inf), upper = c(0,1), mean = c(0,0), sigma = matrix(c(1,0.5,0.5,1),nrow=2))

You'll see that (0,1) and (1,0) could both be considered the 0.468743 quantile of this distribution.

Of course! I believe I was thinking of dnorm. But we already have that as the fitfunction of a Normal Expectation.