Learn R Programming

lmomco (version 2.0.1)

are.par.valid: Are the Distribution Parameters Consistent with the Distribution

Description

This function is a dispatcher on top of the are.parCCC.valid functions, where CCC represents the distribution type: aep4, cau, exp, gam, gev, glo, gno, gov, gpa, gum, kap, kur, lap, ln3, nor, pe3, ray, revgum, rice, sla, st3, wak, or wei. Internally, this function is called only by vec2par in the process of converting a vector into a proper distribution parameter object for this package.

Usage

are.par.valid(para,...)

Arguments

para
A distribution parameter object having at least attributes type and para.
...
Additional arguments for the are.parCCC.valid call that is made internally.

Value

  • TRUEIf the parameters are consistent with the distribution specified by the type attribute of the parameter object.
  • FALSEIf the parameters are not consistent with the distribution specified by the type attribute of the parameter object.

References

Asquith, W.H., 2011, Distributional analysis with L-moment statistics using the R environment for statistical computing: CreateSpace Independent Publishing Platform, 2nd printing, ISBN 978-1463508418.

See Also

vec2par

Examples

Run this code
vec  <- c(12,120)           # parameters of exponential distribution
para <- vec2par(vec,'exp')  # build exponential distribution parameter
                            # object
# The following two conditionals are equivalent as are.parexp.valid()
# is called within are.par.valid().
if(are.par.valid(para))    Q <- quaexp(0.5,para)
if(are.parexp.valid(para)) Q <- quaexp(0.5,para)

Run the code above in your browser using DataLab