dinvgamma {EDISON}R Documentation

Calculate inverse gamma distribution.

Description

This function calculates the density of the inverse gamma distribution.

Usage

dinvgamma(x, shape, scale = 1, log = FALSE)

Arguments

x

Input.

shape

Shape parameter.

scale

Scale parameter (1/rate).

log

Whether to return the log density.

Value

Returns the density (or log density).

Author(s)

Frank Dondelinger

Examples


# Draw samples from inverse gamma distribution with shape parameter 1 
# and scale parameter 1
samples = rinvgamma(100, shape=1, scale=1)

# Calculate density of samples
densities = dinvgamma(samples, shape=1, scale=1)


[Package EDISON version 1.1.1 Index]