Skip to contents

\(E(Z^r \mid Z > t)\) or \(E(Z^r \mid Z \le t)\).

Usage

bd_conditional_moment(r, t, a, b, c, k, upper = TRUE, rel.tol = 1e-10)

Arguments

r

Order of the moment.

t

Vector of thresholds.

a

Shape parameter (beta generator).

b

Shape parameter governing the tail.

c

Shape parameter (baseline).

k

Scale parameter (baseline).

upper

Logical; `TRUE` (default) conditions on \(Z > t\).

rel.tol

Relative accuracy, passed to [stats::integrate()].

Value

A numeric vector the length of `t`.

Examples

bd_conditional_moment(1, t = c(0.5, 1, 2), a = 1.5, b = 3, c = 2, k = 1)
#> [1] 2.091853 2.664506 4.036508