negative.binomial: Family function for Negative Binomial GLMs

View source: R/negbin.R

negative.binomialR Documentation

Family function for Negative Binomial GLMs

Description

Specifies the information required to fit a Negative Binomial generalized linear model, with known theta parameter, using glm().

Usage

negative.binomial(theta = stop("'theta' must be specified"), link = "log")

Arguments

theta

The known value of the additional parameter, theta.

link

The link function, as a character string, name or one-element character vector specifying one of log, sqrt or identity, or an object of class "link-glm".

Value

An object of class "family", a list of functions and expressions needed by glm() to fit a Negative Binomial generalized linear model.

References

Venables, W. N. and Ripley, B. D. (2002) Modern Applied Statistics with S-PLUS. Fourth Edition. Springer.

See Also

glm.nb, anova.negbin, summary.negbin

Examples

# Fitting a Negative Binomial model to the quine data
#   with theta = 2 assumed known.
#
glm(Days ~ .^4, family = negative.binomial(2), data = quine)

MASS documentation built on June 22, 2024, 10:42 a.m.

Related to negative.binomial in MASS...