R Under development (unstable) (2024-10-14 r87233 ucrt) -- "Unsuffered Consequences" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > library(qwraps2) > > set.seed(42) > p <- runif(100) > > stopifnot(all.equal(logit(p), log(p/(1-p)))) > stopifnot(all.equal(invlogit(log(p/(1-p))), p)) > > x <- seq(-3, 3, length = 1001) > stopifnot(all.equal(invlogit(x), plogis(x))) > > x <- seq(sqrt(.Machine$double.eps), 1 - sqrt(.Machine$double.eps), length = 1001) > stopifnot(all.equal(logit(x), qlogis(x))) > > proc.time() user system elapsed 0.18 0.04 0.21