Description Usage Arguments Details Value See Also Examples
Combines main and bootstrap results.
1 | salbmCombine(x0, Samps=NULL, div=c(NA,NA))
|
x0 |
main results from original data. |
Samps |
list of sample results |
div |
low and high alpha points |
Combines data and produces bootstrap summaries including confidence intervals.
Four types of confidence intervals are calculated after combining the results. Fixing the sensitivity parameter, let E be an estimate for a treatment group and for b=1,2,…,B let E_b be the corresponding estimate for bootstrap b. Let SE be a standard error estimate for E and SE_b be a standard error estimate for E_b. Let q( \{x_i\}, v) be the vth quantile for the collection \{x_i\}.
1. Let q_l = q( \{E_b\}, 0.025 ) and q_u = q( \{E_b\}, 0.975 ). Then a 95% confdence interval for E is given by ( q_l, q_u ). These are refered to as c("lb1","ub1") or type 1 confidence intervals.
2. Let q_s = q( \{\mid E_b - E\mid\}, 0.95 ). Then a 95% confdence interval for E is given by ( E - qs, E + qs ). These are refered to as c("lb2","ub2") or type 2 confidence intervals.
3. Let t_b = ( E_b - E ) / SE_b, eqnq_l = q( {t_b}, 0.025 ) and q_u = q( \{t_b\}, 0.975 ). Let M be the mean of E_b. Then a 95% confdence interval for eqnE is given by ( M - q_u SE, M - q_l SE ) These are refered to as c("lb3","ub3") or type 3 confidence intervals.
4. Let t_b = ( E_b - E ) / SE_b, and q_s = q( \{\mid t_b \mid\}, 0.95 ). Let M be the mean of E_b. Then a 95% confdence interval for E is given by ( M - q_s SE, M + q_s SE ) These are refered to as c("lb4","ub4") or type 4 confidence intervals.
Computing SE
Let D be a dataset with n rows and T a fixed timepoint. Three standard deviations are computed
SD_0 the standard deviation of the data in D at timepoint T when 0 is substituted for missing values in D,
SD_1 the standard deviation of the data in D at timepoint T when 1 is substituted for missing values in D, and
SD_m the standard deviation of the data in D at timepoint T when mean value at time T is substituted for missing values at time T.
A low, mid and high values of alpha are choosen and denoted by a_l, a_0, and a_u respectively. In salbm a_0 = 0. Then a standard error is computed as:
SE = ≤ft\{\Large\begin{array}{ll} \frac{( α - a_l ) SD_0 + ( a_0 - α ) SD_m }{ ( a_0 - a_l ) √{n} }&\normalsize \mbox{\hspace{0.2in} when } \normalsize α < 0 \\[0.15in] \frac{( a_u - α ) SD_1 + ( α - a_0 ) SD_m }{ ( a_u - a_0 ) √{n} }&\normalsize \mbox{\hspace{0.2in} when } \normalsize α ≥ 0 \end{array} \right.
a list with combined results
salbm
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | data(trt1)
data(trt2)
data <- list( trt1 = trt1, trt2 = trt2 )
## main run
x0 <- salbm( data = data , K = 6, ntree = 250,
seeds = c(22,18), seeds2 = c(-2,-3),
alphas = -5:5, NBootstraps=0 )
## add Bootstraps
samp1 <- addSamples(obj=x0, seeds=c(99,12),
seeds2 = c(-45,-80), bBS=1,
NBootstraps=250)
## add more Bootstraps
samp2 <- addSamples(obj=x0, seeds=c(9,2),
seeds2 = c(-54,-8), bBS=251,
NBootstraps=250)
## Together
R <- salbmCombine(x0=x0, Samps=list(samp1,samp2))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.