Learn R Programming

boostmath (version 1.0.2)

inverse_gamma_distribution: Inverse Gamma Distribution Functions

Description

Functions to compute the probability density function, cumulative distribution function, and quantile function for the Inverse Gamma distribution.

Usage

inverse_gamma_pdf(x, shape, scale)

inverse_gamma_lpdf(x, shape, scale)

inverse_gamma_cdf(x, shape, scale)

inverse_gamma_lcdf(x, shape, scale)

inverse_gamma_quantile(p, shape, scale)

Value

A single numeric value with the computed probability density, log-probability density, cumulative distribution, log-cumulative distribution, or quantile depending on the function called.

Arguments

x

quantile

shape

shape parameter (shape > 0)

scale

scale parameter (scale > 0)

p

probability (0 <= p <= 1)

See Also

Boost Documentation for more details on the mathematical background.

Examples

Run this code
# Inverse Gamma distribution with shape = 3, scale = 4
inverse_gamma_pdf(2, 3, 4)
inverse_gamma_lpdf(2, 3, 4)
inverse_gamma_cdf(2, 3, 4)
inverse_gamma_lcdf(2, 3, 4)
inverse_gamma_quantile(0.5, 3, 4)

Run the code above in your browser using DataLab