Learn R Programming

rmutil (version 1.1.10)

Inverse Gaussian: Inverse Gaussian Distribution

Description

These functions provide information about the inverse Gaussian distribution with mean equal to m and dispersion equal to s: density, cumulative distribution, quantiles, log hazard, and random generation.

The inverse Gaussian distribution has density $$ f(y) = \frac{1}{\sqrt{2\pi\sigma y^3}} e^{-(y-\mu)^2/(2 y \sigma m^2)}$$ where \(\mu\) is the mean of the distribution and \(\sigma\) is the dispersion.

Usage

dinvgauss(y, m, s, log=FALSE)
pinvgauss(q, m, s)
qinvgauss(p, m, s)
rinvgauss(n, m, s)

Arguments

y

vector of responses.

q

vector of quantiles.

p

vector of probabilities

n

number of values to generate

m

vector of means.

s

vector of dispersion parameters.

log

if TRUE, log probabilities are supplied.

Author

J.K. Lindsey

See Also

dnorm for the normal distribution and dlnorm for the Lognormal distribution.

Examples

Run this code
dinvgauss(5, 5, 1)
pinvgauss(5, 5, 1)
qinvgauss(0.8, 5, 1)
rinvgauss(10, 5, 1)

Run the code above in your browser using DataLab