eff_suggest: Suggest the input 'eff.structure' of function 'SimPRMD' with...

Description Usage Arguments Value Examples

View source: R/eff_summary.R

Description

Suggest the input eff.structure of function SimPRMD with selected eff.sd_tran for given efficacy mean matrix and efficacy standard deviation

Usage

1
eff_suggest(eff.M, eff.sd, eff.sd_trans, n.sim = 30000)

Arguments

eff.M

The efficacy mean matrix whose (i,j)th element save the target mean of the efficacy data

eff.sd

The target standard deviation matrix for all dose and cycles. Notice that the generated efficacy may have different standard deviation matrix due to the correlations across cycles

eff.sd_trans

The eff.sd_trans for test. Notice variance of the generated efficacy data will be effected by eff.sd_trans.

n.sim

The number of simulations for the numerical calculation in the function. The default is 30,000

Value

eff.suggest

The matrix suggested for the input eff.structure of function SimPRMD

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# Provide an target efficacy mean matrix for all dose and cycles
eff.M <- matrix(rep(3:8/10, 6), nrow = 6, ncol = 6)

# Give a target standard deviation matrix for all dose and cycles
# Notice that the generated efficacy may have difference standard deviation
# matrix due to the correlations across cycles
eff.sd <- matrix(0.2, nrow = 6, ncol = 6)

# Select a eff.sd_trans for testing. The efficacy variance are mainly
# controlled by the eff.sd_trans
eff.sd_trans <- 1.5  # or other positive value
eff.structure <- eff_suggest(eff.M = eff.M, eff.sd = eff.sd,
                             eff.sd_trans = eff.sd_trans)

# check whether the suggested eff.M and the selected sd_trans
# generate the desirable scenario
eff.Sigma <- diag(6)
diag(eff.Sigma[-1,]) = 0.5
diag(eff.Sigma[, -1]) = 0.5
eff.check <- eff_summary(eff.structure = eff.structure,
                         eff.Sigma = eff.Sigma,
                         eff.sd_trans = eff.sd_trans,
                         plot.flag = FALSE)
eff.check$eff.M
eff.check$eff.cor.ls

LuZhangstat/Phase1Mayo documentation built on March 16, 2020, 1:32 a.m.