tests/testthat/test_other.R

data(lalonde)
pscores <- propensity_scores(
  .data = lalonde,
  treatment = 'treat',
  response = 're78',
  confounders = c('age', 'educ')
)


test_that("propensity_scores() output is correct", {
  expect_equal(length(pscores), nrow(lalonde))
  expect_vector(pscores)
})

Try the plotBart package in your browser

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

plotBart documentation built on May 27, 2022, 9:12 a.m.