Skip to content

Metrics 0.3.0 gammadeviance

github-actions[bot] edited this page Aug 21, 2026 · 1 revision

Lodestar.Metrics 0.3.0. This page is frozen at that release. Read the current documentation for what main says now. A link to a decision or a migration page follows main, and leaves the archive.

GammaDeviance

The deviance for a strictly positive quantity with no natural unit — a duration, a cost, a claim size. TweedieDeviance at power = 2.

It is scale-invariant, and the Poisson is not. Multiplying both the truth and the prediction by the same factor leaves this number exactly where it was, because the deviance depends on the two only through their ratio. That is what makes it the deviance to reach for when "out by 10%" means the same thing at every magnitude, and PoissonDeviance the one to reach for when a count is a count.

Both operands must be strictly positive. Unlike the Poisson, a zero truth is refused here too: the term carries log(ŷ / y), which has no value at y = 0, and the reference refuses rather than returning an infinity.

Members

Member What it does
GammaDeviance.Score The mean deviance for a positive, scale-free target.

Lodestar

Project

Clone this wiki locally