Learn R Programming

UPG (version 0.3.4)

logLik.UPG.Probit: Compute log-likelihoods from UPG.Probit objects

Description

logLik can be used to compute log-likelihoods from UPG.Probit objects. The log-likelihood is based on the posterior mean of the coefficients.

Usage

# S3 method for UPG.Probit
logLik(object = NULL, ...)

Value

Returns a numeric of class logLik with attributes containing the number of estimated parameters and the number of observations.

Arguments

object

an object of class UPG.Probit.

...

other logLik parameters.

Author

Gregor Zens

See Also

summary.UPG.Probit to summarize a UPG.Probit object and create tables. plot.UPG.Probit to plot a UPG.Probit object. coef.UPG.Probit to extract coefficients from a UPG.Probit object.

Examples

Run this code
# \donttest{
# estimate a probit model using example data
library(UPG)
data(lfp)
y = lfp[,1]
X = lfp[,-1]
results.probit = UPG(y = y, X = X, model = "probit")

# extract log-likelihood
ll.probit = logLik(results.probit)

# }

Run the code above in your browser using DataLab