Initial data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 72d218235f
commit f23f22d71c
199087 changed files with 3378941 additions and 0 deletions

View file

@ -0,0 +1,8 @@
permutation.test <- function(treatment, control) {
perms <- combinations(length(treatment)+length(control),
length(treatment),
c(treatment, control),
set=FALSE)
p <- mean(rowMeans(perms) <= mean(treatment))
c(under=p, over=(1-p))
}

View file

@ -0,0 +1,4 @@
> permutation.test(c(85, 88, 75, 66, 25, 29, 83, 39, 97),
+ c(68, 41, 10, 49, 16, 65, 32, 92, 28, 98))
under over
0.8719717 0.1280283