tests/testthat/test_surv_model_performance.R

context("surv_model_performance")

source("objects_for_tests.R")

test_that("Creating surv_model_performance", {
  expect_is(mp_cph, "surv_model_performance_explainer")
  expect_is(mp_cph, "BS")
  expect_is(mp_cph_artificial, "surv_model_performance_explainer")
})

test_that("Wrong input",{
  expect_error(model_performance(cph_model))
  expect_error(model_performance(surve_cph_null_data))
})

Try the survxai package in your browser

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

survxai documentation built on Aug. 28, 2020, 5:07 p.m.