hyperprior: The Hyperprior Distribution

Description Usage Arguments Details Value See Also

Description

Density, distribution function, quantile function and random generation for the distribution applied as a prior for the scale hyperparameters in the FCS2 model.
This is the distribution of σ = 1 / √{τ} where τ follows a Gamma distribution.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
dhyperprior(x, a, b)

phyperprior(q, a, b, lower.tail = TRUE)

qhyperprior(p, a, b)

rhyperprior(n, a, b)

phyperprior(q, a, b, lower.tail = TRUE)

qhyperprior(p, a, b)

rhyperprior(n, a, b)

Arguments

x

vector of quantiles.

a

a shape parameter, equal to the shape parameter of the related Gamma distribution.

b

a scale parameter, equal to the rate parameter of the related Gamma distribution.

q

vector of quantiles.

lower.tail

logical; if TRUE (default), probabilities are P{X ≤ x}, otherwise, P{X > x}

p

vector of probabilities.

n

number of samples required.

Details

The Hyperprior Distribution

The hyperprior distribution with shape parameter a and scale parameter b has density

(Γ(a) x^(2a + 1)) exp( -b / (x^2) )

for x, a, b > 0.

This is the distribution of σ = 1 / √(τ) where τ follows a Gamma distribution with shape parameter a and rate parameter b.

The mean is given by Γ(a - 0.5) √(b) / Γ(a) if a > 0.5 and is infinite otherwise.
The variance is given by b / (a - 1) - b Γ(a - 0.5)^2 / (Γ(a)^2) if a > 1 and is infinite otherwise.

Value

dhyperprior gives the density, phyperprior gives the distribution function, qhyperprior gives the quantile function, and rhyperprior generates random deviates.

See Also

dgamma for the Gamma distribution.
specialTerms for the non-linear FCS2 model terms that use this distribution as a prior for their scale parameters.


aquaMetrics/fcs2 documentation built on Aug. 21, 2021, 12:55 p.m.