Exp: Exponential Distribution

ExpR Documentation

Exponential Distribution

Description

Exponential distribution with rate parameter \beta.

Usage

expValExp(rate = 1/scale, scale = 1/rate)

varExp(rate = 1/scale, scale = 1/rate)

kthMomentExp(k, rate = 1/scale, scale = 1/rate)

expValLimExp(d, rate = 1/scale, scale = 1/rate)

expValTruncExp(d, rate = 1/scale, scale = 1/rate, less.than.d = TRUE)

stopLossExp(d, rate = 1/scale, scale = 1/rate)

meanExcessExp(d, rate = 1/scale, scale = 1/rate)

VatRExp(kap, rate = 1/scale, scale = 1/rate)

TVatRExp(kap, rate = 1/scale, scale = 1/rate)

mgfExp(t, rate = 1/scale, scale = 1/rate)

Arguments

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 TRUE (default) truncated mean for values <= d, otherwise, for values > d.

kap

probability.

t

t.

Details

The Exponential distribution with rate parameter \beta has density:

f\left(x\right) = \frac{1}{\beta}\textrm{e}^{-\beta x}

for x \in \mathcal{R}^+, \beta > 0.

Value

Function :

  • expValExp gives the expected value.

  • varExp gives the variance.

  • kthMomentExp gives the kth moment.

  • expValLimExp gives the limited mean.

  • expValTruncExp gives the truncated mean.

  • stopLossExp gives the stop-loss.

  • meanExcessExp gives the mean excess loss.

  • VatRExp gives the Value-at-Risk.

  • TVatRExp gives the Tail Value-at-Risk.

  • mgfExp gives the moment generating function (MGF).

Invalid parameter values will return an error detailing which parameter is problematic.

Note

Function VatRExp is a wrapper of the qexp function from the stats package.

Examples

# With scale parameter
expValExp(scale = 4)

# With rate parameter
expValExp(rate = 0.25)

# With scale parameter
varExp(scale = 4)

# With rate parameter
varExp(rate = 0.25)

# With scale parameter
kthMomentExp(k = 2, scale = 4)

# With rate parameter
kthMomentExp(k = 2, rate = 0.25)

# With scale parameter
expValLimExp(d = 2, scale = 4)

# With rate parameter
expValLimExp(d = 2, rate = 0.25)

# With scale parameter
expValTruncExp(d = 2, scale = 4)

# With rate parameter, values greater than d
expValTruncExp(d = 2, rate = 0.25, less.than.d = FALSE)

# With scale parameter
stopLossExp(d = 2, scale = 4)

# With rate parameter
stopLossExp(d = 2, rate = 0.25)

# With scale parameter
meanExcessExp(d = 2, scale = 4)

# With rate parameter
meanExcessExp(d = 5, rate = 0.25)

# With scale parameter
VatRExp(kap = .99, scale = 4)

# With rate parameter
VatRExp(kap = .99, rate = 0.25)

# With scale parameter
TVatRExp(kap = .99, scale = 4)

# With rate parameter
TVatRExp(kap = .99, rate = 0.25)

mgfExp(t = 1, rate = 5)


Distributacalcul documentation built on May 29, 2024, 9:25 a.m.