get_oc_Switch {BayesOrdDesign}R Documentation

Generate operating characteristics for Bayesian two-stage trial design of ordinal endpoints without proportional odds assumption.

Description

Obtain operating characteristics (OC) of the Bayesian two-stage trial design with ordinal endpoints while the proportional odds assumption are violated.

Usage

get_oc_Switch(
  alpha,
  pro_ctr,
  U,
  ors,
  n_range,
  fixed_es,
  n_po,
  n_npo,
  ntrial,
  method
)

Arguments

alpha

the desired type I error to be controlled.

pro_ctr

distribution of clinical categories for the control group.

U

the desirability of each outcome level.

ors

a user-defined matrix, each row denotes the various scenarios, the number of columns depend on the number of outcome scales.

n_range

the additional sample size for each arm each stage after n_po, n_npo.

fixed_es

fixed effect size when simulate the OC for various sample size.

n_po

sample size for the treatment and control groups, at each stage based on PO model.

n_npo

sample size for the treatment and control groups, at each stage based on NPO model.

ntrial

the number of simulated trials.

method

whether the statistical test for interim/final analysis is Bayesian or Frequentist. method = "Frequentist" for Frequentist approach; method = "Bayesian" for Bayesian approach.

Details

Grid search of sample size is used for guarantee a desirable type I error rate. The upper limitation is 200, and lower limitation default is sample size 50 for the control and treatment groups at each stage. Default increment of the sequence is 10.

For the parameter estimation section, we have two options, and can be selected using the method argument. Two following options are available: (i) method = "Frequentist", (ii) method = "Bayesian". If method = "Frequentist", parameters are estimated via package ordinal, which is based on frequentist method, while method = "Bayesian", parameters are estimated through Bayesian model.

Specifically, the numerical utilities U reflect the desirability of each outcome level. To do this, in our example, we first set U[1] = 100 and U[5] = 0, and then asked physicians to specify numerical values for the intermediate levels, that reflect their desirability relative to the best and worst levels.

Function provides two types of operating characteristics via simulation. If user specifies the value of ors and fixed_ss, function will calculate the design's power in terms of effect size. If user specifies the value of n_range and fixed_es, function will calculate the design's power in terms of sample size, and n_range is the upper limitation of sample size for the treatment and control groups at each stage, the lower limitation is 50, the default increment of the sequence is 10.

Arguments n_po and n_npo are the estimated sample size for the treatment and control groups at each stage based on PO model and NPO model respectively. Users can obtained them through function ss_po and ss_npo.

Value

get_oc_NPO() returns the operating characteristics of design as a table, including (1) user-defined value, either sample size or effect size (2) corresponding power (3) average sample size

Examples




get_oc_Switch(alpha = 0.05, pro_ctr = c(0.58,0.05,0.17,0.03,0.04,0.13),
             U = c(100,80,65,25,10,0), n_range = 10, fixed_es = c(1.5,1.5,1,1,1),
             n_po = 475,n_npo = 75, ntrial = 5, method = "Frequentist")


or2 = matrix(rep(seq(1,1.3, by=0.1), times=1, each=3),ncol = 3,byrow = TRUE)
or1 = matrix(rep(1.5, dim(or2)[1]*2), ncol = 2, byrow = TRUE)
ors = cbind(or1, or2)

get_oc_Switch(alpha = 0.05, pro_ctr = c(0.58,0.05,0.17,0.03,0.04,0.13),
              U = c(100,80,65,25,10,0), ors, n_po = 475, n_npo = 75,
              ntrial = 5, method = "Frequentist")
              

[Package BayesOrdDesign version 0.1.2 Index]