marggpd {ReturnCurves} | R Documentation |
Assessing the Marginal Tail Fits
Description
Assessment of the marginal tail fits for each margin following the marginal transformation procedure margtransf
.
Usage
marggpd(margdata, blocksize = 1, nboot = 250, alpha = 0.05)
Arguments
margdata |
An S4 object of class |
blocksize |
Size of the blocks for the block bootstrap procedure. If |
nboot |
Number of bootstrap samples to be taken. Default is |
alpha |
Significance level to compute the \((1-\alpha)\)% tolerance intervals. Default is |
Details
Let \(X^{GPD}_{(i)}\) denote the \(i\)-th ordered increasing statistic
\((i = 1, \ldots, n)\) of the exceedances, i.e., \(X^{GPD}= (X-u \mid X >u),\)
\(n_{exc}\) denote the sample size of these exceedances, and \(F_{GPD}^{-1}\) denote the
inverse of the cumulative distribution function of a generalised Pareto distribution (GPD).
Function plot
shows QQ plots between the model and empirical GPD quantiles for both variables, i.e, for
the first variable points \(\left(F^{-1}_{GPD}\left(\frac{i}{n_{exc}+1}\right) + u, X^{GPD}_{(i)} + u\right)\),
along with the line \(y=x\).
Uncertainty on the empirical quantiles is obtained via a (block) bootstrap procedure and shown by the grey region on the plot. A good fit is shown by agreement of model and empirical quantiles, i.e. points should lie close to the line \(y=x\). In addition, line \(y = x\) should mainly lie within the \((1-\alpha)\)% tolerance intervals.
Value
An object of S4 class marggpd.class
. This object returns the arguments of the function and an extra slot marggpd
which is a list containing:
model |
A list containing the model quantiles for each variable. |
empirical |
A list containing the empirical quantiles for each variable. |
lower |
A list containing the lower bounds of the tolerance intervals for each variable. |
upper |
A list containing the upper bounds of the tolerance intervals for each variable. |
Examples
library(ReturnCurves)
data(airdata)
n <- dim(airdata)[1]
margdata <- margtransf(airdata)
# blocksize to account for temporal dependence
marggpd <- marggpd(margdata = margdata, blocksize = 10)
plot(marggpd)
# To see the the S4 object's slots
str(marggpd)
# To access the list of lists
marggpd@marggpd