tests/testthat/test_misc.R

test_that("misc tests", {

  obj <- kernelboot(mtcars, function(data) coef(lm(mpg ~ ., data = data)), R = 10)

  expect_output(print(obj))
  expect_silent(summary(obj))

  expect_true(kernelboot:::is.diag(diag(10)))
  expect_false(kernelboot:::is.diag(matrix(1:9, 3)))

})

Try the kernelboot package in your browser

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

kernelboot documentation built on April 14, 2023, 5:14 p.m.