tests/testthat/test_add_box_coordinates.r

test_that("general test case", {
  example <- data.frame(x=rnorm(10),
                        y=rnorm(10))

  out <- add_box_coordinates(data=example, box_width=10, box_height=10)

  expect_equal(colnames(out), c("x", "y", "ymax", "ymin", "xmax", "xmin"))
})

Try the simDAG package in your browser

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

simDAG documentation built on April 3, 2025, 10:35 p.m.