# NOT RUN {
# Sample size calculation based on exponentials.
n <- SampleSize(
cens_prop = 0.15,
med1 = 9,
med2 = 12
)
# Sample size calculation based on exponentials with a 2 month margin.
# Note that the required sample size is expected to increase.
n <- SampleSize(
cens_prop = 0.15,
med1 = 9,
med2 = 12,
margin = 2
)
# Sample size calculation based on Weibulls.
n <- SampleSize(
cens_prop = 0.15,
shape1 = 2.8,
rate1 = 0.10,
shape2 = 4.0,
rate2 = 0.08
)
# }
Run the code above in your browser using DataLab