Code for GLM Poisson regression (R):
library(datasets) mydata <- warpbreaks
poisson_mod <- glm(breaks ~ wool + tension, mydata, family = poisson())
Gives:
Call: glm(formula = breaks ~ wool + tension, family = poisson(link = "log"),
data = mydata)
Coefficients:
(Intercept) woolB...