Last chance! 50% off unlimited learning
Sale ends in
Maximum likelihood estimation of the 3-parameter generalized extreme value (GEV) distribution.
gev(llocation = "identitylink", lscale = "loglink",
lshape = logofflink(offset = 0.5), percentiles = c(95, 99),
ilocation = NULL, iscale = NULL, ishape = NULL, imethod = 1,
gprobs.y = (1:9)/10, gscale.mux = exp((-5:5)/6),
gshape = (-5:5) / 11 + 0.01,
iprobs.y = NULL, tolshape0 = 0.001,
type.fitted = c("percentiles", "mean"),
zero = c("scale", "shape"))
gevff(llocation = "identitylink", lscale = "loglink",
lshape = logofflink(offset = 0.5), percentiles = c(95, 99),
ilocation = NULL, iscale = NULL, ishape = NULL, imethod = 1,
gprobs.y = (1:9)/10, gscale.mux = exp((-5:5)/6),
gshape = (-5:5) / 11 + 0.01,
iprobs.y = NULL, tolshape0 = 0.001,
type.fitted = c("percentiles", "mean"), zero = c("scale", "shape"))
Parameter link functions for Links
for more choices.
For the shape parameter,
the default logofflink
link has an offset
called
Numeric vector of percentiles used for the fitted values.
Values should be between 0 and 100.
This argument is ignored if type.fitted = "mean"
.
See CommonVGAMffArguments
for information.
The default is to use the percentiles
argument.
If "mean"
is chosen, then the mean
Numeric. Initial value for the location parameter, NULL
means a value is computed internally.
The argument ishape
is more important than the other two.
If a failure to converge occurs, or even to obtain initial values occurs,
try assigning ishape
some value
(positive or negative; the sign can be very important).
Also, in general, a larger value of iscale
tends to be better than a
smaller value.
Initialization method. Either the value 1 or 2.
If both methods fail then try using ishape
.
See CommonVGAMffArguments
for information.
Numeric vector.
The values are used for a grid search for an initial value
for CommonVGAMffArguments
for information.
Numeric vectors, used for the initial values.
See CommonVGAMffArguments
for information.
Passed into dgev
when computing the log-likelihood.
A specifying which
linear/additive predictors are modelled as intercepts only.
The values can be from the set {1,2,3} corresponding
respectively to zero = NULL
then all linear/additive predictors are modelled as
a linear combination of the explanatory variables.
For many data sets having zero = 3
is a good idea.
See CommonVGAMffArguments
for information.
An object of class "vglmff"
(see vglmff-class
).
The object is used by modelling functions such as vglm
,
and vgam
.
Currently, if an estimate of gev()
with multivariate responses.
In general, gevff()
is more reliable than gev()
.
Fitting the GEV by maximum likelihood estimation can be numerically
fraught. If vgam
with s
is used; then smoothing is best done with
vglm
with regression splines (bs
or ns
) because vglm
implements
half-stepsizing whereas vgam
doesn't (half-stepsizing
helps handle the problem of straying outside the parameter space.)
The GEV distribution function can be written
For the GEV distribution, the
Smith (1985) established that when lshape = logofflink(offset = 0.5)
, say,
or lshape = extlogitlink(min = -0.5, max = 0.5)
, say.
Yee, T. W. and Stephenson, A. G. (2007). Vector generalized linear and additive extreme value models. Extremes, 10, 1--19.
Tawn, J. A. (1988). An extreme-value theory model for dependent observations. Journal of Hydrology, 101, 227--250.
Prescott, P. and Walden, A. T. (1980). Maximum likelihood estimation of the parameters of the generalized extreme-value distribution. Biometrika, 67, 723--724.
Smith, R. L. (1985). Maximum likelihood estimation in a class of nonregular cases. Biometrika, 72, 67--90.
rgev
,
gumbel
,
gumbelff
,
guplot
,
rlplot.gevff
,
gpd
,
weibullR
,
frechet
,
extlogitlink
,
oxtemp
,
venice
,
CommonVGAMffArguments
.
# NOT RUN {
# Multivariate example
fit1 <- vgam(cbind(r1, r2) ~ s(year, df = 3), gev(zero = 2:3),
data = venice, trace = TRUE)
coef(fit1, matrix = TRUE)
head(fitted(fit1))
par(mfrow = c(1, 2), las = 1)
plot(fit1, se = TRUE, lcol = "blue", scol = "forestgreen",
main = "Fitted mu(year) function (centered)", cex.main = 0.8)
with(venice, matplot(year, depvar(fit1)[, 1:2], ylab = "Sea level (cm)",
col = 1:2, main = "Highest 2 annual sea levels", cex.main = 0.8))
with(venice, lines(year, fitted(fit1)[,1], lty = "dashed", col = "blue"))
legend("topleft", lty = "dashed", col = "blue", "Fitted 95 percentile")
# Univariate example
(fit <- vglm(maxtemp ~ 1, gevff, data = oxtemp, trace = TRUE))
head(fitted(fit))
coef(fit, matrix = TRUE)
Coef(fit)
vcov(fit)
vcov(fit, untransform = TRUE)
sqrt(diag(vcov(fit))) # Approximate standard errors
rlplot(fit)
# }
Run the code above in your browser using DataLab