ggpd {extrememix} | R Documentation |
The GGPD distribution
Description
Density, distribution function, quantile function and random generation for the GGPD distribution.
Usage
dggpd(x, xi, sigma, u, mu, eta, log = FALSE)
pggpd(q, xi, sigma, u, mu, eta, lower.tail = TRUE)
qggpd(p, xi, sigma, u, mu, eta, lower.tail = TRUE)
rggpd(N, xi, sigma, u, mu, eta)
Arguments
x , q |
vector of quantiles. |
xi |
shape parameter of the tail GPD (scalar). |
sigma |
scale parameter of the tail GPD (scalar). |
u |
threshold parameter of the tail GPD (scalar). |
mu |
mean of the gamma bulk (scalar). |
eta |
shape of the gamma bulk (scalar). |
log |
logical; if TRUE, probabilities p are given as log(p). |
lower.tail |
logical; if TRUE (default), probabilities are |
p |
vector of probabilities. |
N |
number of observations. |
Value
The GGPD distribution is an extreme value mixture model with density
f_{GGPD}(x|\xi,\sigma,u,\mu,\eta,w)=\left\{\begin{array}{ll} f_{GA}(x|\mu,\eta), & x\leq u \\ (1-F_{GA}(u|\mu,\eta))f_{GPD}(x|\xi,\sigma,u), &\mbox{otherwise}, \end{array}\right.
where f_{GA}
is the density of the Gamma parametrized by mean \mu
and shape \eta
, F_{GA}
is the distribution function of the Gamma and f_{GPD}
is the density of the Generalized Pareto Distribution, i.e.
f_{GPD}(x|\xi,\sigma,u)=\left\{\begin{array}{ll} 1- (1+\frac{\xi}{\sigma}(x-u))^{-1/\xi}, & \mbox{if } \xi\neq 0,\\ 1- \exp\left(-\frac{x-u}{\sigma}\right), & \mbox{if } \xi = 0, \end{array}\right.
where \xi
is a shape parameter, \sigma > 0
is a scale parameter and u>0
is a threshold.
dggpd
gives the density, pggpd
gives the distribution function, qggpd
gives the quantile function, and rggpd
generates random deviates. The length of the result is determined by N
for rggpd
and by the length of x
, q
or p
otherwise.
References
Behrens, Cibele N., Hedibert F. Lopes, and Dani Gamerman. "Bayesian analysis of extreme events with threshold estimation." Statistical Modelling 4.3 (2004): 227-244.
Examples
dggpd(3, xi = 0.5, sigma = 2, u = 5, mu = 3, eta = 3)