Package: safestats
Type: Package
Title: Safe Anytime-Valid Inference
Version: 0.8.8
Date: 2026-09-01
Authors@R: c(
  person("Alexander", "Ly", email = "alexander.ly.nl@gmail.com",
  role = c("cre", "aut")),
  person("Rosanne", "Turner", email = "rosanne.turner@cwi.nl",
  role = "aut"),
  person("Yongqi", "Wang", email = "yongqi.wang@cwi.nl",
  role = "aut"),
  person("Muriel Felipe", "Perez-Ortiz", email = "m.f.perez.ortiz@tue.nl",
  role = c("ctb")),
  person("Udo", "Boehm", email = "udo.boehm@cwi.nl",
  role = c("ctb")),
  person("Judith", "ter Schure", email = "Judith.ter.Schure@cwi.nl",
  role = c("ctb")),
  person("Peter", "Grunwald", email = "Peter.Grunwald@cwi.nl",
  role = c("ctb"))
  )
Maintainer: Alexander Ly <alexander.ly.nl@gmail.com>
Description: Functions to design and apply tests that are anytime valid. The
  functions can be used to design hypothesis tests in the prospective/randomised
  control trial setting or in the observational/retrospective setting. The
  resulting tests remain valid under both optional stopping and optional
  continuation. The current version includes safe t-tests and safe tests of
  two proportions. For details on the theory of safe tests, see Ly, A, Boehm, 
  Grunwald, Ramdas and van Ravenzwaaij (2024). "Safe Anytime-Valid Inference: 
  Practical maximally flexible sampling designs for experiments based on e-values" 
  (<doi:10.31234/osf.io/h5vae>) and Grunwald, de Heide 
  and Koolen (2024) "Safe Testing" (<doi:10.1093/jrsssb/qkae011>), for details 
  on safe logrank tests see ter Schure, Perez-Ortiz, Ly and Grunwald (2024) 
  "The Anytime-Valid Logrank Test: Error Control under Continuous Monitoring with 
  Unlimited Horizon" (<doi:10.51387/24-NEJSDS65>), and Turner, Ly and 
  Grunwald (2024) "Generic E-variables for exact sequential k-sample tests that 
  allow for optional stopping" (<doi:10.1016/j.jspi.2023.106116>) for 
  details on safe contingency table tests.
License: LGPL (>= 3)
Encoding: UTF-8
Depends: R (>= 4.5)
Imports: stats (>= 3.6), lamW (>= 2.2.1), hypergeo (>= 1.2-13),
        survival (>= 3.2-13), BiasedUrn (>= 1.07), boot (>= 1.3-28),
        dplyr (>= 1.0.6), purrr (>= 0.3.5), rlang (>= 1.0.6), Matrix
        (>= 1.7-3), graphics (>= 4.2.2)
Suggests: testthat (>= 3.0.0), knitr (>= 1.49), rmarkdown
VignetteBuilder: knitr
NeedsCompilation: no
RoxygenNote: 8.0.0
Language: en-GB
Config/testthat/edition: 3
Packaged: 2026-09-05 22:30:37 UTC; alexly
Author: Alexander Ly [cre, aut],
  Rosanne Turner [aut],
  Yongqi Wang [aut],
  Muriel Felipe Perez-Ortiz [ctb],
  Udo Boehm [ctb],
  Judith ter Schure [ctb],
  Peter Grunwald [ctb]
Repository: CRAN
Date/Publication: 2026-09-05 23:00:02 UTC
