ci_eval: Confidence Interval Evaluation

Description Usage Arguments Value Author(s) See Also Examples

View source: R/eval.R

Description

Evaluates confidence interval using zero_hit(), theta_hit(), len(), and shape().

Usage

1
ci_eval(ci, thetahat, theta = 0, label = NULL)

Arguments

ci

Vector. Confidence intervals sorted from smallest to largest. The length should be even. The first and the last element correspond to the widest confidence interval. The second and the second to the last element correspond to the second widest confidence interval. And so on and so forth.

thetahat

Numeric. Parameter estimate ≤ft( \hat{ θ } \right) .

theta

Numeric. Population parameter ≤ft( θ \right) .

label

Vector. Vector used to label results. If not provided defaults to label = 1:(length(ci)/2).

Value

Returns a vector with the following elements:

zero_hit_

Logical. Tests if confidence interval contains zero.

theta_hit_

Logical. Tests if confidence interval contains theta.

length_

Length of confidence interval.

shape_

Shape of confidence interval.

Author(s)

Ivan Jacob Agaloos Pesigan

See Also

Other confidence interval evaluation functions: len(), shape()

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
ci <- c(
  98.04786,
  98.38773,
  98.68060,
  100.5447,
  100.8375,
  101.1774
)
thetahat <- 99.6126336
theta <- 100
label <- c(
  0.001,
  0.01,
  0.05
)
ci_eval(
  ci = ci,
  thetahat = thetahat,
  theta = theta,
  label = label
)

jeksterslabds/jeksterslabRboot documentation built on July 20, 2020, 12:56 p.m.