MLE Fitting of Weibull Bulk and GPD Tail Interval Transition Mixture Model
MLE Fitting of Weibull Bulk and GPD Tail Interval Transition Mixture Model
Maximum likelihood estimation for fitting the extreme valeu mixture model with the Weibull bulk and GPD tail interval transition mixture model. With options for profile likelihood estimation for threshold and interval half-width, which can both be fixed.
eseq: vector of epsilons (or scalar) to be considered in profile likelihood or NULL for no profile likelihood
useq: vector of thresholds (or scalar) to be considered in profile likelihood or NULL for no profile likelihood
fixedeu: logical, should threshold and epsilon be fixed (at either scalar value in useq and eseq, or estimated from maximum of profile likelihood evaluated at grid of thresholds and epsilons in useq and eseq)
pvector: vector of initial values of parameters or NULL for default values, see below
std.err: logical, should standard errors be calculated
method: optimisation method (see optim)
control: optimisation control list (see optim)
finitelik: logical, should log-likelihood return finite value for invalid parameters
...: optional inputs passed to optim
wshape: scalar Weibull shape (positive)
wscale: scalar Weibull scale (positive)
epsilon: interval half-width
u: scalar threshold value
sigmau: scalar scale parameter (positive)
xi: scalar shape parameter
log: logical, if TRUE then log-likelihood rather than likelihood is output
eu: vector of epsilon and threshold pair considered in profile likelihood
Returns
Log-likelihood is given by litmweibullgpd and it's wrappers for negative log-likelihood from nlitmweibullgpd
and nluitmweibullgpd. Profile likelihood for threshold and interval half-width given by profluitmweibullgpd. Fitting function fitmweibullgpd returns a simple list with the following elements
call :
optim call
x :
data vector x
init :
pvector
fixedeu :
fixed epsilon and threshold, logical
useq :
threshold vector for profile likelihood or scalar for fixed threshold
eseq :
epsilon vector for profile likelihood or scalar for fixed epsilon
nllheuseq :
profile negative log-likelihood at each combination in (eseq, useq)
optim :
complete optim output
mle :
vector of MLE of parameters
cov :
variance-covariance matrix of MLE of parameters
se :
vector of standard errors of MLE of parameters
nllh :
minimum negative log-likelihood
n :
total sample size
wshape :
MLE of Weibull shape
wscale :
MLE of Weibull scale
epsilon :
MLE of transition half-width
u :
threshold (fixed or MLE)
sigmau :
MLE of GPD scale
xi :
MLE of GPD shape
Details
The extreme value mixture model with the Weibull bulk and GPD tail with interval transition is fitted to the entire dataset using maximum likelihood estimation. The estimated parameters, variance-covariance matrix and their standard errors are automatically output.
See ditmweibullgpd for explanation of Weibull-GPD interval transition model, including mixing functions.
See also help for fnormgpd for mixture model fitting details. Only the different features are outlined below for brevity.
The full parameter vector is (wshape, wscale, epsilon, u, sigmau, xi) if threshold and interval half-width are both estimated and (wshape, wscale, sigmau, xi) for profile likelihood or fixed threshold and epsilon approach.
If the profile likelihood approach is used, then it is applied to both the threshold and epsilon parameters together. A grid search over all combinations of epsilons and thresholds are considered. The combinations which lead to less than 5 on either side of the interval are not considered.
A fixed threshold and epsilon approach is acheived by setting a single scalar value to each in useq and eseq respectively.
If the profile likelihood approach is used, then a grid search over all combinations of epsilon and threshold are carried out. The combinations which lead to less than 5 in any any interval are not considered.
Negative data are ignored.
Note
When pvector=NULL then the initial values are:
MLE of Weibull parameters assuming entire population is Weibull; and
epsilon is MLE of Weibull standard deviation;
threshold 90% quantile (not relevant for profile likelihood for threshold or fixed threshold approaches);
MLE of GPD parameters above threshold.
Acknowledgments
See Acknowledgments in fnormgpd, type help fnormgpd.
Examples
## Not run:set.seed(1)par(mfrow = c(1,1))x = rweibull(1000, shape =1, scale =2)xx = seq(-0.2,10,0.01)y = dweibull(xx, shape =1, scale =2)# MLE for complete parameter setfit = fitmweibullgpd(x)hist(x, breaks = seq(0,20,0.1), freq =FALSE, xlim = c(-0.2,10))lines(xx, y)with(fit, lines(xx, ditmweibullgpd(xx, wshape, wscale, epsilon, u, sigmau, xi), col="red"))abline(v = fit$u + fit$epsilon * seq(-1,1), col ="red")# Profile likelihood for threshold which is then fixedfitfix = fitmweibullgpd(x, eseq = seq(0,2,0.1), useq = seq(0.5,4,0.1), fixedeu =TRUE)with(fitfix, lines(xx, ditmweibullgpd(xx, wshape, wscale, epsilon, u, sigmau, xi), col="blue"))abline(v = fitfix$u + fitfix$epsilon * seq(-1,1), col ="blue")legend("topright", c("True Density","Weibull-GPD ITM","Profile likelihood"), col=c("black","red","blue"), lty =1)## End(Not run)