make_negbin: Construct a 'negbin' object for negative binomial regression...

View source: R/make.R

make_negbinR Documentation

Construct a 'negbin' object for negative binomial regression with predefined coefficients

Description

It creates an object of class negbin from MASS package, as one would obtain when fitting a negative binomial regression, but here there is no fit, one simply provides a design matrix and coefficients. This function is particularly useful in conjunction with simulation method from the ib package to simulate from this model.

Usage

make_negbin(x, coefficients, theta)

Arguments

x

n x p design matrix (no intercept)

coefficients

p+1 vector of coefficients, the first coefficient is the intercept.

theta

additional parameter for negative binomial regression

See Also

glm.nb, simulation


samorso/IBpaper documentation built on April 29, 2022, 10:21 p.m.