# Inverse gamma distribution

Wikipedia (at the time I write this) has two mutually inconsistent entries (one after the other !, http://en.wikipedia.org/wiki/Inverse-gamma_distribution#Properties):

$$X \sim \mbox{Gamma}(k, \theta) \Leftrightarrow \dfrac{1}{X} \sim \mbox{Inv-Gamma}(k, \theta^{-1})$$

$$X \sim \mbox{Gamma}(\alpha, \beta) \Leftrightarrow \dfrac{1}{X} \sim \mbox{Inv-Gamma}(\alpha, \beta)$$

My questions are:

1. Do these two definitions reflect different conventions? Or one of them is plain wrong?
2. Let's assume the mean of the inverse gamma mean is $\dfrac \beta{\alpha-1}$ (as in the Wikipedia page). Which one of the above definitions is consistent with this?
• This is actually a problem I have noticed with other wiki distribution entries. Often they are compiled by different people -- working from (or copying from) different textbooks -- and so the summary distribution results given on wiki do not always match the functional forms being used on the wiki page. Caveat emptor. Jun 7, 2014 at 18:22
• @wolfies: I try to avoid Wikipedia whenever as possible but my bible (De Groot, 1970) does not have anything for the inverse gamma. Jun 7, 2014 at 18:50

Most distributions have alternative or competing definitions or 'parameterisations' -- so using black box names such as $InverseGamma(a,b)$ has no specific meaning unless combined with an explicit statement of the functional form being used. Several software packages make this mistake of assigning black-box names to distributions, which causes a lot of problems and much confusion when users expecting one functional form discover that the software package is using a different form ... and their answers are 'wrong'.

In this specific case, if $X \sim Gamma(a,b)$ with pdf $f(x)$:

$$f(x) = \frac{x^{a-1} e^{-\frac{x}{b}}}{\Gamma(a) b^a }$$

... then the pdf of $Y = 1/X$ is $InverseGamma(a,b)$ with pdf say $g(y)$:

$$g(y) = \frac{y^{-(a+1)} e^{-\frac{1}{b y}}}{\Gamma(a) b^a }$$

Given pdf $g(y)$, $E_g[Y] = \frac{1}{(a-1) b}$ (assuming $a>1$).

• Thanks, this means that for $a>1$ if $b\searrow$ both expectations go up? That is: $\mathbb{E}[X]=\frac{a}{b}\nearrow$ and $\mathbb{E}[1/X]=\frac1{(a-1)b}\nearrow$. Weird no? I would think they should move in opposite directions. Jun 7, 2014 at 18:44
• If $X$ has pdf $f(x)$ as above, then $E_f[X] = a b$ (not $a/b$). Also: $E_f[1/X] = \frac{1}{(a-1)b}$ and $E_g[Y] = \frac{1}{(a-1)b}$ Jun 7, 2014 at 18:50
• we are not suppose to thank but this helped a lot! Jun 7, 2014 at 18:51

Your confusion arises from the fact that there are different parametrizations for the gamma and inverse gamma distribution. The gamma distribution can be parametrized by shape and scale ($(k,\theta)$ in the Wikipedia notation), or by shape and rate. The inverse gamma distribution's entry in Wikipedia is parametrized only by shape and scale. So both of the statements are correct.

You can check it for yourself by taking the gamma density under either parametrization, and doing the transform $Y = 1/X$.

• Actually I think wikipedia has it wrong, the inverse gamma distribution entry there corresponds to the shape and rate parametrization (as it's defined in its Gamma distribution page) and it confusingly/wrongly says it's using the shape and scale parametrization. Nov 24, 2017 at 13:44

I think the main confusion is that Wikipedia calls the Inverse Gamma scale parameter a rate parameter. It is scale as it must be in the units as the random variable.