count-and-rate-models
Model outcomes that are counts or rates, such as orders per day, defects per batch, claims per policy, visits per store or units sold per product and month. Always use this skill when someone asks how to model or forecast a count, why ordinary regression gives negative or fractional counts, how to handle different exposure (days on shelf, population, customer-months) with an offset, what a rate ratio or the exponential of a coefficient means, or why a count model's standard errors look too small (overdispersion), even when the question sounds like a quick regression. Also use it for Poisson, quasi-Poisson and negative binomial models, excess zeros with hurdle or zero-inflated models, repeated units, and comparing count models with deviance and AIC. Not for yes or no outcomes, not for judging forecast error size, and not for choosing between linear and logistic models.
Pinned to revision a18d88341e79, so it is the text this page describes rather than whatever the author pushed since.
Files
- skills/count-and-rate-models/SKILL.md
- skills/count-and-rate-models/references/zero-and-clustered-counts.md
- skills/count-and-rate-models/scripts/count_model_check.py
Every link opens the file at its source, pinned to the revision this page describes.