Computing the standard error for an estimated probability

Each year, the maximum height $X$ of a river is measured. A value over $6\,\text{m}$ would be catastrophic. The distribution $X$ is supposed to be Rayleigh, i.e its density is $$f_{X}(x)=(x/a)e^{-x^{2}/(2a)}\text{,}\ \ x>0 \ \text{,}\ a>0$$ where $a$ is unknown. We observed the following heights in meter over eight years:$$2.5,\ 2.9,\ 1.8,\ 0.9,\ 1.7,\ 2.1,\ 2.2,\ 2.8$$ a) Give the maximum likelihood estimate for $a$.
b) Compute the standard error for the estimated probability $p$ of a catastrophe in a given year, and use it to give a confidence interval for $p$.

Okay, so I managed to do a), and found $\hat{a} = 2.42$ approx.

I also managed to find the estimated probability of a catastrophe in a given year, i.e $$\hat{p}=P(X>6 \ |\ a) = e^{-18/a}.$$

Now, when it comes to computing the standard error, i.e the root of the variance of $\hat{p}$, I do not know how exactly I can do that.

Here is my attempt:$$\operatorname{var}(\hat{p}) = \operatorname{var}(\hat{p}(\hat{a})) = \hat{p}'(\hat{a})\cdot \operatorname{var}(\hat{a}).$$

Now, how do I compute $\operatorname{var}(\hat{a})$?

• Suggest you see 'parameter estimation` in the relevant Wikipedia article. Is the estimate in (b) a function of $\alpha?$ – BruceET Jun 8 '18 at 21:06
• Yes it is. I mean, in a) I get an estimator for $a$, and the estimated $p$ depends on $\hat{a}$ – Skyris Jun 8 '18 at 21:39

$\def\dto{\xrightarrow{\mathrm{d}}}\def\vec{\boldsymbol}$First, because$$L(a; \vec{x}) = f_{\vec{X}}(\vec{x}; a) = \prod_{k = 1}^n \frac{x_k}{a} \exp\left( -\frac{x_k^2}{2a} \right) = \frac{1}{a^n} \left( \prod_{k = 1}^n x_k \right) \exp\left( -\frac{1}{2a} \sum_{k = 1}^n x_k^2 \right),\\ l(a; \vec{x}) = \ln(L(a; \vec{x})) = -\frac{1}{2a} \sum_{k = 1}^n x_k^2 - n \ln a + \sum_{k = 1}^n \ln x_k,$$ then$$\frac{\partial l}{\partial a}(a; \vec{x}) = \frac{1}{2a^2} \sum_{k = 1}^n x_k^2 - \frac{n}{a} \Longrightarrow \widehat{a}_n = \frac{1}{2n} \sum_{k = 1}^n X_k^2.$$
Next, since $X_1, \cdots, X_n$ are i.i.d, then $X_1^2, \cdots, X_n^2$ are also i.i.d., and$$f_{X_1}(x; a) = \frac{x}{a} \exp\left( -\frac{x^2}{2a} \right)\ (x > 0) \Longrightarrow f_{X_1^2}(y; a) = \frac{1}{2a} \exp\left( -\frac{y}{2a} \right)\ (y > 0).$$ Thus,$$D(\widehat{a}_n) = \frac{1}{4n^2} D\left( \sum_{k = 1}^n X_k^2 \right) = \frac{1}{4n} D(X_1^2) = \frac{a^2}{n}.$$
Now, note that$$p = P_a(X > 6) = \exp\left( -\frac{18}{a} \right) \Longrightarrow \widehat{p}_n = \exp\left( -\frac{18}{\widehat{a}_n} \right).$$ Since $E(X_1^2) = 2a$, $D(X_1^2) = 4a^2$, by the central limit theorem,$$\sqrt{n} · \frac{2 \widehat{a}_n - E(X_1^2)}{\sqrt{\smash[b]{D(X_1^2)}}} \dto N(0, 1) \Longrightarrow \sqrt{n} (\widehat{a}_n - a) \dto N(0, a^2).$$ Define $g(x) = \exp\left( -\dfrac{18}{x} \right)$. By the delta method,$$\sqrt{n} (\widehat{p}_n - p) = \sqrt{n} (g(\widehat{a}_n) - g(a)) \dto N(0, (g'(a))^2 · a^2) = N\left( 0, 18\exp\left( -\frac{18}{a} \right) \right).$$ Thus approximately, $\widehat{p}_n - p \sim N\left( 0, \dfrac{18}{n} \exp\left( -\dfrac{18}{a} \right) \right)$, and$$D(\widehat{p}_n) ≈ \frac{18}{n} \exp\left( -\frac{18}{a} \right) ≈ \frac{18}{n} \exp\left( -\frac{18}{\widehat{a}_n} \right).$$
• Thank you very much for your answer. However, could you please explain the first two lines ? Namely, why is the MLE a sum ? Also, I do not get how you transform $f_{X_1}(x;a)$ into $f_{X_{1}^2}(y;a)$. Apart from that, I think I understood everything – Skyris Jun 11 '18 at 12:18
• For $\hat{a}$, what I did was to find the log-likelihood of $a$, find the derivative of this, and then equate it to 0. Which is correct, I mean, the result I got is the right one (according the correction sheet). I don't understand why you have that $\hat{a} = \frac{1}{2n}\sum_{i=1}^{n}X_{i}^{2}$ Where does this come from ? – Skyris Jun 11 '18 at 12:23
• Acutally, sorry. I do understand how you transformed $f_{X_1}$ into $f_{X_{1}^{2}}$, all that remains to be explained is that sum. – Skyris Jun 11 '18 at 12:44
• Thank you for your answer. Yes, as I said, I understand the transformation. My only problem is with your initial statement, namely that $\hat{a}_{n} = \frac{1}{2n}\sum_{k=1}^{n} X_{n}^{2}$. Where does that come from ? I mean, I can find it on wikipedia, but I am not supposed to know that. Which, means that, since I do not know it, I need to find it. The question is, how am I suppose to assert that $\hat{a}_{n} = \frac{1}{2n}\sum_{k=1}^{n} X_{n}^{2}$. I am asking this, because during an exam, I won't be able to check wikipedia... – Skyris Jun 11 '18 at 18:06
• @Skyris I've added the derivation of $\widehat a_n$. – Saad Jun 12 '18 at 0:08