logLik.UPG.Binomial {UPG} | R Documentation |
logLik
can be used to compute log-likelihoods from UPG.Binomial
objects. The log-likelihood is based on the posterior mean of the coefficients and can be used for model selection when combined with,e.g., BIC
or other model selection criteria.
## S3 method for class 'UPG.Binomial' logLik(object = NULL, ...)
object |
an object of class |
... |
other logLik parameters. |
Returns a numeric of class logLik
with attributes containing the number of estimated parameters and the number of observations. Note that the number of observations in binomial models is equal to Ni and not equal to the sample size.
Gregor Zens
summary.UPG.Binomial
to summarize the estimates of a discrete choice model from an UPG.Binomial
object and create tables.
plot.UPG.Binomial
to plot the results of a discrete choice model from an UPG.Binomial
object.
coef.UPG.Binomial
to extract coefficients from an UPG.Binomial
object.
# estimate a binomial logit model using example data library(UPG) data(titanic) y = titanic[,1] Ni = titanic[,2] X = titanic[,-c(1,2)] results.binomial = UPG(y = y, X = X, Ni = Ni, type = "binomial") # extract log-likelihood ll.binomial = logLik(results.binomial) # compute BIC BIC(ll.binomial)