pt_from_ss {preference}R Documentation

Design Preference Trials with Sample Size Constraint(s)

Description

Create a set of preference trials where the maximum sample size for an arm is specified.

Usage

pt_from_ss(
  ss,
  pref_effect,
  selection_effect,
  treatment_effect,
  sigma2,
  pref_prop,
  choice_prop = 0.5,
  stratum_prop = 1,
  alpha = 0.05,
  k = 1
)

Arguments

ss

the maximum size of any of the three arms.

pref_effect

the effect size of the preference arm (delta_pi).

selection_effect

the effect size of selection arm (delta_nu).

treatment_effect

the sample size of the treatment arm (delta_tau)

sigma2

the variance estimate of the outcome of interest. This value should be positive numeric values. If study is stratified, should be vector of within-stratum variances with length equal to the number of strata in the study.

pref_prop

the proportion of patients preferring treatment 1. This value should be between 0 and 1 (phi).

choice_prop

the proportion of patients assigned to choice arm in the initial randomization. Should be numeric value between 0 and 1 (default=0.5) (theta).

stratum_prop

xi a numeric vector of the proportion of patients in each stratum. Length of vector should equal the number of strata in the study and sum of vector should be 1. All vector elements should be numeric values between 0 and 1. Default is 1 (i.e. unstratified design) (xi).

alpha

the desired type I error rate (default 0.05)..

k

the ratio of treatment A to treatment B in the random arm (default 1).

Examples


# Unstratified trials with power constraints.
pt_from_ss(ss=seq(100, 1000, by=100), pref_effect=1, 
  selection_effect=1, treatment_effect=1, sigma2=1, pref_prop=0.6)

# Stratified trials with power constraints. Note that the proportion
# of patients in the choice arm (choice prop) is fixed for all strata.
pt_from_ss(ss=seq(100, 1000, by=100), pref_effect=1, 
  selection_effect=1, treatment_effect=1,
  sigma2=list(c(1, 0.8)), pref_prop=list(c(0.6, 0.3)),
  choice_prop=0.5, stratum_prop=list(c(0.3, 0.7)))

# or...

pt_from_ss(ss=seq(100, 1000, by=100), pref_effect=1, 
  selection_effect=1, treatment_effect=1,
  sigma2=c(1, 0.8), pref_prop=c(0.6, 0.3),
  choice_prop=0.5, stratum_prop=c(0.3, 0.7))


[Package preference version 1.1.6 Index]