Skip to contents

Wraps survey::svyglm(). Family argument accepts the same strings as the Python module ("gaussian", "binomial", "poisson", "gamma", "negativebinomial") or any R family object.

Usage

morie_survey_glm(
  design,
  formula,
  family = c("gaussian", "binomial", "poisson", "gamma", "negativebinomial")
)

Arguments

design

A survey::svydesign object (when interfacing with the survey package directly).

formula

A formula (e.g. y ~ x1 + x2) for survey-weighted regression / GLM.

family

A family object (e.g. stats::binomial()) passed to the survey-weighted GLM.