fitModel | R Documentation |
Wrapper function for 'lm', 'glm', and 'svyglm'.
fitModel(
y,
x,
data,
family = "gaussian",
link = switch(family, gaussian = "gaussian", binomial = "logit", poisson = "log",
negbin = "log"),
design = "simple",
svydes = NA,
surv_params = NULL,
...
)
y |
character string representing the response, |
x |
character string of the explanatory variables, |
data |
name of the object containing the data. |
family |
gaussian, binomial, poisson (so far, no others will be added) |
link |
the link function to use |
design |
data design specification. one of 'simple', 'survey' or 'experiment' |
svydes |
a vector of arguments to be passed to the svydesign function, excluding data (defined above) |
surv_params |
a vector containing arguments for |
... |
further arguments to be passed to lm, glm, svyglm, such as offset, etc. |
A model call formula (using lm, glm, or svyglm)
Tom Elliott
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.