gpdImPb: GPD Bootstrapped Information Matrix (IM) Test

Description Usage Arguments Details Value References Examples

View source: R/gpdImPb.R

Description

Runs the IM Test using a two-step iterative procedure, to boostrap the covariance estimate and critical values. See reference for details.

Usage

1
gpdImPb(data, inner, outer, allowParallel = FALSE, numCores = 1)

Arguments

data

Data should be in vector form.

inner

Number of bootstrap replicates for the covariance estimate.

outer

Number of bootstrap replicates for critical values.

allowParallel

Should the outer bootstrap procedure be run in parallel or not. Defaults to false.

numCores

If allowParallel is true, specify the number of cores to use.

Details

Warning: This test can be very slow, since the covariance estimation is nested within the outer replicates. It would be recommended to use a small number of replicates for the covariance estimate (at most 50).

Value

statistic

Test statistic.

p.value

P-value for the test.

theta

Estimate of theta for the initial dataset.

effective_bootnum

Effective number of outer bootstrap replicates used (only those that converged are used).

References

Dhaene, G., & Hoorelbeke, D. (2004). The information matrix test with bootstrap-based covariance matrix estimation. Economics Letters, 82(3), 341-347.

Examples

1
2
x <- rgpd(200, loc = 0, scale = 1, shape = 0.2)
gpdImPb(x, inner = 20, outer = 99)

eva documentation built on Jan. 13, 2021, 8:34 p.m.