# Basic question about using the chi-square table

We are struggling on this easy question : If X is a chi-square random variable with 6 degrees of freedom, find $P(X \le 6)$ We know the answer is 0.58 according to some online calculator. We need to find it. On the table, we go to line with n = 6. However, 6 is somewhere in the large interval of 1.635 (when alpha = 0.95) and 12.592 (when alpha = 0.05) How do we come up with 0.58?

Thanks!

Most tables for the chi-square distribution are not designed to give you general probabilities; they are designed to give you critical values for specific tail probabilities corresponding to various significance levels. For example, refer to the following table:

To find $\Pr[X \le 6]$ using this table, you'd look up the sixth row, and try to find the column for which the entry in that table equals $6$. In other words, the sixth row and fifth column of this table means $\Pr[X > 5.348] \approx 0.5$, and the sixth row and seventh column means $\Pr[X > 7.84] \approx 0.25$. So in order to get $\Pr[X \le 6] = 1 - \Pr[X > 6]$, we would need a column somewhere in between $0.5$ and $0.25$, but it's not there in the table.

We can, however, use a crude linear interpolation: If we know that $\Pr[X > 5.348] = 0.5$ and $\Pr[X > 7.84] = 0.25$, then we can estimate that $$\Pr[X > 6] \approx 0.5 (1-\lambda) + 0.25 \lambda,$$ where $$\lambda = \frac{6 - 5.348}{7.84 - 5.348} \approx 0.261637.$$ This gives $\Pr[X > 6] \approx 0.434591$, which gives $\Pr[X \le 6] \approx 0.565409$. It's not that bad an approximation; the actual answer calculated with a computer is $\Pr[X \le 6] = 0.57681\ldots$.

Here’s one way to answer your question analytically (no tables). The value of $P(X \le 6)$ in your problem equals the cumulative distribution function of the $\chi^2$-distribution with $k=6$ degrees of freedom for the value $x=6$. This is given by the expression

$$\frac{\gamma(\frac{k}{2},\,\frac{x}{2})}{\Gamma(\frac{k}{2})}$$

where $\gamma$ is the lower incomplete gamma function and $\Gamma$ is the ordinary gamma function.

The denominator is just $\Gamma(3)=2!$. The numerator is given by

$$\gamma (3,3) = \int_0^3 {t^2 } e^{ - t} dt.$$

Using integration by parts, we find that $\gamma (3,3) = 2 - 17e^{ - 3}$. Therefore, we have $P(X \le 6)=1-\frac{17}{2}e^{-3}\approx 0.576809919$.