single_stage_curtail_trial: Create a single-stage curtailed trial design

Description Usage Arguments Details Examples

Description

The single_stage_curtail_trial function creates a single-stage trial object containing design parameters and statistical properties of one or more curtailed designs

Usage

1
single_stage_curtail_trial(p_null, p_alt, s, t, n)

Arguments

p_null

probability of success under the null hypothesis

p_alt

probability of success under the alternative hypothesis

s

number of successes to stop the trial

t

number of failures to stop the trial

n

total maximum planned sample size (n = s+t-1)

Details

There are two ways that the user can specify the parameters to create a single-stage curtailed trial design, as defined in the two cases below. In case 1, the user provide sparameters values of s and t, in which case the trial object is created for that one specific design. In the second case, the user specifies an n rather than s and t and the trial object created contains all possible designs (values of s and t) for the given total sample size, n.

Case 1: User specifies p_null, p_alt, s, t

Case 2: User specifies p_null, p_alt, n

Examples

1
2
3
4
5
Case 1:
trial <- single_stage_curtail_trial(p_null=0.2, p_alt=0.4, s=7, t=11)

Case 2:
trials <- single_stage_curtail_trial(p_null=0.2, p_alt=0.4, n=17)

kaneplusplus/curtail documentation built on May 24, 2019, 2:04 a.m.