mpfit: MPNORMLIM

[Source code]

NAME
MPNORMLIM
AUTHOR
Craig B. Markwardt, NASA/GSFC Code 662, Greenbelt, MD 20770
craigm@lheamail.gsfc.nasa.gov
UPDATED VERSIONs can be found on my WEB PAGE: 
   http://cow.physics.wisc.edu/~craigm/idl/idl.html
PURPOSE
Compute confidence limits for normally distributed variable
MAJOR TOPICS
Curve and Surface Fitting, Statistics
CALLING SEQUENCE
Z = MPNORMLIM(PROB, [/CLEVEL, /SLEVEL ])
DESCRIPTION
The function MPNORMLIM() computes confidence limits of a normally
distributed variable (with zero mean and unit variance), for a
desired probability level.  The returned values, Z, are the
limiting values: a the magnitude of a normally distributed value
is greater than Z by chance with a probability PROB:
  P_NORM(ABS(X) > Z) = PROB
In specifying the probability level the user has two choices:
  * give the confidence level (default);
  * give the significance level (i.e., 1 - confidence level) and
    pass the /SLEVEL keyword; OR
Note that /SLEVEL and /CLEVEL are mutually exclusive.
INPUTS
PROB - scalar or vector number, giving the desired probability
       level as described above.
RETURNS
Returns a scalar or vector of normal confidence limits.
KEYWORD PARAMETERS
SLEVEL - if set, then PROB describes the significance level.
CLEVEL - if set, then PROB describes the confidence level
         (default).
EXAMPLE
print, mpnormlim(0.99d, /clevel)
Print the 99% confidence limit for a normally distributed
variable.  In this case it is about 2.58 sigma.
REFERENCES
Algorithms taken from CEPHES special function library, by Stephen
Moshier. (http://www.netlib.org/cephes/)
MODIFICATION HISTORY
Completed, 1999, CM
Documented, 16 Nov 2001, CM
Reduced obtrusiveness of common block and math error handling, 18
  Nov 2001, CM
Convert to IDL 5 array syntax (!), 16 Jul 2006, CM
Move STRICTARR compile option inside each function/procedure, 9 Oct 2006
Add usage message, 24 Nov 2006, CM
Id: mpnormlim.pro,v 1.6 2006/11/25 01:44:13 craigm Exp $