lweibullgpd(x, wshape = 1, wscale = 1,
u = qweibull(0.9, wshape, wscale),
sigmau = sqrt(wscale^2 * gamma(1 + 2/wshape) - (wscale * gamma(1 + 1/wshape))^2),
xi = 0, phiu = TRUE, log = TRUE)
nlweibullgpd(pvector, x, phiu = TRUE, finitelik = FALSE)
wshape
, wscale
, u
,
sigmau
, xi
) or NULL
lweibullgpd
gives
(log-)likelihood and
nlweibullgpd
gives the
negative log-likelihood.fweibullgpd
.
Non-positive data are ignored.
They are designed to be used for MLE in
fweibullgpd
but are
available for wider usage, e.g. constructing your own
extreme value mixture models.
See fweibullgpd
and
fgpd
for full details.
Log-likelihood calculations are carried out in
lweibullgpd
, which takes
parameters as inputs in the same form as distribution
functions. The negative log-likelihood is a wrapper for
lweibullgpd
, designed
towards making it useable for optimisation (e.g.
parameters are given a vector as first input). The tail
fraction phiu
is treated separately to the other
parameters, to allow for all it's representations.
Unlike the distribution functions
weibullgpd
the
phiu
must be either logical (TRUE
or
FALSE
) or numerical in range $(0, 1)$. The
default is to specify phiu=TRUE
so that the tail
fraction is specified by Weibull distribution $\phi_u
= 1 - H(u)$, or phiu=FALSE
to treat the tail
fraction as an extra parameter estimated using the sample
proportion. Specify a numeric phiu
as
pre-specified probability $(0, 1)$. Notice that the
tail fraction probability cannot be 0 or 1 otherwise
there would be no contribution from either tail or bulk
components respectively.
The function lweibullgpd
carries out the calculations for the log-likelihood
directly, which can be exponentiated to give actual
likelihood using (log=FALSE
).lgpd
and
gpd
Other weibullgpd: dweibullgpd
,
fweibullgpd
, pweibullgpd
,
qweibullgpd
, rweibullgpd
,
weibullgpd