tests/testthat/test_TRC.R

context("TRC")
library(modi)

test_that("Length of output vector is equal to no. of rows of input data", {
  data(bushfirem, bushfire.weights)
  invisible(capture.output(det.res <- TRC(bushfirem, weights = bushfire.weights)))
  expect_equal(length(det.res$outind), dim(bushfirem)[1])
})

Try the modi package in your browser

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

modi documentation built on March 31, 2023, 8:35 p.m.