Description Usage Arguments Details Value Author(s) Source References See Also Examples
Density function, distribution function, quantile function, random number generation and hazard rate function for the inverse Lindley distribution with parameter theta.
1 2 3 4 5 6 7 8 9 |
x, q |
vector of positive quantiles. |
theta |
positive parameter. |
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 |
mixture |
logical; If TRUE, (default), random deviates are generated from a two-component mixture of inverse-gamma distributions, otherwise from the quantile function. |
Probability density function
f(x\mid θ )=\frac{θ ^{2}}{1+θ }≤ft( \frac{1+x}{x^{3}}\right) e^{-\frac{θ }{x}}
Cumulative distribution function
F(x\mid θ )=≤ft( 1+\frac{θ }{x≤ft( 1+θ \right) }\right) {e{^{-{\frac{θ }{x}}}}}
Quantile function
Q(p\mid θ) =-≤ft[ 1+\frac{1}{θ }+\frac{1}{θ }W_{-1}≤ft( -p≤ft( 1+θ \right) e{^{-≤ft( 1+θ \right) }} \right) \right] ^{-1}
Hazard rate function
h(x\mid θ )=\frac{θ ^{2}≤ft( 1+x\right) {e{^{-{\frac{θ }{x}}}}}}{x^{3}≤ft( 1+θ \right) ≤ft[ 1-≤ft( 1+\frac{θ }{x≤ft(1+θ \right) }\right) {e{^{-{\frac{θ }{x}}}}}\right] }
where W_{-1} denotes the negative branch of the Lambert W function.
dilindley
gives the density, pilindley
gives the distribution function, qilindley
gives the quantile function, rilindley
generates random deviates and hilindley
gives the hazard rate function.
Invalid arguments will return an error message.
Josmar Mazucheli jmazucheli@gmail.com
Larissa B. Fernandes lbf.estatistica@gmail.com
[d-h-p-q-r]ilindley are calculated directly from the definitions. rilindley
uses either a two-component mixture of inverse gamma distributions or the quantile function.
Sharma, V. K., Singh, S. K., Singh, U., Agiwal, V., (2015). The inverse Lindley distribution: a stress-strength reliability model with application to head and neck cancer data. Journal of Industrial and Production Engineering, 32, (3), 162-173.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | x <- seq(from = 0.1, to = 3, by = 0.05)
plot(x, dilindley(x, theta = 1.0), xlab = 'x', ylab = 'pdf')
p <- seq(from = 0.1, to = 0.9, by = 0.1)
q <- quantile(x, prob = p)
pilindley(q, theta = 1.5, lower.tail = TRUE)
pilindley(q, theta = 1.5, lower.tail = FALSE)
qilindley(p, theta = 1.5, lower.tail = TRUE)
qilindley(p, theta = 1.5, lower.tail = FALSE)
set.seed(1)
x <- rilindley(n = 100, theta = 1.0)
library(fitdistrplus)
fit <- fitdist(x, 'ilindley', start = list(theta = 1.0))
plot(fit)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.