The GPD distribution function with parameters \(\code{location} = a\), \(\code{scale} = b\) and \(\code{shape} = s\) is
dist_gpd(location, scale, shape)
$$F(x) = 1 - \left(1+s(x-a)/b\right)^{-1/s}$$
for \(1+s(x-a)/b > 0\), where \(b > 0\). If \(s = 0\) the distribution is defined by continuity, giving
$$F(x) = 1 - \exp\left(-\frac{x-a}{b}\right)$$
The support of the distribution is \(x \geq a\) if \(s \geq 0\), and \(a \leq x \leq a -b/s\) if \(s < 0\).
The Pickands–Balkema–De Haan theorem states that for a large class of distributions, the tail (above some threshold) can be approximated by a GPD.
gpd
dist <- dist_gpd(location = 0, scale = 1, shape = 0)