lmomlap: L-moments of the Laplace Distribution

lmomlapR Documentation

L-moments of the Laplace Distribution

Description

This function estimates the L-moments of the Laplace distribution given the parameters (\xi and \alpha) from parlap. The L-moments in terms of the parameters are \lambda_1 = \xi, \lambda_2 = 3\alpha/4, \tau_3 = 0, \tau_4 = 17/72, \tau_5 = 0, and \tau_6 = 31/360.

For r odd and r \ge 3, \lambda_r = 0, and for r even and r \ge 2, the L-moments using the hypergeometric function {}_2F_1() (refer to the hypergeo package) are

\lambda_r = \frac{2\alpha}{r(r-1)}\bigl[1 - {}_2F_1(-r, r-1, 1, 1/2)\bigr]\mbox{,}

where {}_2F_1(a, b, c, z) is defined as

{}_2F_1(a, b, c, z) = \sum_{n=0}^\infty \frac{(a)_n(b)_n}{(c)_n}\frac{z^n}{n!}\mbox{,}

where (x)_n is the rising factorial (rising Pochhammer symbol), which is defined by

(x)_n = 1 \mbox{\ for\ } n = 0\mbox{, and}

(x)_n = x(x+1)\cdots(x+n-1) \mbox{\ for\ } n > 0\mbox{.}

Usage

lmomlap(para)

Arguments

para

The parameters of the distribution.

Details

Hosking (1986) presents the \lambda_2, \tau_4, and \tau_6 as integer ratios relative to whatever the \alpha parameter is. We can cross check those readily with the hypergeo and numbers packages:

  L2  <- (1-hypergeo::hypergeo(-2, 2-1, 1, 1/2)) * (2/(2*(2-1))) # 0.75+0i = 3/4
  r   <- c(4, 6)
  L46 <- (1-hypergeo::hypergeo(-r, r-1, 1, 1/2)) * (2/(r*(r-1)))
  print(L46 / L2, digits=16) # Tau4 and Tau6
  # 0.2361111111111111+0i 0.0861111111111111+0i
  Tau <- as.numeric( L46 / L2 )
  numbers::contfrac(Tau[1], tol=.0001 ) # no better than 17 /  72
  numbers::contfrac(Tau[2], tol=.00001) # no better than 31 / 360
  # These results are consistent with Hosking (1986) and no better accuracy is
  # possible on "modern" computers because the 0***11111...... and check by
  # continued fraction providing also the integer ratio to a tolerance.

Value

An R list is returned.

lambdas

Vector of the L-moments. First element is \lambda_1, second element is \lambda_2, and so on.

ratios

Vector of the L-moment ratios. Second element is \tau, third element is \tau_3 and so on.

trim

Level of symmetrical trimming used in the computation, which is 0.

leftrim

Level of left-tail trimming used in the computation, which is NULL.

rightrim

Level of right-tail trimming used in the computation, which is NULL.

source

An attribute identifying the computational source of the L-moments: “lmomlap”.

Author(s)

W.H. Asquith

References

Hosking, J.R.M., 1986, The theory of probability weighted moments: IBM Research Report RC12210, T.J. Watson Research Center, Yorktown Heights, New York.

See Also

parlap, cdflap, pdflap, qualap

Examples

lmr <- lmoms(c(123,34,4,654,37,78)); para <- parlap(lmr, minvar=FALSE)
print( str(          lmr  )  )
print( str( lmomlap( para ) ))

## Not run: 
  para <- vec2par(c(0, 4), type="lap")
  q <- rlmomco(3000, para); lmr <- lmoms(q)
  parlap(lmr, minvar=TRUE )$para
  parlap(lmr, minvar=FALSE)$para # 
## End(Not run)

lmomco documentation built on Oct. 18, 2026, 5:07 p.m.