AI Glossary / Probabilistic machine learning / Intermediate

Poisson regression

Definition

Poisson regression models a nonnegative count outcome using a Poisson distribution whose mean depends on predictors. With the common log link, the logarithm of the expected count is linear in those predictors. An exposure offset can account for different amounts of observation time, area, or other opportunity for events to occur.

What it means

Counts such as the number of requests received in an hour cannot be negative and often vary differently from continuous measurements. Poisson regression connects their expected value to explanatory variables while keeping the predicted mean positive.
The observed count remains an integer, but its expected value can be fractional. A prediction of 2.4 means an average under the model, not a claim that one observation contains part of an event. The standard Poisson distribution also ties conditional variance to conditional mean, which is a substantive assumption to check rather than a universal property of count data.

How it works

Specify Y_i conditional on predictors as Poisson(mu_i). Under the log-link formulation, log(mu_i) = x_i beta. A one-unit increase in a predictor multiplies the expected count by exp(beta_j), holding the other terms fixed.
When observation opportunities differ, use log(mu_i) = log(exposure_i) + x_i beta. The log exposure is an offset with coefficient fixed at one, so the model describes a rate multiplied by exposure. This assumes proportional scaling with the chosen exposure measure.
Estimate coefficients and evaluate fit, residual variation, and dependence among observations. If the variance structure or zero pattern is not adequately represented, consider an appropriate alternative or uncertainty treatment. A log-link Poisson model is not obtained by simply taking logarithms of observed counts and fitting ordinary least squares.

Three practical examples

  • Service workload: model the number of incoming requests while accounting for the length of each observation window.
  • Equipment-event analysis: compare event counts across machines using operating hours as exposure, provided the assumed proportional-rate structure is appropriate.
  • Website activity research: model counts over comparable traffic opportunities, checking whether repeated users or time dependence require a richer model.

Think of it this way

Think of a tap delivering events at a modeled rate. Leaving the tap open twice as long doubles the expected total if the rate stays the same. The analogy has limits: real event arrivals can cluster, the rate can change, and exposure need not be literal time. Those features may violate the simple model rather than being explained by the metaphor.

Worked example

Consider an original model for a count over E hours: log(mu) = log(E) + log(2) + log(1.5) x, where x is a binary operating indicator. Thus the baseline rate is 2 events per hour, and x = 1 multiplies that rate by 1.5.
For E = 3 and x = 0, the expected count is 3 × 2 = 6. For E = 3 and x = 1, it is 3 × 2 × 1.5 = 9. Doubling exposure to 6 hours while keeping x = 1 gives expected count 18.
Under the standard Poisson distribution, a case with mean 6 also has variance 6 and standard deviation square-root(6), approximately 2.449. Its probability of zero events is exp(−6), approximately 0.002479.
These values are conditional on the assumed predictors and parameters. They are not confidence intervals for the estimated rate, and the mean-variance equality does not imply that raw counts pooled across different exposures must have equal overall mean and variance. Variation in their conditional means can create extra variability in the pooled data.

Illustrative case study

Fictional case: Larch Services compares daily request counts across teams. One team appears busier until analysts account for its longer staffed hours. They fit a model with an exposure offset and inspect whether workload scales proportionally with staffed time.
Residuals show clustering around product launches, so the team considers additional predictors and a variance model suited to the remaining dispersion. It reports rate comparisons with uncertainty instead of treating raw count rankings as performance measures. This scenario illustrates analysis choices, not a claimed business improvement.

Common misconceptions and mistakes

Do not confuse a count with a rate. A rate requires a defined denominator, and exposure should correspond to a meaningful opportunity for the event.
An offset has a fixed coefficient of one. Including log exposure as an ordinary fitted predictor asks a different question about scaling.
The Poisson mean-variance equality is conditional, not necessarily a property of the marginal mixture of all observations.
Finally, a regression coefficient is not an additive change in expected count under a log link. Its exponential is a multiplicative factor under the stated model. Statistical association does not automatically identify the effect of changing an operational policy.

Business use

Poisson regression can make count comparisons more meaningful when exposure and observed conditions vary. It supports prediction and rate-based reporting with an interpretable multiplicative structure.
Define the event and exposure consistently, check whether observations are independent enough for the intended inference, and assess dispersion after accounting for predictors. Evaluate forecasts on representative held-out periods. If a model is used to compare teams or systems, explain which conditions were adjusted for and avoid interpreting unexplained differences as causal performance effects.

People also ask

Can observed counts be zero?

Yes. Zero is part of the Poisson distribution; no logarithm of the observed count is needed in standard likelihood fitting.

Can the predicted mean be 0.7?

Yes. Expectations need not be integers even though each observed outcome is an integer count.

What if variance is greater than mean?

Investigate conditional overdispersion, omitted structure, dependence, and suitable alternatives such as a negative-binomial model or an appropriate robust inference approach.

Check your understanding

A log-link coefficient is log(2). What does a one-unit predictor increase do to the expected rate, with other terms fixed?

Answer: It multiplies the rate by exp(log(2)) = 2. The absolute increase in expected count still depends on the starting rate and exposure.

Related terms

  • Count data
  • Generalized linear model
  • Conditional means
  • log link
  • exposure
  • offset
  • rate ratio
  • overdispersion
  • negative-binomial regression
  • conditional mean

Learn next

Review the Poisson mean and variance, then translate log-link coefficients into multiplicative changes. Add an exposure offset and compare count predictions with rate predictions. Finally, assess conditional dispersion and dependence before relying on standard model-based uncertainty estimates.

More in Probabilistic machine learning

  • Periodic kernel - A periodic kernel is a covariance function that represents repeating relationships in a Gaussian process or another suitable kernel model.
  • Persistent contrastive divergence - Persistent contrastive divergence, or PCD, is a learning method for energy-based models that maintains sampling chains across parameter updates.
  • Perturb-and-MAP sampling - Perturb-and-MAP sampling generates random configurations by perturbing an objective or energy function and then optimizing the perturbed function.
  • Policy gradient theorem - The policy gradient theorem expresses how an agent's expected cumulative reward changes when the parameters of its action-selection policy change.
  • Polyak-Ruppert averaging - Polyak-Ruppert averaging is a stochastic-approximation technique that averages successive parameter estimates rather than returning only the last estimate.
  • Posterior predictive check - A posterior predictive check compares observed data with replicated data generated from a fitted Bayesian model.

Sources

statsmodels, Generalized Linear Models, official family and link definitions: https://www.statsmodels.org/stable/glm.html statsmodels, GLM, official offset and exposure specification: https://www.statsmodels.org/stable/generated/statsmodels.genmod.generalized_linear_model.GLM.html The official GLM family and offset/exposure documentation was independently consulted, including the fixed unit coefficient on log exposure.

Previous: Poisson noise Next: Policy

  • Home
  • Daily AI Updates
  • Blog
  • AIFBL Academy
  • AI Glossary
  • Products and Tools
  • Store
  • Free CFO AI Prompt Pack
  • About Shihan Sheriff
  • Privacy Policy
  • Terms of Use
  • Refund Policy
  • Cookie Policy
  • Earnings Disclaimer