Learn R Programming

Distributacalcul (version 0.2.2)

perlang: Cumulative density function of the Erlang distribution

Description

Cumulative density function of the Erlang distribution with shape parameter \(n\) and rate parameter \(\beta\).

Usage

perlang(q, shape, rate = 1/scale, scale = 1/rate, lower.tail = TRUE)

Arguments

q

quantile.

shape

shape parameter \(n\), must be positive integer.

rate

\(\beta\) is the rate parameter, must be positive.

scale

alternative parameterization to rate parameter, scale = 1 / rate.

lower.tail

logical; if TRUE (default) probabilities are Pr(M <= k), otherwise, Pr(M > k).

Value

Function :

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

Details

The Erlang distribution with shape parameter \(n\) and rate parameter \(\beta\) has density: $$f\left(x\right) = \frac{\beta^{n}}{\Gamma(n)} x^{n - 1}% \mathrm{e}^{-\beta x}$$ for \(x \in \mathcal{R}^+\), \(\beta > 0\), \(n \in \mathcal{N}^+\)

See Also

Other Erlang Distribution: E_erlang(), Elim_erlang(), Etronq_erlang(), MGF_erlang(), Mexcess_erlang(), SL_erlang(), TVaR_erlang(), V_erlang(), VaR_erlang(), derlang(), kthmoment_erlang()

Examples

Run this code
# NOT RUN {
# With scale parameter
perlang(q = 2, shape = 2, scale = 5)

# With rate parameter
perlang(q = 2, shape = 2, rate = 0.2)

# }

Run the code above in your browser using DataLab