llmnp(bayesm) | R Documentation |
llmnp
evaluates the log-likelihood for the multinomial probit model.
llmnp(X, y, beta, Sigma, r)
X |
X is n*(p-1) x k array. X is from differenced system. |
y |
y is vector of n indicators of multinomial response (1, ..., p). |
beta |
k x 1 vector of coefficients |
Sigma |
(p-1) x (p-1) Covariance matrix of errors |
r |
number of draws used in GHK |
X is (p-1)*n x k matrix. Use createX
with DIFF=TRUE
to create X.
Model for each obs: w = Xbeta + e. e ~N(0,Sigma)
censoring mechanism:
if y=j (j<p), w_j > max(w_-j) and w_j >0
if y=p, w < 0
To use GHK, we must transform so that these are rectangular regions e.g. if y=1, w_1 > 0 and w_1 - w_-1 > 0. Define Aj such that if j=1,...,p-1, Ajw = Ajmu + Aje > 0 is equivalent to y=j implies Aje > -Ajmu. Lower truncation is -Ajmu and cov = AjSigma t(Aj). For p, e < - mu
value of log-likelihood (sum of log prob of observed multinomial outcomes).
This routine is a utility routine that does not check the input arguments for proper dimensions and type.
Peter Rossi, Graduate School of Business, University of Chicago, Peter.Rossi@ChicagoGsb.edu.
For further discussion, see Bayesian Statistics and Marketing
by Allenby, McCulloch, and Rossi, Chapters 2 and 4.
http://gsbwww.uchicago.edu/fac/peter.rossi/research/bsm.html
## ## Not run: ll=llmnp(X,y,beta,Sigma,r)