tests/testthat/test-draw_cumulative_intensity_inversion.R

test_that("draw_cumulative_intensity_inversion() works with the Lambda_inv option", {
  L <- function(t) {
    return(2 * t)
  }
  Li <- function(z) {
    return(z / 2)
  }
  withr::with_seed(12345, df1 <- draw_cumulative_intensity_inversion(Lambda = L, Lambda_inv = Li, t_min = 0, t_max = 1))
  check_ppp_sample_validity(times = df1, t_min = 0, t_max = 1)
})

Try the nhppp package in your browser

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

nhppp documentation built on Oct. 30, 2024, 9:28 a.m.