sc_lago: Optimum interventions under the single center LAGO design

Description Usage Arguments Value Examples

View source: R/single_center_lago.R

Description

This function takes as input several study design parameters of a multi-stage, single center per stage LAGO design and provides the estimated optimal intervention package through simulations. The required parameters that need to be supplied to the function are an initial starting intervention package which is optimized over the stages, the lower and upper limits for the components of the intervention package, the true or best guess beta values, number of stages K, sample size per stage n, the unit costs for the intervention package components and the desired outcome goal for the LAGO study. Since this function returns the estimated optimal interventions through simulations, this function also needs as input the expected variation among the subjects within the center at any stage.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
sc_lago(
  x0,
  lower,
  upper,
  nstages,
  beta.true,
  sample.size,
  icc,
  cost.vec,
  prob,
  intercept = TRUE,
  B = 100
)

Arguments

x0

a vector of starting values for the components of the intervention package

lower

a vector providing the values of lower limits for the components of the intervention package

upper

a vector providing the values of upper limits for the components of the intervention package

nstages

the number of stages of the LAGO design K (>=2)

beta.true

a vector of true i.e. population beta values

sample.size

sample size (n) in each of the K stages

icc

the expected variation among subjects within the center at any stage

cost.vec

a vector of per unit linear cost coefficients

prob

the desired outcome goal

intercept

a logical argument to include intercept in the model or not (default = TRUE)

B

the number of simulations (default = 100)

Value

The returned value is a named list containing

xopt

a dataframe containing the stage-wise estimated optimum intervention package obtained by considering the median over the given number of simulations

p.opt.hat

a vector containing the stage-wise estimated success probabilities, i.e. the success probabilities corresponding to the estimated optimal intervention package by considering the median over simulations

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
x.init = c(2.5, 12.5, 7) # Initial value interventions
x.l = c(1, 10, 2) # Lower limits for X
x.u = c(4, 15, 15) # Upper limits for X
n = 50 # Sample size
K = 3 # Number of stages
cost_lin = c(1, 8, 2.5) # Costs
p_bar = 0.9 # Desired outcome goal
# True/best guess beta values
beta = c(log(0.05), log(1.2), log(1.1), log(1.3))

sim_sc <- sc_lago(x0 = x.init, lower = x.l, upper = x.u,
                  nstages = K, beta.true = beta,
                  sample.size = n, icc = 0.1,
                  cost.vec = cost_lin, prob = p_bar,
                  B = 100, intercept = TRUE)

Arhit-Chakrabarti/logisticLAGO documentation built on Dec. 17, 2021, 9:43 a.m.