MyNixOS website logo
Description

Goodness-of-Fit Tests and Diagrams Based on Mellin Log-Cumulants.

A family of three complementary goodness-of-fit tests based on an adaptation of Hotelling's T-squared statistic applied to vectors of sample log-cumulants (Mellin statistics) for positive-support reliability data. The package provides the asymptotic chi-squared reference and parametric bootstrap p-values for reliable finite-sample inference, covering the Weibull, Frechet, Gamma, Inverse-Gamma, Log-Normal, and Log-Logistic families. It also provides three diagnostic diagrams (log-cumulant, kurtosis-skewness, and coefficient-of-variation) with bootstrap concentration ellipses, in the spirit of moment-ratio diagrams. Methods are described in Santos, Ospina, Espinheira and Oliveira (2025).

logcumulant logcumulant logo

License: GPL v3 R-CMD-check

logcumulant provides goodness-of-fit tests and diagnostic diagrams for positive-support reliability data, built on Mellin log-cumulants. It implements a family of three complementary Hotelling-type \eqn{T^2} statistics together with three moment-ratio-style diagrams, all calibrated by a parametric bootstrap for reliable finite-sample inference.

The package is built around a few design choices:

  • Three nested tests.T2_(2,3) targets log-scale shape (dispersion and skewness); T2_(1,2,3) adds the entropy-related first log-cumulant; and T2_(1,...,6) exploits higher-order log-cumulants for tail discrimination.
  • Bootstrap-first inference. The discrepancy covariance is typically ill-conditioned, so the asymptotic chi-squared reference is unreliable in finite samples; the parametric bootstrap restores correct size.
  • Diagnostic diagrams. Log-cumulant, kurtosis-skewness, and coefficient-of-variation diagrams, each overlaying the theoretical loci of six reliability families with a bootstrap cloud and a 95% concentration ellipse.
  • Six reliability families. Weibull, Frechet, Gamma, Inverse-Gamma, Log-Normal, and Log-Logistic, all fitted by maximum likelihood with a fast C++ core.

Installation

The package depends on a small set of CRAN packages. Install them first if needed:

install.packages(c("Rcpp", "RcppArmadillo", "MASS", "VGAM", "actuar",
                   "numDeriv", "goftest", "ggplot2", "gridExtra"))

Then install the development version from GitHub:

# install.packages("remotes")
remotes::install_github("raydonal/logcumulant")

remotes (or devtools) installs the required dependencies automatically.

A 30-second tour

library(logcumulant)
data(reliability_datasets)

bb <- reliability_datasets$BallBearing

# Quick log-cumulant diagram with bootstrap cloud
plot_lc(bb, B = 100)

# The three diagnostic diagrams
three_diagrams(bb, "Ball Bearing")

# Compare all six families (T2, AD, CvM, AIC with bootstrap p-values)
gof_compare_all(bb, use_bootstrap = TRUE)

When to use which tool

GoalFunction
Quick log-cumulant diagramplot_lc()
Log-cumulant diagram (full control)log_cumulant_diagram()
Kurtosis-skewness diagramkurtosis_diagram()
Coefficient-of-variation diagramcv_diagram()
All three diagrams togetherthree_diagrams()
Several datasets on one diagrammulti_lc_diagram()
The three T-squared statisticsT2_all()
Bootstrap p-valuesT2_bootstrap()
Full model comparisongof_compare_all()
Size / power simulationsize_study(), power_study()

Citation

If you use logcumulant in academic work, please cite:

Santos, C. C. F., Ospina, R., Espinheira, P., & Oliveira, M. (2025). Goodness-of-Fit Tests Based on Mellin Statistics for Reliability Data.

License

GPL-3.

Metadata

Version

0.1.0

License

Unknown

Platforms (79)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    uefi
    wasip1
    Windows
Show all
  • aarch64-darwin
  • aarch64-freebsd
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64-uefi
  • aarch64-windows
  • aarch64_be-none
  • arc-linux
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-linux
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • sh4-linux
  • vc4-none
  • wasm32-wasip1
  • wasm64-wasip1
  • x86_64-cygwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-uefi
  • x86_64-windows