Skip to contents

Side-by-side fit statistics for ordered / inflated ordered models

Usage

compare_models(...)

Arguments

...

Named "iord" fits.

Value

A data frame with one row per model: model label, log-likelihood, degrees of freedom, AIC, BIC, N, and the inflated category (if any), sorted as supplied.

Examples

set.seed(6)
d <- riop(500, beta = c(0.8, -0.5), tau = c(-0.6, 0.7), gamma = c(0.3, 1), inflate = "bottom")
compare_models(op = oprobit(y ~ x1 + x2, d), ziop = iop(y ~ x1 + x2 | z1, d, inflate = "bottom"))
#>   model                                           type    logLik df      AIC
#> 1    op                                 Ordered probit -437.6995  4 883.3990
#> 2  ziop Inflated ordered probit (inflated category: 0) -378.3508  6 768.7016
#>        BIC   N
#> 1 900.2575 500
#> 2 793.9893 500