Recovering Standard Deviation from a Normal Forecast Interval
Summary
The document explains how to recover the standard deviation of a normally distributed forecast from two interval quantiles. It uses an 80% interval and a point forecast as context, then presents the general quantile relationship: a normal quantile equals the mean plus the standard deviation multiplied by the corresponding standard-normal quantile. Taking the difference between the interval endpoints removes the mean, so the interval width can be divided by the difference between the matching standard-normal quantiles to obtain the standard deviation.
The answer illustrates the relationship using R’s quantile function and a separate example with a chosen mean and standard deviation. It does not calculate the requested numerical estimate from the stated interval. The method assumes a normal distribution and that the supplied bounds correspond to known tail probabilities; the prompt’s integral expression also appears to omit the usual squared deviation in the normal density exponent. The procedure estimates standard deviation, with variance obtained by squaring that result.
Key ideas
- A normal-distribution quantile is the mean plus its standard-normal quantile multiplied by the standard deviation.
- Subtracting two quantiles cancels the mean and leaves an expression determined by interval width and tail probabilities.
- The standard deviation follows by dividing interval width by the difference between the matching standard-normal quantiles.
- The method depends on the normality assumption and correctly specified interval coverage.
Tags
Full text
# How to extract standard deviation from normal distribution in R
# How to extract standard deviation from normal distribution in R
If I have some point forecast and an 80% confidence interval, with the forecast assumed to be normally distributed with a constant variance, how do I extract the actual variance?
Let us work with the following data:
- Lower 80%: 6476
- Upper 80%: 6547
By definition, we thus know that:
\begin{equation} \int_{6476}^{6547} \frac{1}{\sqrt{2 \pi \sigma^2}}exp \bigg(\frac{x-6511}{2 \sigma^2} \bigg) dx = 0.8 \end{equation}
Can you provide some R-Code to find $\sigma$?
Thank you very much.
## Answer by Cettt (score 1, accepted)
https://quant.stackexchange.com/a/51269
this I just want to add some details to noob2 comments and also answer your second question inside the comments.
So first lets consider a standard normal distribution $X_0$. This means that $X_0$ has mean zero ($\mu = 0$) and standard deviation 1 ($\sigma = 1$). Let's write $ \Phi^{-1}(\alpha)$ for the $\alpha$ quantile of $X_0$. In R you can compute $ \Phi^ {-1}(\alpha)$ using `qnorm`, i.g. $\Phi^{-1}(0.1)$ = `qnorm(0.1)`.
Now consider $X \sim \mathcal{N}(\mu, \sigma)$. Then we have that $$ X \stackrel{\text{d}}{=} \mu + \sigma \cdot X_0. $$ As a consequence the quantiles of $X$ can be written as $\Phi^{-1}(\alpha) \cdot \sigma + \mu$. You can easily verify this in R:
```
mu <- 3
sigma <- 1.2
alpha <- 0.45
qnorm(0.45) * sigma + mu
[1] 2.849206
qnorm(0.45, mean = mu, sd = sigma)
[1] 2.849206
```
Therefore
$$ \frac{90th quantilie - 10th quantile}{\sigma} = \frac{\Phi^{-1}(0.9) \cdot \sigma + \mu - \Bigl(\Phi^{-1}(0.1) \cdot \sigma + \mu \Bigr)}{\sigma} =\\ \Phi^{-1}(0.9) - \Phi^{-1}(0.1). $$ I hope this answers your question from the comments.Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.