designObj <- designSafeT(deltaMin=0.6, alpha=0.008, alternative="greater",
testType="twoSample", ratio=1.2)
set.seed(1)
x <- rnorm(100)
y <- rnorm(100)
safeTTest(x, y, designObj=designObj) #0.2959334
safeTTest(1:10, y = c(7:20), pilot=TRUE) # s = 658.69 > 1/alpha
designObj <- designSafeT(deltaMin=0.6, alpha=0.008, alternative="greater",
testType="twoSample", ratio=1.2)
set.seed(1)
x <- rnorm(100)
y <- rnorm(100)
safe.t.test(x, y, alternative="greater", designObj=designObj) #0.2959334
safe.t.test(1:10, y = c(7:20), pilot=TRUE) # s = 658.69 > 1/alpha
Run the code above in your browser using DataLab