Gompertz Regression Family Function
gompertz.RdMaximum likelihood estimation of the 2-parameter Gompertz distribution.
Usage
gompertz(lscale = "loglink", lshape = "loglink",
iscale = NULL, ishape = NULL,
nsimEIM = 500, zero = NULL, nowarning = FALSE)Arguments
- nowarning
Logical. Suppress a warning? Ignored for VGAM 0.9-7 and higher.
- lshape, lscale
Parameter link functions applied to the shape parameter
a, scale parameterscale. All parameters are positive. SeeLinksfor more choices.
Details
The Gompertz distribution has a cumulative distribution function
$$F(x;\alpha, \beta) = 1 - \exp[-(\alpha/\beta) \times (\exp(\beta x) - 1) ]$$
which leads to a probability density function
$$f(x; \alpha, \beta) = \alpha \exp(\beta x)
\exp [-(\alpha/\beta) \times (\exp(\beta x) - 1) ]$$
for \(\alpha > 0\),
\(\beta > 0\),
\(x > 0\).
Here, \(\beta\) is called the scale parameter scale,
and \(\alpha\) is called the shape parameter
(one could refer to \(\alpha\) as a location parameter and \(\beta\) as
a shape parameter—see Lenart (2014)).
The mean is involves an exponential integral function.
Simulated Fisher scoring is used and multiple responses are handled.
The Makeham distibution has an additional parameter compared to the Gompertz distribution. If \(X\) is defined to be the result of sampling from a Gumbel distribution until a negative value \(Z\) is produced, then \(X = -Z\) has a Gompertz distribution.
Value
An object of class "vglmff" (see vglmff-class).
The object is used by modelling functions such as vglm,
and vgam.
References
Lenart, A. (2014). The moments of the Gompertz distribution and maximum likelihood estimation of its parameters. Scandinavian Actuarial Journal, 2014, 255–277.
Warning
The same warnings in makeham apply here too.
Examples
if (FALSE) { # \dontrun{
gdata <- data.frame(x2 = runif(nn <- 1000))
gdata <- transform(gdata, eta1 = -1,
eta2 = -1 + 0.2 * x2,
ceta1 = 1,
ceta2 = -1 + 0.2 * x2)
gdata <- transform(gdata, shape1 = exp(eta1),
shape2 = exp(eta2),
scale1 = exp(ceta1),
scale2 = exp(ceta2))
gdata <- transform(gdata, y1 = rgompertz(nn, scale = scale1, shape = shape1),
y2 = rgompertz(nn, scale = scale2, shape = shape2))
fit1 <- vglm(y1 ~ 1, gompertz, data = gdata, trace = TRUE)
fit2 <- vglm(y2 ~ x2, gompertz, data = gdata, trace = TRUE)
coef(fit1, matrix = TRUE)
Coef(fit1)
summary(fit1)
coef(fit2, matrix = TRUE)
summary(fit2)
} # }