loglikValue {micEcon} | R Documentation |
Return the log likelihood value. Objects should be models, estimated by Maksimum Likelihood, or other statistical models where the likelihood makes sense.
loglikValue(x, ...)
x |
object, usually a model estimated with Maximum Likelihood |
... |
additional arguments to methods |
The default method returns the component loglik
A single numeric, log likelihood of the estimated model
Ott Toomet otoomet@ut.ee
## We estimate a tobit-2 model and print the loglik value library(mvtnorm) N <- 500 vc <- diag(2) vc[2,1] <- vc[1,2] <- -0.7 eps <- rmvnorm(N, rep(0, 2), vc) xs <- runif(N) ys <- xs + eps[,1] > 0 xo <- runif(N) yo <- (xo + eps[,2])*(ys > 0) a <- selection(ys~xs, yo ~xo) loglikValue(a) # this values is also printed by 'summary'