rGIG: Simulate generalised inverse-Gaussian (GIG) random variables.

rGIGR Documentation

Simulate generalised inverse-Gaussian (GIG) random variables.

Description

A function to simulate random numbers from GIG distribution – GIG(p, a, b).

Usage

rGIG(p, a, b, seed = 0)

Arguments

p

A numeric vector for p parameters.

a

A numeric vector for a parameters.

b

A numeric vector for b parameters.

seed

A numeric value for setting the seed of random number generation.

Details

This function is a user-friendly wrapper that calls the rGIG_cpp function. Probability density function of GIG(p, a, b) is given by

f(x; p, a, b) = ((a/b)^(p/2))/(2K_p(sqrt(ab))) x^(p-1) exp(-(a/2)x - (b/2)/x),

where K_p is modified Bessel function of the second kind of order p.

Value

A list of outputs.

Examples

  ## Not run: 
  rGIG(...)
  
## End(Not run)

davidbolin/ngme documentation built on Dec. 5, 2023, 11:48 p.m.