tests/testthat/test_warnings.R

test_that("Weighted ITT", {
  data <- copy(SEQdata)
  expect_warning(SEQuential(data, "ID", "time", "eligible", "tx_init", "outcome", list("N", "L", "P"), list("sex"),
    method = "ITT",
    options = SEQopts(weighted = TRUE)
  ))
})

test_that("Unexcused Excused Censoring", {
  data <- copy(SEQdata)
  expect_warning(SEQuential(data, "ID", "time", "eligible", "tx_init", "outcome", list("N", "L", "P"), list("sex"),
    method = "censoring",
    options = SEQopts(weighted = TRUE, excused = TRUE)
  ))
})

Try the SEQTaRget package in your browser

Any scripts or data that you put into this service are public.

SEQTaRget documentation built on Sept. 15, 2025, 9:09 a.m.