LPfit {LNPar} | R Documentation |
Estimating a lognormal-Pareto mixture by maximizing the profile log-likelihood
Description
This function fits a lognormal-Pareto mixture by maximizing the profile log-likelihood.
Usage
LPfit(y, minRank, nboot)
Arguments
y |
numerical vector: random sample from the mixture. |
minRank |
integer: minimum possible rank of the threshold. |
nboot |
number of bootstrap replications used for estimating the standard errors. If omitted, no standard errors are computed. |
Details
Estimation is implemented as in Bee (2022). As of standard errors, at each bootstrap replication the mixture is estimated with thresholds equal to ys(minRank), ys(minRank+1),..., ys(n), where n is the sample size and ys is the sample sorted in ascending order. The latter procedure is implemented via parallel computing. If the algorithm does not converge in 1000 iterations, a message is displayed.
Value
A list with the following elements:
xmin: estimated threshold.
prior: estimated mixing weight.
postProb: matrix of posterior probabilities.
alpha: estimated Pareto shape parameter.
mu: estimated expectation of the lognormal distribution on the lognormal scale.
sigma: estimated standard deviation of the lognormal distribution on the lognormal scale.
loglik: maximized log-likelihood.
nit: number of iterations.
npareto: estimated number of Pareto observations.
bootstd: bootstrap standard errors of the estimators.
References
Bee M (2022). “On discriminating between lognormal and Pareto tail: an unsupervised mixture-based approach.” Advances in Data Analysis and Classification. doi:10.1007/s11634-022-00497-4.
Examples
mixFit <- LPfit(TN2016,90,0)