ReIns (version 1.0.10)

trTestMLE: Test for truncated GPD tails

Description

Test between non-truncated GPD tails (light truncation) and truncated GPD tails (rough truncation).

Usage

trTestMLE(data, gamma, tau, alpha = 0.05, plot = TRUE, main = "Test for truncation", ...)

Value

A list with following components:

k

Vector of the values of the tail parameter \(k\).

testVal

Corresponding test values.

critVal

Critical value used for the test, i.e. \(\ln(1/\alpha)\).

Pval

Corresponding P-values.

Reject

Logical vector indicating if the null hypothesis is rejected for a certain value of k.

Arguments

data

Vector of \(n\) observations.

gamma

Vector of \(n-1\) estimates for the EVI obtained from trMLE.

tau

Vector of \(n-1\) estimates for the \(\tau\) obtained from trMLE.

alpha

The used significance level, default is 0.05.

plot

Logical indicating if the P-values should be plotted as a function of \(k\), default is FALSE.

main

Title for the plot, default is "Test for truncation".

...

Additional arguments for the plot function, see plot for more details.

Author

Tom Reynkens.

Details

We want to test \(H_0: X\) has non-truncated GPD tails vs. \(H_1: X\) has truncated GPD tails. Let \(\hat{\gamma}_k\) and \(\hat{\tau}_k\) be the truncated MLE estimates for \(\gamma\) and \(\tau\). The test statistic is then $$T_{k,n}=k (1+\hat{\tau} (X_{n,n}-X_{-k,n}) )^{-1/\hat{\xi}_k}$$ which is asymptotically standard exponentially distributed. We reject \(H_0\) on level \(\alpha\) if \(T_{k,n}>\ln (1/{\alpha)}\). The corresponding P-value is given by \(\exp(-T_{k,n})\).

See Beirlant et al. (2017) for more details.

References

Beirlant, J., Fraga Alves, M. I. and Reynkens, T. (2017). "Fitting Tails Affected by Truncation". Electronic Journal of Statistics, 11(1), 2026--2065.

See Also

trMLE, trDTMLE, trProbMLE, trEndpointMLE, trTestMLE, trTest

Examples

Run this code
# Sample from GPD truncated at 99% quantile
gamma <- 0.5
sigma <- 1.5
X <- rtgpd(n=250, gamma=gamma, sigma=sigma, endpoint=qgpd(0.99, gamma=gamma, sigma=sigma))

# Truncated ML estimator
trmle <- trMLE(X, plot=TRUE, ylim=c(0,2))

# Test for truncation
trTestMLE(X, gamma=trmle$gamma, tau=trmle$tau)

Run the code above in your browser using DataCamp Workspace