Learn R Programming

eha (version 2.4-6)

Lognormal: The Lognormal Distribution

Description

Hazard function and cumulative hazard function for the Lognormal distribution with parameters shape and scale.

Usage

hlnorm(x, meanlog = 0, sdlog = 1,
shape = 1 / sdlog, scale = exp(meanlog), prop = 1, log = FALSE)
Hlnorm(x, meanlog = 0, sdlog = 1,
shape = 1 / sdlog, scale = exp(meanlog), prop = 1, log.p = FALSE)

Arguments

x

vector of quantiles.

meanlog, sdlog

Mean and standard deviation in the distribution of the logarithm of a lognormal random variable.

shape, scale

shape and scale parameters, both defaulting to 1.

prop

A 'proportional hazards' parameter, see Details.

log, log.p

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

Value

hlnorm gives the hazard function, and Hlnorm gives the cumulative hazard function.

Invalid arguments will result in return value NaN, with a warning.

Details

This is a complement to the Lognormal distribution, see Lognormal for further details.

From eha version 2.3-0, the lognormal distribution is extended to a three-parameter family of distributions. The third parameter, 'prop', is a 'proportional hazards' parameter, simply multiplying the hazard function by its value. For now only implemented in the hazard and cumulative hazards functions, but it will be introduced fully soon. Probably as a class of distributions with a new name.

See Also

phreg, aftreg.