The Gumbel Distribution
Density, distribution function, quantile function, random generation, and gradient of density of the extreme value (maximum and minimum) distributions. The Gumbel distribution is also known as the extreme value maximum distribution, the double-exponential distribution and the log-Weibull distribution.
dgumbel(x, location = 0, scale = 1, log = FALSE, max = TRUE) pgumbel(q, location = 0, scale = 1, lower.tail = TRUE, max = TRUE) qgumbel(p, location = 0, scale = 1, lower.tail = TRUE, max = TRUE) rgumbel(n, location = 0, scale = 1, max = TRUE) ggumbel(x, max = TRUE)
x,q |
numeric vector of quantiles. |
p |
vector of probabilities. |
n |
number of observations. |
location |
numeric scalar. |
scale |
numeric scalar. |
lower.tail |
logical; if |
log |
logical; if |
max |
distribution for extreme maxima (default) or minima? The default corresponds to the standard right-skew Gumbel distribution. |
dgumbel, pgumbel and ggumbel are implemented in C
for speed and care is taken that 'correct' results are provided for
values of NA, NaN, Inf, -Inf or just
extremely small or large.
pgumbel gives the distribution function, dgumbel
gives the density, ggumbel gives the gradient of the
density, qgumbel is the quantile function, and
rgumbel generates random deviates.
Rune Haubo B Christensen
## Illustrating the symmetry of the distribution functions: pgumbel(5) == 1 - pgumbel(-5, max=FALSE) ## TRUE dgumbel(5) == dgumbel(-5, max=FALSE) ## TRUE ggumbel(5) == -ggumbel(-5, max=FALSE) ## TRUE ## More examples: x <- -5:5 (pp <- pgumbel(x)) qgumbel(pp) dgumbel(x) ggumbel(x) (ppp <- pgumbel(x, max=FALSE)) ## Observe that probabilities close to 0 are more accurately determined than ## probabilities close to 1: qgumbel(ppp, max=FALSE) dgumbel(x, max=FALSE) ggumbel(x, max=FALSE) ## random deviates: set.seed(1) (r1 <- rgumbel(10)) set.seed(1) r2 <- -rgumbel(10, max = FALSE) all(r1 == r2) ## TRUE
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.