parTLgld {lmomco}R Documentation

Estimate the Parameters of the Generalized Lambda Distribution using Trimmed L-moments (t=1)

Description

This function estimates the parameters of the Generalized Lambda distribution given the trimmed L-moments (TL-moments) for t=1 of the data in a TL-moment object with a trim level of unity (trim=1). The relation between distribution parameters and TL-moments is seen under lmomTLgld. There are no simple expressions for the parameters in terms of the L-moments. This function is considered EXPERIMENTAL and general details of the algorithm are provided below. Further, consider that multiple parameter solutions are possible with the Generalized Lambda so some expertise in the distribution and other aspects are needed.

Usage

parTLgld(lmom,result='best',verbose=FALSE,extract=0,initkh=NULL)

Arguments

lmom A TL-moment object created by TLmoms.
result If best, then the minimum error solution is returned. If dataframe, then data.frame is returned with sequence of valid solutions sorted in ascending error order.
verbose A logical switch on the verbosity of output. Default is verbose=FALSE.
extract If result=dataframe and extract greater than zero, then the extract=n returns the nth element of the data.frame as if that element was the best solution.
initkh A vector of the initial guess of the kappa and h parameters. No other regions of parameter space are consulted.

Details

Karian and Dudewicz (2000) summarize six regions of the kappa and h space in which the Generalized Lambda distribution is valid for suitably choosen α. Numerical experimentation suggestions that the L-moments are not valid in Regions 1 and 2. However, initial guesses of the parameters within each region are used numerous six separate optim (the R function) efforts to perform a least sum-of-square errors on the following objective function.

(hat{tau}^{(1)}_3 - tilde{tau}^{(1)}_3)^2 + (hat{tau}^{(1)}_4 - tilde{tau}^{(1)}_4)^2 mbox{, }

where tilde{tau}^{(1)}_r is the L-moment ratio of the data, hat{tau}^{(1)}_r is the estimated value of the TL-moment ratio for the current pairing of kappa and h and tau^{(1)}_r is the actual value of the L-moment ratio.

For each optimization a check on the validity of the parameters so produced is made–are the parameters consistent with the Generalized Lambda distribution and a second check is made on the validity of tau^{(1)}_3 and tau^{(1)}_4. If both validity checks return TRUE then the optimization is retained if its sum-of-square error is less than the previous optimum value. It is possible for a given solution to be found outside the starting region of the initial guesses. The surface generated by the tau^{(1)}_3 and tau^{(1)}_4 equations seen in lmomTLgld is complex–different initial guesses within a given region can yield what appear to be radically different kappa and h. Users are encouraged to “play” with alternative solutions (see the verbose argument). A quick double check on the L-moments (not TL-moments) from the solved parameters using lmomTLgld is encouraged as well.

Value

An R list is returned if result='best'.

type The type of distribution: gld.
para The parameters of the distribution.
error Smallest sum of square error found.
tau5diff Difference between true hat{tau}^{(1)}_5 and the tilde{tau}^{(1)}_5 of the fitted distribution.
source The source of the parameters: “parTLgld”.
attempt The attempt number that found valid TL-moments and parameters of GLD.
x The location parameter of the distribution.
a The scale parameter of the distribution.
k The 1st shape parameter of the distribution.
h The 2nd shape parameter of the distribution.
tau5_diff The absolute difference between hat{tau}^{(1)}_5 of data to tilde{tau}^{(1)}_5 of the fitted distribution.
error The sum of square error found.
initial_k The starting point of the kappa parameter.
initial_h The starting point of the h parameter.

Note

Although the underlying derivations of the TL-moments in terms of the parameters are sound and this function uses built-in functions of R for the optimization, this function should be considered experimental until further notice. The “preferred” solution might not be appropriate. This function is not for production code. This is a cumbersome method of parameter solution and enhancements or total redesign of the algorithm is expected.

Author(s)

W.H. Asquith

Source

R hacking by W.H. Asquith in February 2006 with copy of Karian and Dudewicz (2000).

References

Karian, Z.A., and Dudewicz, E.J., 2000, Fitting statistical distributions—The generalized lambda distribution and generalized bootstrap methods: CRC Press, Boca Raton, FL, 438 p.

See Also

TLmoms, lmomTLgld, cdfgld, quagld, pargld

Examples

TL1 <- TLmoms(rnorm(200),trim=1)
p <- parTLgld(TL1)
TL2 <- lmomTLgld(p)

[Package lmomco version 0.96.3 Index]