Package 'TukeyGH77'

Title: Tukey g-&-h Distribution
Description: Density, cumulative density, quantile and simulation of the 4-parameter Tukey g-and-h (1977) distributions. The quantile-based transformation (Hoaglin 1985 <doi:10.1002/9781118150702.ch11>) and its reverse transformation.
Authors: Tingting Zhan [aut, cre] (ORCID: <https://orcid.org/0000-0001-9971-4844>)
Maintainer: Tingting Zhan <[email protected]>
License: GPL-2
Version: 0.2.0
Built: 2026-07-20 15:46:26 UTC
Source: https://github.com/tingtingzhan/tukeygh77

Help Index


TukeyGH77: Tukey g-&-h Distribution

Description

Density, cumulative density, quantile and simulation of the 4-parameter Tukey g-and-h (1977) distributions. The quantile-based transformation (Hoaglin 1985 doi:10.1002/9781118150702.ch11) and its reverse transformation.

Author(s)

Maintainer: Tingting Zhan [email protected] (ORCID)

Authors:

References

Tukey, J.W. (1977): Modern Techniques in Data Analysis. In: NSF-sponsored Regional Research Conference at Southeastern Massachusetts University, North Dartmouth, MA.

Hoaglin, D.C. (1985): Summarizing shape numerically: The gg-and-hh distributions. Exploring data tables, trends, and shapes, pp. 461–513. John Wiley & Sons, Ltd, New York.


Tukey gg-&-hh Distribution

Description

Density, distribution, quantile and simulation for Tukey gg-&-hh distribution with location parameter AA, scale parameter BB, skewness gg and elongation hh.

Usage

dGH(x, A = 0, B = 1, g = 0, h = 0, log = FALSE, ...)

rGH(n, A = 0, B = 1, g = 0, h = 0)

qGH(p, A = 0, B = 1, g = 0, h = 0, lower.tail = TRUE, log.p = FALSE)

pGH(q, A = 0, B = 1, g = 0, h = 0, lower.tail = TRUE, log.p = FALSE, ...)

Arguments

x

double vector, quantiles xx, missingness is allowed for function fitdistrplus::fitdist()

A

double scalar, location parameter AA, default A=0A=0,

B

double scalar, scale parameter B>0B>0, default B=1B=1

g

double scalar, skewness parameter gg, default g=0g=0 (i.e., no skewness)

h

double scalar, elongation parameter h0h\geq 0, default h=0h=0 (i.e., no elongation)

log, log.p

logical scalar, if TRUE, probabilities pp are given as log(p)\log(p).

...

additional parameters of function gh2z()

n

integer scalar, number of observations

p

double vector, probabilities pp, missingness is not allowed

lower.tail

logical scalar, if TRUE (default), probabilities are Pr(Xx)Pr(X\le x) otherwise, Pr(X>x)Pr(X>x).

q

double vector, quantiles qq, missingness is not allowed

Value

Density function dGH() returns double vector.

Distribution function pGH() returns double vector.

Quantile function qGH() returns double vector.

Random generator function rGH() returns double vector.

Examples

dGH(x, g = .3, h = .1) |> curve(from = -2.5, to = 3.5)
pGH(x, g = .3, h = .1) |> curve(from = -2.5, to = 3.5)
qGH(x, g = .3, h = .1) |> curve(from = 0, to = 1)