Algorithm Lab
Verified statistical algorithms with formulas, assumptions and references. Every algorithm is validated against Minitab, R, or NIST reference data.
Distributions & Tests
Math Utility Functions (Distributions)
Collection of numerical distribution functions (normal, χ², t, F) — the foundation of all hypothesis tests.
Random Variates from Statistical Distributions
Generation of pseudo-random numbers from over 20 continuous and discrete distributions using the Mulberry32 PRNG.
Process Capability
Process Capability Cp
Measures process spread relative to the tolerance width, ignoring centering.
Process Capability Index Cpk
Measures how well a process fits within specification limits, accounting for centering.
Overall Process Capability Ppk
Overall process capability based on total variation (population σ, ddof = 0).
Hypothesis Tests
Shapiro-Wilk Test
Tests whether a sample comes from a normally distributed population.
Anderson-Darling Test
Tests whether a sample comes from a normally distributed population — especially sensitive in the distribution tails.
Jarque-Bera Test
Asymptotic normality test based on skewness and kurtosis (chi-squared with 2 degrees of freedom). Reliable for large samples (n > 30).
D'Agostino-Pearson Omnibus Test
Omnibus normality test: Combines Z-scores from skewness and kurtosis into a χ²(2) test statistic. Requires n ≥ 20.
Chi-Square Variance Test
Tests whether the population variance equals a hypothesized value (one-sample variance test).
F-Test (Variance Equality)
Tests whether two normally distributed populations have equal variances.
Levene Test (Brown-Forsythe)
Robust test for equality of variances of two samples, insensitive to non-normality.
One-Sample t-Test
Tests whether the population mean equals a hypothesized value.
Two-Sample t-Test (pooled)
Compares the means of two independent samples assuming equal variances.
Welch t-Test
Compares the means of two independent samples without assuming equal variances.
Wilcoxon Signed-Rank Test
Nonparametric alternative to the one-sample t-test for the median.
Mann-Whitney U Test
Nonparametric alternative to the two-sample t-test for independent samples.
Regression & Correlation
Regression ANOVA (Variance Decomposition)
Decomposes total variation of the response into explained (regression) and unexplained (residual) components.
Regression Coefficients (t-Test & Confidence Intervals)
Tests the significance of individual regression coefficients via t-test and determines confidence intervals.
Correlation Analysis (Pearson, Spearman, Kendall)
Computes Pearson r, Spearman ρ and Kendall τ including p-values and confidence intervals.
Logistic Regression (Binomial GLM)
Models a binary response (0/1) as a function of predictors using the logistic link function and IRLS estimation.
Poisson Regression
Generalized linear model for count data with log link function and Poisson distribution.
Negative Binomial Regression
Regression model for overdispersed count data using a log link and negative binomial distribution.
ROC Curve & AUC
Computes the ROC curve (Receiver Operating Characteristic) and the Area Under the Curve (AUC) for binary classification.
Hosmer-Lemeshow Test
Tests the goodness of fit of a logistic regression model using groups of predicted probabilities.
Overdispersion Check
Checks for overdispersion in count data models using the Pearson χ²/df ratio.
Measurement System Analysis
Repeatability Index Cg (MSA Type 1)
Evaluates the repeatability of a measurement instrument: How large is the spread of repeated measurements relative to the tolerance?
Repeatability and Bias Index Cgk (MSA Type 1)
Evaluates repeatability and systematic deviation (bias) of a measurement instrument in a single index.
Gage R&R — ANOVA-Based Measurement System Analysis Type 2
Decomposes measurement variation into repeatability (EV), reproducibility (AV), and part-to-part variation using two-factor crossed ANOVA with interaction.
Control Charts
Design of Experiments
Design Efficiency (D, A, G)
Evaluates the quality of an experimental design using three criteria: D-efficiency (determinant), A-efficiency (trace), and G-efficiency (leverage).
DoE Planner (Design Generation)
Generates structural experimental designs: full 2^k, fractional 2^(k-p), CCD and Box-Behnken.
Variance Inflation Factors (VIF)
Measures multicollinearity between model terms in an experimental design.