Learn R Programming

reliaR (version 0.01)

GPWeibull: The generalized power Weibull(GPW) distribution

Description

Density, distribution function, quantile function and random generation for the generalized power Weibull(GPW) distribution with shape parameters alpha and theta.

Usage

dgp.weibull(x, alpha, theta, log = FALSE) pgp.weibull(q, alpha, theta, lower.tail = TRUE, log.p = FALSE) qgp.weibull(p, alpha, theta, lower.tail = TRUE, log.p = FALSE) rgp.weibull(n, alpha, theta)

Arguments

x,q
vector of quantiles.
p
vector of probabilities.
n
number of observations. If length(n) > 1, the length is taken to be the number required.
alpha
shape parameter.
theta
shape parameter.
log, log.p
logical; if TRUE, probabilities p are given as log(p).
lower.tail
logical; if TRUE (default), probabilities are $P[X \le x]$ otherwise, $P[X > x]$.

Value

dgp.weibull gives the density, pgp.weibull gives the distribution function, qgp.weibull gives the quantile function, and rgp.weibull generates random deviates.

Details

The generalized power Weibull(GPW) distribution has density $$f(x) = \alpha \theta x^{\alpha -1} \left(1 + x^{\alpha} \right)^{\theta - 1} \exp\left\{1-\left(1+x^{\alpha}\right)^{\theta}\right\};\, x \ge 0, \alpha > 0, \theta > 0.$$ where $\alpha$ and $\theta$ are the shape and scale parameters, respectively.

References

Nikulin, M. and Haghighi, F. (2006). A Chi-squared test for the generalized power Weibull family for the head-and-neck cancer censored data, Journal of Mathematical Sciences, Vol. 133(3), 1333-1341.

Pham, H. and Lai, C.D. (2007). On recent generalizations of the Weibull distribution, IEEE Trans. on Reliability, Vol. 56(3), 454-458.

See Also

.Random.seed about random number; sgp.weibull for generalized power Weibull(GPW) survival / hazard etc. functions

Examples

Run this code
## Load data sets
data(repairtimes)
## Maximum Likelihood(ML) Estimates of alpha & theta for the data(repairtimes)
## Estimates of alpha & theta using 'maxLik' package
## alpha.est = 1.566093, theta.est = 0.355321

dgp.weibull(repairtimes, 1.566093, 0.355321, log = FALSE)
pgp.weibull(repairtimes, 1.566093, 0.355321, lower.tail = TRUE, log.p = FALSE)
qgp.weibull(0.25, 1.566093, 0.355321, lower.tail=TRUE, log.p = FALSE)
rgp.weibull(30, 1.566093, 0.355321)

Run the code above in your browser using DataLab