Can anyone give me advice on computing the asymptotic confidence intervals for a difference in quantiles of a distribution? For example, I have fit a log-normal distribution to doubly interval censored data with a maximum likelihood estimator and want to make statements about a percentage of the probability mass falling outside two fixed values (i.e. 23% (XX-YY) of values in this distribution fall outside of the range 1-2).

I can get SEs for the median ($e^{\mu}$), dispersion ($e^s$), and quantiles ($e^{\mu+sq}$) using the delta method but for some reason can't think of how to get SEs for differences between them. To get the SEs for the quantiles and params above I use the following:

$\bigtriangledown g(\mu, \log(\sigma)) = \left( \begin{array}{ccc} e^{\mu} & 0 & e^{\mu+s*z_{quants}}\\ 0 & e^{s+\log s} & z_{quants}e^{\mu +qs+\log s} \\ \end{array} \right)$

Which means that the new standard errors will be $\bigtriangledown g(\mu, \log(\sigma))^{T} H^{-1} \bigtriangledown g(\mu, \log(\sigma))$ where H is the approximated Hessian Matrix.


It doesn't sound like you want the difference in quantiles: the parameter you describe is the probability of the interval $[1,2]$. More generally, you can specify any interval endpoints $[x_-, x_+]$ in advance. Given parameters $(\mu, \sigma)$ of the distribution with CDF $F_{(\mu, \sigma)}$, this probability would be written

$$\theta(\mu, \sigma) = F_{(\mu, \sigma)}(x_+) - F_{(\mu, \sigma)}(x_-).$$

As such it's just a (nice, differentiable) function of the parameters and can be addressed--at least conceptually--as would any other such function.

Specifically, let $\Lambda$ be the log likelihood (a function of $(\mu,\sigma)$) with maximum value $\Lambda_0$ and let $1-\alpha$ be the desired confidence (e.g., $\alpha=0.05$ for a 95% confidence interval). To find this confidence interval you would compute the upper $1-\alpha$ percentile $c$ of a $\chi^2(1)$ distribution (e.g., equal to 3.841 for $\alpha=0.05$) and explore the values attained by $\alpha$ within the locus of all $(\mu,\sigma)$ for which $\Lambda(\mu,\sigma) \ge 2 \Lambda_0 - c$. The range of these values forms a confidence region for $\theta$.

For example, I obtained 20 iid variates from a Normal$(1, 1/2)$ distribution (which emulates the problem situation, viewing the values as logarithms). The mean of this sample was $1.016$ and its standard deviation was $0.689$. The maximum value of twice the log likelihood equals $-40.8172$. I chose $x_- = 0$ and $x_+ = \log(2) \approx 0.693$ (which to correspond to the interval $[1,2]$ for $\exp(x)$ as in the problem statement). For this interval, the value of $\theta$ is $0.247$.

Contours of lambda and theta

The ML estimates are the coordinates of the dot in the middle where $2 \Lambda$ is largest, because the likelihood is maximized exactly when twice its logarithm is maximized. Shaded areas show contours of $2\Lambda(\mu,\sigma)$ in the $(\mu,\sigma)$ plane in intervals of $3.841/4$, so that the region of interest (by descending values of $2\Lambda$) is comprised of the red, orange, yellow, and light yellow areas, terminated by the beginning of the blue area.

The thick lines and dashed lines, labeled 0.1, 0.15, 0.2, 0.25, 0.3, 0.35, and 0.4, are contours of $\theta(\mu,\sigma)$. (Notice how the $0.25$ contour passes through the point of maximum likelihood. This means that $0.25$ is the ML estimate of $\theta$. Because the true value of $\theta$ is $0.247$, the ML estimate of $\theta$ is almost exactly right. This was a matter of luck, not design.)

Green dots mark where the extreme values of $\theta$ are attained: they equal $0.151$ at $\mu=1.29, \sigma=0.63$ (the right-hand dot) and they equal $0.350$ at $\mu = 0.75, \sigma=0.62$ (the left-hand dot). As the pattern of $\theta$ contours shows, all other values of $\theta$ within the region of interest lie between these two values. Therefore, a 95% CI for $\theta$ is $[0.151, 0.350]$.


This figure plots the PDFs of the distributions corresponding to the two extreme values of $\theta$. (For reference, the true PDF is shown in light dashes.) The one on the right (in blue) has the larger mean. It corresponds to the right green dot in the contour plot. Its value of $\theta$ is the blue shaded area beneath it from $0$ to $\log(2)$. The one on the left (in red) has the smaller mean. It corresponds to the left green dot in the contour plot. Its value of $\theta$ is the corresponding area beneath it. Both these PDFs are (just barely) consistent with the data: their likelihoods are within $3.841/2$ of the maximum likelihood. As you move around within the region of interest in the contour, the corresponding PDFs vary. (Indeed, some of them have more extreme means than exhibited by these two and many of them have greater standard deviations.) However, none of them has any more or any less probability between $x_-$ and $x_+$ than the two PDFs shown here.

In summary, I have described a constrained optimization problem: to find the confidence limits of $\theta$, minimize and maximize $\theta$ within the region $2 \Lambda(\mu,\sigma) \ge 2 \Lambda_0 - c$. When the log likelihood is expensive to compute, this problem can be computationally expensive to solve, but at least it is straightforward.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.