Chi-squared Distribution
- Special case of the Gamma Distribution.
- has a chi-squared distribution with degrees of freedom () if and only if is a random variable with a Gamma Distribution with and
- A random variable is obtained by square and summing standard normal variables
- Where
- Proven using MGF
- Properties:
- Mean:
- Variance:
- MGF: for
- is a case of Gamma Distribution with and .
- Very skewed for lower values of
\begin{document}
\begin{tikzpicture}[xscale=0.8, yscale=10, domain=0:12, samples=100, every node/.style={font=\small}]
% Draw axes
\draw[->] (-0.2,0) -- (12.5,0) node[right] {$x$};
\draw[->] (0,-0.02) -- (0,0.55) node[above] {$f(x; k, \theta)$};
% Draw grid for better readability
\draw[very thin, gray!30, step=1] (0,0) grid (12,0.5);
% Gamma(1, 2) - Exponential
\draw[thick, color=red] plot (\x, {0.5*exp(-0.5*\x)})
node[right] at (1, 0.35) {$\Gamma(1,2)$};
% Gamma(1.5, 2)
\draw[thick, color=blue] plot (\x, {(sqrt(\x)*exp(-0.5*\x))/2.5066})
node[right] at (2.5, 0.28) {$\Gamma(1.5,2)$};
% Gamma(2, 2)
\draw[thick, color=orange] plot (\x, {(\x*exp(-0.5*\x))/4})
node[right] at (4.5, 0.2) {$\Gamma(2,2)$};
% Gamma(3, 2)
\draw[thick, color=teal] plot (\x, {(\x*\x*exp(-0.5*\x))/16})
node[right] at (7, 0.12) {$\Gamma(3,2)$};
% X-axis labels
\foreach \x in {2,4,6,8,10,12}
\draw (\x, 0.01) -- (\x, -0.01) node[below] {\x};
% Y-axis labels
\foreach \y in {0.1, 0.2, 0.3, 0.4, 0.5}
\draw (0.1, \y) -- (-0.1, \y) node[left] {\y};
% Legend or Title (optional)
\node[draw, fill=white, anchor=north east] at (12, 0.5) {$\theta = 2$};
\end{tikzpicture}
\end{document}
- Distribution of Sum of Squared Random Variables from a Standard Normal Distribution
- Let
- But
- A chi-squared random variable is obtained from the sum of Standard Normal Distribution variables squared.
- Moment Generating Function is standard for getting a random variable from another random variable.
- MGF of the Normal Distribution:
- Normal:
- :
- Gaussian Integral
- Proof:
- Let
- Normal:
- The Moment Generating Function of is:
-
-
- This is taking form of the Gaussian Integral
- Consider we didn't let and did U-Substitution.
- We'd need to have and
- We'd need to change the limits.
- Let
- From the Gaussian Integral we know what this will be.
- See this looks like the Moment Generating Function of Chi-squared Distribution with
- It's shown that
- Now let's move on to the sum of of these random variables.
- Let
-
- Examples: STA260 Lecture 05