EXTILindley: Extended Inverse Lindley Distribution

Description Usage Arguments Details Value Author(s) Source References See Also Examples

Description

Density function, distribution function, quantile function, random number generation and hazard rate function for the extended inverse Lindley distribution with parameters theta, alpha and beta.

Usage

1
2
3
4
5
6
7
8
9
dextilindley(x, theta, alpha, beta, log = FALSE)

pextilindley(q, theta, alpha, beta, lower.tail = TRUE, log.p = FALSE)

qextilindley(p, theta, alpha, beta, lower.tail = TRUE, log.p = FALSE)

rextilindley(n, theta, alpha, beta, mixture = TRUE)

hextilindley(x, theta, alpha, beta, log = TRUE)

Arguments

x, q

vector of positive quantiles.

theta, alpha, beta

positive parameters.

log, log.p

logical; If TRUE, probabilities p are given as log(p).

lower.tail

logical; If TRUE, (default), P(X ≤q x) are returned, otherwise P(X > x).

p

vector of probabilities.

n

number of observations. If length(n) > 1, the length is taken to be the number required.

mixture

logical; If TRUE, (default), random deviates are generated from a two-component mixture of inverse-gamma distributions, otherwise from the quantile function. #'

Details

Probability density function

f(x\mid θ ,α ,β )=\frac{β θ ^{2}}{θ +α }≤ft( \frac{α +x^{β }}{x^{2β +1}}\right) e^{-\frac{θ }{ x^{β }}}

Cumulative distribution function

F(x\mid θ ,α ,β )=≤ft( 1+\frac{θ α }{≤ft( θ +α \right) }\frac{1}{{x}^{β }}\right) e{{^{-{\frac{θ }{ x^{β }}}}}}

Quantile function

Q(p\mid θ ,α ,β) =≤ft[ -\frac{1}{θ }-\frac{1}{α }-\frac{1}{θ }W_{-1}{≤ft( -\frac{p}{α }≤ft( θ+α \right) {e{^{-≤ft( {\frac{θ +α }{α }}\right) }}}\right) }\right] ^{-\frac{1}{β }}

Hazard rate function

h(x\mid θ ,α ,β )=\frac{β θ ^{2}≤ft( α+x^{β }\right) e^{-\frac{θ }{x^{β }}}}{≤ft( θ +α\right) x^{2β +1}≤ft[ 1-≤ft( 1+\frac{θ α }{≤ft( θ+α \right) }\frac{1}{{x}^{β }}\right) e{{^{-{\frac{θ }{x^{β }}}}}}\right] }

where W_{-1} denotes the negative branch of the Lambert W function.

Particular cases: α = 1, β = 1 the inverse Lindley distribution, α = 1 the generalized inverse Lindley distribution and for α = 0 the inverse Weibull distribution.

Value

dextilindley gives the density, pextilindley gives the distribution function, qextilindley gives the quantile function, rextilindley generates random deviates and hextilindley gives the hazard rate function.

Invalid arguments will return an error message.

Author(s)

Josmar Mazucheli jmazucheli@gmail.com

Larissa B. Fernandes lbf.estatistica@gmail.com

Source

[d-h-p-q-r]extilindley are calculated directly from the definitions. rextilindley uses either a two-component mixture of generalized inverse gamma distributions or the quantile function.

References

Alkarni, S. H., (2015). Extended inverse Lindley distribution: properties and application. SpringerPlus, 4, (1), 690-703.

Mead, M. E., (2015). Generalized inverse gamma distribution and its application in reliability. Communication in Statistics - Theory and Methods, 44, 1426-1435.

See Also

lambertWm1.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
set.seed(1)
x <- rextilindley(n = 10000, theta = 5, alpha = 20, beta = 10)
R <- range(x)
S <- seq(from = R[1], to = R[2], by = 0.01)
plot(S, dextilindley(S, theta = 5, alpha = 20, beta = 20), xlab = 'x', ylab = 'pdf')
hist(x, prob = TRUE, main = '', add = TRUE)

p <- seq(from = 0.1, to = 0.9, by = 0.1)
q <- quantile(x, prob = p)
pextilindley(q, theta = 5, alpha = 20, beta = 10, lower.tail = TRUE)
pextilindley(q, theta = 5, alpha = 20, beta = 10, lower.tail = FALSE)
qextilindley(p, theta = 5, alpha = 20, beta = 10, lower.tail = TRUE)
qextilindley(p, theta = 5, alpha = 20, beta = 10, lower.tail = FALSE)

library(fitdistrplus)
fit <- fitdist(x, 'extilindley', start = list(theta = 5, alpha = 20, beta = 10))
plot(fit)

LindleyR documentation built on May 1, 2019, 8:05 p.m.