ACI_AKP: Optimal Average Coverage Confidence Interval Using AKP...

Description Usage Arguments Value Examples

View source: R/CI_calc.R

Description

Calculates the estimated optimal average coverage CIs, and tuning parameters associated with those CIs, using ebci package.

Usage

1
ACI_AKP(x_vec, sig_vec, alpha, min_mu2)

Arguments

x_vec

a vector of observed values.

sig_vec

a vector of individual standard deviations.

alpha

a desired level of non-coverage.

min_mu2

the cut-off value.

Value

a list with four components; lam_opt gives the value of the optimal shrinkage factor, chi_opt gives the value of the normalized half-length associated with the optimal shrinkage factor, and CI_l and CI_u gives the vector of lower and upper ends of the confidence intervals, respectively.

Examples

1
2
3
4
th_vec <- rnorm(50) + 1
sig_vec <- rnorm(50)^2 + 1
x_vec <- rnorm(50, th_vec, sig_vec)
ACI_AKP(x_vec, sig_vec, 0.05, 0.04)

koohyun-kwon/OptACI documentation built on Oct. 6, 2020, 8:09 a.m.