tests/testthat/test-plot_curve_params_one_ab.R

test_that("`plot_curve_params_one_ab()` produces consistent results", {
  params <-
    data.frame(
      y0 = 10,
      y1 = 10 ^ 4,
      t1 = 9.5,
      alpha = 0.01,
      r = 1,
      antigen_iso = "test"
    ) |>
    as_curve_params()


  fig1 <-
    params |>
    plot_curve_params_one_ab(n_points = 10 ^ 5,
                             xlim = c(0, 25),
                             log_y = FALSE)

  fig1 |>
    vdiffr::expect_doppelganger(title = "curve_r1")

})

Try the serocalculator package in your browser

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

serocalculator documentation built on April 3, 2025, 7:35 p.m.