Llogis {flexsurv} | R Documentation |
The log-logistic distribution
Description
Density, distribution function, hazards, quantile function and random generation for the log-logistic distribution.
Usage
dllogis(x, shape = 1, scale = 1, log = FALSE)
pllogis(q, shape = 1, scale = 1, lower.tail = TRUE, log.p = FALSE)
qllogis(p, shape = 1, scale = 1, lower.tail = TRUE, log.p = FALSE)
rllogis(n, shape = 1, scale = 1)
hllogis(x, shape = 1, scale = 1, log = FALSE)
Hllogis(x, shape = 1, scale = 1, log = FALSE)
Arguments
x , q |
vector of quantiles. |
shape , scale |
vector of shape and scale parameters. |
log , log.p |
logical; if TRUE, probabilities p are given as log(p). |
lower.tail |
logical; if TRUE (default), probabilities are
|
p |
vector of probabilities. |
n |
number of observations. If |
Details
The log-logistic distribution with shape
parameter
and
scale
parameter has probability
density function
and hazard
for . The hazard is decreasing for shape
, and unimodal for
.
The probability distribution function is
If , the mean is
, and if
the variance is
, where
, otherwise these are undefined.
Value
dllogis
gives the density, pllogis
gives the
distribution function, qllogis
gives the quantile function,
hllogis
gives the hazard function, Hllogis
gives the
cumulative hazard function, and rllogis
generates random
deviates.
Note
Various different parameterisations of this distribution are
used. In the one used here, the interpretation of the parameters
is the same as in the standard Weibull distribution
(dweibull
). Like the Weibull, the survivor function
is a transformation of from the non-negative real line to [0,1],
but with a different link function. Covariates on
represent time acceleration factors, or ratios of expected
survival.
The same parameterisation is also used in
eha::dllogis
in the eha package.
Author(s)
Christopher Jackson <chris.jackson@mrc-bsu.cam.ac.uk>
References
Stata Press (2007) Stata release 10 manual: Survival analysis and epidemiological tables.