Skip to contents

The df attribute counts every parameter associated with the reported likelihood, including fitted shape, dispersion, variance, and explicit fixed-effect parameters. For conditional Poisson and conditional logistic likelihoods, only parameters remaining in the conditional likelihood are counted. Models estimated without a likelihood return NA.

Usage

# S3 method for class 'panglm'
logLik(object, ...)

Arguments

object

a fitted "panglm" object

...

unused

Value

an object of class "logLik"

Examples

data(copd)
fit <- panglm(exacerbations ~ crp, data = copd,
              index = c("id", "visit"), model = "pooling",
              family = "poisson")
logLik(fit)
#> 'log Lik.' -604.8321 (df=2)
AIC(fit)
#> [1] 1213.664
BIC(fit)
#> [1] 1221.072