Skip to contents

This function computes the (tail)-index as a function of k It returns the unbiased Hill estimator from de Haan et al. with tuning parameter rho = 2

Usage

alphaestimator(
  sample,
  k1 = floor(n^(0.7)),
  plot = FALSE,
  R0 = 100,
  hill = FALSE,
  ylim0 = NULL
)

Arguments

sample

(Vector of nonnegative univariate entries)

k1

(Integer indicating the number of high order statistics to consider for inference)

plot

(T or F indicate if the plot of Hill estimates as a function of k must be shown)

R0

(Integer with the number of bootstrap replicates to consider for computing confidence intervals)

hill

(T or F indicate if the classical Hill-plot is also plotted)

ylim0

(Vector with lower and upper bounds of the y-axis for the plot )

Value

A data.frame with the xi estimate and the confidence intervals lower and upper bounds.

Examples

sample   <- abs( arima.sim(n = 8000, list(ar=0.5, ma=0), rand.gen=function(n) rt(n,df=4) ) )
h <- alphaestimator(sample, plot=TRUE , R0 = 100,  hill=TRUE,   k1 = 1000 )

h <- alphaestimator(sample, plot=TRUE , R0 = 100,  hill=FALSE,  k1 = 1000 )
abline(h=0.25,col = "red")