jack_hat: Jackknife Estimates

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/jack.R

Description

Calculates jackknife estimates.

Usage

1
2
3
4
5
6
7
jack_hat(
  thetahatstarjack,
  thetahat,
  alpha = c(0.001, 0.01, 0.05),
  eval = FALSE,
  theta = 0
)

Arguments

thetahatstarjack

Numeric vector. Jackknife sampling distribution, that is, the sampling distribution of thetahat estimated for each i jackknife sample. \hat{ θ }_{ ≤ft( 1 \right) }, \hat{ θ }_{ ≤ft( 2 \right) }, \hat{ θ }_{ ≤ft( 3 \right) }, …, \hat{ θ }_{ ≤ft( n \right) } .

thetahat

Numeric. Parameter estimate ≤ft( \hat{ θ } \right) from the original sample data.

alpha

Numeric vector. Significance level ≤ft( α \right) . By default, alpha is set to conventional significance levels alpha = c(0.001, 0.01, 0.05).

eval

Logical. Evaluate confidence intervals using zero_hit(), theta_hit(), len(), and shape().

theta

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

Details

The jackknife estimate of bias is given by

\widehat{ \mathrm{ bias } }_{ \mathrm{ jack } } ≤ft( θ \right) = ≤ft( n - 1 \right) ≤ft( \hat{ θ }_{ ≤ft( \cdot \right) } - \hat{ θ } \right)

where

\hat{ θ }_{ ≤ft( \cdot \right) } = \frac{ 1 } { n } ∑_{ i = 1 }^{ n } \hat{ θ }_{ ≤ft( i \right) } .

The jackknife estimate of standard error is given by

\widehat{ \mathrm{ se } }_{ \mathrm{ jack } } ≤ft( \hat{ θ } \right) = √{ \frac{ n - 1 } { n } ∑_{ i = 1 }^{ n } ≤ft( \hat{ θ }_{ ≤ft( i \right) } - \hat{ θ }_{ ≤ft( \cdot \right) } \right)^2 } .

The bias-corrected jackknife estimate is given by

\hat{ θ }_{ \mathrm{ jack } } = \hat{ θ } - \hat{ \mathrm{ bias } }_{ \mathrm{ jack } } ≤ft( θ \right) = n \hat{ θ } - ≤ft( n - 1 \right) \hat{ θ }_{ ≤ft( \cdot \right) } .

Pseudo-values can be computed using

\tilde{ θ }_{ i } = n \hat{ θ } - ≤ft( n - 1 \right) \hat{ θ }_{ ≤ft( i \right) } .

The standard error can be estimated using the pseudo-values

\widehat{ \mathrm{ se } }_{ \mathrm{ jack } } ≤ft( \tilde{ θ } \right) = √{ ∑_{ i = 1 }^{ n } \frac{ ≤ft( \tilde{ θ }_{ i } - \tilde{ θ } \right)^2 } { ≤ft( n - 1 \right) n } }

where

\tilde{ θ } = \frac{ 1 } { n } ∑_{ i = 1 }^{ n } \tilde{ θ }_{ i } .

An interval can be generated using

\tilde{ θ } \pm t_{ \frac{ α } { 2 } } \times \widehat{ \mathrm{ se } }_{ \mathrm{ jack } } ≤ft( \tilde{ θ } \right)

with degrees of freedom ν = n - 1 .

Value

Returns a list with the following elements:

hat

Jackknife estimates.

ps

Pseudo-values.

ci

Confidence intervals using pseudo-values.

The first list element hat contains the following:

mean

Mean of thetahatstarjack ≤ft( \hat{θ}_{≤ft( \cdot \right) } \right).

bias

Jackknife estimate of bias ≤ft( \widehat{\mathrm{bias}}_{\mathrm{jack}} ≤ft( θ \right) \right).

se

Jackknife estimate of standard error ≤ft( \widehat{\mathrm{se}}_{\mathrm{jack}} ≤ft( \hat{θ} \right) \right).

thetahatjack

Bias-corrected jackknife estimate ≤ft( \hat{θ}_{\mathrm{jack}} \right).

Author(s)

Ivan Jacob Agaloos Pesigan

References

Wikipedia: Jackknife resampling

See Also

Other jackknife functions: jack()

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
26
27
28
29
30
31
n <- 100
x <- rnorm(n = n)
thetahat <- mean(x)
xstar <- jack(
  data = x
)
thetahatstarjack <- sapply(
  X = xstar,
  FUN = mean
)
str(xstar, list.len = 6)
hist(
  thetahatstarjack,
  main = expression(
    paste(
      "Histogram of ",
      hat(theta),
      "*"
    )
  ),
  xlab = expression(
    paste(
      hat(theta),
      "*"
    )
  )
)
jack_hat(
  thetahatstarjack = thetahatstarjack,
  thetahat = thetahat
)

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