Function for heuristically choosing the domain where extreme value theory can be applied
choosethres(data, thresh, guess = c(1, 0.1), plots = 1:3, R = 200, ncpus = 1)
a numeric vector containing the observation used for verification
vector of thresholds to try
starting values for GPD's sigma and xi (0<xi<1)
which parameter plots do you want
number of bootstrap estimates for confidence intervals
if you want to make bootstrap on several cores
three plots summarizing the stability of the parameters to threshold. The starting threshold admits kappa=1 and its confidence interval ; according Papastathopoulos & Tawn (2013)
a list with thresholds used, GP parameters and CIs, optimal threshold and xi.