llmnl {bayesm}  R Documentation 
llmnl
evaluates loglikelihood for the multinomial logit model.
llmnl(beta, y, X)
beta 

y 

X 

Let \mu_i = X_i beta
, then Pr(y_i=j) = exp(\mu_{i,j}) / \sum_k exp(\mu_{i,k})
.
X_i
is the submatrix of X
corresponding to the
i
th observation. X
has n*p
rows.
Use createX
to create X
.
Value of loglikelihood (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, Anderson School, UCLA, perossichi@gmail.com.
For further discussion, see Bayesian Statistics and Marketing by Rossi, Allenby, and McCulloch.
## Not run: ll=llmnl(beta,y,X)