confidence interval for median of an exponential distribution

1.4k Views Asked by At

I am having a hard time finding the confidence interval of the median of an exponential distribution. I am currently studying for an upcoming test.

I found the mle of $\lambda = \frac{5}{61}$

I solved $S(t>z)=0.5$ and found the median is $z=\frac{\log(2)} {\lambda}$

Now I need to find the 95% confidence interval. I am unsure of how to do this. My first thought is to try something like:

$$ CI = \frac{\log(2)}{\lambda} \pm 1.96\sqrt{Var\left(\frac{\log(2)}{\lambda}\right)} $$ where $\lambda$ is the mle I found above.

Is that how you correctly solve for the CI for the median? If so, how do I find $Var(\frac{\log(2)}{\lambda})$ ?

EDIT: i solved for 5/61 by maximizing the log-likelihood function. I am dealing with discrete data that is subject to right censoring

I would greatly appreciate someones help, thanks!

2

There are 2 best solutions below

0
On

For a sample $X_1, \ldots, X_n$ from an exponential distribution with unknown (rate) parameter $\lambda$, the sum $S = \sum_{i=1}^n X_i$ is a sufficient statistic. Moreover, this has a Gamma distribution with parameters $n$ and $\lambda$. For $n = 5000$, the normal approximation should be quite good.

That Gamma distribution has mean $\mu = n/\lambda$ and standard deviation $\sigma = \sqrt{n}/\lambda$. So we have $ \mu - c \sigma \le S \le \mu + c \sigma$ with probability $0.95$, where $c \approx 1.96$. Since $\mu \pm c \sigma = (n \pm c \sqrt{n})/\lambda$, this translates to a 95\% confidence interval for $1/\lambda$ of $[S/(n + 1.96 \sqrt{n}), S/(n - 1.96 \sqrt{n}]$.

Note that the median of the exponential distribution with parameter $\lambda$ is $\sqrt{2}/\lambda$. So the confidence interval for the median is $[\sqrt{2} S/(n + 1.96 \sqrt{n}), \sqrt{2} S/(n - 1.96 \sqrt{n})]$$

0
On

If you wanted to compute $\operatorname{Var}\left(\frac{\log 2}\lambda\right)$, that would just be \begin{align} \operatorname{Var}\left(\frac{\log 2}\lambda\right) = &\log^22\operatorname{Var}\left(\frac1{\sum_{i=1}^n X_i}\right) \end{align} (where the $x_i$ are i.i.d. $\operatorname{Exp}(\lambda)$ random variables. Now, we compute for $x>0$, \begin{align} \mathbb P\left(\frac1{\sum_{k=1}^n X_k }\leqslant x \right) &= \mathbb P\left(\sum_{k=1}^n X_k \geqslant\frac1x \right)\\ &= 1 - \mathbb P\left(\sum_{k=1}^n X_k\leqslant \frac1x\right). \end{align} Now, the some of $n$ i.i.d. $\operatorname{Exp}(\lambda)$ random variables has $\operatorname{Erlang}(n,\lambda)$ distribution, that is, if $X= \sum_{k=1}^n X_k$ then the distribution function of $X$ is $$F_X(t) = 1 - \sum_{k=0}^{n-1}\frac1{k!}(\lambda t)^{k} e^{-\lambda t} $$ (this may be proved by a by induction with a somewhat tedious computation). Setting $t=\frac1x$, we have $$ \mathbb P\left(\sum_{k=1}^n X_k \geqslant\frac1x \right) = \sum_{k=0}^{n-1}\frac1{k!}\left(\frac\lambda x\right)^n e^{-\frac\lambda x}, $$ and so $$\frac1{\sum_{k=1}^n X_k} \sim \operatorname{Erlang}\left(n,\frac1\lambda\right) $$

But I don't recognize the form of this distribution, and my eyes started to hurt as I computed the derivative to see if I might recognize a density...so I will advise that you defer to @Robert Israel's answer.

By the way, we generally are more interested in the asymptotic variance, i.e. the behavior of the sample variance as $n\to\infty$, than the exact variance which I computed above.