Pregibon Distribution
Density, distribution function, quantile function and random
generation for the Pregibon distribution with parameters
a
and b
. It is a special case of the generalized
Tukey lambda distribution.
dpregibon(x, a = 0, b = 0, log = FALSE, tol = 1e-12) ppregibon(q, a = 0, b = 0, lower.tail = TRUE, log.p = FALSE, tol = 1e-12) qpregibon(p, a = 0, b = 0, lower.tail = TRUE, log.p = FALSE) rpregibon(n, a = 0, b = 0)
x, q |
vector of quantiles. |
p |
vector of probabilities. |
n |
number of observations. If |
a, b |
distribution parameters. |
log, log.p |
logical; if TRUE, probabilities p are given as log(p). |
lower.tail |
logical; if TRUE (default), probabilities are P[X ≤ x], otherwise, P[X > x]. |
tol |
numeric tolerance for computation of the distribution function. |
The distribution is a special case of the generalized Tukey lambda distribution and is used by Pregibon (1980) for goodness-of-link testing. See Koenker (2006) and Koenker and Yoon (2009) for more details.
The implementation is based on the corresponding functions for the GeneralisedLambdaDistribution in the gld package (King 2013).
The corresponding link generator is available in the function pregibon
.
dpregibon
gives the probability density function,
ppregibon
gives the cumulative distribution function,
qpregibon
gives the quantile function, and
rpregibon
generates random deviates.
King R (2013). “Estimation and Use of the Generalised (Tukey) Lambda Distribution.” R package version 2.0.1. http://CRAN.R-project.org/package=gld
Koenker R (2006). “Parametric Links for Binary Response.” R News, 6(4), 32–34.
Koenker R, Yoon J (2009). “Parametric Links for Binary Choice Models: A Fisherian-Bayesian Colloquy.” Journal of Econometrics, 152, 120–130.
Pregibon D (1980). “Goodness of Link Tests for Generalized Linear Models.” Journal of the Royal Statistical Society C, 29, 15–23.
## Koenker & Yoon (2009), Figure 2 par(mfrow = c(3, 3)) pregiboncurve <- function(a, b, from, to, n = 301) { dp <- function(x) dpregibon(x, a = a, b = b) curve(dp, from = from, to = to, n = n, xlab = "", ylab = "", main = paste("a = ", a, ", b = ", b, sep = "")) } pregiboncurve(-0.25, -0.25, -5, 65) pregiboncurve(-0.25, 0, -18, 18) pregiboncurve(-0.25, 0.25, -65, 5) pregiboncurve( 0, -0.25, -4, 22) pregiboncurve( 0, 0, -8, 8) pregiboncurve( 0, 0.25, -22, 4) pregiboncurve( 0.25, -0.25, -2.4,9) pregiboncurve( 0.25, 0, -4, 4) pregiboncurve( 0.25, 0.25, -9, 2.4) par(mfrow = c(1, 1))
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.