| GEV | R Documentation |
Provides density, distribution function, quantile function, random value generation, and raw moments of order r for the generalized extreme value distribution.
dgev(x, loc, scale, shape, log = FALSE)
pgev(q, loc, scale, shape, lower.tail = TRUE, log.p = FALSE)
qgev(p, loc, scale, shape, lower.tail = TRUE, log.p = FALSE)
rgev(n, loc, scale, shape)
mgev(r, loc, scale, shape)
x, q |
vector of quantiles. |
loc, scale, shape |
location, scale, and shape parameters. |
log, log.p |
logical; if |
lower.tail |
logical; if |
p |
vector of probabilities. |
n |
number of observations. If |
r |
raw moment order. |
dgev returns a numeric vector of density values.
pgev returns a numeric vector of cumulative probabilities.
qgev returns a numeric vector of quantiles.
rgev returns a numeric vector of random deviates.
mgev returns the raw moment of order r (via numerical
integration).
fitDist, moments
## plot the density
ggplot(data.frame(x = c(0, 20)),
aes(x)) +
stat_function(fun = dgev,
args = list(loc = 1,
scale = .5,
shape = .15),
colour = "royalblue4") +
labs(x = "",
y = "Density") +
theme_classic()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.