File: test-model_parameters.logitr.R

package info (click to toggle)
r-cran-parameters 0.24.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 3,852 kB
  • sloc: sh: 16; makefile: 2
file content (19 lines) | stat: -rw-r--r-- 530 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
skip_on_cran()
skip_if_not_installed("logitr")

test_that("model_parameters.logitr", {
  data(yogurt, package = "logitr")
  m <- logitr::logitr(
    data = yogurt,
    outcome = "choice",
    obsID = "obsID",
    pars = c("feat", "brand"),
    scalePar = "price",
    numMultiStarts = 5
  )
  params <- model_parameters(m, verbose = FALSE)
  expect_snapshot(params, variant = "windows")

  params <- model_parameters(m, verbose = FALSE, ci_method = "residual")
  expect_snapshot(params, variant = "windows")
})