Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

mills.ratio

Mills Ratio


Description

Computes the Mills ratio.

Usage

mills.ratio(x)
mills.ratio2(x)

Arguments

x

Numeric (real).

Details

The Mills ratio here is dnorm(x) / pnorm(x) (some use (1 - pnorm(x)) / dnorm(x)). Some care is needed as x approaches -Inf; when x is very negative then its value approaches -x.

Value

mills.ratio returns the Mills ratio, and mills.ratio2 returns dnorm(x) * dnorm(x) / pnorm(x).

Author(s)

T. W. Yee

References

Mills, J. P. (1926). Table of the ratio: area to bounding ordinate, for any portion of normal curve. Biometrika. 18(3/4), 395–400.

See Also

Examples

## Not run: 
curve(mills.ratio, -5, 5, col = "orange", las = 1)
curve(mills.ratio, -5, 5, col = "orange", las = 1, log = "y")

## End(Not run)

VGAM

Vector Generalized Linear and Additive Models

v1.1-5
GPL-3
Authors
Thomas Yee [aut, cre], Cleve Moler [ctb] (author of several LINPACK routines)
Initial release
2021-01-13

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.