Skip to contents

A wrapper for feglm with family = poisson().

Usage

fepoisson(
  formula = NULL,
  data = NULL,
  weights = NULL,
  beta_start = NULL,
  eta_start = NULL,
  control = NULL
)

Arguments

formula

an object of class "formula": a symbolic description of the model to be fitted. formula must be of type y ~ x | k, where the second part of the formula refers to factors to be concentrated out. It is also possible to pass clustering variables to feglm as y ~ x | k | c.

data

an object of class "data.frame" containing the variables in the model. The expected input is a dataset with the variables specified in formula and a number of rows at least equal to the number of variables in the model.

weights

an optional string with the name of the 'prior weights' variable in data.

beta_start

an optional vector of starting values for the structural parameters in the linear predictor. Default is \(\boldsymbol{\beta} = \mathbf{0}\).

eta_start

an optional vector of starting values for the linear predictor.

control

a named list of parameters for controlling the fitting process. See feglm_control for details.

Value

A named list of class "feglm".

Examples

# check the feglm examples for the details about clustered standard errors
mod <- fepoisson(mpg ~ wt | cyl, mtcars)
summary(mod)
#> Formula: mpg ~ wt | cyl
#> <environment: 0x59238a6221b0>
#> 
#> Family: Poisson
#> 
#> Estimates:
#> 
#> |    | Estimate | Std. Error | z value | Pr(>|z|) |
#> |----|----------|------------|---------|----------|
#> | wt |  -0.1799 |     0.0716 | -2.5126 | 0.0120 * |
#> 
#> Significance codes: *** 99.9%; ** 99%; * 95%; . 90%
#> 
#> Pseudo R-squared: 0.6155 
#> 
#> Number of observations: Full 32; Missing 0; Perfect classification 0 
#> 
#> Number of Fisher Scoring iterations: 4