ecd.cusp_std_moment: The moments, characteristic function (CF), and moment...

ecd.cusp_std_momentR Documentation

The moments, characteristic function (CF), and moment generating function (MGF) of standard cusp distribution.

Description

The moments of standard cusp distribution are calculated via Gamma function. The CF and MGF are calculated as sum of moment terms. The CF is a complex number. Since the terms in MGF is ultimately diverging, the sum is truncated before the terms are increasing.

Usage

ecd.cusp_std_moment(n)

ecd.cusp_std_cf(t, mu = 0, sigma = 1, rel.tol = 1e-08, show.warning = FALSE)

ecd.cusp_std_mgf(t, mu = 0, sigma = 1, rel.tol = 1e-07, show.warning = FALSE)

Arguments

n

integer vector specifying the n-th moments

t

numeric vector for CF and MGF

mu

length-one numeric, specifying mean for CF and MGF

sigma

length-one numeric, specifying volatility for CF and MGF

rel.tol

relative tolerance

show.warning

logical, to show warning or not.

Value

the values of the moments, CF, MGF

Examples

ecd.cusp_std_moment(c(2,4))


ecd documentation built on May 10, 2022, 1:07 a.m.