How to convert an approximation of CCDF for a standard normal to an approximation with a different mean and variance?

472 Views Asked by At

Abramowitz and Stegun give an approximation for the standard normal's complementary cumulative distribution function (CCDF) in Formula 26.2.23

A&S Formula 26.2.23

I understand this to be an approximation for when $\mu = 0$ and $\sigma = 1.$ Is there a procedure to transform the coefficients to generate an approximation fitting a CCDF for different values of $\mu$ and $\sigma?$

1

There are 1 best solutions below

1
On BEST ANSWER

Comment (with room for notation and code).

In R statistical software the standard normal CDF $\Phi$ is denoted as pnorm: that is, $P(Z \le 1.96) = 0.975,$ where $Z \sim \mathsf{Norm}(\mu=0, \sigma=1).$

pnorm(1.96)
[1] 0.9750021

Also, the inverse CDF $\Phi^{-1}$ or 'quantile function' of $Z$ is denoted as qnorm: that is $c = 1.96$ has $P(Z \le c) = 0.975.$

> qnorm(.975)
[1] 1.959964

The CDF of $X \sim \mathsf{Norm}(\mu, \sigma),$ for general mean $\mu$ and standard deviation $\sigma$ is denoted by pnorm with the mean as the second argument and the SD as the third. And similarly for the quantile function qnorm. Letting $\mu = 100$ and $\sigma = 10,$ we have:

> qnorm(.975, 100, 10)
[1] 119.5996
> pnorm(119.6, 100, 10)
[1] 0.9750021

The relationship between the quantile function of standard normal and the quantile function of $\mathsf{Norm}(100, 10)$ is suggested by:

> (qnorm(.975, 100, 10) - 100)/10
[1] 1.959964

> qnorm(.975)*10 + 100
[1] 119.5996

Maybe this answers some of your questions. I will leave it to you to put this into your favorite notation.


Notes: I believe you may want to use the quantile function to generate random samples from a normal distribution. In R, the straightforward way is to use the function rnorm with appropriate parameters.

set.seed(125);  rnorm(5)  # Sample of 5 from NORM(0,1)
[1]  0.93332697 -0.52503178  1.81443979  0.08304562  0.39571880

The method behind rnorm is to use pseudorandom numbers that behave as a random sample from $\mathsf{Unif}(0,1)$ followed by a rational approximation of $\Phi^{-1}$ due to Michael Wichura. The approximation is accurate to within the ability of R to represent results in double precision. This can be demonstrated by generating a single standard normal observation, as shown below. (You can read more about this on the R documentation page for rnorm .)

> set.seed(125);  rnorm(1)        # One simulated observation from NORM(0,1)
[1] 0.933327
> set.seed(125);  qnorm(runif(1)) # Same seed, emulates 'rnorm', same result
[1] 0.933327

To simulate an observation from $\mathsf{Norm}(100, 10),$ we can use:

> set.seed(125);  qnorm(runif(1))*10 + 100
[1] 109.3333
> set.seed(125);  rnorm(1, 100, 10)
[1] 109.3333