ARL_Clminus {LGCU}R Documentation

ARL Estimation in CUSUM Control Charts with Gamma Distribution and Cautious Learning for downward detection

Description

This function calculates the Average Run Length (ARL) of a CUSUM control chart based on the Gamma distribution, incorporating a cautious learning scheme for the dynamic update of parameters.

The function allows the evaluation of the CUSUM chart’s performance under different parameterization scenarios, ensuring efficient detection of process changes.

Based on the methodology presented in the work of Madrid-Alvarez, García-Díaz, and Tercero-Gómez (2024), this implementation uses Monte Carlo simulations optimized in C++ for efficient execution and progressive adjustment of the control chart parameters.

The values for H_minus, H_delta, K_l, delay, and tau can be referenced in the tables from the article:

Madrid-Alvarez, H. M., García-Díaz, J. C., & Tercero-Gómez, V. G. (2024). A CUSUM control chart for the Gamma distribution with cautious parameter learning. Quality Engineering, 1-23.

Usage Scenarios:

Scenario 1: Known alpha and estimated beta

Scenario 2: Both alpha and beta are estimated

Features:

This function is ideal for quality control studies where reliable detection of process changes modeled with Gamma distributions is required.

Usage

ARL_Clminus(
  alpha,
  beta,
  alpha0_est,
  beta0_est,
  known_alpha,
  beta_ratio,
  H_delta,
  H_minus,
  n_I,
  replicates,
  K_l,
  delay,
  tau
)

Arguments

alpha

Shape parameter of the Gamma distribution.

beta

Scale parameter of the Gamma distribution.

alpha0_est

Initial estimate of the shape parameter alpha. If known_alpha is TRUE, this value will be equal to alpha.

beta0_est

Initial estimate of the scale parameter beta. This value is updated dynamically during the simulation.

known_alpha

TRUE if alpha0_est is fixed, FALSE if it must be estimated.

beta_ratio

Ratio between beta and its posterior estimate.

H_delta

Increment of the lower control limit in the CUSUM chart.

H_minus

Initial control limit of the CUSUM chart for downward detection.

n_I

Sample size in Phase I.

replicates

Number of Monte Carlo simulations.

K_l

Secondary control threshold for parameter updating.

delay

Number of observations before updating beta0_est.

tau

Time point at which beta changes.

Value

A numeric value corresponding to the ARL estimate for the downward CUSUM control chart with cautious learning.

Examples

# Option 1: Provide parameters directly
ARL_Clminus(
   alpha = 1,
   beta = 1,
   alpha0_est = 1.067,  # alpha = known_alpha
   beta0_est = 0.2760,   # Estimated Beta
   known_alpha = TRUE,
   beta_ratio = 1/2,
   H_delta = 0.6946,
   H_minus = -4.8272,
   n_I = 500,
   replicates = 1000,
   K_l = 0.5,
   delay = 25,
   tau = 1
)

# Option 2: Use generated data
set.seed(123)
datos_faseI <- rgamma(n = 500, shape = 1, scale = 1)
alpha0_est <- mean(datos_faseI)^2 / var(datos_faseI)  # Alpha estimation
beta0_est <- mean(datos_faseI) / alpha0_est  # Beta estimation

ARL_Clminus(
   alpha = 1,
   beta = 1,
   alpha0_est = 1.067,  # alpha = known_alpha
   beta0_est = 0.2760,   # Estimated Beta
   known_alpha = FALSE,
   beta_ratio = 1/2,
   H_delta = 0.6946,
   H_minus = -4.8272,
   n_I = 500,
   replicates = 1000,
   K_l = 0.5,
   delay = 25,
   tau = 1
)

[Package LGCU version 0.1.5 Index]