Computes various risk measures (mean, variance, Value-at-Risk (VaR), and Tail Value-at-Risk (TVaR)) for the compound Binomial distribution.

pCompBinom(
x,
size,
prob,
shape,
rate = 1/scale,
scale = 1/rate,
k0,
distr_severity = "Gamma"
)

expValCompBinom(
size,
prob,
shape,
rate = 1/scale,
scale = 1/rate,
distr_severity = "Gamma"
)

varCompBinom(
size,
prob,
shape,
rate = 1/scale,
scale = 1/rate,
distr_severity = "Gamma"
)

VatRCompBinom(
kap,
size,
prob,
shape,
rate = 1/scale,
scale = 1/rate,
k0,
distr_severity = "Gamma"
)

TVatRCompBinom(
kap,
size,
prob,
shape,
rate = 1/scale,
scale = 1/rate,
vark,
k0,
distr_severity = "Gamma"
)

## Arguments

x vector of quantiles. Number of trials (0 or more). Probability of success in each trial. shape parameter $$\alpha$$, must be positive. rate parameter $$\beta$$, must be positive. alternative parameterization to the rate parameter, scale = 1 / rate. point up to which to sum the distribution for the approximation. Choice of severity distribution. "gamma" (default) "lognormal" only for the expected value and variance. probability. Value-at-Risk (VaR) calculated at the given probability kap.

## Value

Function :

• pCompBinom gives the cumulative density function.

• expValCompBinom gives the expected value.

• varCompBinom gives the variance.

• TVatRCompBinom gives the Tail Value-at-Risk.

• VatRCompBinom gives the Value-at-Risk.

Returned values are approximations for the cumulative density function, TVaR, and VaR.

## Details

The compound binomial distribution has density ....

## Examples

pCompBinom(x = 2, size = 1, prob = 0.2, shape = log(1000) - 0.405, rate = 0.9^2, k0 = 1E2, distr_severity = "Gamma")
#> [1] 0.8006133
expValCompBinom(size = 1, prob = 0.2, shape = log(1000) - 0.405, rate = 0.9^2, distr_severity = "Lognormale")
#> [1] 200
varCompBinom(size = 1, prob = 0.2, shape = log(1000) - 0.405, rate = 0.9^2, distr_severity = "Lognormale")
#> [1] 409581.6
VatRCompBinom(kap = 0.9, size = 1, prob = 0.2, shape = log(1000) - 0.405, rate = 0.9^2, k0 = 1E2, distr_severity = "Gamma")
#> [1] 7.620525
vark_calc <- VatRCompBinom(kap = 0.9, size = 1, prob = 0.2, shape = 0.59, rate = 0.9^2, k0 = 1E2, distr_severity = "Gamma") TVatRCompBinom(kap = 0.9, size = 1, prob = 0.2, shape = 0.59, rate = 0.9^2, vark = vark_calc, k0 = 1E2, distr_severity = "Gamma")
#> [1] 1.326515