# Example: Exponential Distribution

Let $X_{1}..X_{n}$ be a random sample with density $f\left(\left.x\right|\theta\right)=\lambda\exp\left(-\lambda x\right).$

The maximum likelihood estimate is $\widehat{\lambda}_{ML}=\frac{1}{\overline{x}}$. In large samples,

$\sqrt{n}\left(\widehat{\lambda}_{ML}-\lambda\right)\sim N\left(0,\frac{1}{\lambda^{2}}\right)$

A confidence interval with asymptotic level 0.95 exploits this result: \begin{aligned} CI & =\left(\widehat{\lambda}_{ML}-1.96\frac{1}{\sqrt{n}\widehat{\lambda}_{ML}},\widehat{\lambda}_{ML}+1.96\frac{1}{\sqrt{n}\widehat{\lambda}_{ML}}\right)\end{aligned}.

This confidence interval can be obtained by test inversion.

Consider the test problem $H_{0}:\lambda=\lambda_{0}$ vs. $H_{1}:\lambda\neq\lambda_{0}$.

The Wald test statistic is given by

$T_{W}=n\left(\widehat{\lambda}_{ML}-\lambda_{0}\right)^{2}\underset{=\widehat{\lambda}_{ML}^{2}}{\underbrace{I\left(\widehat{\lambda}_{ML}\right)}}\sim\chi_{\left(1\right)}^{2}$

And we reject the null hypothesis if $T_{W}\gt 1.96^{2}$ in order to obtain a test with $\alpha=0.05$. This leads to the 95% confidence interval above.