mean_zictp: Theoretical moments and mode of the ZI-CTP distribution

View source: R/moments.R

mean_zictpR Documentation

Theoretical moments and mode of the ZI-CTP distribution

Description

Theoretical moments and mode of the ZI-CTP distribution

Usage

mean_zictp(a, b, gama, omega)

var_zictp(a, b, gama, omega)

skew_zictp(a, b, gama, omega)

Arguments

a, b, gama

CTP parameters.

omega

Zero-inflation parameter.

Details

These functions do not validate that the parameter constraints required for a given moment to exist are satisfied (e.g. gama > 2*a+2 for the variance, gama > 2*a+3 for the skewness), the same caveat documented in mean_ctp.

Examples

# Quick illustration (fast, runs during R CMD check)
mean_zictp(a = 1, b = 0.5, gama = 6, omega = 0.3)
var_zictp(a = 1, b = 0.5, gama = 6, omega = 0.3)
skew_ctp(a = 1, b = 0.5, gama = 6)
skew_zictp(a = 1, b = 0.5, gama = 6, omega = 0.3)
mode_zictp(a = 1, b = 0.5, gama = 6, omega = 0.3)


# Empirical check against simulated data (slower, skipped on CRAN checks)
set.seed(2026)
x <- rzictp(50000, a = 1, b = 0.5, gama = 6, omega = 0.3)
skew_zictp(1, 0.5, 6, 0.3)                       # theoretical
mean((x - mean(x))^3) / sd(x)^3                  # empirical



zmctp documentation built on Sept. 20, 2026, 5:07 p.m.