Description Usage Arguments Details Value Note Examples
Gamma distribution with shape parameter alpha and rate parameter beta.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | expValGamma(shape, rate = 1/scale, scale = 1/rate)
varGamma(shape, rate = 1/scale, scale = 1/rate)
kthMomentGamma(k, shape, rate = 1/scale, scale = 1/rate)
expValLimGamma(d, shape, rate = 1/scale, scale = 1/rate)
expValTruncGamma(d, shape, rate = 1/scale, scale = 1/rate, less.than.d = TRUE)
stopLossGamma(d, shape, rate = 1/scale, scale = 1/rate)
meanExcessGamma(d, shape, rate = 1/scale, scale = 1/rate)
VatRGamma(kap, shape, rate = 1/scale, scale = 1/rate)
TVatRGamma(kap, shape, rate = 1/scale, scale = 1/rate)
mgfGamma(t, shape, rate = 1/scale, scale = 1/rate)
|
shape |
shape parameter alpha, must be positive. |
rate |
rate parameter beta, must be positive. |
scale |
alternative parameterization to the rate parameter, scale = 1 / rate. |
k |
kth-moment. |
d |
cut-off value. |
less.than.d |
logical; if |
kap |
probability. |
t |
t. |
The Gamma distribution with shape parameter a and rate parameter b has density:
f(x) = b^a / Γ(a) x^{a - 1} e^{-b x}
for x > 0, b, a > 0.
Function :
expValGamma
gives the expected value.
varGamma
gives the variance.
kthMomentGamma
gives the kth moment.
expValLimGamma
gives the limited mean.
expValTruncGamma
gives the truncated mean.
stopLossGamma
gives the stop-loss.
meanExcessGamma
gives the mean excess loss.
VatRGamma
gives the Value-at-Risk.
TVatRGamma
gives the Tail Value-at-Risk.
mgfGamma
gives the moment generating function (MGF).
Invalid parameter values will return an error detailing which parameter is problematic.
Function VatRGamma is a wrapper for the qgamma
function stats package.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 | # With scale parameter
expValGamma(shape = 3, scale = 4)
# With rate parameter
expValGamma(shape = 3, rate = 0.25)
# With scale parameter
varGamma(shape = 3, scale = 4)
# With rate parameter
varGamma(shape = 3, rate = 0.25)
# With scale parameter
kthMomentGamma(k = 2, shape = 3, scale = 4)
# With rate parameter
kthMomentGamma(k = 2, shape = 3, rate = 0.25)
# With scale parameter
expValLimGamma(d = 2, shape = 3, scale = 4)
# With rate parameter
expValLimGamma(d = 2, shape = 3, rate = 0.25)
# With scale parameter
expValTruncGamma(d = 2, shape = 3, scale = 4)
# With rate parameter
expValTruncGamma(d = 2, shape = 3, rate = 0.25)
# values greather than d
expValTruncGamma(d = 2, shape = 3, rate = 0.25, less.than.d = FALSE)
# With scale parameter
stopLossGamma(d = 2, shape = 3, scale = 4)
# With rate parameter
stopLossGamma(d = 2, shape = 3, rate = 0.25)
# With scale parameter
meanExcessGamma(d = 2, shape = 3, scale = 4)
# With rate parameter
meanExcessGamma(d = 2, shape = 3, rate = 0.25)
# With scale parameter
VatRGamma(kap = .2, shape = 3, scale = 4)
# With rate parameter
VatRGamma(kap = .2, shape = 3, rate = 0.25)
# With scale parameter
TVatRGamma(kap = .2, shape = 3, scale = 4)
# With rate parameter
TVatRGamma(kap = .2, shape = 3, rate = 0.25)
mgfGamma(t = 1, shape = 3, rate = 5)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.