| pc.gamma {INLA} | R Documentation |
Utility functions for the PC prior for Gamma(1/a, 1/a)
Description
Functions to evaluate, sample, compute quantiles and percentiles of the PC
prior for Gamma(1/a, 1/a)
Usage
inla.pc.rgamma(n, lambda = 1)
inla.pc.dgamma(x, lambda = 1, log = FALSE)
inla.pc.qgamma(p, lambda = 1)
inla.pc.pgamma(q, lambda = 1)
Arguments
n |
Number of observations |
lambda |
The rate parameter (see Details) |
x |
Evaluation points |
log |
Logical. Return the density in natural or log-scale. |
p |
Vector of probabilities |
q |
Vector of quantiles |
Details
This gives the PC prior for the Gamma(1/a, 1/a) case, where
a=0 is the base model.
Value
inla.pc.dgamma gives the density, inla.pc.pgamma
gives the distribution function, inla.pc.qgamma gives the quantile
function, and inla.pc.rgamma generates random deviates.
Author(s)
Havard Rue hrue@r-inla.org
See Also
inla.doc("pc.gamma")
Examples
x = inla.pc.rgamma(100, lambda = 1)
d = inla.pc.dgamma(x, lambda = 1)
x = inla.pc.qgamma(0.5, lambda = 1)
inla.pc.pgamma(x, lambda = 1)
[Package INLA version 25.10.19 Index]