Stephens 1974 weights with later Anderson-Darling calibration
Case STAT-DESC-AD-STEPHENS-001 · status: passed
Reference
- Evidence type
- R
- Source
- Stephens (1974) printed inputs; R nortest 1.0-4 statistic and later p calibration
- Citation
- Stephens (1974), Illustration 2/Table 1.3; nortest 1.0-4 ad.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · nortest 1.0.4, jsonlite 2.0.0
- Reference script
- generators/r/reference_stephens_ad.R · sha256 dc3c92cceb7d2180
- Dataset
- reference_data/datasets/DESC_STEPHENS_1974_WEIGHTS.json
Settings compared
column= "value"method= "anderson_darling"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.9467718795988862 | 0.9467718795988862 | 1.28E-18 | 17 | passed |
/p_value | tail_probability | 0.010454024005147776 | 0.010454024005147776 | 4.36E-19 | 16 | passed |
/observations | exact | 11 | 11 | 0.00E+2 | passed |
Convention
- The raw A2 is computed from source printed inputs and fitted mean/sample SD.
- The source's 1974 modified A2=1.095 and one-percent critical 1.092 reject; the later nortest p=0.010454 does not reject at one percent.
- Published and later calibration decisions are distinct; source does not publish this later p-value.
Reference code
The lines of the reference script that produce this case's expected values.
3 id <- "STAT-DESC-AD-STEPHENS-001"
3 x 3 crosstab: chi-square family, nominal, ordinal, linear-by-linear and eta
Case STAT-DESC-ASSOCIATION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::chisq.test, cor(method = kendall) and aov; DescTools association measures; SPSS CROSSTABS ASE formulas written out
- Citation
- Goodman & Kruskal (1954) JASA 49:732-764; Agresti (2013) Categorical Data Analysis ch. 2-3; IBM SPSS Statistics Algorithms, CROSSTABS; DescTools 0.99 documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, DescTools 0.99.60, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_association.R · sha256 16db03dab046251a
- Dataset
- reference_data/datasets/DESC_ASSOC_01.json
Settings compared
column= "outcome"confidence= 0.95haldane_correction= falserow= "exposure"row_order= ["Low", "Medium", "High"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_analysed | exact | 33 | 33 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/row_categories/0 | exact | Low | Low | passed | ||
/row_order_source | exact | declared | declared | passed | ||
/column_order_source | exact | numeric | numeric | passed | ||
/counts/0/0 | exact | 7 | 7 | 0.00E+2 | passed | |
/counts/2/2 | exact | 8 | 8 | 0.00E+2 | passed | |
/chi_square | tolerance | 14.980227272727271 | 14.980227272727273 | 1.95E-15 | 15 | passed |
/chi_square_df | exact | 4 | 4 | 0.00E+2 | passed | |
/chi_square_p | tail_probability | 0.004742403276540969 | 0.004742403276540968 | 8.54E-19 | 15 | passed |
/cells_expected_below_5 | exact | 9 | 9 | 0.00E+2 | passed | |
/cells/0/expected | tolerance | 3.3333333333333335 | 3.3333333333333335 | 1.86E-17 | 17 | passed |
/cells/0/standardized_residual | tolerance | 2.0083160441856087 | 2.0083160441856087 | 1.75E-17 | 17 | passed |
/cells/0/adjusted_residual | tolerance | 2.9462577590239274 | 2.9462577590239274 | 8.31E-18 | 17 | passed |
/cells/8/adjusted_residual | tolerance | 3.0705978943149539 | 3.0705978943149534 | 4.53E-16 | 15 | passed |
/risks/0 | absent | None | passed | |||
/measures/0/name | exact | Phi | Phi | passed | ||
/measures/0/direction | exact | symmetric | symmetric | passed | ||
/measures/0/estimate | tolerance | 0.67375535692989896 | 0.673755356929899 | 3.08E-18 | 17 | passed |
/measures/1/name | exact | Cramer's V | Cramer's V | passed | ||
/measures/1/direction | exact | symmetric | symmetric | passed | ||
/measures/1/estimate | tolerance | 0.47641698174589425 | 0.4764169817458943 | 5.79E-17 | 15 | passed |
/measures/2/name | exact | Contingency coefficient | Contingency coefficient | passed | ||
/measures/2/direction | exact | symmetric | symmetric | passed | ||
/measures/2/estimate | tolerance | 0.55876352794947692 | 0.5587635279494769 | 3.60E-18 | 17 | passed |
/measures/3/name | exact | Lambda | Lambda | passed | ||
/measures/3/direction | exact | symmetric | symmetric | passed | ||
/measures/3/estimate | tolerance | 0.42857142857142855 | 0.42857142857142855 | 2.36E-18 | 17 | passed |
/measures/4/name | exact | Lambda | Lambda | passed | ||
/measures/4/direction | exact | row dependent | row dependent | passed | ||
/measures/4/estimate | tolerance | 0.42857142857142855 | 0.42857142857142855 | 2.36E-18 | 17 | passed |
/measures/5/name | exact | Lambda | Lambda | passed | ||
/measures/5/direction | exact | column dependent | column dependent | passed | ||
/measures/5/estimate | tolerance | 0.42857142857142855 | 0.42857142857142855 | 2.36E-18 | 17 | passed |
/measures/6/name | exact | Goodman and Kruskal tau | Goodman and Kruskal tau | passed | ||
/measures/6/direction | exact | row dependent | row dependent | passed | ||
/measures/6/estimate | tolerance | 0.22196132596685084 | 0.22196132596685086 | 2.42E-17 | 15 | passed |
/measures/7/name | exact | Goodman and Kruskal tau | Goodman and Kruskal tau | passed | ||
/measures/7/direction | exact | column dependent | column dependent | passed | ||
/measures/7/estimate | tolerance | 0.23301104972375689 | 0.233011049723757 | 1.07E-16 | 15 | passed |
/measures/8/name | exact | Uncertainty coefficient | Uncertainty coefficient | passed | ||
/measures/8/direction | exact | symmetric | symmetric | passed | ||
/measures/8/estimate | tolerance | 0.20223101450041778 | 0.2022310145004176 | 1.69E-16 | 15 | passed |
/measures/9/name | exact | Uncertainty coefficient | Uncertainty coefficient | passed | ||
/measures/9/direction | exact | row dependent | row dependent | passed | ||
/measures/9/estimate | tolerance | 0.20223101450041778 | 0.20223101450041722 | 5.58E-16 | 14 | passed |
/measures/10/name | exact | Uncertainty coefficient | Uncertainty coefficient | passed | ||
/measures/10/direction | exact | column dependent | column dependent | passed | ||
/measures/10/estimate | tolerance | 0.20223101450041778 | 0.20223101450041758 | 1.97E-16 | 15 | passed |
/measures/11/name | exact | Gamma | Gamma | passed | ||
/measures/11/direction | exact | symmetric | symmetric | passed | ||
/measures/11/estimate | tolerance | 0.73880597014925375 | 0.7388059701492536 | 1.06E-16 | 15 | passed |
/measures/11/ase1 | tolerance | 0.13644614839981636 | 0.13644614839981634 | 2.40E-17 | 15 | passed |
/measures/11/ase0 | tolerance | 0.17074718192011271 | 0.1707471819201127 | 3.88E-18 | 16 | passed |
/measures/11/lower | tolerance | 0.47137643345640623 | 0.4713764334564061 | 1.11E-16 | 15 | passed |
/measures/11/upper | tolerance | 1.0062355068421014 | 1.0062355068421012 | 2.32E-16 | 15 | passed |
/measures/12/name | exact | Somers' d | Somers' d | passed | ||
/measures/12/direction | exact | column dependent | column dependent | passed | ||
/measures/12/estimate | tolerance | 0.54696132596685088 | 0.5469613259668509 | 4.65E-18 | 17 | passed |
/measures/12/ase1 | tolerance | 0.12521464898720611 | 0.12521464898720616 | 5.19E-17 | 15 | passed |
/measures/12/ase0 | tolerance | 0.12640951589665803 | 0.12640951589665805 | 2.34E-17 | 15 | passed |
/measures/13/name | exact | Somers' d | Somers' d | passed | ||
/measures/13/direction | exact | row dependent | row dependent | passed | ||
/measures/13/estimate | tolerance | 0.54696132596685088 | 0.5469613259668509 | 4.65E-18 | 17 | passed |
/measures/13/ase1 | tolerance | 0.12733013928478912 | 0.12733013928478903 | 8.55E-17 | 15 | passed |
/measures/13/ase0 | tolerance | 0.12640951589665803 | 0.12640951589665805 | 2.34E-17 | 15 | passed |
/measures/14/name | exact | Somers' d | Somers' d | passed | ||
/measures/14/direction | exact | symmetric | symmetric | passed | ||
/measures/14/estimate | tolerance | 0.54696132596685088 | 0.5469613259668509 | 4.65E-18 | 17 | passed |
/measures/14/ase0 | tolerance | 0.12640951589665803 | 0.12640951589665805 | 2.34E-17 | 15 | passed |
/measures/15/name | exact | Kendall's tau-b | Kendall's tau-b | passed | ||
/measures/15/direction | exact | symmetric | symmetric | passed | ||
/measures/15/estimate | tolerance | 0.54696132596685088 | 0.5469613259668509 | 4.65E-18 | 17 | passed |
/measures/15/ase0 | tolerance | 0.12640951589665803 | 0.12640951589665805 | 2.34E-17 | 15 | passed |
/measures/15/ase1 | tolerance | 0.12616830412055072 | 0.12616830412055074 | 2.50E-17 | 15 | passed |
/measures/15/lower | tolerance | 0.29967599390007504 | 0.29967599390007493 | 1.07E-16 | 15 | passed |
/measures/15/upper | tolerance | 0.79424665803362671 | 0.7942466580336268 | 1.08E-16 | 15 | passed |
/measures/16/name | exact | Kendall's tau-c | Kendall's tau-c | passed | ||
/measures/16/direction | exact | symmetric | symmetric | passed | ||
/measures/16/estimate | tolerance | 0.54545454545454541 | 0.5454545454545454 | 4.17E-18 | 17 | passed |
/measures/16/ase1 | tolerance | 0.12606128031567548 | 0.12606128031567554 | 5.90E-17 | 15 | passed |
/measures/16/ase0 | tolerance | 0.12606128031567548 | 0.1260612803156755 | 3.13E-17 | 15 | passed |
/measures/17/name | exact | Linear-by-linear association | Linear-by-linear association | passed | ||
/measures/17/direction | exact | symmetric | symmetric | passed | ||
/measures/17/estimate | tolerance | 11.175377857763811 | 11.175377857763817 | 5.54E-15 | 15 | passed |
/measures/18/name | exact | Eta | Eta | passed | ||
/measures/18/direction | exact | outcome dependent | outcome dependent | passed | ||
/measures/18/estimate | tolerance | 0.59105022577877397 | 0.5910502257787742 | 2.26E-16 | 15 | passed |
/measures/17/p_value | tail_probability | 0.0008289001258196734 | 0.0008289001258196723 | 1.08E-18 | 14 | passed |
/measures/11/p_value | tail_probability | 1.5122261925217157e-05 | 1.5122261925217155e-05 | 1.59E-21 | 15 | passed |
/measures/15/p_value | tail_probability | 1.5122261925217098e-05 | 1.5122261925217155e-05 | 5.74E-20 | 14 | passed |
/measures/19 | absent | None | passed |
Convention
- R: chisq.test(correct = FALSE) for chi-square, expected counts and adjusted residuals; lambda, GK tau and U from the Goodman-Kruskal/Theil definitions; gamma, Somers' d, tau-b, tau-c with the SAS/SPSS CROSSTABS ASE1/ASE0 formulas written out (DescTools reproduces the gamma, Somers' d and tau-c intervals; its tau-b variance code differs from the published formula and is not used); tau-b equals cor(method = 'kendall') on integer scores.
- Intervals are estimate +/- z ASE1 without truncation to [-1, 1]; the gamma upper bound exceeds 1 on this table, where DescTools clips to 1.
- Measure indexes follow the window's list: chi-square family, lambda (symmetric, row, column), GK tau (row, column), U (symmetric, row, column), gamma, Somers' d (column, row, symmetric), tau-b, tau-c, linear-by-linear, eta.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:65-82: declared text order for ordinal measures, integer scores, ASE1 for intervals and separate null ASE for tests, eta in the numeric direction.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
260 m1 <- merge_outputs(m1,
261 measure(0, "Phi", "symmetric", "estimate", cf$phi, "phi = sqrt(chi2/n)"),
262 measure(1, "Cramer's V", "symmetric", "estimate", cf$v, "Cramer's V"),
263 measure(2, "Contingency coefficient", "symmetric", "estimate", cf$c, "contingency coefficient"),
264 measure(3, "Lambda", "symmetric", "estimate", lambda_sym(tab), "symmetric lambda (Goodman-Kruskal 1954)"),
265 measure(4, "Lambda", "row dependent", "estimate", lambda_col(t(tab)), "lambda predicting the row from the column"),
266 measure(5, "Lambda", "column dependent", "estimate", lambda_col(tab), "lambda predicting the column from the row"),
267 measure(6, "Goodman and Kruskal tau", "row dependent", "estimate", gk_tau_col(t(tab)), "GK tau, row predicted"),
268 measure(7, "Goodman and Kruskal tau", "column dependent", "estimate", gk_tau_col(tab), "GK tau, column predicted"),
269 measure(8, "Uncertainty coefficient", "symmetric", "estimate", uncert(tab, "symmetric"), "symmetric U = 2I/(H_R + H_C)"),
270 measure(9, "Uncertainty coefficient", "row dependent", "estimate", uncert(tab, "row"), "U(R|C) = I/H_R"),
271 measure(10, "Uncertainty coefficient", "column dependent", "estimate", uncert(tab, "column"), "U(C|R) = I/H_C"),
272 measure(11, "Gamma", "symmetric", "estimate", ord$gamma, "gamma = (P-Q)/(P+Q)"),
273 measure(11, "Gamma", "symmetric", "ase1", ord$gamma_ase1, "gamma ASE1 (SPSS CROSSTABS; DescTools interval agrees)"),
274 measure(11, "Gamma", "symmetric", "ase0", ord$gamma_ase0, "gamma ASE0 = 2/(P+Q) sqrt(sum n(A-D)^2 - (P-Q)^2/n)"),
275 measure(11, "Gamma", "symmetric", "lower", ord$gamma - z95 * ord$gamma_ase1, "Wald lower bound estimate - z ASE1 (DescTools agrees)"),
276 measure(11, "Gamma", "symmetric", "upper", ord$gamma + z95 * ord$gamma_ase1, "Wald upper bound estimate + z ASE1, not truncated at 1 (DescTools clips it to 1)"),
277 measure(12, "Somers' d", "column dependent", "estimate", ord$d_col, "Somers' d(C|R) = (P-Q)/(n^2 - sum n_i+^2)"),
278 measure(12, "Somers' d", "column dependent", "ase1", ord$d_col_ase1, "Somers' d ASE1 (SPSS CROSSTABS; DescTools interval agrees)"),
279 measure(12, "Somers' d", "column dependent", "ase0", ord$d_col_ase0, "Somers' d ASE0"),
280 measure(13, "Somers' d", "row dependent", "estimate", ord$d_row, "Somers' d(R|C)"),
281 measure(13, "Somers' d", "row dependent", "ase1", ord$d_row_ase1, "Somers' d(R|C) ASE1 (SPSS formula on the transposed table; DescTools agrees)"),
282 measure(13, "Somers' d", "row dependent", "ase0", ord$d_row_ase0, "Somers' d(R|C) ASE0"),
283 measure(14, "Somers' d", "symmetric", "estimate", ord$d_sym, "symmetric Somers' d = 2(P-Q)/(D_r + D_c)"),
284 measure(14, "Somers' d", "symmetric", "ase0", ord$d_sym_ase0, "symmetric Somers' d ASE0"),
285 measure(15, "Kendall's tau-b", "symmetric", "estimate", ord$tau_b, "tau-b (equals cor(method = kendall) on integer scores)"),
286 measure(15, "Kendall's tau-b", "symmetric", "ase0", ord$tau_b_ase0, "tau-b ASE0 = 2 sqrt(S)/sqrt(D_r D_c)"),
287 measure(15, "Kendall's tau-b", "symmetric", "ase1", ord$tau_b_ase1, "tau-b ASE1 by the SAS/SPSS formula (1/w^2) sqrt(sum n (2 w d + tau v)^2 - n^3 tau^2 (w_r + w_c)^2)"),
288 measure(15, "Kendall's tau-b", "symmetric", "lower", ord$tau_b - z95 * ord$tau_b_ase1, "Wald lower bound with the SAS/SPSS ASE1"),
289 measure(15, "Kendall's tau-b", "symmetric", "upper", ord$tau_b + z95 * ord$tau_b_ase1, "Wald upper bound with the SAS/SPSS ASE1"),
290 measure(16, "Kendall's tau-c", "symmetric", "estimate", ord$tau_c, "tau-c = m(P-Q)/(n^2 (m-1))"),
291 measure(16, "Kendall's tau-c", "symmetric", "ase1", ord$tau_c_ase, "tau-c ASE (SAS; DescTools interval agrees)"),
292 measure(16, "Kendall's tau-c", "symmetric", "ase0", ord$tau_c_ase, "tau-c ASE0 equals its ASE1"),
293 measure(17, "Linear-by-linear association", "symmetric", "estimate", lbl$m2, "(n-1) r^2 with integer scores in declared order"),
294 measure(18, "Eta", "outcome dependent", "estimate", eta_outcome, "eta with the numeric outcome as the scale (aov between/total SS)")
295 )
296 m1[["/measures/17/p_value"]] <- prob(lbl$p, "linear-by-linear chi-square tail, 1 df")
297 m1[["/measures/11/p_value"]] <- prob(2 * stats::pnorm(-abs(ord$gamma / ord$gamma_ase0)), "gamma T = estimate/ASE0, normal two-sided")
298 m1[["/measures/15/p_value"]] <- prob(2 * stats::pnorm(-abs(ord$tau_b / ord$tau_b_ase0)), "tau-b T = estimate/ASE0, normal two-sided")
299 m1[["/measures/19"]] <- absent("the row variable is text, so no second eta")
300 emit("STAT-DESC-ASSOCIATION-001", "3 x 3 crosstab: chi-square family, nominal, ordinal, linear-by-linear and eta",
301 "nominal",
302 list(row = "exposure", column = "outcome", confidence = 0.95, haldane_correction = FALSE,
303 row_order = list("Low", "Medium", "High")),
304 m1,
305 c("R: chisq.test(correct = FALSE) for chi-square, expected counts and adjusted residuals; lambda, GK tau and U from the Goodman-Kruskal/Theil definitions; gamma, Somers' d, tau-b, tau-c with the SAS/SPSS CROSSTABS ASE1/ASE0 formulas written out (DescTools reproduces the gamma, Somers' d and tau-c intervals; its tau-b variance code differs from the published formula and is not used); tau-b equals cor(method = 'kendall') on integer scores.",
306 "Intervals are estimate +/- z ASE1 without truncation to [-1, 1]; the gamma upper bound exceeds 1 on this table, where DescTools clips to 1.",
307 "Measure indexes follow the window's list: chi-square family, lambda (symmetric, row, column), GK tau (row, column), U (symmetric, row, column), gamma, Somers' d (column, row, symmetric), tau-b, tau-c, linear-by-linear, eta.",
308 paste0(manual, ":65-82: declared text order for ordinal measures, integer scores, ASE1 for intervals and separate null ASE for tests, eta in the numeric direction.")))
2 x 2 crosstab at 90%: signed phi, odds ratio and relative risk intervals
Case STAT-DESC-ASSOCIATION-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::chisq.test, cor(method = kendall) and aov; DescTools association measures; SPSS CROSSTABS ASE formulas written out
- Citation
- Goodman & Kruskal (1954) JASA 49:732-764; Agresti (2013) Categorical Data Analysis ch. 2-3; IBM SPSS Statistics Algorithms, CROSSTABS; DescTools 0.99 documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, DescTools 0.99.60, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_association.R · sha256 16db03dab046251a
- Dataset
- reference_data/datasets/DESC_ASSOC_01.json
Settings compared
column= "passed"confidence= 0.9haldane_correction= falserow= "treated"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_analysed | exact | 33 | 33 | 0.00E+2 | passed | |
/row_categories/0 | exact | A | A | passed | ||
/column_categories/0 | exact | 0 | 0 | passed | ||
/row_order_source | exact | undeclared | undeclared | passed | ||
/counts/0/0 | exact | 8 | 8 | 0.00E+2 | passed | |
/chi_square | tolerance | 0.60923076923076946 | 0.6092307692307695 | 4.43E-18 | 17 | passed |
/chi_square_df | exact | 1 | 1 | 0.00E+2 | passed | |
/chi_square_p | tail_probability | 0.43507758619242809 | 0.4350775861924282 | 1.11E-16 | 15 | passed |
/measures/0/estimate | tolerance | -0.13587324409735149 | -0.1358732440973515 | 2.11E-18 | 16 | passed |
/measures/1/estimate | tolerance | 0.13587324409735152 | 0.13587324409735152 | 1.34E-19 | 18 | passed |
/risks/0/name | exact | Odds ratio | Odds ratio | passed | ||
/risks/0/estimate | tolerance | 0.5714285714285714 | 0.5714285714285714 | 3.15E-18 | 17 | passed |
/risks/0/lower | tolerance | 0.17494386057969719 | 0.1749438605796971 | 8.75E-17 | 15 | passed |
/risks/0/upper | tolerance | 1.8664879759878406 | 1.8664879759878414 | 8.41E-16 | 15 | passed |
/risks/1/name | exact | Relative risk (row 1) | Relative risk (row 1) | passed | ||
/risks/1/estimate | tolerance | 0.74285714285714288 | 0.7428571428571429 | 2.52E-18 | 17 | passed |
/risks/1/lower | tolerance | 0.40061713398878518 | 0.400617133988785 | 1.68E-16 | 15 | passed |
/risks/1/upper | tolerance | 1.377466633040527 | 1.3774666330405274 | 4.11E-16 | 15 | passed |
/measures/11/estimate | absent | None | passed | |||
/measures/17/estimate | absent | None | passed | |||
/measures/18/direction | exact | passed dependent | passed dependent | passed | ||
/measures/18/estimate | tolerance | 0.13587324409735146 | 0.13587324409735144 | 2.34E-17 | 15 | passed |
Convention
- R: table rows A, B (alphabetical) and columns 0, 1; a = A x 0 = 8, b = 12, c = 7, d = 6; odds ratio ad/(bc) with the Woolf interval exp(log OR +/- z sqrt(1/a+1/b+1/c+1/d)); relative risk of column 0 for row A over row B with the Katz interval; z at 90%.
- Without a declared order for the text rows the ordinal measures and the linear-by-linear test are unavailable; the manual says alphabetical order is a display rule.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:65-69 and 85-96.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
312 tab2 <- table(d$treated, d$passed)
313 stopifnot(all(tab2 == matrix(c(8, 12, 7, 6), 2, byrow = TRUE)))
314 cf2 <- chi_family(tab2)
315 rk <- risks(tab2, 0.90)
316 stopifnot(abs(rk$odds - DescTools::OddsRatio(tab2)) < 1e-12)
317 stopifnot(abs(rk$rr - DescTools::RelRisk(tab2)) < 1e-12)
318 or_dt <- DescTools::OddsRatio(tab2, conf.level = 0.90, method = "wald")
319 stopifnot(abs(or_dt[["lwr.ci"]] - rk$odds_lower) < 1e-9)
320 ord2 <- ordinal(tab2)
321 m2 <- list(
322 "/rows_analysed" = exact(as.integer(sum(tab2)), "33 rows"),
323 "/row_categories/0" = exact("A", "text rows in alphabetical display order"),
324 "/column_categories/0" = exact("0", "numeric columns in numeric order"),
325 "/row_order_source" = exact("undeclared", "no declared row order"),
326 "/counts/0/0" = exact(8L, "A x 0 is cell a"),
327 "/chi_square" = tol(cf2$chi2, "Pearson chi-square without continuity correction"),
328 "/chi_square_df" = exact(1L, "1 df"),
329 "/chi_square_p" = prob(cf2$p, "chi-square tail"),
330 "/measures/0/estimate" = tol(cf2$phi, "signed phi (ad-bc)/sqrt(margins)"),
331 "/measures/1/estimate" = tol(cf2$v, "Cramer's V equals |phi| for 2 x 2"),
332 "/risks/0/name" = exact("Odds ratio", "first risk"),
333 "/risks/0/estimate" = tol(rk$odds, "odds ratio ad/(bc) with a = A x 0"),
334 "/risks/0/lower" = tol(rk$odds_lower, "Woolf log-scale 90% lower (DescTools wald agrees)"),
335 "/risks/0/upper" = tol(rk$odds_upper, "Woolf log-scale 90% upper"),
336 "/risks/1/name" = exact("Relative risk (row 1)", "second risk"),
337 "/risks/1/estimate" = tol(rk$rr, "risk of column 0 in row A over row B"),
338 "/risks/1/lower" = tol(rk$rr_lower, "Katz log-scale 90% lower"),
339 "/risks/1/upper" = tol(rk$rr_upper, "Katz log-scale 90% upper"),
340 "/measures/11/estimate" = absent("gamma is unavailable without a declared order for the text rows"),
341 "/measures/17/estimate" = absent("linear-by-linear is unavailable without a declared order"),
342 "/measures/18/direction" = exact("passed dependent", "eta in the numeric direction only")
343 )
344 m2[["/measures/18/estimate"]] <- tol(sqrt(stats::anova(stats::lm(passed ~ treated, data = d))[["Sum Sq"]][1] /
345 sum(stats::anova(stats::lm(passed ~ treated, data = d))[["Sum Sq"]])),
346 "eta with passed as the scale")
347 emit("STAT-DESC-ASSOCIATION-002", "2 x 2 crosstab at 90%: signed phi, odds ratio and relative risk intervals",
348 "axis_coverage",
349 list(row = "treated", column = "passed", confidence = 0.90, haldane_correction = FALSE),
350 m2,
351 c("R: table rows A, B (alphabetical) and columns 0, 1; a = A x 0 = 8, b = 12, c = 7, d = 6; odds ratio ad/(bc) with the Woolf interval exp(log OR +/- z sqrt(1/a+1/b+1/c+1/d)); relative risk of column 0 for row A over row B with the Katz interval; z at 90%.",
352 "Without a declared order for the text rows the ordinal measures and the linear-by-linear test are unavailable; the manual says alphabetical order is a display rule.",
353 paste0(manual, ":65-69 and 85-96.")))
2 x 2 crosstab with an empty cell and the 0.5 correction
Case STAT-DESC-ASSOCIATION-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::chisq.test, cor(method = kendall) and aov; DescTools association measures; SPSS CROSSTABS ASE formulas written out
- Citation
- Goodman & Kruskal (1954) JASA 49:732-764; Agresti (2013) Categorical Data Analysis ch. 2-3; IBM SPSS Statistics Algorithms, CROSSTABS; DescTools 0.99 documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, DescTools 0.99.60, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_association.R · sha256 16db03dab046251a
- Dataset
- reference_data/datasets/DESC_ASSOC_01.json
Settings compared
column= "severe"confidence= 0.95haldane_correction= truerow= "treated"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/1/1 | exact | 0 | 0 | 0.00E+2 | passed | |
/risks/0/estimate | tolerance | 0.082621082621082614 | 0.08262108262108261 | 3.61E-19 | 17 | passed |
/risks/0/lower | tolerance | 0.004236957265306404 | 0.0042369572653064005 | 3.49E-18 | 15 | passed |
/risks/0/upper | tolerance | 1.611119222130297 | 1.611119222130298 | 9.01E-16 | 15 | passed |
/risks/0/infinite | exact | False | False | passed | ||
/risks/1/estimate | tolerance | 0.71604938271604934 | 0.7160493827160493 | 2.97E-18 | 17 | passed |
/risks/1/lower | tolerance | 0.52856384687868052 | 0.5285638468786805 | 1.08E-18 | 17 | passed |
/risks/1/upper | tolerance | 0.97003743543156051 | 0.9700374354315605 | 2.99E-18 | 17 | passed |
/chi_square | tolerance | 4.7666666666666666 | 4.7666666666666675 | 8.96E-16 | 15 | passed |
Convention
- R: cells 14.5, 6.5, 13.5, 0.5; odds ratio ad/(bc) and relative risk (a/(a+b))/(c/(c+d)) with Woolf and Katz log-scale intervals at 95%; the chi-square ignores the correction.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:96-98: the 0.5 correction adds 0.5 to all cells only when explicitly selected.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
357 tab3 <- table(d$treated, d$severe)
358 stopifnot(all(tab3 == matrix(c(14, 6, 13, 0), 2, byrow = TRUE)))
359 rk3 <- risks(tab3, 0.95, haldane = TRUE)
360 emit("STAT-DESC-ASSOCIATION-003", "2 x 2 crosstab with an empty cell and the 0.5 correction",
361 "axis_coverage",
362 list(row = "treated", column = "severe", confidence = 0.95, haldane_correction = TRUE),
363 list(
364 "/counts/1/1" = exact(0L, "B x 1 is empty"),
365 "/risks/0/estimate" = tol(rk3$odds, "odds ratio after adding 0.5 to all four cells"),
366 "/risks/0/lower" = tol(rk3$odds_lower, "Woolf interval on the corrected cells"),
367 "/risks/0/upper" = tol(rk3$odds_upper, "Woolf interval on the corrected cells"),
368 "/risks/0/infinite" = exact(FALSE, "finite after correction"),
369 "/risks/1/estimate" = tol(rk3$rr, "relative risk on the corrected cells"),
370 "/risks/1/lower" = tol(rk3$rr_lower, "Katz interval on the corrected cells"),
371 "/risks/1/upper" = tol(rk3$rr_upper, "Katz interval on the corrected cells"),
372 "/chi_square" = tol(chi_family(tab3)$chi2, "chi-square is on the uncorrected counts")
373 ),
374 c("R: cells 14.5, 6.5, 13.5, 0.5; odds ratio ad/(bc) and relative risk (a/(a+b))/(c/(c+d)) with Woolf and Katz log-scale intervals at 95%; the chi-square ignores the correction.",
375 paste0(manual, ":96-98: the 0.5 correction adds 0.5 to all cells only when explicitly selected.")))
2 x 2 crosstab with an empty cell and no correction
Case STAT-DESC-ASSOCIATION-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::chisq.test, cor(method = kendall) and aov; DescTools association measures; SPSS CROSSTABS ASE formulas written out
- Citation
- Goodman & Kruskal (1954) JASA 49:732-764; Agresti (2013) Categorical Data Analysis ch. 2-3; IBM SPSS Statistics Algorithms, CROSSTABS; DescTools 0.99 documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, DescTools 0.99.60, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_association.R · sha256 16db03dab046251a
- Dataset
- reference_data/datasets/DESC_ASSOC_01.json
Settings compared
column= "severe"confidence= 0.95haldane_correction= falserow= "treated"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/risks/0/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/risks/0/lower | absent | None | passed | |||
/risks/1/estimate | tolerance | 0.69999999999999996 | 0.7 | 4.41E-18 | 17 | passed |
/risks/1/lower | tolerance | 0.52540583642181649 | 0.5254058364218165 | 4.40E-18 | 17 | passed |
/measures/0/estimate | tolerance | -0.38005847503304596 | -0.38005847503304596 | 1.58E-18 | 17 | passed |
Convention
- R: a = 14, b = 6, c = 13, d = 0: odds ratio 0 with no log-scale interval; relative risk 0.7 with the Katz interval.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:96-98: zero cells may make log-scale intervals unavailable.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
377 emit("STAT-DESC-ASSOCIATION-004", "2 x 2 crosstab with an empty cell and no correction",
378 "boundary",
379 list(row = "treated", column = "severe", confidence = 0.95, haldane_correction = FALSE),
380 list(
381 "/risks/0/estimate" = tol(0, "odds ratio ad/(bc) = 0 when d = 0"),
382 "/risks/0/lower" = absent("log-scale interval unavailable with a zero cell"),
383 "/risks/1/estimate" = tol((14 / 20) / (13 / 13), "relative risk of column 0: 0.7"),
384 "/risks/1/lower" = tol(exp(log(0.7) - stats::qnorm(0.975) * sqrt(1 / 14 - 1 / 20 + 1 / 13 - 1 / 13)), "Katz lower bound, defined because both row risks are positive"),
385 "/measures/0/estimate" = tol(chi_family(tab3)$phi, "signed phi with a zero cell")
386 ),
387 c("R: a = 14, b = 6, c = 13, d = 0: odds ratio 0 with no log-scale interval; relative risk 0.7 with the Katz interval.",
388 paste0(manual, ":96-98: zero cells may make log-scale intervals unavailable.")))
Case summaries by group: five listed, statistics on every case
Case STAT-DESC-CASESUMMARIES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base mean and sd by group
- Citation
- R stats::sd documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
columns= ["score"]frequency_weight= nullgroup= "group"limit= 5metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}statistics= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/listed | exact | 5 | 5 | 0.00E+2 | passed | |
/total | exact | 24 | 24 | 0.00E+2 | passed | |
/rows/0/0 | exact | 1 | 1 | passed | ||
/rows/0/1 | exact | A | A | passed | ||
/rows/0/2 | exact | 12.5 | 12.5 | passed | ||
/rows/2/2 | exact | passed | ||||
/rows/5 | absent | None | passed | |||
/statistics/0/group | exact | A | A | passed | ||
/statistics/0/n | exact | 10 | 10 | 0.00E+2 | passed | |
/statistics/0/mean | tolerance | 17.009999999999998 | 17.009999999999998 | 1.05E-17 | 18 | passed |
/statistics/0/sd | tolerance | 2.3268720062206545 | 2.3268720062206545 | 1.26E-17 | 17 | passed |
/statistics/1/group | exact | B | B | passed | ||
/statistics/1/n | exact | 10 | 10 | 0.00E+2 | passed | |
/statistics/1/mean | tolerance | 23.82 | 23.82 | 2.84E-16 | 16 | passed |
/statistics/1/sd | tolerance | 4.89280651115038 | 4.89280651115038 | 1.11E-17 | 17 | passed |
/statistics/2/group | exact | Total | Total | passed | ||
/statistics/2/n | exact | 20 | 20 | 0.00E+2 | passed | |
/statistics/2/mean | tolerance | 20.414999999999999 | 20.415 | 1.47E-16 | 17 | passed |
/statistics/2/sd | tolerance | 5.1096683381914128 | 5.109668338191413 | 4.91E-17 | 17 | passed |
Convention
- R: mean and sd of the valid scores (NA and 999 excluded) per group and overall.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:16-18: summaries use all eligible cases, not just the displayed rows.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
310 by_group <- function(g) d$score[valid_score & d$group == g]
311 cs_outputs <- list(
312 "/listed" = exact(5L, "limit of 5"),
313 "/total" = exact(nrow(d), "all 24 rows are summarised"),
314 "/rows/0/0" = exact("1", "first listed case number"),
315 "/rows/0/1" = exact("A", "its group"),
316 "/rows/0/2" = exact("12.5", "its score as shown"),
317 "/rows/2/2" = exact("", "the third row's score is system-missing"),
318 "/rows/5" = absent("only five rows are listed"),
319 "/statistics/0/group" = exact("A", "groups in sorted order"),
320 "/statistics/0/n" = exact(length(by_group("A")), "valid scores in A"),
321 "/statistics/0/mean" = tol(mean(by_group("A")), "mean of A"),
322 "/statistics/0/sd" = tol(sd(by_group("A")), "SD of A"),
323 "/statistics/1/group" = exact("B", "second group"),
324 "/statistics/1/n" = exact(length(by_group("B")), "valid scores in B"),
325 "/statistics/1/mean" = tol(mean(by_group("B")), "mean of B"),
326 "/statistics/1/sd" = tol(sd(by_group("B")), "SD of B"),
327 "/statistics/2/group" = exact("Total", "total row"),
328 "/statistics/2/n" = exact(n, "all valid scores"),
329 "/statistics/2/mean" = tol(mean(x), "overall mean"),
330 "/statistics/2/sd" = tol(sd(x), "overall SD")
331 )
332 emit("STAT-DESC-CASESUMMARIES-001", "Case summaries by group: five listed, statistics on every case",
333 "nominal", "tabelz.analysis.report_listings:compute_case_summaries", "caseSummariesMenuItem",
334 "CASESUMMARIES",
335 list(columns = list("score"), group = "group", limit = 5L, statistics = TRUE,
336 metadata = metadata, frequency_weight = NULL),
337 cs_outputs,
338 c("R: mean and sd of the valid scores (NA and 999 excluded) per group and overall.",
339 paste0(manual, ":16-18: summaries use all eligible cases, not just the displayed rows.")),
340 "R base mean and sd by group", "R stats::sd documentation")
Case summaries under an integer frequency weight
Case STAT-DESC-CASESUMMARIES-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base rep/mean/sd (literal replication)
- Citation
- R stats::sd documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
columns= ["score"]frequency_weight= "weight"limit= 100metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}statistics= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/listed | exact | 24 | 24 | 0.00E+2 | passed | |
/columns/1 | exact | Weight | Weight | passed | ||
/rows/0/1 | exact | 1 | 1 | passed | ||
/rows/20/1 | exact | passed | ||||
/statistics/0/n | exact | 18 | 18 | 0.00E+2 | passed | |
/statistics/0/weight_sum | tolerance | 28 | 28.0 | 0.00E+2 | passed | |
/statistics/0/mean | tolerance | 19.921428571428571 | 19.921428571428574 | 3.37E-15 | 15 | passed |
/statistics/0/sd | tolerance | 4.8893199665648535 | 4.8893199665648535 | 4.09E-17 | 17 | passed |
Convention
- R: mean and sd of rep(score, weight) over valid scores with positive weight; a missing weight is 0.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:19-27: weighted mean over positive weights, squared deviations divided by W - 1, zero-weight rows listed but not summarised.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
342 w <- d$weight
343 w[is.na(w)] <- 0L
344 chosen <- valid_score & w > 0
345 W <- sum(w[chosen])
346 wm <- sum(w[chosen] * d$score[chosen]) / W
347 wsd <- sqrt(sum(w[chosen] * (d$score[chosen] - wm)^2) / (W - 1))
348 stopifnot(abs(wm - mean(rep(d$score[chosen], w[chosen]))) < 1e-12)
349 stopifnot(abs(wsd - sd(rep(d$score[chosen], w[chosen]))) < 1e-12)
350 cw_outputs <- list(
351 "/listed" = exact(nrow(d), "all rows fit within the limit"),
352 "/columns/1" = exact("Weight", "the weight column is shown"),
353 "/rows/0/1" = exact("1", "first row's weight"),
354 "/rows/20/1" = exact("", "the missing weight is shown blank"),
355 "/statistics/0/n" = exact(sum(chosen), "rows with a valid score and a positive weight"),
356 "/statistics/0/weight_sum" = tol(W, "W, the sum of the positive weights of valid scores"),
357 "/statistics/0/mean" = tol(wm, "weighted mean (mean of the replicated values)"),
358 "/statistics/0/sd" = tol(wsd, "SD with denominator W - 1 (sd of the replicated values)")
359 )
360 emit("STAT-DESC-CASESUMMARIES-002", "Case summaries under an integer frequency weight",
361 "axis_coverage", "tabelz.analysis.report_listings:compute_case_summaries", "caseSummariesMenuItem",
362 "CASESUMMARIES",
363 list(columns = list("score"), limit = 100L, statistics = TRUE,
364 metadata = metadata, frequency_weight = "weight"),
365 cw_outputs,
366 c("R: mean and sd of rep(score, weight) over valid scores with positive weight; a missing weight is 0.",
367 paste0(manual, ":19-27: weighted mean over positive weights, squared deviations divided by W - 1, zero-weight rows listed but not summarised.")),
368 "R base rep/mean/sd (literal replication)", "R stats::sd documentation")
Codebook: scale summary, labelled categories and missing counts
Case STAT-DESC-CODEBOOK-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base table and stats; quantile type 6
- Citation
- R stats::quantile documentation (type 6)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
columns= ["score", "grade", "group"]metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows | exact | 24 | 24 | 0.00E+2 | passed | |
/entries/0/column | exact | score | score | passed | ||
/entries/0/level | exact | scale | scale | passed | ||
/entries/0/valid | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/entries/0/user_missing_count | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/entries/0/system_missing_count | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/entries/0/summary/0/1 | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/entries/0/summary/1/1 | tolerance | 20.414999999999999 | 20.415 | 1.47E-16 | 17 | passed |
/entries/0/summary/2/1 | tolerance | 5.1096683381914128 | 5.109668338191413 | 4.91E-17 | 17 | passed |
/entries/0/summary/3/1 | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/entries/0/summary/4/1 | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
/entries/0/summary/5/1 | tolerance | 16.599999999999998 | 16.599999999999998 | 1.32E-16 | 17 | passed |
/entries/0/summary/6/1 | tolerance | 19.5 | 19.5 | 0.00E+1 | passed | |
/entries/0/summary/7/1 | tolerance | 23.249999999999996 | 23.25 | 4.00E-15 | 15 | passed |
/entries/1/level | exact | nominal | nominal | passed | ||
/entries/1/label | exact | Grade | Grade | passed | ||
/entries/1/valid | tolerance | 21 | 21.0 | 0.00E+2 | passed | |
/entries/1/user_missing_count | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/entries/1/system_missing_count | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/entries/1/values/[value=2]/count | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/entries/1/values/[value=2]/label | exact | Fair | Fair | passed | ||
/entries/1/values/[value=5]/count | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/entries/1/values/[value=9]/missing | exact | user-missing | user-missing | passed | ||
/entries/1/values/[value=9]/count | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/entries/2/level | exact | nominal | nominal | passed | ||
/entries/2/values/[value=A]/count | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/entries/2/values/[value=B]/valid_percent | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/entries/2/valid | tolerance | 24 | 24.0 | 0.00E+2 | passed |
Convention
- R: mean, sd, min, max and quantile(type = 6) on the 20 valid scores; table() counts for grade and group with the labelled code 5 at 0.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:11-14: counts and labels including labelled categories with no cases; scale variables carry numerical summaries.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
268 cb_outputs <- list(
269 "/rows" = exact(nrow(d), "all 24 rows"),
270 "/entries/0/column" = exact("score", "first entry"),
271 "/entries/0/level" = exact("scale", "numeric without a declared level is scale"),
272 "/entries/0/valid" = tol(n, "valid scores"),
273 "/entries/0/user_missing_count" = tol(sum(d$score == 999, na.rm = TRUE), "two 999 scores"),
274 "/entries/0/system_missing_count" = tol(sum(is.na(d$score)), "two NA scores"),
275 "/entries/0/summary/0/1" = tol(n, "Valid N"),
276 "/entries/0/summary/1/1" = tol(mean(x), "mean"),
277 "/entries/0/summary/2/1" = tol(sd(x), "sample SD"),
278 "/entries/0/summary/3/1" = tol(min(x), "minimum"),
279 "/entries/0/summary/4/1" = tol(max(x), "maximum"),
280 "/entries/0/summary/5/1" = tol(q6(x, 0.25), "25th percentile type 6"),
281 "/entries/0/summary/6/1" = tol(q6(x, 0.5), "50th percentile type 6"),
282 "/entries/0/summary/7/1" = tol(q6(x, 0.75), "75th percentile type 6"),
283 "/entries/1/level" = exact("nominal", "declared nominal"),
284 "/entries/1/label" = exact("Grade", "variable label"),
285 "/entries/1/valid" = tol(length(grade_valid), "valid grades"),
286 "/entries/1/user_missing_count" = tol(sum(d$grade == 9, na.rm = TRUE), "code 9 count"),
287 "/entries/1/system_missing_count" = tol(sum(is.na(d$grade)), "NA grade count"),
288 "/entries/1/values/[value=2]/count" = tol(as.numeric(counts[["2"]]), "grade 2 count"),
289 "/entries/1/values/[value=2]/label" = exact("Fair", "value label"),
290 "/entries/1/values/[value=5]/count" = tol(0, "labelled code 5 has no cases"),
291 "/entries/1/values/[value=9]/missing" = exact("user-missing", "code 9 listed as user-missing"),
292 "/entries/1/values/[value=9]/count" = tol(sum(d$grade == 9, na.rm = TRUE), "code 9 count"),
293 "/entries/2/level" = exact("nominal", "text is nominal"),
294 "/entries/2/values/[value=A]/count" = tol(sum(d$group == "A"), "group A count"),
295 "/entries/2/values/[value=B]/valid_percent" = tol(100 * sum(d$group == "B") / nrow(d), "group B valid percent"),
296 "/entries/2/valid" = tol(nrow(d), "every group value is valid")
297 )
298 emit("STAT-DESC-CODEBOOK-001", "Codebook: scale summary, labelled categories and missing counts",
299 "nominal", "tabelz.analysis.report_listings:compute_codebook", "codebookMenuItem",
300 "CODEBOOK",
301 list(columns = list("score", "grade", "group"), metadata = metadata),
302 cb_outputs,
303 c("R: mean, sd, min, max and quantile(type = 6) on the 20 valid scores; table() counts for grade and group with the labelled code 5 at 0.",
304 paste0(manual, ":11-14: counts and labels including labelled categories with no cases; scale variables carry numerical summaries.")),
305 "R base table and stats; quantile type 6",
306 "R stats::quantile documentation (type 6)")
Custom table: counts, column, row and table percents, chi-square
Case STAT-DESC-CUSTOMTABLES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base table, stats::chisq.test, prop.test, t.test and p.adjust
- Citation
- R stats documentation: chisq.test, prop.test (correct = FALSE), t.test (var.equal = FALSE), p.adjust (holm, bonferroni)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_custom_tables.R · sha256 54816fc0af9ccf42
- Dataset
- reference_data/datasets/DESC_CUSTOM_01.json
Settings compared
adjustment= "holm"alpha= 0.05columns= ["site"]compare= "none"independence= truerows= ["dept"]statistics= ["count", "column_percent", "row_percent", "table_percent"]totals= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/used_rows | exact | 40 | 40 | 0.00E+2 | passed | |
/missing_rows | exact | 2 | 2 | 0.00E+2 | passed | |
/row_keys/0/0 | exact | Ops | Ops | passed | ||
/column_keys/2/0 | exact | West | West | passed | ||
/column_letters/2 | exact | C | C | passed | ||
/independence/0/variable | exact | dept | dept | passed | ||
/independence/0/chi_square | tolerance | 25.370245139475909 | 25.37024513947591 | 2.42E-16 | 17 | passed |
/independence/0/df | exact | 4 | 4 | 0.00E+2 | passed | |
/independence/0/p_value | tail_probability | 4.2380878730493824e-05 | 4.238087873049383e-05 | 6.33E-21 | 15 | passed |
/independence/0/min_expected | tolerance | 3.8999999999999999 | 3.9 | 1.12E-17 | 17 | passed |
/independence/0/small_expected | exact | 8 | 8 | 0.00E+2 | passed | |
/independence/0/cells | exact | 9 | 9 | 0.00E+2 | passed | |
/cells/0/value | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/cells/1/value | tolerance | 76.92307692307692 | 76.92307692307692 | 2.03E-16 | 17 | passed |
/cells/2/value | tolerance | 71.428571428571431 | 71.42857142857143 | 3.98E-16 | 17 | passed |
/cells/3/value | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/cells/4/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/5/value | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/cells/6/value | tolerance | 7.1428571428571432 | 7.142857142857143 | 3.78E-17 | 17 | passed |
/cells/7/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/8/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cells/9/value | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/cells/10/value | tolerance | 21.428571428571427 | 21.428571428571427 | 4.88E-17 | 17 | passed |
/cells/11/value | tolerance | 7.5 | 7.5 | 0.00E+1 | passed | |
/cells/16/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/17/value | tolerance | 7.6923076923076925 | 7.6923076923076925 | 1.27E-17 | 17 | passed |
/cells/18/value | tolerance | 7.6923076923076925 | 7.6923076923076925 | 1.27E-17 | 17 | passed |
/cells/19/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/20/value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/cells/21/value | tolerance | 75 | 75.0 | 0.00E+2 | passed | |
/cells/22/value | tolerance | 69.230769230769226 | 69.23076923076923 | 3.97E-16 | 17 | passed |
/cells/23/value | tolerance | 22.5 | 22.5 | 0.00E+1 | passed | |
/cells/24/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cells/25/value | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/cells/26/value | tolerance | 23.076923076923077 | 23.076923076923077 | 3.50E-16 | 16 | passed |
/cells/27/value | tolerance | 7.5 | 7.5 | 0.00E+1 | passed | |
/cells/32/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/33/value | tolerance | 15.384615384615385 | 15.384615384615385 | 2.53E-17 | 17 | passed |
/cells/34/value | tolerance | 15.384615384615385 | 15.384615384615385 | 2.53E-17 | 17 | passed |
/cells/35/value | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cells/36/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/37/value | tolerance | 16.666666666666668 | 16.666666666666668 | 1.49E-16 | 17 | passed |
/cells/38/value | tolerance | 15.384615384615385 | 15.384615384615385 | 2.53E-17 | 17 | passed |
/cells/39/value | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cells/40/value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/cells/41/value | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/cells/42/value | tolerance | 69.230769230769226 | 69.23076923076923 | 3.97E-16 | 17 | passed |
/cells/43/value | tolerance | 22.5 | 22.5 | 0.00E+1 | passed | |
/cells/12/value | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/cells/13/value | tolerance | 35 | 35.0 | 0.00E+2 | passed | |
/cells/52/value | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/cells/53/value | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/cells/60/value | tolerance | 40 | 40.0 | 0.00E+2 | passed | |
/cells/64 | absent | None | passed |
Convention
- R: table(dept, site) over the 40 complete rows; column percent divides by the column total (the outer row group is the whole table with one row variable), row percent by the row total, table percent by 40; chisq.test(correct = FALSE).
- Cell order: for each row (Ops, Sales, Tech, Total) the columns East, North, West, Total, each with the four statistics in the requested order.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:50-55: column percentages are taken within the outer row group; chi-square with expected-count diagnostics.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
124 o1[[cell(0, 3, 0, 3, 4)]] <- tol(sum(tab[1, ]), "Ops total column count")
125 o1[[cell(0, 3, 1, 3, 4)]] <- tol(100 * sum(tab[1, ]) / N, "Ops total column percent is its share of all rows")
126 o1[[cell(3, 1, 0, 3, 4)]] <- tol(sum(tab[, 2]), "Total row, North count")
127 o1[[cell(3, 1, 1, 3, 4)]] <- tol(100, "Total row column percent is 100")
128 o1[[cell(3, 3, 0, 3, 4)]] <- tol(N, "grand total")
129 o1[["/cells/64"]] <- absent("4 blocks x 4 columns x 4 statistics = 64 cells")
130 emit("STAT-DESC-CUSTOMTABLES-001", "Custom table: counts, column, row and table percents, chi-square",
131 "nominal",
132 list(rows = list("dept"), columns = list("site"), statistics = as.list(stats1),
133 totals = TRUE, independence = TRUE, compare = "none", adjustment = "holm",
134 alpha = 0.05),
135 o1,
136 c("R: table(dept, site) over the 40 complete rows; column percent divides by the column total (the outer row group is the whole table with one row variable), row percent by the row total, table percent by 40; chisq.test(correct = FALSE).",
137 "Cell order: for each row (Ops, Sales, Tech, Total) the columns East, North, West, Total, each with the four statistics in the requested order.",
138 paste0(manual, ":50-55: column percentages are taken within the outer row group; chi-square with expected-count diagnostics.")))
Custom table: column proportion comparisons with Holm letters
Case STAT-DESC-CUSTOMTABLES-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base table, stats::chisq.test, prop.test, t.test and p.adjust
- Citation
- R stats documentation: chisq.test, prop.test (correct = FALSE), t.test (var.equal = FALSE), p.adjust (holm, bonferroni)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_custom_tables.R · sha256 54816fc0af9ccf42
- Dataset
- reference_data/datasets/DESC_CUSTOM_01.json
Settings compared
adjustment= "holm"alpha= 0.05columns= ["site"]compare= "proportions"independence= falserows= ["dept"]statistics= ["count", "column_percent"]totals= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/comparisons/9 | absent | None | passed | |||
/comparisons/0/subject | exact | dept: Ops | dept: Ops | passed | ||
/comparisons/0/first | exact | East | East | passed | ||
/comparisons/0/second | exact | North | North | passed | ||
/comparisons/0/statistic | tolerance | 3.4516847392436554 | 3.4516847392436554 | 2.46E-17 | 17 | passed |
/comparisons/0/p_value | tail_probability | 0.00055709823627738959 | 0.0005570982362773896 | 2.33E-21 | 17 | passed |
/comparisons/0/adjusted_p | tail_probability | 0.0050138841264965065 | 0.0050138841264965065 | 4.78E-20 | 17 | passed |
/comparisons/0/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/1/subject | exact | dept: Ops | dept: Ops | passed | ||
/comparisons/1/first | exact | East | East | passed | ||
/comparisons/1/second | exact | West | West | passed | ||
/comparisons/1/statistic | tolerance | 3.0120861079812262 | 3.0120861079812262 | 2.40E-17 | 17 | passed |
/comparisons/1/p_value | tail_probability | 0.0025945898764241498 | 0.0025945898764241464 | 3.43E-18 | 14 | passed |
/comparisons/1/adjusted_p | tail_probability | 0.018162129134969049 | 0.018162129134969025 | 2.44E-17 | 14 | passed |
/comparisons/1/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/2/subject | exact | dept: Ops | dept: Ops | passed | ||
/comparisons/2/first | exact | North | North | passed | ||
/comparisons/2/second | exact | West | West | passed | ||
/comparisons/2/statistic | tolerance | -0.84795149574161077 | -0.8479514957416108 | 2.33E-18 | 17 | passed |
/comparisons/2/p_value | tail_probability | 0.39646498401781738 | 0.39646498401781727 | 1.12E-16 | 15 | passed |
/comparisons/2/adjusted_p | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/comparisons/2/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/3/subject | exact | dept: Sales | dept: Sales | passed | ||
/comparisons/3/first | exact | East | East | passed | ||
/comparisons/3/second | exact | North | North | passed | ||
/comparisons/3/statistic | tolerance | -3.4320323649182209 | -3.432032364918221 | 4.58E-17 | 16 | passed |
/comparisons/3/p_value | tail_probability | 0.00059907606015491689 | 0.000599076060154916 | 8.67E-19 | 14 | passed |
/comparisons/3/adjusted_p | tail_probability | 0.0050138841264965065 | 0.0050138841264965065 | 4.78E-20 | 17 | passed |
/comparisons/3/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/4/subject | exact | dept: Sales | dept: Sales | passed | ||
/comparisons/4/first | exact | East | East | passed | ||
/comparisons/4/second | exact | West | West | passed | ||
/comparisons/4/statistic | tolerance | -0.92819096178451421 | -0.9281909617845142 | 2.42E-18 | 17 | passed |
/comparisons/4/p_value | tail_probability | 0.35330852193784368 | 0.3533085219378437 | 1.90E-18 | 17 | passed |
/comparisons/4/adjusted_p | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/comparisons/4/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/5/subject | exact | dept: Sales | dept: Sales | passed | ||
/comparisons/5/first | exact | North | North | passed | ||
/comparisons/5/second | exact | West | West | passed | ||
/comparisons/5/statistic | tolerance | 2.8578838324886475 | 2.8578838324886475 | 2.42E-17 | 17 | passed |
/comparisons/5/p_value | tail_probability | 0.0042647649140305343 | 0.004264764914030529 | 5.20E-18 | 14 | passed |
/comparisons/5/adjusted_p | tail_probability | 0.025588589484183206 | 0.025588589484183175 | 3.14E-17 | 14 | passed |
/comparisons/5/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/6/subject | exact | dept: Tech | dept: Tech | passed | ||
/comparisons/6/first | exact | East | East | passed | ||
/comparisons/6/second | exact | North | North | passed | ||
/comparisons/6/statistic | tolerance | -0.0873570697268264 | -0.0873570697268264 | 1.47E-19 | 17 | passed |
/comparisons/6/p_value | tail_probability | 0.9303876922688854 | 0.9303876922688855 | 1.13E-16 | 15 | passed |
/comparisons/6/adjusted_p | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/comparisons/6/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/7/subject | exact | dept: Tech | dept: Tech | passed | ||
/comparisons/7/first | exact | East | East | passed | ||
/comparisons/7/second | exact | West | West | passed | ||
/comparisons/7/statistic | tolerance | -2.4107943187305225 | -2.4107943187305225 | 2.30E-17 | 17 | passed |
/comparisons/7/p_value | tail_probability | 0.015917822372370011 | 0.01591782237237 | 9.97E-18 | 15 | passed |
/comparisons/7/adjusted_p | tail_probability | 0.079589111861850054 | 0.07958911186185 | 5.58E-17 | 15 | passed |
/comparisons/7/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/8/subject | exact | dept: Tech | dept: Tech | passed | ||
/comparisons/8/first | exact | North | North | passed | ||
/comparisons/8/second | exact | West | West | passed | ||
/comparisons/8/statistic | tolerance | -2.2771094116724551 | -2.277109411672455 | 3.62E-17 | 16 | passed |
/comparisons/8/p_value | tail_probability | 0.022779692809855905 | 0.02277969280985589 | 1.36E-17 | 15 | passed |
/comparisons/8/adjusted_p | tail_probability | 0.091118771239423621 | 0.09111877123942357 | 5.55E-17 | 15 | passed |
/comparisons/8/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/cells/0/flags | exact | BC | BC | passed | ||
/cells/2/flags | exact | passed | ||||
/cells/4/flags | exact | passed | ||||
/cells/8/flags | exact | passed | ||||
/cells/10/flags | exact | AC | AC | passed | ||
/cells/12/flags | exact | passed | ||||
/cells/16/flags | exact | passed | ||||
/cells/18/flags | exact | passed | ||||
/cells/20/flags | exact | passed |
Convention
- R: for each dept and each pair of sites, the pooled-null two-proportion z of the dept's share of the two site columns (prop.test(correct = FALSE) gives z^2 and the same p); p.adjust(holm) over the 9 comparisons; a count cell carries the letters of the columns that are significantly smaller.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:57-61: two-proportion tests, Holm by default over all comparisons in the layer, a letter names a column with a significantly smaller value.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
182 emit("STAT-DESC-CUSTOMTABLES-002", "Custom table: column proportion comparisons with Holm letters",
183 "axis_coverage",
184 list(rows = list("dept"), columns = list("site"), statistics = list("count", "column_percent"),
185 totals = TRUE, independence = FALSE, compare = "proportions", adjustment = "holm",
186 alpha = 0.05),
187 o2,
188 c("R: for each dept and each pair of sites, the pooled-null two-proportion z of the dept's share of the two site columns (prop.test(correct = FALSE) gives z^2 and the same p); p.adjust(holm) over the 9 comparisons; a count cell carries the letters of the columns that are significantly smaller.",
189 paste0(manual, ":57-61: two-proportion tests, Holm by default over all comparisons in the layer, a letter names a column with a significantly smaller value.")))
Custom table: scale summaries and Welch mean comparisons with Bonferroni
Case STAT-DESC-CUSTOMTABLES-003 · status: passed
Reference
- Evidence type
- R
- Source
- R base table, stats::chisq.test, prop.test, t.test and p.adjust
- Citation
- R stats documentation: chisq.test, prop.test (correct = FALSE), t.test (var.equal = FALSE), p.adjust (holm, bonferroni)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_custom_tables.R · sha256 54816fc0af9ccf42
- Dataset
- reference_data/datasets/DESC_CUSTOM_01.json
Settings compared
adjustment= "bonferroni"alpha= 0.05columns= ["site"]compare= "means"independence= falserows= ["dept"]statistics= ["mean", "sd", "median", "valid_n", "count"]summary= "sales"totals= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/comparisons/0/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/0/statistic | absent | None | passed | |||
/comparisons/0/adjusted_p | absent | None | passed | |||
/comparisons/1/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/1/statistic | tolerance | -42.465332301523155 | -42.465332301523155 | 3.25E-17 | 18 | passed |
/comparisons/1/p_value | tail_probability | 5.325826372087215e-13 | 5.325826372087189e-13 | 2.62E-27 | 14 | passed |
/comparisons/1/adjusted_p | tail_probability | 4.7932437348784934e-12 | 4.79324373487847e-12 | 2.34E-26 | 14 | passed |
/comparisons/2/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/2/statistic | absent | None | passed | |||
/comparisons/2/adjusted_p | absent | None | passed | |||
/comparisons/3/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/3/statistic | absent | None | passed | |||
/comparisons/3/adjusted_p | absent | None | passed | |||
/comparisons/4/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/4/statistic | absent | None | passed | |||
/comparisons/4/adjusted_p | absent | None | passed | |||
/comparisons/5/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/5/statistic | tolerance | -11.404537543005951 | -11.40453754300595 | 2.05E-16 | 16 | passed |
/comparisons/5/p_value | tail_probability | 0.001015216978433273 | 0.0010152169784332758 | 2.80E-18 | 14 | passed |
/comparisons/5/adjusted_p | tail_probability | 0.0091369528058994568 | 0.009136952805899483 | 2.60E-17 | 14 | passed |
/comparisons/6/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/6/statistic | tolerance | -5.9207226111810662 | -5.920722611181066 | 4.17E-17 | 17 | passed |
/comparisons/6/p_value | tail_probability | 0.087642531941430402 | 0.08764253194143042 | 1.35E-17 | 15 | passed |
/comparisons/6/adjusted_p | tail_probability | 0.78878278747287367 | 0.7887827874728738 | 1.11E-16 | 15 | passed |
/comparisons/7/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/7/statistic | tolerance | -32.456658227793142 | -32.45665822779314 | 3.09E-16 | 17 | passed |
/comparisons/7/p_value | tail_probability | 1.6867623945864102e-05 | 1.686762394586407e-05 | 3.10E-20 | 14 | passed |
/comparisons/7/adjusted_p | tail_probability | 0.00015180861551277692 | 0.00015180861551277665 | 2.74E-19 | 14 | passed |
/comparisons/8/family_size | exact | 9 | 9 | 0.00E+2 | passed | |
/comparisons/8/statistic | tolerance | -5.3210890454535509 | -5.321089045453551 | 1.91E-17 | 17 | passed |
/comparisons/8/p_value | tail_probability | 0.097267636169179786 | 0.09726763616917983 | 4.15E-17 | 15 | passed |
/comparisons/8/adjusted_p | tail_probability | 0.87540872552261806 | 0.8754087255226184 | 3.32E-16 | 15 | passed |
/cells/0/value | tolerance | 28.260000000000002 | 28.26 | 4.37E-16 | 16 | passed |
/cells/1/value | tolerance | 2.5717266141209061 | 2.5717266141209056 | 4.59E-16 | 15 | passed |
/cells/2/value | tolerance | 28.300000000000001 | 28.3 | 2.89E-16 | 16 | passed |
/cells/3/value | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/cells/4/value | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/cells/5/value | tolerance | 48.799999999999997 | 48.8 | 1.58E-16 | 17 | passed |
/cells/6/value | absent | None | passed | |||
/cells/7/value | tolerance | 48.799999999999997 | 48.8 | 1.58E-16 | 17 | passed |
/cells/8/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/9/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/10/value | tolerance | 68.799999999999997 | 68.8 | 1.58E-16 | 17 | passed |
/cells/11/value | tolerance | 0.8660254037844386 | 0.8660254037844386 | 3.41E-18 | 17 | passed |
/cells/12/value | tolerance | 69.299999999999997 | 69.3 | 1.58E-16 | 17 | passed |
/cells/13/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cells/14/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cells/20/value | tolerance | 22.399999999999999 | 22.4 | 4.21E-16 | 16 | passed |
/cells/21/value | absent | None | passed | |||
/cells/22/value | tolerance | 22.399999999999999 | 22.4 | 4.21E-16 | 16 | passed |
/cells/23/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/24/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/25/value | tolerance | 50.544444444444444 | 50.544444444444444 | 2.87E-16 | 17 | passed |
/cells/26/value | tolerance | 2.8609924462986229 | 2.860992446298623 | 2.65E-17 | 17 | passed |
/cells/27/value | tolerance | 50.700000000000003 | 50.7 | 1.58E-16 | 17 | passed |
/cells/28/value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/cells/29/value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/cells/30/value | tolerance | 73.666666666666671 | 73.66666666666667 | 4.04E-16 | 17 | passed |
/cells/31/value | tolerance | 3.098924544633729 | 3.098924544633729 | 1.69E-17 | 17 | passed |
/cells/32/value | tolerance | 75.200000000000003 | 75.2 | 1.58E-16 | 17 | passed |
/cells/33/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cells/34/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cells/40/value | tolerance | 31.049999999999997 | 31.049999999999997 | 1.58E-16 | 17 | passed |
/cells/41/value | tolerance | 1.2020815280171302 | 1.2020815280171302 | 3.58E-18 | 17 | passed |
/cells/42/value | tolerance | 31.049999999999997 | 31.049999999999997 | 1.58E-16 | 17 | passed |
/cells/43/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/44/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/45/value | tolerance | 51.799999999999997 | 51.8 | 1.58E-16 | 17 | passed |
/cells/46/value | tolerance | 4.8083261120685261 | 4.808326112068526 | 1.47E-17 | 17 | passed |
/cells/47/value | tolerance | 51.799999999999997 | 51.8 | 1.58E-16 | 17 | passed |
/cells/48/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/49/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/50/value | tolerance | 70.471428571428575 | 70.47142857142858 | 8.28E-17 | 17 | passed |
/cells/51/value | tolerance | 2.2954406154478537 | 2.295440615447854 | 4.60E-16 | 15 | passed |
/cells/52/value | tolerance | 71 | 71.0 | 0.00E+2 | passed | |
/cells/53/value | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/cells/54/value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/cells/75/value | tolerance | 49.871052631578948 | 49.87105263157895 | 3.32E-17 | 18 | passed |
/cells/78/value | tolerance | 38 | 38.0 | 0.00E+2 | passed |
Convention
- R: mean, sd, median and non-missing count of sales per dept x site cell; t.test(var.equal = FALSE) per dept and site pair; p.adjust(bonferroni) over the 9 planned comparisons with an uncomputable pair (one value) entering as p = 1.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:57-61: Welch tests for numerical means; Bonferroni as an option.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
235 all_sales <- dd$sales[!is.na(dd$sales)]
236 o3[[cell(3, 3, 0, 3, 5)]] <- tol(mean(all_sales), "grand mean of sales")
237 o3[[cell(3, 3, 3, 3, 5)]] <- tol(length(all_sales), "valid N over all complete rows")
238 emit("STAT-DESC-CUSTOMTABLES-003", "Custom table: scale summaries and Welch mean comparisons with Bonferroni",
239 "axis_coverage",
240 list(rows = list("dept"), columns = list("site"), summary = "sales",
241 statistics = as.list(stats3), totals = TRUE, independence = FALSE,
242 compare = "means", adjustment = "bonferroni", alpha = 0.05),
243 o3,
244 c("R: mean, sd, median and non-missing count of sales per dept x site cell; t.test(var.equal = FALSE) per dept and site pair; p.adjust(bonferroni) over the 9 planned comparisons with an uncomputable pair (one value) entering as p = 1.",
245 paste0(manual, ":57-61: Welch tests for numerical means; Bonferroni as an option.")))
Custom table: nested rows with subtotals and outer-group column percents
Case STAT-DESC-CUSTOMTABLES-004 · status: passed
Reference
- Evidence type
- R
- Source
- R base table, stats::chisq.test, prop.test, t.test and p.adjust
- Citation
- R stats documentation: chisq.test, prop.test (correct = FALSE), t.test (var.equal = FALSE), p.adjust (holm, bonferroni)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_custom_tables.R · sha256 54816fc0af9ccf42
- Dataset
- reference_data/datasets/DESC_CUSTOM_01.json
Settings compared
adjustment= "holm"alpha= 0.05columns= ["site"]compare= "none"independence= falserows= ["dept", "level"]statistics= ["count", "column_percent", "layer_percent"]totals= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/row_keys/0/0 | exact | Ops | Ops | passed | ||
/row_keys/0/1 | exact | Junior | Junior | passed | ||
/row_keys/6 | absent | None | passed | |||
/cells/120 | absent | None | passed | |||
/cells/0/value | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cells/1/value | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/2/value | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/3/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/4/value | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/cells/5/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/6/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/7/value | tolerance | 33.333333333333336 | 33.333333333333336 | 2.98E-16 | 17 | passed |
/cells/8/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/12/value | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cells/13/value | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/14/value | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/15/value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/cells/16/value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/cells/17/value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/cells/18/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/19/value | tolerance | 66.666666666666671 | 66.66666666666667 | 4.04E-16 | 17 | passed |
/cells/20/value | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cells/24/value | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/cells/25/value | tolerance | 76.92307692307692 | 76.92307692307692 | 2.03E-16 | 17 | passed |
/cells/27/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/28/value | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/cells/30/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cells/31/value | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/cells/33/value | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/cells/36/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/37/value | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/cells/38/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/39/value | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/cells/40/value | tolerance | 44.444444444444443 | 44.44444444444444 | 1.35E-16 | 17 | passed |
/cells/41/value | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/cells/42/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/43/value | tolerance | 66.666666666666671 | 66.66666666666667 | 4.04E-16 | 17 | passed |
/cells/44/value | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cells/48/value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/cells/49/value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/cells/50/value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/cells/51/value | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cells/52/value | tolerance | 55.555555555555557 | 55.55555555555556 | 1.35E-16 | 17 | passed |
/cells/53/value | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/54/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/55/value | tolerance | 33.333333333333336 | 33.333333333333336 | 2.98E-16 | 17 | passed |
/cells/56/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/60/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/61/value | tolerance | 7.6923076923076925 | 7.6923076923076925 | 1.27E-17 | 17 | passed |
/cells/63/value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/cells/64/value | tolerance | 75 | 75.0 | 0.00E+2 | passed | |
/cells/66/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cells/67/value | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/cells/69/value | tolerance | 13 | 13.0 | 0.00E+2 | passed | |
/cells/72/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/73/value | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/74/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/75/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/76/value | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/77/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/78/value | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cells/79/value | tolerance | 55.555555555555557 | 55.55555555555556 | 1.35E-16 | 17 | passed |
/cells/80/value | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/84/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/85/value | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/86/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/87/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cells/88/value | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/89/value | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/cells/90/value | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/cells/91/value | tolerance | 44.444444444444443 | 44.44444444444444 | 1.35E-16 | 17 | passed |
/cells/92/value | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/cells/96/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/97/value | tolerance | 15.384615384615385 | 15.384615384615385 | 2.53E-17 | 17 | passed |
/cells/99/value | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cells/100/value | tolerance | 16.666666666666668 | 16.666666666666668 | 1.49E-16 | 17 | passed |
/cells/102/value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/cells/103/value | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/cells/105/value | tolerance | 13 | 13.0 | 0.00E+2 | passed | |
/cells/117/value | tolerance | 40 | 40.0 | 0.00E+2 | passed | |
/cells/109/value | tolerance | 100 | 100.0 | 0.00E+2 | passed |
Convention
- R: table(dept, level, site); a leaf row's column percent divides by the dept group's count in that site column; a subtotal's column percent divides by the column total; with no layer the layer percent divides by all 40 rows.
- Cell order: Ops/Junior, Ops/Senior, Ops subtotal, Sales/Junior, Sales/Senior, Sales subtotal, Tech/Junior, Tech/Senior, Tech subtotal, Total; columns East, North, West, Total; statistics count, column %, layer %.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:50-55: up to three nested variables, subtotals, column percentages within the outer row group.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
276 o4[[cell(9, 3, 0, 3, 3)]] <- tol(N, "grand total")
277 o4[[cell(9, 0, 1, 3, 3)]] <- tol(100, "Total row column percent is 100")
278 emit("STAT-DESC-CUSTOMTABLES-004", "Custom table: nested rows with subtotals and outer-group column percents",
279 "axis_coverage",
280 list(rows = list("dept", "level"), columns = list("site"),
281 statistics = list("count", "column_percent", "layer_percent"), totals = TRUE,
282 independence = FALSE, compare = "none", adjustment = "holm", alpha = 0.05),
283 o4,
284 c("R: table(dept, level, site); a leaf row's column percent divides by the dept group's count in that site column; a subtotal's column percent divides by the column total; with no layer the layer percent divides by all 40 rows.",
285 "Cell order: Ops/Junior, Ops/Senior, Ops subtotal, Sales/Junior, Sales/Senior, Sales subtotal, Tech/Junior, Tech/Senior, Tech subtotal, Total; columns East, North, West, Total; statistics count, column %, layer %.",
286 paste0(manual, ":50-55: up to three nested variables, subtotals, column percentages within the outer row group.")))
Shapiro-Wilk normality
Case STAT-DESC-DIAG-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey/stats/nortest
- Citation
- R survey::svydesign/svymean, stats::shapiro.test and nortest::ad.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, nortest 1.0.4, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_diagnostics.R · sha256 5427a49203331a27
- Dataset
- reference_data/datasets/DESC_DIAGNOSTIC_01.json
Settings compared
column= "value"method= "shapiro_wilk"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.99334774111542046 | 0.9933477411154202 | 2.25E-16 | 15 | passed |
/p_value | tail_probability | 0.99999067852027823 | 0.9999906785202782 | 1.11E-18 | 17 | passed |
/observations | exact | 12 | 12 | 0.00E+2 | passed |
Convention
- Manual chapter 30 lines 15-17: Shapiro-Wilk applies to 3-5000 finite values.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
84 shapiro <- stats::shapiro.test(diagnostic$value)
85 emit("STAT-DESC-DIAG-001", "Shapiro-Wilk normality", "tabelz.executor.distribution_diagnostics",
86 "distributionDiagnosticsMenuItem", "DESC_DIAGNOSTIC_01",
87 list(column = "value", method = "shapiro_wilk"),
88 list("/statistic" = tol(shapiro$statistic, "Shapiro-Wilk W; owner 1e-9 tier."),
89 "/p_value" = tail(shapiro$p.value, "Calibrated Shapiro-Wilk upper-tail p-value; owner 1e-9 tier."),
90 "/observations" = exact(nrow(diagnostic), "Twelve finite complete cases.")),
91 c("Manual chapter 30 lines 15-17: Shapiro-Wilk applies to 3-5000 finite values."))
Anderson-Darling fitted-normal diagnostic
Case STAT-DESC-DIAG-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey/stats/nortest
- Citation
- R survey::svydesign/svymean, stats::shapiro.test and nortest::ad.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, nortest 1.0.4, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_diagnostics.R · sha256 5427a49203331a27
- Dataset
- reference_data/datasets/DESC_DIAGNOSTIC_01.json
Settings compared
column= "value"method= "anderson_darling"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.081106340212951267 | 0.08110634021294949 | 1.78E-15 | 13 | passed |
/p_value | tail_probability | 0.99816870312259887 | 0.9981687031225991 | 2.18E-16 | 15 | passed |
Convention
- Manual chapter 30 lines 18-20: fitted normal mean and variance, not a known-parameter test.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
93 anderson <- nortest::ad.test(diagnostic$value)
94 emit("STAT-DESC-DIAG-002", "Anderson-Darling fitted-normal diagnostic",
95 "tabelz.executor.distribution_diagnostics", "distributionDiagnosticsMenuItem",
96 "DESC_DIAGNOSTIC_01", list(column = "value", method = "anderson_darling"),
97 list("/statistic" = tol(anderson$statistic, "Fitted-mean-and-variance Anderson-Darling statistic; owner 1e-9 tier."),
98 "/p_value" = tail(anderson$p.value, "Fitted-normal Anderson-Darling p-value; owner 1e-9 tier.")),
99 c("Manual chapter 30 lines 18-20: fitted normal mean and variance, not a known-parameter test."))
All eight candidates on positive unimodal data
Case STAT-DESC-DISTFIT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_01.json
Settings compared
candidates= ["normal", "student_t", "laplace", "logistic", "lognormal", "gamma", "weibull", "exponential"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=normal]/parameters/0/1 | tolerance | 4.6543585600000004 | 4.65435856 | 3.34E-17 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=normal]/parameters/1/1 | tolerance | 0.95127213353294771 | 0.9512721335329477 | 4.30E-18 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=normal]/log_likelihood | tolerance | -34.224585774197365 | -34.224585774197365 | 1.40E-16 | 17 | passed |
/columns/0/candidates/[key=normal]/aic | tolerance | 72.44917154839473 | 72.44917154839473 | 2.80E-16 | 17 | passed |
/columns/0/candidates/[key=normal]/bic | tolerance | 74.886923198131129 | 74.88692319813113 | 2.57E-16 | 17 | passed |
/columns/0/candidates/[key=laplace]/parameters/0/1 | tolerance | 4.5983080000000003 | 4.598308 | 1.60E-17 | 17 | passed |
/columns/0/candidates/[key=laplace]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=laplace]/parameters/1/1 | tolerance | 0.81963896000000003 | 0.8196389599999999 | 1.14E-16 | 15 | passed |
/columns/0/candidates/[key=laplace]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=laplace]/log_likelihood | tolerance | -37.356396304897402 | -37.3563963048974 | 2.94E-16 | 17 | passed |
/columns/0/candidates/[key=laplace]/aic | tolerance | 78.712792609794803 | 78.7127926097948 | 4.11E-16 | 17 | passed |
/columns/0/candidates/[key=laplace]/bic | tolerance | 81.150544259531202 | 81.1505442595312 | 1.26E-16 | 17 | passed |
/columns/0/candidates/[key=logistic]/parameters/0/1 | tolerance | 4.6584936946720159 | 4.658493694850639 | 1.79E-10 | 10 | passed |
/columns/0/candidates/[key=logistic]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=logistic]/parameters/1/1 | tolerance | 0.57643830368367355 | 0.5764383036984855 | 1.48E-11 | 10 | passed |
/columns/0/candidates/[key=logistic]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=logistic]/log_likelihood | tolerance | -35.311585296391961 | -35.31158529639196 | 2.47E-16 | 17 | passed |
/columns/0/candidates/[key=logistic]/aic | tolerance | 74.623170592783922 | 74.62317059278392 | 4.94E-16 | 17 | passed |
/columns/0/candidates/[key=logistic]/bic | tolerance | 77.06092224252032 | 77.06092224252032 | 3.09E-17 | 18 | passed |
/columns/0/candidates/[key=lognormal]/parameters/0/1 | tolerance | 0.21159124881224173 | 0.21159124881224173 | 2.13E-18 | 16 | passed |
/columns/0/candidates/[key=lognormal]/parameters/0/0 | exact | s | s | passed | ||
/columns/0/candidates/[key=lognormal]/parameters/1/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=lognormal]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=lognormal]/parameters/2/1 | tolerance | 4.5538413688664221 | 4.553841368866421 | 8.87E-16 | 15 | passed |
/columns/0/candidates/[key=lognormal]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=lognormal]/log_likelihood | tolerance | -34.545268245090099 | -34.54526824509009 | 6.69E-15 | 15 | passed |
/columns/0/candidates/[key=lognormal]/aic | tolerance | 73.090536490180199 | 73.09053649018018 | 1.44E-14 | 15 | passed |
/columns/0/candidates/[key=lognormal]/bic | tolerance | 75.528288139916597 | 75.52828813991658 | 1.39E-14 | 15 | passed |
/columns/0/candidates/[key=gamma]/parameters/0/1 | tolerance | 23.066582950777786 | 23.066582950777487 | 2.99E-13 | 13 | passed |
/columns/0/candidates/[key=gamma]/parameters/0/0 | exact | a | a | passed | ||
/columns/0/candidates/[key=gamma]/parameters/1/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=gamma]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=gamma]/parameters/2/1 | tolerance | 0.20177928260687869 | 0.2017792826068813 | 2.61E-15 | 13 | passed |
/columns/0/candidates/[key=gamma]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=gamma]/log_likelihood | tolerance | -34.323543742469269 | -34.323543742469255 | 1.41E-14 | 15 | passed |
/columns/0/candidates/[key=gamma]/aic | tolerance | 72.647087484938538 | 72.64708748493851 | 2.82E-14 | 15 | passed |
/columns/0/candidates/[key=gamma]/bic | tolerance | 75.084839134674937 | 75.08483913467491 | 2.88E-14 | 15 | passed |
/columns/0/candidates/[key=weibull]/parameters/0/1 | tolerance | 5.6077661847020019 | 5.607766184701999 | 2.62E-15 | 15 | passed |
/columns/0/candidates/[key=weibull]/parameters/0/0 | exact | c | c | passed | ||
/columns/0/candidates/[key=weibull]/parameters/1/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=weibull]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=weibull]/parameters/2/1 | tolerance | 5.0434255608479326 | 5.0434255608479335 | 8.75E-16 | 15 | passed |
/columns/0/candidates/[key=weibull]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=weibull]/log_likelihood | tolerance | -34.111307853414985 | -34.111307853414985 | 5.26E-17 | 17 | passed |
/columns/0/candidates/[key=weibull]/aic | tolerance | 72.22261570682997 | 72.22261570682997 | 1.05E-16 | 17 | passed |
/columns/0/candidates/[key=weibull]/bic | tolerance | 74.660367356566368 | 74.66036735656637 | 3.58E-16 | 17 | passed |
/columns/0/candidates/[key=exponential]/parameters/0/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=exponential]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=exponential]/parameters/1/1 | tolerance | 4.6543585600000004 | 4.65435856 | 3.34E-17 | 17 | passed |
/columns/0/candidates/[key=exponential]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=exponential]/log_likelihood | tolerance | -63.445102632898326 | -63.44510263289833 | 7.18E-15 | 15 | passed |
/columns/0/candidates/[key=exponential]/aic | tolerance | 128.89020526579665 | 128.89020526579668 | 3.06E-14 | 15 | passed |
/columns/0/candidates/[key=exponential]/bic | tolerance | 130.10908109066486 | 130.10908109066486 | 1.51E-15 | 16 | passed |
/candidate_keys | sequence | ['normal', 'student_t', 'laplace', 'logistic', 'lognormal', | ['normal', 'student_t', 'laplace', 'logistic', 'lognormal', | passed | ||
/columns/0/count | exact | 25 | 25 | 0.00E+2 | passed |
Convention
- Smallest BIC gap between the seven finite candidates: 0.197916.
- Gamma and Weibull solve their one-dimensional profile score with uniroot(tol = 1e-15); logistic solves its two score equations with nested uniroot(tol = 1e-15).
- Student t: the df score of the profile likelihood is still positive at df = 1e4, so the likelihood rises toward the normal and no finite maximum exists; its outputs are deferred.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
195 set.seed(20260924)
196 export_dataset(data.frame(y = round(rgamma(25, shape = 6, rate = 1.5) + 1, 6)),
197 "DESC_DISTFIT_01", "Constructed: rgamma(25, shape 6, rate 1.5) + 1, seed 20260924, rounded to 6 decimals",
198 "R stats::rgamma documentation", "Constructed validation data; no third-party license.",
199 c(y = "Float64"))
200 x <- read_dataset("DESC_DISTFIT_01")$y
201 n <- length(x)
202 if (!is.null(fit_t(x))) stop("expected no finite Student t maximum on DESC_DISTFIT_01")
203 fits <- list(fit_normal(x), fit_laplace(x), fit_logistic(x), fit_lognormal(x, 0),
204 fit_gamma(x, 0), fit_weibull(x, 0), fit_exponential(x, 0))
205 out <- list(); for (f in fits) out <- c(out, candidate_outputs(f, n))
206 gap <- min_gap(fits, n)
207 out[["/candidate_keys"]] <- keys_in_order(unlist(all8), "Selected candidates in the stable user-facing order.")
208 out[["/columns/0/count"]] <- exact(n, "All 25 values are finite.")
209 emit("STAT-DESC-DISTFIT-001", "All eight candidates on positive unimodal data", "DESC_DISTFIT_01",
210 list(columns = list("y"), candidates = all8, origin = 0), out,
211 c(sprintf("Smallest BIC gap between the seven finite candidates: %.6g.", gap),
212 "Gamma and Weibull solve their one-dimensional profile score with uniroot(tol = 1e-15); logistic solves its two score equations with nested uniroot(tol = 1e-15).",
213 "Student t: the df score of the profile likelihood is still positive at df = 1e4, so the likelihood rises toward the normal and no finite maximum exists; its outputs are deferred."),
214 deferred = list(list(path = "/columns/0/candidates/[key=student_t]",
215 reason = "No finite Student t maximum-likelihood estimate on these data (df diverges); no reference value exists.")))
Candidate ranking by BIC then AIC
Case STAT-DESC-DISTFIT-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_01.json
Settings compared
candidates= ["normal", "laplace", "logistic", "lognormal", "gamma", "weibull", "exponential"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/0/key | exact | weibull | weibull | passed | ||
/columns/0/candidates/1/key | exact | normal | normal | passed | ||
/columns/0/candidates/2/key | exact | gamma | gamma | passed | ||
/columns/0/candidates/3/key | exact | lognormal | lognormal | passed | ||
/columns/0/candidates/4/key | exact | logistic | logistic | passed | ||
/columns/0/candidates/5/key | exact | laplace | laplace | passed | ||
/columns/0/candidates/6/key | exact | exponential | exponential | passed | ||
/columns/0/best_label | exact | Weibull (origin fixed at 0) | Weibull (origin fixed at 0) | passed | ||
/columns/0/bic | tolerance | 74.660367356566368 | 74.66036735656637 | 3.58E-16 | 17 | passed |
Convention
- R ranking by BIC then AIC: weibull, normal, gamma, lognormal, logistic, laplace, exponential; smallest BIC gap 0.197916.
- Student t is left out: it has no finite maximum on these data (see STAT-DESC-DISTFIT-001).
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
224 emit("STAT-DESC-DISTFIT-002", "Candidate ranking by BIC then AIC", "DESC_DISTFIT_01",
225 list(columns = list("y"), candidates = list("normal", "laplace", "logistic", "lognormal",
226 "gamma", "weibull", "exponential"), origin = 0),
227 c(rank_out, list(
228 "/columns/0/best_label" = exact(
229 c(normal = "Normal", student_t = "Student t", laplace = "Laplace", logistic = "Logistic",
230 lognormal = "Lognormal (origin fixed at 0)", gamma = "Gamma (origin fixed at 0)",
231 weibull = "Weibull (origin fixed at 0)",
232 exponential = "Exponential (origin fixed at 0)")[[ranking[1]]],
233 "The leading label names the exact fixed origin of a positive family (issue #3)."),
234 "/columns/0/bic" = (if (ranking[1] %in% c("normal", "laplace", "lognormal", "exponential")) closed else iterative)(
235 log(n) * fits[[match(ranking[1], vapply(fits, `[[`, "", "key"))]]$k -
236 2 * fits[[match(ranking[1], vapply(fits, `[[`, "", "key"))]]$ll,
237 "BIC of the leading candidate."))),
238 c(sprintf("R ranking by BIC then AIC: %s; smallest BIC gap %.6g.", paste(ranking, collapse = ", "), gap),
239 "Student t is left out: it has no finite maximum on these data (see STAT-DESC-DISTFIT-001)."),
240 kind = "threshold")
Positive families at a declared origin of 2.5
Case STAT-DESC-DISTFIT-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_01.json
Settings compared
candidates= ["lognormal", "gamma", "weibull", "exponential"]columns= ["y"]origin= 2.5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=lognormal]/parameters/0/1 | tolerance | 0.53784075864028102 | 0.537840758640281 | 4.76E-18 | 17 | passed |
/columns/0/candidates/[key=lognormal]/parameters/0/0 | exact | s | s | passed | ||
/columns/0/candidates/[key=lognormal]/parameters/1/1 | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/columns/0/candidates/[key=lognormal]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=lognormal]/parameters/2/1 | tolerance | 1.901930700947468 | 1.901930700947468 | 3.29E-17 | 16 | passed |
/columns/0/candidates/[key=lognormal]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=lognormal]/log_likelihood | tolerance | -36.040382788505106 | -36.040382788505106 | 2.07E-16 | 17 | passed |
/columns/0/candidates/[key=lognormal]/aic | tolerance | 76.080765577010212 | 76.08076557701021 | 4.13E-16 | 17 | passed |
/columns/0/candidates/[key=lognormal]/bic | tolerance | 78.51851722674661 | 78.51851722674661 | 4.93E-17 | 18 | passed |
/columns/0/candidates/[key=gamma]/parameters/0/1 | tolerance | 4.1714850879553778 | 4.171485087955377 | 9.31E-16 | 15 | passed |
/columns/0/candidates/[key=gamma]/parameters/0/0 | exact | a | a | passed | ||
/columns/0/candidates/[key=gamma]/parameters/1/1 | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/columns/0/candidates/[key=gamma]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=gamma]/parameters/2/1 | tolerance | 0.51644882208027809 | 0.5164488220802782 | 1.13E-16 | 15 | passed |
/columns/0/candidates/[key=gamma]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=gamma]/log_likelihood | tolerance | -34.686907703712279 | -34.68690770371228 | 2.72E-16 | 17 | passed |
/columns/0/candidates/[key=gamma]/aic | tolerance | 73.373815407424559 | 73.37381540742456 | 4.57E-16 | 17 | passed |
/columns/0/candidates/[key=gamma]/bic | tolerance | 75.811567057160957 | 75.81156705716096 | 6.09E-18 | 19 | passed |
/columns/0/candidates/[key=weibull]/parameters/0/1 | tolerance | 2.4702321488708967 | 2.4702321488708963 | 4.40E-16 | 15 | passed |
/columns/0/candidates/[key=weibull]/parameters/0/0 | exact | c | c | passed | ||
/columns/0/candidates/[key=weibull]/parameters/1/1 | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/columns/0/candidates/[key=weibull]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=weibull]/parameters/2/1 | tolerance | 2.4330375317763591 | 2.4330375317763586 | 4.80E-16 | 15 | passed |
/columns/0/candidates/[key=weibull]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=weibull]/log_likelihood | tolerance | -33.672596016577792 | -33.672596016577785 | 7.11E-15 | 15 | passed |
/columns/0/candidates/[key=weibull]/aic | tolerance | 71.345192033155584 | 71.34519203315557 | 1.42E-14 | 15 | passed |
/columns/0/candidates/[key=weibull]/bic | tolerance | 73.782943682891982 | 73.78294368289197 | 1.37E-14 | 15 | passed |
/columns/0/candidates/[key=exponential]/parameters/0/1 | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/columns/0/candidates/[key=exponential]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=exponential]/parameters/1/1 | tolerance | 2.1543585599999999 | 2.15435856 | 2.25E-17 | 16 | passed |
/columns/0/candidates/[key=exponential]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=exponential]/log_likelihood | tolerance | -44.187325681910316 | -44.187325681910316 | 1.77E-16 | 17 | passed |
/columns/0/candidates/[key=exponential]/aic | tolerance | 90.374651363820632 | 90.37465136382063 | 3.55E-16 | 17 | passed |
/columns/0/candidates/[key=exponential]/bic | tolerance | 91.593527188688839 | 91.59352718868884 | 3.08E-16 | 17 | passed |
/columns/0/candidates/[key=lognormal]/label | exact | Lognormal (origin fixed at 2.5) | Lognormal (origin fixed at 2.5) | passed |
Convention
- The origin 2.5 lies below every value, so no family is skipped; the fits use y - 2.5.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
263 origin <- 2.5
264 positive <- list(fit_lognormal(x, origin), fit_gamma(x, origin), fit_weibull(x, origin),
265 fit_exponential(x, origin))
266 if (min(x) <= origin) stop("dataset must lie above the origin")
267 out <- list(); for (f in positive) out <- c(out, candidate_outputs(f, n))
268 out[["/columns/0/candidates/[key=lognormal]/label"]] <- exact("Lognormal (origin fixed at 2.5)", "The label names the exact declared origin (issue #3).")
269 emit("STAT-DESC-DISTFIT-003", "Positive families at a declared origin of 2.5", "DESC_DISTFIT_01",
270 list(columns = list("y"), candidates = list("lognormal", "gamma", "weibull", "exponential"), origin = origin),
271 out, c("The origin 2.5 lies below every value, so no family is skipped; the fits use y - 2.5."))
Anderson-Darling statistic of the normal fit
Case STAT-DESC-DISTFIT-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_01.json
Settings compared
calibration= "fixed"candidates= ["normal"]columns= ["y"]mc_samples= 99origin= 0seed= 17
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=normal]/parameters/0/1 | tolerance | 4.6543585600000004 | 4.65435856 | 3.34E-17 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=normal]/parameters/1/1 | tolerance | 0.95127213353294771 | 0.9512721335329477 | 4.30E-18 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=normal]/log_likelihood | tolerance | -34.224585774197365 | -34.224585774197365 | 1.40E-16 | 17 | passed |
/columns/0/candidates/[key=normal]/aic | tolerance | 72.44917154839473 | 72.44917154839473 | 2.80E-16 | 17 | passed |
/columns/0/candidates/[key=normal]/bic | tolerance | 74.886923198131129 | 74.88692319813113 | 2.57E-16 | 17 | passed |
/columns/0/goodness/value | tolerance | 0.31144612908592961 | 0.3114461290859296 | 2.76E-18 | 17 | passed |
/columns/0/goodness/statistic | exact | Anderson-Darling | Anderson-Darling | passed |
Convention
- The Monte Carlo p-value (99 seeded refits) belongs to the V27 simulation studies.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
274 nf <- fit_normal(x)
275 emit("STAT-DESC-DISTFIT-004", "Anderson-Darling statistic of the normal fit", "DESC_DISTFIT_01",
276 list(columns = list("y"), candidates = list("normal"), origin = 0,
277 calibration = "fixed", mc_samples = 99L, seed = 17L),
278 c(candidate_outputs(nf, n),
279 list("/columns/0/goodness/value" = closed(
280 anderson_darling(x, function(v) pnorm(v, nf$par[["loc"]], nf$par[["scale"]])),
281 "A^2 = -n - (1/n) sum (2i-1)[log F(x_i) + log(1 - F(x_(n+1-i)))] at the MLE."),
282 "/columns/0/goodness/statistic" = exact("Anderson-Darling", "Named statistic."))),
283 c("The Monte Carlo p-value (99 seeded refits) belongs to the V27 simulation studies."),
284 deferred = list(list(path = "/columns/0/goodness/p_value",
285 reason = "Monte Carlo p-value; covered by V27 simulation studies, not a closed-form reference.")),
286 version = "1.1.0")
Smallest accepted sample of eight
Case STAT-DESC-DISTFIT-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_MIN8.json
Settings compared
candidates= ["normal", "exponential"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=normal]/parameters/0/1 | tolerance | 5.1749999999999998 | 5.175 | 2.24E-17 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=normal]/parameters/1/1 | tolerance | 0.67777208558629809 | 0.677772085586298 | 1.11E-16 | 15 | passed |
/columns/0/candidates/[key=normal]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=normal]/log_likelihood | tolerance | -8.2399546295772392 | -8.239954629577237 | 1.75E-15 | 15 | passed |
/columns/0/candidates/[key=normal]/aic | tolerance | 20.479909259154478 | 20.479909259154475 | 3.09E-15 | 15 | passed |
/columns/0/candidates/[key=normal]/bic | tolerance | 20.638792342514151 | 20.638792342514147 | 3.71E-15 | 15 | passed |
/columns/0/candidates/[key=exponential]/parameters/0/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=exponential]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=exponential]/parameters/1/1 | tolerance | 5.1749999999999998 | 5.175 | 2.24E-17 | 17 | passed |
/columns/0/candidates/[key=exponential]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=exponential]/log_likelihood | tolerance | -21.150714713211464 | -21.150714713211464 | 9.79E-17 | 17 | passed |
/columns/0/candidates/[key=exponential]/aic | tolerance | 44.301429426422928 | 44.30142942642293 | 1.96E-16 | 17 | passed |
/columns/0/candidates/[key=exponential]/bic | tolerance | 44.380870968102762 | 44.38087096810276 | 2.20E-16 | 17 | passed |
/columns/0/count | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- distribution_fit.MIN_OBSERVATIONS is 8; Laplace is omitted because its location is not unique for even n.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
327 export_dataset(data.frame(y = c(4.1, 5.3, 4.8, 6.2, 5.9, 5.1, 4.4, 5.6)),
328 "DESC_DISTFIT_MIN8", "Constructed: eight values, the manual's minimum",
329 "Hand-constructed", "Constructed validation data; no third-party license.", c(y = "Float64"))
330 x8 <- read_dataset("DESC_DISTFIT_MIN8")$y
331 out <- c(candidate_outputs(fit_normal(x8), 8), candidate_outputs(fit_exponential(x8, 0), 8))
332 out[["/columns/0/count"]] <- exact(8L, "Eight finite values, the minimum.")
333 emit("STAT-DESC-DISTFIT-005", "Smallest accepted sample of eight", "DESC_DISTFIT_MIN8",
334 list(columns = list("y"), candidates = list("normal", "exponential"), origin = 0), out,
335 c("distribution_fit.MIN_OBSERVATIONS is 8; Laplace is omitted because its location is not unique for even n."),
336 kind = "boundary")
Positive families skipped for a value at the origin
Case STAT-DESC-DISTFIT-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_ZERO.json
Settings compared
candidates= ["normal", "lognormal", "gamma"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=normal]/parameters/0/1 | tolerance | 1.9272727272727272 | 1.9272727272727272 | 4.85E-17 | 16 | passed |
/columns/0/candidates/[key=normal]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=normal]/parameters/1/1 | tolerance | 0.81919129644136801 | 0.819191296441368 | 9.39E-19 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=normal]/log_likelihood | tolerance | -13.414509723891303 | -13.414509723891301 | 1.64E-15 | 15 | passed |
/columns/0/candidates/[key=normal]/aic | tolerance | 30.829019447782606 | 30.829019447782603 | 3.27E-15 | 15 | passed |
/columns/0/candidates/[key=normal]/bic | tolerance | 31.624809993379348 | 31.624809993379344 | 3.94E-15 | 15 | passed |
/columns/0/candidates/1 | absent | None | passed |
Convention
- One value equals the origin 0, so both strictly positive families are skipped (issue #3 ruling, item 5).
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
339 export_dataset(data.frame(y = c(0, 1.2, 2.3, 1.9, 3.1, 2.6, 1.4, 2.2, 2.8, 1.7, 2.0)),
340 "DESC_DISTFIT_ZERO", "Constructed: eleven values including one at the origin 0",
341 "Hand-constructed", "Constructed validation data; no third-party license.", c(y = "Float64"))
342 xz <- read_dataset("DESC_DISTFIT_ZERO")$y
343 emit("STAT-DESC-DISTFIT-006", "Positive families skipped for a value at the origin", "DESC_DISTFIT_ZERO",
344 list(columns = list("y"), candidates = list("normal", "lognormal", "gamma"), origin = 0),
345 c(candidate_outputs(fit_normal(xz), length(xz)),
346 list("/columns/0/candidates/1" = list(comparison = "absent",
347 rationale = "Lognormal and gamma need every value strictly above the origin, so both are skipped, leaving the normal fit only."))),
348 c("One value equals the origin 0, so both strictly positive families are skipped (issue #3 ruling, item 5)."),
349 kind = "boundary")
Missing values and excluded rows
Case STAT-DESC-DISTFIT-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_MISSING.json
Settings compared
candidates= ["normal", "laplace"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=normal]/parameters/0/1 | tolerance | 50.169409090909092 | 50.16940909090909 | 2.69E-16 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=normal]/parameters/1/1 | tolerance | 3.6244169932316623 | 3.6244169932316623 | 3.17E-17 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=normal]/log_likelihood | tolerance | -29.772951770358866 | -29.772951770358862 | 4.02E-15 | 15 | passed |
/columns/0/candidates/[key=normal]/aic | tolerance | 63.545903540717731 | 63.545903540717724 | 7.04E-15 | 15 | passed |
/columns/0/candidates/[key=normal]/bic | tolerance | 64.341694086314476 | 64.34169408631446 | 1.43E-14 | 15 | passed |
/columns/0/candidates/[key=laplace]/parameters/0/1 | tolerance | 50.438699999999997 | 50.4387 | 2.03E-16 | 17 | passed |
/columns/0/candidates/[key=laplace]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=laplace]/parameters/1/1 | tolerance | 2.6880545454545453 | 2.6880545454545453 | 4.78E-17 | 16 | passed |
/columns/0/candidates/[key=laplace]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=laplace]/log_likelihood | tolerance | -29.501613847450319 | -29.501613847450322 | 3.23E-15 | 15 | passed |
/columns/0/candidates/[key=laplace]/aic | tolerance | 63.003227694900637 | 63.003227694900644 | 7.45E-15 | 15 | passed |
/columns/0/candidates/[key=laplace]/bic | tolerance | 63.799018240497375 | 63.79901824049739 | 1.43E-14 | 15 | passed |
/columns/0/count | exact | 11 | 11 | 0.00E+2 | passed |
Convention
- Rows 0, 7 and 12 (0-based) excluded and two missing values dropped: 11 values remain (odd, so the Laplace location is unique).
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
357 export_dataset(data.frame(id = seq_len(16L), y = raw), "DESC_DISTFIT_MISSING",
358 "Constructed: rnorm(16, 50, 4), seed 20260925, rounded to 4 decimals, rows 3 and 11 missing",
359 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
360 c(id = "Int64", y = "Float64"))
361 xm <- read_dataset("DESC_DISTFIT_MISSING")$y
362 if (length(xm) != 16L) stop("DESC_DISTFIT_MISSING lost rows on reading")
363 excluded <- c(0L, 7L, 12L)
364 kept <- xm[-(excluded + 1L)]; kept <- kept[!is.na(kept)]
365 out <- c(candidate_outputs(fit_normal(kept), length(kept)), candidate_outputs(fit_laplace(kept), length(kept)))
366 out[["/columns/0/count"]] <- exact(length(kept), "Excluded rows and missing values are both dropped.")
367 emit("STAT-DESC-DISTFIT-007", "Missing values and excluded rows", "DESC_DISTFIT_MISSING",
368 list(columns = list("y"), candidates = list("normal", "laplace"), origin = 0), out,
369 c(sprintf("Rows 0, 7 and 12 (0-based) excluded and two missing values dropped: %d values remain (odd, so the Laplace location is unique).", length(kept))),
370 kind = "missing_excluded", excluded = as.list(excluded))
Large offset with a small spread
Case STAT-DESC-DISTFIT-008 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_OFFSET.json
Settings compared
candidates= ["normal", "laplace"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=normal]/parameters/0/1 | tolerance | 1000000.0003495974 | 1000000.0003495978 | 3.73E-10 | 15 | passed |
/columns/0/candidates/[key=normal]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=normal]/parameters/1/1 | tolerance | 0.00096528908289216268 | 0.0009652890840489342 | 1.16E-12 | 8 | passed |
/columns/0/candidates/[key=normal]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=normal]/log_likelihood | tolerance | 116.00703241088178 | 116.00703238571604 | 2.52E-8 | 9 | passed |
/columns/0/candidates/[key=normal]/aic | tolerance | -228.01406482176355 | -228.0140647714321 | 5.03E-8 | 9 | passed |
/columns/0/candidates/[key=normal]/bic | tolerance | -225.9250199463167 | -225.92501989598523 | 5.03E-8 | 9 | passed |
/columns/0/candidates/[key=laplace]/parameters/0/1 | tolerance | 1000000.000677591 | 1000000.0006775911 | 7.33E-11 | 16 | passed |
/columns/0/candidates/[key=laplace]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=laplace]/parameters/1/1 | tolerance | 0.00076396946817459098 | 0.0007639694626310042 | 5.54E-12 | 8 | passed |
/columns/0/candidates/[key=laplace]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=laplace]/log_likelihood | tolerance | 115.16054659533098 | 115.16054674771316 | 1.52E-7 | 8 | passed |
/columns/0/candidates/[key=laplace]/aic | tolerance | -226.32109319066197 | -226.3210934954263 | 3.05E-7 | 8 | passed |
/columns/0/candidates/[key=laplace]/bic | tolerance | -224.23204831521511 | -224.23204861997945 | 3.05E-7 | 8 | passed |
Convention
- Values near 1e6 with a spread of 1e-3; the MLE scale is computed from centered values in R.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
373 set.seed(20260926)
374 export_dataset(data.frame(y = 1e6 + round(rnorm(21, 0, 1e-3), 9)), "DESC_DISTFIT_OFFSET",
375 "Constructed: 1e6 + rnorm(21, 0, 0.001), seed 20260926, rounded to 1e-9",
376 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(y = "Float64"))
377 xo <- read_dataset("DESC_DISTFIT_OFFSET")$y
378 emit("STAT-DESC-DISTFIT-008", "Large offset with a small spread", "DESC_DISTFIT_OFFSET",
379 list(columns = list("y"), candidates = list("normal", "laplace"), origin = 0),
380 c(candidate_outputs(fit_normal(xo), length(xo)), candidate_outputs(fit_laplace(xo), length(xo))),
381 c("Values near 1e6 with a spread of 1e-3; the MLE scale is computed from centered values in R."),
382 kind = "hard_numeric")
Seven values are below the minimum
Case STAT-DESC-DISTFIT-009 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_SEVEN.json
Settings compared
candidates= ["normal"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- distribution_fit.MIN_OBSERVATIONS is 8.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
385 export_dataset(data.frame(y = c(1.5, 2.5, 3.5, 2.0, 4.0, 3.0, 2.2)), "DESC_DISTFIT_SEVEN",
386 "Constructed: seven values, one below the minimum", "Hand-constructed",
387 "Constructed validation data; no third-party license.", c(y = "Float64"))
388 emit("STAT-DESC-DISTFIT-009", "Seven values are below the minimum", "DESC_DISTFIT_SEVEN",
389 list(columns = list("y"), candidates = list("normal"), origin = 0), list(),
390 c("distribution_fit.MIN_OBSERVATIONS is 8."), kind = "invalid_input",
391 error = list(error_class = "ValueError", message_contains = "needs at least 8 finite observations"))
A constant column has no distribution
Case STAT-DESC-DISTFIT-010 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_CONSTANT.json
Settings compared
candidates= ["normal"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A zero-variance column is refused before fitting.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
392 export_dataset(data.frame(y = rep(3.25, 10)), "DESC_DISTFIT_CONSTANT",
393 "Constructed: ten equal values", "Hand-constructed",
394 "Constructed validation data; no third-party license.", c(y = "Float64"))
395 emit("STAT-DESC-DISTFIT-010", "A constant column has no distribution", "DESC_DISTFIT_CONSTANT",
396 list(columns = list("y"), candidates = list("normal"), origin = 0), list(),
397 c("A zero-variance column is refused before fitting."), kind = "invalid_input",
398 error = list(error_class = "ValueError", message_contains = "is constant"))
An unknown candidate is refused
Case STAT-DESC-DISTFIT-011 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_01.json
Settings compared
candidates= ["normal", "cauchy"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Only the eight manual candidates are accepted (manual lines 772-774).
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
399 emit("STAT-DESC-DISTFIT-011", "An unknown candidate is refused", "DESC_DISTFIT_01",
400 list(columns = list("y"), candidates = list("normal", "cauchy"), origin = 0), list(),
401 c("Only the eight manual candidates are accepted (manual lines 772-774)."), kind = "invalid_input",
402 error = list(error_class = "ValueError", message_contains = "Unknown distributions: cauchy"))
Unrestricted Student t is refused
Case STAT-DESC-DISTFIT-012 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_HEAVY.json
Settings compared
candidates= ["student_t"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A local profile maximum exists at df = 7.144350834, but the likelihood is unbounded as the scale tends to zero with df < 1/(N - 1).
- Until 2026-09-25 this case expected that local maximum; the issue #7 ruling makes the candidate unavailable.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
255 emit("STAT-DESC-DISTFIT-012", "Unrestricted Student t is refused", "DESC_DISTFIT_HEAVY",
256 list(columns = list("y"), candidates = list("student_t"), origin = 0), list(),
257 c(sprintf("A local profile maximum exists at df = %.10g, but the likelihood is unbounded as the scale tends to zero with df < 1/(N - 1).", th$par[["df"]]),
258 "Until 2026-09-25 this case expected that local maximum; the issue #7 ruling makes the candidate unavailable."),
259 kind = "invalid_input",
260 error = list(error_class = "ValueError", message_contains = "No finite unrestricted maximum-likelihood fit"))
Exponential with a value at its origin
Case STAT-DESC-DISTFIT-013 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_ZERO.json
Settings compared
candidates= ["exponential"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=exponential]/parameters/0/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=exponential]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=exponential]/parameters/1/1 | tolerance | 1.9272727272727272 | 1.9272727272727272 | 4.85E-17 | 16 | passed |
/columns/0/candidates/[key=exponential]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=exponential]/log_likelihood | tolerance | -18.217164997675557 | -18.21716499767556 | 3.30E-15 | 15 | passed |
/columns/0/candidates/[key=exponential]/aic | tolerance | 38.434329995351113 | 38.43432999535112 | 7.60E-15 | 15 | passed |
/columns/0/candidates/[key=exponential]/bic | tolerance | 38.832225268149486 | 38.83222526814949 | 7.05E-15 | 15 | passed |
/columns/0/goodness/value | absent | None | passed |
Convention
- Until 2026-09-24 the product refused this valid fit; the statistician's ruling on issue #3 allows x = origin for the exponential only.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
406 emit("STAT-DESC-DISTFIT-013", "Exponential with a value at its origin", "DESC_DISTFIT_ZERO",
407 list(columns = list("y"), candidates = list("exponential"), origin = 0),
408 c(candidate_outputs(fit_exponential(xz, 0), length(xz)),
409 list("/columns/0/goodness/value" = list(comparison = "absent",
410 rationale = "At a value on the origin F(x) = 0, so the Anderson-Darling statistic is undefined and is reported unavailable, not approximated (issue #3)."))),
411 c("Until 2026-09-24 the product refused this valid fit; the statistician's ruling on issue #3 allows x = origin for the exponential only."),
412 kind = "boundary")
Fixed-origin positive families on 1 to 8
Case STAT-DESC-DISTFIT-014 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_ONE_TO_EIGHT.json
Settings compared
candidates= ["lognormal", "gamma", "weibull", "exponential"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=lognormal]/parameters/0/1 | tolerance | 0.65796556832390418 | 0.6579655683239042 | 1.90E-18 | 17 | passed |
/columns/0/candidates/[key=lognormal]/parameters/0/0 | exact | s | s | passed | ||
/columns/0/candidates/[key=lognormal]/parameters/1/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=lognormal]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=lognormal]/parameters/2/1 | tolerance | 3.7643505995031279 | 3.764350599503128 | 7.88E-18 | 17 | passed |
/columns/0/candidates/[key=lognormal]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=lognormal]/log_likelihood | tolerance | -18.607289753973134 | -18.607289753973134 | 3.39E-16 | 16 | passed |
/columns/0/candidates/[key=lognormal]/aic | tolerance | 41.214579507946269 | 41.21457950794627 | 3.23E-16 | 17 | passed |
/columns/0/candidates/[key=lognormal]/bic | tolerance | 41.373462591305938 | 41.37346259130594 | 4.92E-16 | 16 | passed |
/columns/0/candidates/[key=gamma]/parameters/0/1 | tolerance | 2.9572380128934164 | 2.957238012893418 | 1.74E-15 | 15 | passed |
/columns/0/candidates/[key=gamma]/parameters/0/0 | exact | a | a | passed | ||
/columns/0/candidates/[key=gamma]/parameters/1/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=gamma]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=gamma]/parameters/2/1 | tolerance | 1.5216901650730226 | 1.5216901650730217 | 9.17E-16 | 15 | passed |
/columns/0/candidates/[key=gamma]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=gamma]/log_likelihood | tolerance | -18.066674545012052 | -18.066674545012056 | 3.83E-15 | 15 | passed |
/columns/0/candidates/[key=gamma]/aic | tolerance | 40.133349090024105 | 40.13334909002411 | 6.66E-15 | 15 | passed |
/columns/0/candidates/[key=gamma]/bic | tolerance | 40.292232173383773 | 40.29223217338378 | 7.49E-15 | 15 | passed |
/columns/0/candidates/[key=weibull]/parameters/0/1 | tolerance | 2.0617677291819563 | 2.0617677291819554 | 9.11E-16 | 15 | passed |
/columns/0/candidates/[key=weibull]/parameters/0/0 | exact | c | c | passed | ||
/columns/0/candidates/[key=weibull]/parameters/1/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=weibull]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=weibull]/parameters/2/1 | tolerance | 5.0782703288067239 | 5.078270328806722 | 1.77E-15 | 15 | passed |
/columns/0/candidates/[key=weibull]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=weibull]/log_likelihood | tolerance | -17.754362454758262 | -17.754362454758265 | 3.24E-15 | 15 | passed |
/columns/0/candidates/[key=weibull]/aic | tolerance | 39.508724909516523 | 39.50872490951653 | 7.49E-15 | 15 | passed |
/columns/0/candidates/[key=weibull]/bic | tolerance | 39.667607992876192 | 39.6676079928762 | 7.32E-15 | 15 | passed |
/columns/0/candidates/[key=exponential]/parameters/0/1 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/columns/0/candidates/[key=exponential]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=exponential]/parameters/1/1 | tolerance | 4.5 | 4.5 | 0.00E+1 | passed | |
/columns/0/candidates/[key=exponential]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=exponential]/log_likelihood | tolerance | -20.032619174210193 | -20.032619174210193 | 3.36E-16 | 16 | passed |
/columns/0/candidates/[key=exponential]/aic | tolerance | 42.065238348420387 | 42.06523834842039 | 3.29E-16 | 17 | passed |
/columns/0/candidates/[key=exponential]/bic | tolerance | 42.144679890100221 | 42.14467989010022 | 8.69E-17 | 17 | passed |
Convention
- Reproduces the statistician's issue #3 table (lognormal, gamma, Weibull, exponential at origin 0).
- Weibull shape from its score equation, which SciPy's fit missed by 7.3e-6 relative.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
423 emit("STAT-DESC-DISTFIT-014", "Fixed-origin positive families on 1 to 8", "DESC_DISTFIT_ONE_TO_EIGHT",
424 list(columns = list("y"), candidates = list("lognormal", "gamma", "weibull", "exponential"), origin = 0),
425 out,
426 c("Reproduces the statistician's issue #3 table (lognormal, gamma, Weibull, exponential at origin 0).",
427 "Weibull shape from its score equation, which SciPy's fit missed by 7.3e-6 relative."))
Hybrid normality test with separate sample-SD estimators
Case STAT-DESC-DISTFIT-015 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_01.json
Settings compared
calibration= "hybrid"candidates= ["normal"]columns= ["y"]origin= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=normal]/parameters/0/1 | tolerance | 4.6543585600000004 | 4.65435856 | 3.34E-17 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/0/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=normal]/parameters/1/1 | tolerance | 0.95127213353294771 | 0.9512721335329477 | 4.30E-18 | 17 | passed |
/columns/0/candidates/[key=normal]/parameters/1/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=normal]/log_likelihood | tolerance | -34.224585774197365 | -34.224585774197365 | 1.40E-16 | 17 | passed |
/columns/0/candidates/[key=normal]/aic | tolerance | 72.44917154839473 | 72.44917154839473 | 2.80E-16 | 17 | passed |
/columns/0/candidates/[key=normal]/bic | tolerance | 74.886923198131129 | 74.88692319813113 | 2.57E-16 | 17 | passed |
/columns/0/goodness/value | tolerance | 0.28020989484554448 | 0.28020989484554804 | 3.56E-15 | 13 | passed |
/columns/0/goodness/modified_statistic | tolerance | 0.28962494731235477 | 0.2896249473123585 | 3.72E-15 | 13 | passed |
/columns/0/goodness/p_value | tolerance | 0.61363263500563814 | 0.6136326350056261 | 1.20E-14 | 13 | passed |
/columns/0/goodness/calibration | exact | published_table | published_table | passed | ||
/columns/0/goodness/monte_carlo_interval | absent | None | passed |
Convention
- Owner-approved #201 amendment: test mean/sample SD differ from the retained ML distribution fit.
- D'Agostino and Stephens (1986), chapter 4, Case 3 p. 122; Tables 4.7 p. 123 and 4.9 p. 127.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
314 emit("STAT-DESC-DISTFIT-015", "Hybrid normality test with separate sample-SD estimators", "DESC_DISTFIT_01",
315 list(columns = list("y"), candidates = list("normal"), origin = 0, calibration = "hybrid"),
316 c(candidate_outputs(nf, n), normality_outputs(x)),
317 c("Owner-approved #201 amendment: test mean/sample SD differ from the retained ML distribution fit.",
318 "D'Agostino and Stephens (1986), chapter 4, Case 3 p. 122; Tables 4.7 p. 123 and 4.9 p. 127."))
Hybrid fixed-origin lognormal normality test
Case STAT-DESC-DISTFIT-016 · status: passed
Reference
- Evidence type
- R
- Source
- R stats (optimize, uniroot, nlminb)
- Citation
- R stats::nlminb, stats::uniroot and stats::dt/dlogis/dgamma/dweibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_distribution_fit.R · sha256 5d3685be492c803d
- Dataset
- reference_data/datasets/DESC_DISTFIT_01.json
Settings compared
calibration= "hybrid"candidates= ["lognormal"]columns= ["y"]origin= 2.5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/candidates/[key=lognormal]/parameters/0/1 | tolerance | 0.53784075864028102 | 0.537840758640281 | 4.76E-18 | 17 | passed |
/columns/0/candidates/[key=lognormal]/parameters/0/0 | exact | s | s | passed | ||
/columns/0/candidates/[key=lognormal]/parameters/1/1 | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/columns/0/candidates/[key=lognormal]/parameters/1/0 | exact | loc | loc | passed | ||
/columns/0/candidates/[key=lognormal]/parameters/2/1 | tolerance | 1.901930700947468 | 1.901930700947468 | 3.29E-17 | 16 | passed |
/columns/0/candidates/[key=lognormal]/parameters/2/0 | exact | scale | scale | passed | ||
/columns/0/candidates/[key=lognormal]/log_likelihood | tolerance | -36.040382788505106 | -36.040382788505106 | 2.07E-16 | 17 | passed |
/columns/0/candidates/[key=lognormal]/aic | tolerance | 76.080765577010212 | 76.08076557701021 | 4.13E-16 | 17 | passed |
/columns/0/candidates/[key=lognormal]/bic | tolerance | 78.51851722674661 | 78.51851722674661 | 4.93E-17 | 18 | passed |
/columns/0/goodness/value | tolerance | 0.61980545803414344 | 0.6198054580341434 | 1.64E-18 | 17 | passed |
/columns/0/goodness/modified_statistic | tolerance | 0.64063092142409073 | 0.6406309214240907 | 3.18E-18 | 17 | passed |
/columns/0/goodness/p_value | tolerance | 0.094795973710728107 | 0.09479597371072811 | 3.54E-20 | 18 | passed |
/columns/0/goodness/calibration | exact | published_table | published_table | passed | ||
/columns/0/goodness/monte_carlo_interval | absent | None | passed |
Convention
- Owner-approved #201 amendment: normality of log(x - origin), with origin fixed at 2.5 and sample SD for the test only.
- D'Agostino and Stephens (1986), chapter 4, Case 3 p. 122; Tables 4.7 p. 123 and 4.9 p. 127.
- Manual chapter 07, Distribution fit, and GitHub issue #3: origin fixed for positive families and not counted in k; BIC then AIC ranking.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
319 lnf <- fit_lognormal(x, 2.5)
320 emit("STAT-DESC-DISTFIT-016", "Hybrid fixed-origin lognormal normality test", "DESC_DISTFIT_01",
321 list(columns = list("y"), candidates = list("lognormal"), origin = 2.5, calibration = "hybrid"),
322 c(candidate_outputs(lnf, n), normality_outputs(log(x - 2.5))),
323 c("Owner-approved #201 amendment: normality of log(x - origin), with origin fixed at 2.5 and sample SD for the test only.",
324 "D'Agostino and Stephens (1986), chapter 4, Case 3 p. 122; Tables 4.7 p. 123 and 4.9 p. 127."))
Explore one dependent: descriptives, M-estimators, extremes, normality, box
Case STAT-DESC-EXPLORE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS, nortest and e1071
- Citation
- R stats::t.test, shapiro.test, quantile (type 6), fivenum; nortest::lillie.test (Dallal-Wilkinson/Stephens); MASS::huber; e1071 type-2 moments
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
confidence_level= 0.95dependents= ["score"]metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}quartiles= "haverage"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/0/n | exact | 20 | 20 | 0.00E+2 | passed | |
/cells/0/descriptives/0/1 | tolerance | 20.414999999999999 | 20.415 | 1.47E-16 | 17 | passed |
/cells/0/descriptives/0/2 | tolerance | 1.1425565746674382 | 1.1425565746674382 | 7.27E-18 | 17 | passed |
/cells/0/descriptives/1/1 | tolerance | 20.144444444444446 | 20.144444444444446 | 2.92E-16 | 16 | passed |
/cells/0/descriptives/2/1 | tolerance | 19.5 | 19.5 | 0.00E+1 | passed | |
/cells/0/descriptives/3/1 | tolerance | 26.108710526315793 | 26.108710526315793 | 3.24E-17 | 17 | passed |
/cells/0/descriptives/4/1 | tolerance | 5.1096683381914128 | 5.109668338191413 | 4.91E-17 | 17 | passed |
/cells/0/descriptives/5/1 | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/0/descriptives/6/1 | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
/cells/0/descriptives/7/1 | tolerance | 20.700000000000003 | 20.700000000000003 | 1.58E-16 | 17 | passed |
/cells/0/descriptives/9/1 | tolerance | 0.83023957898392808 | 0.8302395789839283 | 2.26E-16 | 15 | passed |
/cells/0/descriptives/9/2 | tolerance | 0.51210333670775743 | 0.5121033367077574 | 1.69E-18 | 17 | passed |
/cells/0/descriptives/10/1 | tolerance | 0.72187289698248236 | 0.7218728969824824 | 6.37E-19 | 18 | passed |
/cells/0/descriptives/10/2 | tolerance | 0.99238361254184504 | 0.992383612541845 | 6.55E-19 | 18 | passed |
/cells/0/mean_lower | tolerance | 18.023601605698687 | 18.023601605698687 | 3.29E-17 | 17 | passed |
/cells/0/mean_upper | tolerance | 22.806398394301311 | 22.80639839430131 | 3.28E-16 | 16 | passed |
/cells/0/normality/[test=Shapiro-Wilk]/statistic | tolerance | 0.95974416887460512 | 0.9597441688746048 | 3.34E-16 | 15 | passed |
/cells/0/normality/[test=Shapiro-Wilk]/p_value | tail_probability | 0.53875082657940176 | 0.5387508265793961 | 5.66E-15 | 13 | passed |
/cells/0/normality/[test=Kolmogorov-Smirnov (Lilliefors)]/statistic | tolerance | 0.12457835946272716 | 0.12457835946272716 | 1.77E-18 | 16 | passed |
/cells/0/normality/[test=Kolmogorov-Smirnov (Lilliefors)]/p_value | tail_probability | 0.57350020347354214 | 0.5735002034735417 | 4.48E-16 | 15 | passed |
/cells/0/m_estimates/0/value | tolerance | 20.014861439997851 | 20.014861438471417 | 1.53E-9 | 10 | passed |
/cells/0/m_estimates/1/value | tolerance | 19.992157202907084 | 19.99215719909851 | 3.81E-9 | 9 | passed |
/cells/0/m_estimates/2/value | tolerance | 20.140593777777735 | 20.140593776793278 | 9.84E-10 | 10 | passed |
/cells/0/m_estimates/3/value | tolerance | 19.994558878697617 | 19.994558874836414 | 3.86E-9 | 9 | passed |
/cells/0/extremes/0/value | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
/cells/0/extremes/0/case | exact | 23 | 23 | 0.00E+2 | passed | |
/cells/0/extremes/5/value | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/0/extremes/5/case | exact | 1 | 1 | 0.00E+2 | passed | |
/cells/0/extremes/1/value | tolerance | 28.699999999999999 | 28.7 | 2.89E-16 | 16 | passed |
/cells/0/extremes/1/case | exact | 22 | 22 | 0.00E+2 | passed | |
/cells/0/extremes/6/value | tolerance | 14.1 | 14.1 | 3.55E-16 | 16 | passed |
/cells/0/extremes/6/case | exact | 2 | 2 | 0.00E+2 | passed | |
/cells/0/extremes/2/value | tolerance | 26.300000000000001 | 26.3 | 2.89E-16 | 16 | passed |
/cells/0/extremes/2/case | exact | 20 | 20 | 0.00E+2 | passed | |
/cells/0/extremes/7/value | tolerance | 15.300000000000001 | 15.3 | 2.89E-16 | 16 | passed |
/cells/0/extremes/7/case | exact | 24 | 24 | 0.00E+2 | passed | |
/cells/0/extremes/3/value | tolerance | 24.899999999999999 | 24.9 | 4.21E-16 | 16 | passed |
/cells/0/extremes/3/case | exact | 19 | 19 | 0.00E+2 | passed | |
/cells/0/extremes/8/value | tolerance | 15.9 | 15.9 | 3.55E-16 | 16 | passed |
/cells/0/extremes/8/case | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/0/extremes/4/value | tolerance | 23.399999999999999 | 23.4 | 4.21E-16 | 16 | passed |
/cells/0/extremes/4/case | exact | 18 | 18 | 0.00E+2 | passed | |
/cells/0/extremes/9/value | tolerance | 16.399999999999999 | 16.4 | 4.21E-16 | 16 | passed |
/cells/0/extremes/9/case | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/0/descriptives/8/1 | tolerance | 6.6499999999999986 | 6.650000000000002 | 3.53E-15 | 15 | passed |
/cells/0/box/q1 | tolerance | 16.599999999999998 | 16.599999999999998 | 1.32E-16 | 17 | passed |
/cells/0/box/q3 | tolerance | 23.249999999999996 | 23.25 | 4.00E-15 | 15 | passed |
/cells/0/box/median | tolerance | 19.5 | 19.5 | 0.00E+1 | passed | |
/cells/0/box/whisker_low | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/0/box/whisker_high | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
/cells/0/box/outliers/0 | absent | None | passed | |||
/cells/0/box/extremes/0 | absent | None | passed | |||
/cells/0/missing | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/0/group | exact | passed |
Convention
- R: t.test interval; SPSS trimmed mean formula (equals mean(trim = 0.05) here); e1071 type-2 G1/G2 with closed-form SEs; quantile(type = 6) quartiles and 1.5/3 IQR fences; shapiro.test; nortest::lillie.test; MASS::huber(k = 1.339) and the documented fixed-MAD weighted-mean iteration for the Tukey, Hampel and Andrews weights (tolerance 1e-6 for the iterative estimators).
- docs/manual/chapters/82-descriptive-reports-and-association.tex:35-46: trimmed mean with fractional boundary weight, whiskers within 1.5 IQR, extremes beyond 3 IQR, fixed 1.4826 MAD scale, fitted-normal K-S approximation.
- Extreme case numbers are 1-based row positions in the dataset before exclusions.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
458 positions_all <- which(valid_score)
459 ex1 <- explore_cell(0L, x, positions_all, 0.95, desc_index_h, "haverage")
460 ex1[["/cells/0/missing"]] <- exact(as.integer(total - n), "user- and system-missing scores")
461 ex1[["/cells/0/group"]] <- exact("", "no factor")
462 emit("STAT-DESC-EXPLORE-001", "Explore one dependent: descriptives, M-estimators, extremes, normality, box",
463 "nominal", "tabelz.analysis.report_explore:compute_explore", "exploreMenuItem", "EXPLORE",
464 list(dependents = list("score"), confidence_level = 0.95, quartiles = "haverage",
465 metadata = metadata),
466 ex1,
467 c("R: t.test interval; SPSS trimmed mean formula (equals mean(trim = 0.05) here); e1071 type-2 G1/G2 with closed-form SEs; quantile(type = 6) quartiles and 1.5/3 IQR fences; shapiro.test; nortest::lillie.test; MASS::huber(k = 1.339) and the documented fixed-MAD weighted-mean iteration for the Tukey, Hampel and Andrews weights (tolerance 1e-6 for the iterative estimators).",
468 paste0(manual, ":35-46: trimmed mean with fractional boundary weight, whiskers within 1.5 IQR, extremes beyond 3 IQR, fixed 1.4826 MAD scale, fitted-normal K-S approximation."),
469 "Extreme case numbers are 1-based row positions in the dataset before exclusions."),
470 "R stats, MASS, nortest and e1071", explore_cite)
Explore by factor with Tukey's hinges, a 90% interval and exclusions
Case STAT-DESC-EXPLORE-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS, nortest and e1071
- Citation
- R stats::t.test, shapiro.test, quantile (type 6), fivenum; nortest::lillie.test (Dallal-Wilkinson/Stephens); MASS::huber; e1071 type-2 moments
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
confidence_level= 0.9dependents= ["score"]factor= "group"metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}quartiles= "tukey_hinges"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/0/n | exact | 8 | 8 | 0.00E+2 | passed | |
/cells/0/descriptives/0/1 | tolerance | 17.449999999999999 | 17.45 | 2.89E-16 | 16 | passed |
/cells/0/descriptives/0/2 | tolerance | 0.82743148184176374 | 0.8274314818417638 | 1.10E-16 | 15 | passed |
/cells/0/descriptives/1/1 | tolerance | 17.605555555555554 | 17.605555555555554 | 2.92E-16 | 16 | passed |
/cells/0/descriptives/2/1 | tolerance | 18.050000000000001 | 18.05 | 2.89E-16 | 16 | passed |
/cells/0/descriptives/3/1 | tolerance | 5.4771428571428569 | 5.477142857142859 | 1.75E-15 | 15 | passed |
/cells/0/descriptives/4/1 | tolerance | 2.3403296471101793 | 2.3403296471101798 | 4.67E-16 | 15 | passed |
/cells/0/descriptives/5/1 | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/0/descriptives/6/1 | tolerance | 19.600000000000001 | 19.6 | 4.21E-16 | 16 | passed |
/cells/0/descriptives/7/1 | tolerance | 7.1000000000000014 | 7.100000000000001 | 2.11E-17 | 17 | passed |
/cells/0/descriptives/13/1 | tolerance | -1.5449316965811812 | -1.5449316965811806 | 6.31E-16 | 15 | passed |
/cells/0/descriptives/13/2 | tolerance | 0.75210143309035493 | 0.7521014330903549 | 1.64E-18 | 17 | passed |
/cells/0/descriptives/14/1 | tolerance | 2.4937370353226962 | 2.49373703532269 | 6.22E-15 | 14 | passed |
/cells/0/descriptives/14/2 | tolerance | 1.4808804789742462 | 1.4808804789742462 | 3.93E-17 | 16 | passed |
/cells/0/mean_lower | tolerance | 15.882366017324673 | 15.882366017324674 | 1.35E-15 | 16 | passed |
/cells/0/mean_upper | tolerance | 19.017633982675328 | 19.017633982675324 | 3.77E-15 | 15 | passed |
/cells/0/normality/[test=Shapiro-Wilk]/statistic | tolerance | 0.8560388912334701 | 0.8560388912334704 | 3.34E-16 | 15 | passed |
/cells/0/normality/[test=Shapiro-Wilk]/p_value | tail_probability | 0.10960730767080444 | 0.10960730767080529 | 8.47E-16 | 14 | passed |
/cells/0/normality/[test=Kolmogorov-Smirnov (Lilliefors)]/statistic | tolerance | 0.20746487549691794 | 0.20746487549691794 | 4.28E-18 | 16 | passed |
/cells/0/normality/[test=Kolmogorov-Smirnov (Lilliefors)]/p_value | tail_probability | 0.3943620604187954 | 0.3943620604187954 | 1.52E-18 | 17 | passed |
/cells/0/m_estimates/0/value | tolerance | 17.845182637143232 | 17.84518263744874 | 3.06E-10 | 10 | passed |
/cells/0/m_estimates/1/value | tolerance | 17.978976814273409 | 17.978976817577042 | 3.30E-9 | 9 | passed |
/cells/0/m_estimates/2/value | tolerance | 17.761076857142861 | 17.76107685730271 | 1.60E-10 | 11 | passed |
/cells/0/m_estimates/3/value | tolerance | 17.978445443170884 | 17.978445447895606 | 4.72E-9 | 9 | passed |
/cells/0/extremes/0/value | tolerance | 19.600000000000001 | 19.6 | 4.21E-16 | 16 | passed |
/cells/0/extremes/0/case | exact | 12 | 12 | 0.00E+2 | passed | |
/cells/0/extremes/5/value | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/0/extremes/5/case | exact | 1 | 1 | 0.00E+2 | passed | |
/cells/0/extremes/1/value | tolerance | 19.399999999999999 | 19.4 | 4.21E-16 | 16 | passed |
/cells/0/extremes/1/case | exact | 11 | 11 | 0.00E+2 | passed | |
/cells/0/extremes/6/value | tolerance | 15.9 | 15.9 | 3.55E-16 | 16 | passed |
/cells/0/extremes/6/case | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/0/extremes/2/value | tolerance | 18.899999999999999 | 18.9 | 4.21E-16 | 16 | passed |
/cells/0/extremes/2/case | exact | 10 | 10 | 0.00E+2 | passed | |
/cells/0/extremes/7/value | tolerance | 17.199999999999999 | 17.2 | 2.89E-16 | 16 | passed |
/cells/0/extremes/7/case | exact | 7 | 7 | 0.00E+2 | passed | |
/cells/0/extremes/3/value | tolerance | 18.300000000000001 | 18.3 | 2.89E-16 | 16 | passed |
/cells/0/extremes/3/case | exact | 9 | 9 | 0.00E+2 | passed | |
/cells/0/extremes/8/value | tolerance | 17.800000000000001 | 17.8 | 2.89E-16 | 16 | passed |
/cells/0/extremes/8/case | exact | 8 | 8 | 0.00E+2 | passed | |
/cells/0/extremes/4/value | tolerance | 17.800000000000001 | 17.8 | 2.89E-16 | 16 | passed |
/cells/0/extremes/4/case | exact | 8 | 8 | 0.00E+2 | passed | |
/cells/0/extremes/9/value | tolerance | 18.300000000000001 | 18.3 | 2.89E-16 | 16 | passed |
/cells/0/extremes/9/case | exact | 9 | 9 | 0.00E+2 | passed | |
/cells/0/descriptives/8/1 | tolerance | 16.225000000000001 | 16.225 | 4.21E-16 | 16 | passed |
/cells/0/descriptives/9/1 | tolerance | 19.274999999999999 | 19.275 | 4.21E-16 | 16 | passed |
/cells/0/descriptives/10/1 | tolerance | 16.550000000000001 | 16.55 | 2.89E-16 | 16 | passed |
/cells/0/descriptives/11/1 | tolerance | 19.149999999999999 | 19.15 | 4.21E-16 | 16 | passed |
/cells/0/descriptives/12/1 | tolerance | 2.5999999999999979 | 2.599999999999998 | 3.16E-17 | 16 | passed |
/cells/0/box/q1 | tolerance | 16.550000000000001 | 16.55 | 2.89E-16 | 16 | passed |
/cells/0/box/q3 | tolerance | 19.149999999999999 | 19.15 | 4.21E-16 | 16 | passed |
/cells/0/box/median | tolerance | 18.050000000000001 | 18.05 | 2.89E-16 | 16 | passed |
/cells/0/box/whisker_low | tolerance | 15.9 | 15.9 | 3.55E-16 | 16 | passed |
/cells/0/box/whisker_high | tolerance | 19.600000000000001 | 19.6 | 4.21E-16 | 16 | passed |
/cells/0/box/outliers/1 | absent | None | passed | |||
/cells/0/box/extremes/0 | absent | None | passed | |||
/cells/0/box/outliers/0/0 | exact | 1 | 1 | 0.00E+2 | passed | |
/cells/0/box/outliers/0/1 | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/0/group | exact | A | A | passed | ||
/cells/0/missing | exact | 2 | 2 | 0.00E+2 | passed | |
/cells/1/n | exact | 10 | 10 | 0.00E+2 | passed | |
/cells/1/descriptives/0/1 | tolerance | 23.82 | 23.82 | 2.84E-16 | 16 | passed |
/cells/1/descriptives/0/2 | tolerance | 1.5472412725737235 | 1.5472412725737235 | 4.16E-17 | 16 | passed |
/cells/1/descriptives/1/1 | tolerance | 23.772222222222222 | 23.772222222222222 | 1.43E-16 | 17 | passed |
/cells/1/descriptives/2/1 | tolerance | 23.100000000000001 | 23.1 | 4.21E-16 | 16 | passed |
/cells/1/descriptives/3/1 | tolerance | 23.939555555555557 | 23.939555555555554 | 3.08E-15 | 15 | passed |
/cells/1/descriptives/4/1 | tolerance | 4.89280651115038 | 4.89280651115038 | 1.11E-17 | 17 | passed |
/cells/1/descriptives/5/1 | tolerance | 15.300000000000001 | 15.3 | 2.89E-16 | 16 | passed |
/cells/1/descriptives/6/1 | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
/cells/1/descriptives/7/1 | tolerance | 17.900000000000002 | 17.900000000000002 | 1.32E-16 | 17 | passed |
/cells/1/descriptives/13/1 | tolerance | 0.31827985873495301 | 0.318279858734953 | 3.94E-18 | 16 | passed |
/cells/1/descriptives/13/2 | tolerance | 0.68704291862151667 | 0.6870429186215167 | 3.92E-18 | 17 | passed |
/cells/1/descriptives/14/1 | tolerance | 0.93500190023311891 | 0.9350019002331189 | 3.36E-20 | 19 | passed |
/cells/1/descriptives/14/2 | tolerance | 1.3342487699899821 | 1.334248769989982 | 2.57E-18 | 17 | passed |
/cells/1/mean_lower | tolerance | 20.983732013305612 | 20.983732013305612 | 4.40E-16 | 16 | passed |
/cells/1/mean_upper | tolerance | 26.656267986694388 | 26.656267986694388 | 1.28E-16 | 17 | passed |
/cells/1/normality/[test=Shapiro-Wilk]/statistic | tolerance | 0.97686818143932785 | 0.9768681814393279 | 3.97E-18 | 17 | passed |
/cells/1/normality/[test=Shapiro-Wilk]/p_value | tail_probability | 0.94623349609786711 | 0.9462334960978667 | 4.44E-16 | 15 | passed |
/cells/1/normality/[test=Kolmogorov-Smirnov (Lilliefors)]/statistic | tolerance | 0.1342033167625844 | 0.1342033167625844 | 1.46E-18 | 16 | passed |
/cells/1/normality/[test=Kolmogorov-Smirnov (Lilliefors)]/p_value | tail_probability | 0.87699097038838358 | 0.8769909703883836 | 3.87E-18 | 17 | passed |
/cells/1/m_estimates/0/value | tolerance | 23.680640479998178 | 23.680640471230305 | 8.77E-9 | 9 | passed |
/cells/1/m_estimates/1/value | tolerance | 23.572644009570052 | 23.57264400282733 | 6.74E-9 | 9 | passed |
/cells/1/m_estimates/2/value | tolerance | 23.712499999999977 | 23.712499997453662 | 2.55E-9 | 9 | passed |
/cells/1/m_estimates/3/value | tolerance | 23.574421699801178 | 23.574421693566045 | 6.24E-9 | 9 | passed |
/cells/1/extremes/0/value | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
/cells/1/extremes/0/case | exact | 23 | 23 | 0.00E+2 | passed | |
/cells/1/extremes/5/value | tolerance | 15.300000000000001 | 15.3 | 2.89E-16 | 16 | passed |
/cells/1/extremes/5/case | exact | 24 | 24 | 0.00E+2 | passed | |
/cells/1/extremes/1/value | tolerance | 28.699999999999999 | 28.7 | 2.89E-16 | 16 | passed |
/cells/1/extremes/1/case | exact | 22 | 22 | 0.00E+2 | passed | |
/cells/1/extremes/6/value | tolerance | 20.100000000000001 | 20.1 | 4.21E-16 | 16 | passed |
/cells/1/extremes/6/case | exact | 13 | 13 | 0.00E+2 | passed | |
/cells/1/extremes/2/value | tolerance | 26.300000000000001 | 26.3 | 2.89E-16 | 16 | passed |
/cells/1/extremes/2/case | exact | 20 | 20 | 0.00E+2 | passed | |
/cells/1/extremes/7/value | tolerance | 21.5 | 21.5 | 0.00E+1 | passed | |
/cells/1/extremes/7/case | exact | 15 | 15 | 0.00E+2 | passed | |
/cells/1/extremes/3/value | tolerance | 24.899999999999999 | 24.9 | 4.21E-16 | 16 | passed |
/cells/1/extremes/3/case | exact | 19 | 19 | 0.00E+2 | passed | |
/cells/1/extremes/8/value | tolerance | 22 | 22.0 | 0.00E+2 | passed | |
/cells/1/extremes/8/case | exact | 16 | 16 | 0.00E+2 | passed | |
/cells/1/extremes/4/value | tolerance | 23.399999999999999 | 23.4 | 4.21E-16 | 16 | passed |
/cells/1/extremes/4/case | exact | 18 | 18 | 0.00E+2 | passed | |
/cells/1/extremes/9/value | tolerance | 22.800000000000001 | 22.8 | 2.89E-16 | 16 | passed |
/cells/1/extremes/9/case | exact | 17 | 17 | 0.00E+2 | passed | |
/cells/1/descriptives/8/1 | tolerance | 21.149999999999999 | 21.15 | 4.21E-16 | 16 | passed |
/cells/1/descriptives/9/1 | tolerance | 26.900000000000002 | 26.9 | 3.42E-15 | 15 | passed |
/cells/1/descriptives/10/1 | tolerance | 21.5 | 21.5 | 0.00E+1 | passed | |
/cells/1/descriptives/11/1 | tolerance | 26.300000000000001 | 26.3 | 2.89E-16 | 16 | passed |
/cells/1/descriptives/12/1 | tolerance | 4.8000000000000007 | 4.800000000000001 | 1.05E-17 | 17 | passed |
/cells/1/box/q1 | tolerance | 21.5 | 21.5 | 0.00E+1 | passed | |
/cells/1/box/q3 | tolerance | 26.300000000000001 | 26.3 | 2.89E-16 | 16 | passed |
/cells/1/box/median | tolerance | 23.100000000000001 | 23.1 | 4.21E-16 | 16 | passed |
/cells/1/box/whisker_low | tolerance | 15.300000000000001 | 15.3 | 2.89E-16 | 16 | passed |
/cells/1/box/whisker_high | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
/cells/1/box/outliers/0 | absent | None | passed | |||
/cells/1/box/extremes/0 | absent | None | passed | |||
/cells/1/group | exact | B | B | passed | ||
/cells/1/missing | exact | 2 | 2 | 0.00E+2 | passed | |
/cells/2 | absent | None | passed |
Convention
- R: per level of group after excluding rows 2 and 5 (1-based); fivenum hinges give the box, fences and hinge spread; the type-6 quartiles are reported beside them; t.test at 0.90.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:35-41.
- Case numbers in extremes and outliers are positions before exclusion (#131).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
482 ex2[["/cells/2"]] <- absent("two levels give two cells")
483 emit("STAT-DESC-EXPLORE-002", "Explore by factor with Tukey's hinges, a 90% interval and exclusions",
484 "axis_coverage", "tabelz.analysis.report_explore:compute_explore", "exploreMenuItem", "EXPLORE",
485 list(dependents = list("score"), factor = "group", confidence_level = 0.90,
486 quartiles = "tukey_hinges", metadata = metadata),
487 ex2,
488 c("R: per level of group after excluding rows 2 and 5 (1-based); fivenum hinges give the box, fences and hinge spread; the type-6 quartiles are reported beside them; t.test at 0.90.",
489 paste0(manual, ":35-41."),
490 "Case numbers in extremes and outliers are positions before exclusion (#131)."),
491 "R stats, MASS, nortest and e1071", explore_cite, excluded = as.list(excluded2))
Frequencies with labels, user-missing codes and type-6 percentiles
Case STAT-DESC-FREQUENCIES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base table and stats::quantile type 6; e1071 type-2 moments
- Citation
- R stats::quantile documentation (type 6, Weibull); e1071::skewness and kurtosis documentation (type 2, SPSS G1/G2)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
columns= ["grade", "score"]metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}percentiles= [10, 90]quartiles= truestatistics= trueuser_missing_valid= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/tables/0/values/[value=1]/count | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/tables/0/values/[value=1]/percent | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/tables/0/values/[value=1]/valid_percent | tolerance | 14.285714285714286 | 14.285714285714286 | 4.76E-16 | 16 | passed |
/tables/0/values/[value=1]/cumulative_percent | tolerance | 14.285714285714286 | 14.285714285714286 | 4.76E-16 | 16 | passed |
/tables/0/values/[value=2]/count | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/tables/0/values/[value=2]/percent | tolerance | 29.166666666666668 | 29.166666666666668 | 1.49E-16 | 17 | passed |
/tables/0/values/[value=2]/valid_percent | tolerance | 33.333333333333336 | 33.333333333333336 | 2.98E-16 | 17 | passed |
/tables/0/values/[value=2]/cumulative_percent | tolerance | 47.61904761904762 | 47.61904761904762 | 4.01E-16 | 17 | passed |
/tables/0/values/[value=3]/count | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/tables/0/values/[value=3]/percent | tolerance | 29.166666666666668 | 29.166666666666668 | 1.49E-16 | 17 | passed |
/tables/0/values/[value=3]/valid_percent | tolerance | 33.333333333333336 | 33.333333333333336 | 2.98E-16 | 17 | passed |
/tables/0/values/[value=3]/cumulative_percent | tolerance | 80.952380952380949 | 80.95238095238095 | 2.58E-18 | 19 | passed |
/tables/0/values/[value=4]/count | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/0/values/[value=4]/percent | tolerance | 16.666666666666668 | 16.666666666666668 | 1.49E-16 | 17 | passed |
/tables/0/values/[value=4]/valid_percent | tolerance | 19.047619047619047 | 19.047619047619047 | 4.50E-16 | 16 | passed |
/tables/0/values/[value=4]/cumulative_percent | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/tables/0/values/[value=5]/count | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/tables/0/values/[value=5]/percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/tables/0/values/[value=5]/valid_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/tables/0/values/[value=5]/cumulative_percent | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/tables/0/values/[value=5]/label | exact | Excellent | Excellent | passed | ||
/tables/0/values/[value=9]/count | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/tables/0/values/[value=9]/missing | exact | user-missing | user-missing | passed | ||
/tables/0/values/[value=9]/percent | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/tables/0/values/[missing=system-missing]/count | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/tables/0/valid | tolerance | 21 | 21.0 | 0.00E+2 | passed | |
/tables/0/missing | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/tables/1/valid | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/tables/1/missing | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/1/values/[value=12.5]/valid_percent | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/tables/1/statistics/0/1 | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/tables/1/statistics/1/1 | tolerance | 20.414999999999999 | 20.415 | 1.47E-16 | 17 | passed |
/tables/1/statistics/2/1 | tolerance | 1.1425565746674382 | 1.1425565746674382 | 7.27E-18 | 17 | passed |
/tables/1/statistics/3/1 | tolerance | 19.5 | 19.5 | 0.00E+1 | passed | |
/tables/1/statistics/4/1 | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/tables/1/statistics/5/1 | tolerance | 5.1096683381914128 | 5.109668338191413 | 4.91E-17 | 17 | passed |
/tables/1/statistics/6/1 | tolerance | 26.108710526315793 | 26.108710526315793 | 3.24E-17 | 17 | passed |
/tables/1/statistics/7/1 | tolerance | 0.83023957898392808 | 0.8302395789839283 | 2.26E-16 | 15 | passed |
/tables/1/statistics/8/1 | tolerance | 0.51210333670775743 | 0.5121033367077574 | 1.69E-18 | 17 | passed |
/tables/1/statistics/9/1 | tolerance | 0.72187289698248236 | 0.7218728969824824 | 6.37E-19 | 18 | passed |
/tables/1/statistics/10/1 | tolerance | 0.99238361254184504 | 0.992383612541845 | 6.55E-19 | 18 | passed |
/tables/1/statistics/11/1 | tolerance | 20.700000000000003 | 20.700000000000003 | 1.58E-16 | 17 | passed |
/tables/1/statistics/12/1 | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/tables/1/statistics/13/1 | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
/tables/1/statistics/14/1 | tolerance | 408.30000000000001 | 408.3 | 1.37E-15 | 17 | passed |
/tables/1/percentiles/0/0 | exact | 10 | 10 | passed | ||
/tables/1/percentiles/0/1 | tolerance | 14.219999999999999 | 14.22 | 1.64E-15 | 15 | passed |
/tables/1/percentiles/1/0 | exact | 25 | 25 | passed | ||
/tables/1/percentiles/1/1 | tolerance | 16.599999999999998 | 16.599999999999998 | 1.32E-16 | 17 | passed |
/tables/1/percentiles/2/0 | exact | 50 | 50 | passed | ||
/tables/1/percentiles/2/1 | tolerance | 19.5 | 19.5 | 0.00E+1 | passed | |
/tables/1/percentiles/3/0 | exact | 75 | 75 | passed | ||
/tables/1/percentiles/3/1 | tolerance | 23.249999999999996 | 23.25 | 4.00E-15 | 15 | passed |
/tables/1/percentiles/4/0 | exact | 90 | 90 | passed | ||
/tables/1/percentiles/4/1 | tolerance | 28.460000000000008 | 28.459999999999997 | 1.07E-14 | 15 | passed |
Convention
- R: table() over valid codes, labelled code 5 listed with count 0; percent of all rows, valid percent and cumulative valid percent by hand; quantile(type = 6).
- docs/manual/chapters/82-descriptive-reports-and-association.tex:28-33: percent of all rows versus valid percent, user-missing listed separately, percentile at (n+1)p.
- Statistics order follows the engine's statistics list; skewness and kurtosis are the SPSS G1 and G2 (e1071 type 2).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
205 emit("STAT-DESC-FREQUENCIES-001", "Frequencies with labels, user-missing codes and type-6 percentiles",
206 "nominal", "tabelz.analysis.report_listings:compute_frequencies", "frequenciesMenuItem",
207 "FREQUENCIES",
208 list(columns = list("grade", "score"), quartiles = TRUE, percentiles = list(10, 90),
209 statistics = TRUE, user_missing_valid = FALSE, metadata = metadata),
210 c(grade_outputs, score_outputs),
211 c("R: table() over valid codes, labelled code 5 listed with count 0; percent of all rows, valid percent and cumulative valid percent by hand; quantile(type = 6).",
212 paste0(manual, ":28-33: percent of all rows versus valid percent, user-missing listed separately, percentile at (n+1)p."),
213 "Statistics order follows the engine's statistics list; skewness and kurtosis are the SPSS G1 and G2 (e1071 type 2)."),
214 freq_source, freq_cite)
Frequencies treating user-missing values as valid
Case STAT-DESC-FREQUENCIES-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base table and stats::quantile type 6; e1071 type-2 moments
- Citation
- R stats::quantile documentation (type 6, Weibull); e1071::skewness and kurtosis documentation (type 2, SPSS G1/G2)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
columns= ["grade", "score"]metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}percentiles= [50]quartiles= falsestatistics= trueuser_missing_valid= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/tables/0/values/[value=9]/valid_percent | tolerance | 8.695652173913043 | 8.695652173913043 | 1.49E-17 | 17 | passed |
/tables/0/values/[value=9]/missing | exact | passed | ||||
/tables/0/valid | tolerance | 23 | 23.0 | 0.00E+2 | passed | |
/tables/0/missing | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/tables/1/valid | tolerance | 22 | 22.0 | 0.00E+2 | passed | |
/tables/1/values/[value=999]/count | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/tables/1/statistics/1/1 | tolerance | 109.37727272727273 | 109.37727272727274 | 9.42E-15 | 16 | passed |
/tables/1/statistics/13/1 | tolerance | 999 | 999.0 | 0.00E+2 | passed | |
/tables/1/statistics/5/1 | tolerance | 287.98470351543756 | 287.9847035154375 | 5.79E-14 | 15 | passed |
/tables/1/percentiles/0/1 | tolerance | 19.850000000000001 | 19.85 | 4.21E-16 | 16 | passed |
Convention
- R: the same tabulation with the user-missing codes 9 and 999 kept as valid values.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:28-33.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
217 x2 <- d$score[!is.na(d$score)]
218 stopifnot(length(x2) == 22)
219 grade_valid2 <- d$grade[!is.na(d$grade)]
220 um_outputs <- list(
221 "/tables/0/values/[value=9]/valid_percent" = tol(100 * sum(grade_valid2 == 9) / length(grade_valid2), "code 9 valid percent when user-missing counts as valid"),
222 "/tables/0/values/[value=9]/missing" = exact("", "Code 9 is a valid category here."),
223 "/tables/0/valid" = tol(length(grade_valid2), "valid grades including code 9"),
224 "/tables/0/missing" = tol(sum(is.na(d$grade)), "only the system-missing grade is missing"),
225 "/tables/1/valid" = tol(length(x2), "valid scores including 999"),
226 "/tables/1/values/[value=999]/count" = tol(sum(x2 == 999), "999 counted as a valid score value")
227 )
228 um_outputs[[stat_path(1, "Mean")]] <- tol(mean(x2), "mean including the two 999 values")
229 um_outputs[[stat_path(1, "Maximum")]] <- tol(max(x2), "maximum including 999")
230 um_outputs[[stat_path(1, "Std. deviation")]] <- tol(sd(x2), "SD including 999")
231 um_outputs[["/tables/1/percentiles/0/1"]] <- tol(q6(x2, 0.5), "median (quartiles on) including 999")
232 emit("STAT-DESC-FREQUENCIES-002", "Frequencies treating user-missing values as valid",
233 "axis_coverage", "tabelz.analysis.report_listings:compute_frequencies", "frequenciesMenuItem",
234 "FREQUENCIES",
235 list(columns = list("grade", "score"), quartiles = FALSE, percentiles = list(50),
236 statistics = TRUE, user_missing_valid = TRUE, metadata = metadata),
237 um_outputs,
238 c("R: the same tabulation with the user-missing codes 9 and 999 kept as valid values.",
239 paste0(manual, ":28-33.")),
240 freq_source, freq_cite)
Frequencies cut points after row exclusions, no statistics
Case STAT-DESC-FREQUENCIES-003 · status: passed
Reference
- Evidence type
- R
- Source
- R base table and stats::quantile type 6; e1071 type-2 moments
- Citation
- R stats::quantile documentation (type 6, Weibull); e1071::skewness and kurtosis documentation (type 2, SPSS G1/G2)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
columns= ["score"]cut_points= 4metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}percentiles= []quartiles= falsestatistics= falseuser_missing_valid= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/tables/0/valid | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/tables/0/missing | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/0/statistics/0 | absent | None | passed | |||
/tables/0/percentiles/0/0 | exact | 25 | 25 | passed | ||
/tables/0/percentiles/0/1 | tolerance | 17.650000000000002 | 17.65 | 3.42E-15 | 15 | passed |
/tables/0/percentiles/1/1 | tolerance | 19.850000000000001 | 19.85 | 4.21E-16 | 16 | passed |
/tables/0/percentiles/2/1 | tolerance | 23.774999999999999 | 23.775 | 4.21E-16 | 16 | passed |
/tables/0/percentiles/3 | absent | None | passed |
Convention
- R: quantile(type = 6) at 25, 50 and 75 on the 18 valid scores of the 22 non-excluded rows.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:28-33.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
243 keep <- valid_score & !(seq_len(nrow(d)) %in% c(1, 5))
244 x3 <- d$score[keep]
245 stopifnot(length(x3) == 18)
246 cut_outputs <- list(
247 "/tables/0/valid" = tol(length(x3), "valid scores after excluding two rows"),
248 "/tables/0/missing" = tol(nrow(d) - 2 - length(x3), "missing among the 22 remaining rows"),
249 "/tables/0/statistics/0" = absent("Statistics were not requested."),
250 "/tables/0/percentiles/0/0" = exact("25", "first cut point of four"),
251 "/tables/0/percentiles/0/1" = tol(q6(x3, 0.25), "25th percentile type 6 after exclusions"),
252 "/tables/0/percentiles/1/1" = tol(q6(x3, 0.5), "50th percentile type 6 after exclusions"),
253 "/tables/0/percentiles/2/1" = tol(q6(x3, 0.75), "75th percentile type 6 after exclusions"),
254 "/tables/0/percentiles/3" = absent("Four cut points give three percentiles.")
255 )
256 emit("STAT-DESC-FREQUENCIES-003", "Frequencies cut points after row exclusions, no statistics",
257 "axis_coverage", "tabelz.analysis.report_listings:compute_frequencies", "frequenciesMenuItem",
258 "FREQUENCIES",
259 list(columns = list("score"), quartiles = FALSE, percentiles = list(), cut_points = 4L,
260 statistics = FALSE, user_missing_valid = FALSE, metadata = metadata),
261 cut_outputs,
262 c("R: quantile(type = 6) at 25, 50 and 75 on the 18 valid scores of the 22 non-excluded rows.",
263 paste0(manual, ":28-33.")),
264 freq_source, freq_cite, excluded = list(0L, 4L))
Multiple-response crosstab against a column on the cases base
Case STAT-DESC-MRCROSS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base table() and aggregate() on a long (row, category) layout
- Citation
- R base::table documentation; manual chapter 80 multiple-response definitions
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_multiple_response.R · sha256 ee4f1ee9a38ca2f3
- Dataset
- reference_data/datasets/DESC_MR_01.json
Settings compared
base= "cases"by_column= "region"response_set= {"name": "features", "kind": "dichotomy", "columns": ["s1", "s2", "s3"], "counted_value": 1, "label": "Features used"}set_name= "features"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_analysed | exact | 14 | 14 | 0.00E+2 | passed | |
/valid_cases | exact | 10 | 10 | 0.00E+2 | passed | |
/left_out_cases | exact | 4 | 4 | 0.00E+2 | passed | |
/base_total | exact | 10 | 10 | 0.00E+2 | passed | |
/row_totals/s1 | exact | 7 | 7 | 0.00E+2 | passed | |
/column_totals/North | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/6 | absent | None | passed | |||
/cells/0/row | exact | s1 | s1 | passed | ||
/cells/0/column | exact | North | North | passed | ||
/cells/0/count | exact | 2 | 2 | 0.00E+2 | passed | |
/cells/0/row_percent | tolerance | 28.571428571428573 | 28.571428571428573 | 4.88E-17 | 17 | passed |
/cells/0/column_percent | tolerance | 40 | 40.0 | 0.00E+2 | passed | |
/cells/0/total_percent | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/cells/1/row | exact | s1 | s1 | passed | ||
/cells/1/column | exact | South | South | passed | ||
/cells/1/count | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/1/row_percent | tolerance | 71.428571428571431 | 71.42857142857143 | 3.98E-16 | 17 | passed |
/cells/1/column_percent | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/cells/1/total_percent | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/2/row | exact | s2 | s2 | passed | ||
/cells/2/column | exact | North | North | passed | ||
/cells/2/count | exact | 3 | 3 | 0.00E+2 | passed | |
/cells/2/row_percent | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/2/column_percent | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/cells/2/total_percent | tolerance | 30 | 30.0 | 0.00E+2 | passed | |
/cells/3/row | exact | s2 | s2 | passed | ||
/cells/3/column | exact | South | South | passed | ||
/cells/3/count | exact | 3 | 3 | 0.00E+2 | passed | |
/cells/3/row_percent | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/3/column_percent | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/cells/3/total_percent | tolerance | 30 | 30.0 | 0.00E+2 | passed | |
/cells/4/row | exact | s3 | s3 | passed | ||
/cells/4/column | exact | North | North | passed | ||
/cells/4/count | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/4/row_percent | tolerance | 80 | 80.0 | 0.00E+2 | passed | |
/cells/4/column_percent | tolerance | 80 | 80.0 | 0.00E+2 | passed | |
/cells/4/total_percent | tolerance | 40 | 40.0 | 0.00E+2 | passed | |
/cells/5/row | exact | s3 | s3 | passed | ||
/cells/5/column | exact | South | South | passed | ||
/cells/5/count | exact | 1 | 1 | 0.00E+2 | passed | |
/cells/5/row_percent | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/cells/5/column_percent | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/cells/5/total_percent | tolerance | 10 | 10.0 | 0.00E+2 | passed |
Convention
- R: (row, dichotomy) pairs joined to the row's region, rows without a region dropped; each cell counts distinct cases; row and column totals count distinct cases; percents divide by those totals.
- docs/manual/chapters/80-column-meaning-and-populations.tex:160-165: on a case base a case counts once for each category pair; denominators match the selected base.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
168 emit("STAT-DESC-MRCROSS-001", "Multiple-response crosstab against a column on the cases base",
169 "nominal", "tabelz.analysis.multiple_response:compute_mr_crosstab",
170 "multipleResponseCrosstabMenuItem", "MULTIPLE-RESPONSE-CROSSTAB",
171 list(set_name = "features", response_set = features, by_column = "region",
172 base = "cases"),
173 o3,
174 c("R: (row, dichotomy) pairs joined to the row's region, rows without a region dropped; each cell counts distinct cases; row and column totals count distinct cases; percents divide by those totals.",
175 paste0(manual, ":160-165: on a case base a case counts once for each category pair; denominators match the selected base.")))
Multiple-response crosstab of two sets on the responses base
Case STAT-DESC-MRCROSS-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base table() and aggregate() on a long (row, category) layout
- Citation
- R base::table documentation; manual chapter 80 multiple-response definitions
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_multiple_response.R · sha256 ee4f1ee9a38ca2f3
- Dataset
- reference_data/datasets/DESC_MR_01.json
Settings compared
base= "responses"by_set= {"name": "choices", "kind": "category", "columns": ["c1", "c2"], "counted_value": null, "label": "Suppliers named"}by_set_name= "choices"response_set= {"name": "features", "kind": "dichotomy", "columns": ["s1", "s2", "s3"], "counted_value": 1, "label": "Features used"}set_name= "features"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/valid_cases | exact | 10 | 10 | 0.00E+2 | passed | |
/base_total | exact | 29 | 29 | 0.00E+2 | passed | |
/row_totals/s2 | exact | 10 | 10 | 0.00E+2 | passed | |
/column_totals/A | exact | 14 | 14 | 0.00E+2 | passed | |
/cells/0/row | exact | s1 | s1 | passed | ||
/cells/0/column | exact | A | A | passed | ||
/cells/0/count | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/0/responses | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/0/cases | exact | 3 | 3 | 0.00E+2 | passed | |
/cells/0/row_percent | tolerance | 36.363636363636367 | 36.36363636363637 | 1.34E-16 | 17 | passed |
/cells/0/total_percent | tolerance | 13.793103448275861 | 13.793103448275861 | 2.11E-16 | 16 | passed |
/cells/1/row | exact | s1 | s1 | passed | ||
/cells/1/column | exact | B | B | passed | ||
/cells/1/count | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/1/responses | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/1/cases | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/1/row_percent | tolerance | 36.363636363636367 | 36.36363636363637 | 1.34E-16 | 17 | passed |
/cells/1/total_percent | tolerance | 13.793103448275861 | 13.793103448275861 | 2.11E-16 | 16 | passed |
/cells/2/row | exact | s1 | s1 | passed | ||
/cells/2/column | exact | C | C | passed | ||
/cells/2/count | exact | 3 | 3 | 0.00E+2 | passed | |
/cells/2/responses | exact | 3 | 3 | 0.00E+2 | passed | |
/cells/2/cases | exact | 2 | 2 | 0.00E+2 | passed | |
/cells/2/row_percent | tolerance | 27.272727272727273 | 27.272727272727273 | 3.73E-16 | 16 | passed |
/cells/2/total_percent | tolerance | 10.344827586206897 | 10.344827586206897 | 2.03E-16 | 16 | passed |
/cells/3/row | exact | s2 | s2 | passed | ||
/cells/3/column | exact | A | A | passed | ||
/cells/3/count | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/3/responses | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/3/cases | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/3/row_percent | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/3/total_percent | tolerance | 17.241379310344829 | 17.24137931034483 | 1.79E-16 | 16 | passed |
/cells/4/row | exact | s2 | s2 | passed | ||
/cells/4/column | exact | B | B | passed | ||
/cells/4/count | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/4/responses | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/4/cases | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/4/row_percent | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/cells/4/total_percent | tolerance | 17.241379310344829 | 17.24137931034483 | 1.79E-16 | 16 | passed |
/cells/5/row | exact | s2 | s2 | passed | ||
/cells/5/column | exact | C | C | passed | ||
/cells/5/count | exact | 0 | 0 | 0.00E+2 | passed | |
/cells/5/responses | exact | 0 | 0 | 0.00E+2 | passed | |
/cells/5/cases | exact | 0 | 0 | 0.00E+2 | passed | |
/cells/5/row_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/cells/5/total_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/cells/6/row | exact | s3 | s3 | passed | ||
/cells/6/column | exact | A | A | passed | ||
/cells/6/count | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/6/responses | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/6/cases | exact | 4 | 4 | 0.00E+2 | passed | |
/cells/6/row_percent | tolerance | 62.5 | 62.5 | 0.00E+1 | passed | |
/cells/6/total_percent | tolerance | 17.241379310344829 | 17.24137931034483 | 1.79E-16 | 16 | passed |
/cells/7/row | exact | s3 | s3 | passed | ||
/cells/7/column | exact | B | B | passed | ||
/cells/7/count | exact | 2 | 2 | 0.00E+2 | passed | |
/cells/7/responses | exact | 2 | 2 | 0.00E+2 | passed | |
/cells/7/cases | exact | 2 | 2 | 0.00E+2 | passed | |
/cells/7/row_percent | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/cells/7/total_percent | tolerance | 6.8965517241379306 | 6.896551724137931 | 5.71E-18 | 18 | passed |
/cells/8/row | exact | s3 | s3 | passed | ||
/cells/8/column | exact | C | C | passed | ||
/cells/8/count | exact | 1 | 1 | 0.00E+2 | passed | |
/cells/8/responses | exact | 1 | 1 | 0.00E+2 | passed | |
/cells/8/cases | exact | 1 | 1 | 0.00E+2 | passed | |
/cells/8/row_percent | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/cells/8/total_percent | tolerance | 3.4482758620689653 | 3.4482758620689653 | 2.85E-18 | 18 | passed |
Convention
- R: the (row, dichotomy) pairs joined to the (row, code) pairs of the same row; a cell counts the joined records (occurrence pairs, repeated codes multiplying them) and, separately, the distinct cases; totals sum the cells.
- docs/manual/chapters/80-column-meaning-and-populations.tex:160-165: on a response base repetitions multiply the paired response count.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
205 emit("STAT-DESC-MRCROSS-002", "Multiple-response crosstab of two sets on the responses base",
206 "axis_coverage", "tabelz.analysis.multiple_response:compute_mr_crosstab",
207 "multipleResponseCrosstabMenuItem", "MULTIPLE-RESPONSE-CROSSTAB",
208 list(set_name = "features", response_set = features, by_set_name = "choices",
209 by_set = choices, base = "responses"),
210 o4,
211 c("R: the (row, dichotomy) pairs joined to the (row, code) pairs of the same row; a cell counts the joined records (occurrence pairs, repeated codes multiplying them) and, separately, the distinct cases; totals sum the cells.",
212 paste0(manual, ":160-165: on a response base repetitions multiply the paired response count.")))
Multiple-dichotomy frequencies: case base, responses and percents
Case STAT-DESC-MRFREQ-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base table() and aggregate() on a long (row, category) layout
- Citation
- R base::table documentation; manual chapter 80 multiple-response definitions
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_multiple_response.R · sha256 ee4f1ee9a38ca2f3
- Dataset
- reference_data/datasets/DESC_MR_01.json
Settings compared
response_set= {"name": "features", "kind": "dichotomy", "columns": ["s1", "s2", "s3"], "counted_value": 1, "label": "Features used"}set_name= "features"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_analysed | exact | 14 | 14 | 0.00E+2 | passed | |
/valid_cases | exact | 11 | 11 | 0.00E+2 | passed | |
/cases_without_response | exact | 3 | 3 | 0.00E+2 | passed | |
/all_missing_rows | exact | 1 | 1 | 0.00E+2 | passed | |
/total_responses | exact | 19 | 19 | 0.00E+2 | passed | |
/categories/3 | absent | None | passed | |||
/categories/0/category | exact | s1 | s1 | passed | ||
/categories/0/responses | exact | 7 | 7 | 0.00E+2 | passed | |
/categories/0/cases | exact | 7 | 7 | 0.00E+2 | passed | |
/categories/0/percent_of_responses | tolerance | 36.842105263157897 | 36.8421052631579 | 3.55E-16 | 17 | passed |
/categories/0/percent_of_cases | tolerance | 63.636363636363633 | 63.63636363636363 | 1.34E-16 | 17 | passed |
/categories/1/category | exact | s2 | s2 | passed | ||
/categories/1/responses | exact | 7 | 7 | 0.00E+2 | passed | |
/categories/1/cases | exact | 7 | 7 | 0.00E+2 | passed | |
/categories/1/percent_of_responses | tolerance | 36.842105263157897 | 36.8421052631579 | 3.55E-16 | 17 | passed |
/categories/1/percent_of_cases | tolerance | 63.636363636363633 | 63.63636363636363 | 1.34E-16 | 17 | passed |
/categories/2/category | exact | s3 | s3 | passed | ||
/categories/2/responses | exact | 5 | 5 | 0.00E+2 | passed | |
/categories/2/cases | exact | 5 | 5 | 0.00E+2 | passed | |
/categories/2/percent_of_responses | tolerance | 26.315789473684209 | 26.31578947368421 | 1.57E-16 | 17 | passed |
/categories/2/percent_of_cases | tolerance | 45.454545454545453 | 45.45454545454545 | 2.54E-16 | 17 | passed |
Convention
- R: table() of the (row, column) pairs where the column holds the counted value 1; a case is a row with at least one such pair; percent of responses divides by all pairs, percent of cases by the cases.
- docs/manual/chapters/80-column-meaning-and-populations.tex:111-117: the case base consists of rows with at least one counted response; a row answering No to every dichotomy is outside that base; rows with no counted response and rows missing all responses are counted separately.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
106 emit("STAT-DESC-MRFREQ-001", "Multiple-dichotomy frequencies: case base, responses and percents",
107 "nominal", "tabelz.analysis.multiple_response:compute_mr_frequencies",
108 "multipleResponseFrequenciesMenuItem", "MULTIPLE-RESPONSE-FREQUENCIES",
109 list(set_name = "features", response_set = features),
110 o1,
111 c("R: table() of the (row, column) pairs where the column holds the counted value 1; a case is a row with at least one such pair; percent of responses divides by all pairs, percent of cases by the cases.",
112 paste0(manual, ":111-117: the case base consists of rows with at least one counted response; a row answering No to every dichotomy is outside that base; rows with no counted response and rows missing all responses are counted separately.")))
Multiple-category frequencies: repeated codes count as responses once per case
Case STAT-DESC-MRFREQ-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base table() and aggregate() on a long (row, category) layout
- Citation
- R base::table documentation; manual chapter 80 multiple-response definitions
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_multiple_response.R · sha256 ee4f1ee9a38ca2f3
- Dataset
- reference_data/datasets/DESC_MR_01.json
Settings compared
response_set= {"name": "choices", "kind": "category", "columns": ["c1", "c2"], "counted_value": null, "label": "Suppliers named"}set_name= "choices"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/valid_cases | exact | 13 | 13 | 0.00E+2 | passed | |
/cases_without_response | exact | 1 | 1 | 0.00E+2 | passed | |
/all_missing_rows | exact | 1 | 1 | 0.00E+2 | passed | |
/total_responses | exact | 24 | 24 | 0.00E+2 | passed | |
/categories/0/category | exact | A | A | passed | ||
/categories/0/responses | exact | 10 | 10 | 0.00E+2 | passed | |
/categories/0/cases | exact | 8 | 8 | 0.00E+2 | passed | |
/categories/0/percent_of_responses | tolerance | 41.666666666666664 | 41.666666666666664 | 2.98E-16 | 17 | passed |
/categories/0/percent_of_cases | tolerance | 61.53846153846154 | 61.53846153846154 | 1.01E-16 | 17 | passed |
/categories/1/category | exact | B | B | passed | ||
/categories/1/responses | exact | 8 | 8 | 0.00E+2 | passed | |
/categories/1/cases | exact | 7 | 7 | 0.00E+2 | passed | |
/categories/1/percent_of_responses | tolerance | 33.333333333333336 | 33.333333333333336 | 2.98E-16 | 17 | passed |
/categories/1/percent_of_cases | tolerance | 53.846153846153847 | 53.84615384615385 | 3.00E-16 | 17 | passed |
/categories/2/category | exact | C | C | passed | ||
/categories/2/responses | exact | 6 | 6 | 0.00E+2 | passed | |
/categories/2/cases | exact | 5 | 5 | 0.00E+2 | passed | |
/categories/2/percent_of_responses | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/categories/2/percent_of_cases | tolerance | 38.46153846153846 | 38.46153846153846 | 1.01E-16 | 17 | passed |
Convention
- R: table() of every non-missing code across c1 and c2 (occurrences) and of the distinct (row, code) pairs (cases).
- docs/manual/chapters/80-column-meaning-and-populations.tex:119-158: the worked example distinguishes mentions from technicians; case percentages can total more than 100.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
130 emit("STAT-DESC-MRFREQ-002", "Multiple-category frequencies: repeated codes count as responses once per case",
131 "axis_coverage", "tabelz.analysis.multiple_response:compute_mr_frequencies",
132 "multipleResponseFrequenciesMenuItem", "MULTIPLE-RESPONSE-FREQUENCIES",
133 list(set_name = "choices", response_set = choices),
134 o2,
135 c("R: table() of every non-missing code across c1 and c2 (occurrences) and of the distinct (row, code) pairs (cases).",
136 paste0(manual, ":119-158: the worked example distinguishes mentions from technicians; case percentages can total more than 100.")))
Missing value analysis with the default settings
Case STAT-DESC-MVA-001 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) with a hand-written multivariate-normal EM
- Citation
- Little, R. J. A. (1988). A test of missing completely at random for multivariate data with missing values. JASA 83:1198-1202; Dempster, Laird and Rubin (1977) JRSS B 39:1-38; R stats: quantile (type 7), t.test, p.adjust, pchisq, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_missing_values.R · sha256 1c2458fc190a7995
- Dataset
- reference_data/datasets/DESC_MVA_01.json
Settings compared
categorical= ["g"]quantitative= ["x", "y", "z"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cases | exact | 24 | 24 | 0.00E+2 | passed | |
/univariate/0/present | exact | 19 | 19 | 0.00E+2 | passed | |
/univariate/0/missing | exact | 5 | 5 | 0.00E+2 | passed | |
/univariate/0/percent_missing | tolerance | 20.833333333333332 | 20.833333333333332 | 1.49E-16 | 17 | passed |
/univariate/0/mean | tolerance | 5.8473684210526313 | 5.847368421052632 | 9.15E-16 | 15 | passed |
/univariate/0/sd | tolerance | 0.96342469062346747 | 0.9634246906234676 | 1.13E-16 | 15 | passed |
/univariate/0/low_extremes | exact | 0 | 0 | 0.00E+2 | passed | |
/univariate/0/high_extremes | exact | 0 | 0 | 0.00E+2 | passed | |
/univariate/3/missing | exact | 3 | 3 | 0.00E+2 | passed | |
/univariate/3/percent_missing | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/patterns_total | exact | 6 | 6 | 0.00E+2 | passed | |
/patterns/0/count | exact | 14 | 14 | 0.00E+2 | passed | |
/patterns/0/percent | tolerance | 58.333333333333336 | 58.333333333333336 | 2.98E-16 | 17 | passed |
/patterns/0/variables_missing | exact | 0 | 0 | 0.00E+2 | passed | |
/welch_filtered/0/0 | exact | z | z | passed | ||
/welch_filtered/0/1 | tolerance | 4.1666666666666661 | 4.166666666666666 | 2.55E-17 | 17 | passed |
/welch/0/present_count | exact | 15 | 15 | 0.00E+2 | passed | |
/welch/0/missing_count | exact | 5 | 5 | 0.00E+2 | passed | |
/welch/0/difference | tolerance | 0.34666666666666757 | 0.34666666666666934 | 1.77E-15 | 14 | passed |
/welch/0/t_value | tolerance | 0.65487488947616923 | 0.6548748894761727 | 3.44E-15 | 14 | passed |
/welch/0/df | tolerance | 11.543550101067417 | 11.543550101067417 | 3.02E-16 | 16 | passed |
/welch/0/p_value | tail_probability | 0.52538278122137905 | 0.525382781221377 | 2.00E-15 | 14 | passed |
/welch/0/adjusted_p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/welch/1/present_count | exact | 19 | 19 | 0.00E+2 | passed | |
/welch/1/missing_count | exact | 4 | 4 | 0.00E+2 | passed | |
/welch/1/difference | tolerance | 0.33421052631578929 | 0.3342105263157893 | 1.37E-18 | 17 | passed |
/welch/1/t_value | tolerance | 1.5088073591886564 | 1.5088073591886564 | 1.71E-17 | 16 | passed |
/welch/1/df | tolerance | 7.8785468391037776 | 7.87854683910378 | 2.69E-15 | 15 | passed |
/welch/1/p_value | tail_probability | 0.17035788165279489 | 0.17035788165279483 | 5.53E-17 | 15 | passed |
/welch/1/adjusted_p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/welch/2/present_count | exact | 15 | 15 | 0.00E+2 | passed | |
/welch/2/missing_count | exact | 4 | 4 | 0.00E+2 | passed | |
/welch/2/difference | tolerance | 0.37666666666666693 | 0.37666666666666604 | 8.91E-16 | 14 | passed |
/welch/2/t_value | tolerance | 0.86106998765791565 | 0.8610699876579135 | 2.11E-15 | 14 | passed |
/welch/2/df | tolerance | 7.0117718683739998 | 7.011771868374002 | 1.77E-15 | 15 | passed |
/welch/2/p_value | tail_probability | 0.41766888020344639 | 0.4176688802034474 | 1.00E-15 | 14 | passed |
/welch/2/adjusted_p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/welch/3/present_count | exact | 19 | 19 | 0.00E+2 | passed | |
/welch/3/missing_count | exact | 4 | 4 | 0.00E+2 | passed | |
/welch/3/difference | tolerance | 0.061842105263157698 | 0.061842105263157254 | 4.44E-16 | 14 | passed |
/welch/3/t_value | tolerance | 0.21586980048900192 | 0.21586980048900037 | 1.55E-15 | 14 | passed |
/welch/3/df | tolerance | 5.1214660685228095 | 5.121466068522809 | 8.88E-16 | 15 | passed |
/welch/3/p_value | tail_probability | 0.83742432815470702 | 0.8374243281547082 | 1.22E-15 | 14 | passed |
/welch/3/adjusted_p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/welch/4/present_count | exact | 16 | 16 | 0.00E+2 | passed | |
/welch/4/missing_count | exact | 3 | 3 | 0.00E+2 | passed | |
/welch/4/difference | tolerance | 0.29374999999999929 | 0.2937499999999993 | 5.43E-19 | 17 | passed |
/welch/4/t_value | tolerance | 0.6433850384639147 | 0.6433850384639147 | 4.64E-18 | 17 | passed |
/welch/4/df | tolerance | 4.1169108655431694 | 4.1169108655431685 | 8.59E-16 | 15 | passed |
/welch/4/p_value | tail_probability | 0.55406491411452952 | 0.5540649141145294 | 1.15E-16 | 15 | passed |
/welch/4/adjusted_p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/welch/5/present_count | exact | 19 | 19 | 0.00E+2 | passed | |
/welch/5/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/welch/5/status | exact | not computed: fewer than two cases in a group | not computed: fewer than two cases in a group | passed | ||
/welch/6/present_count | exact | 20 | 20 | 0.00E+2 | passed | |
/welch/6/missing_count | exact | 3 | 3 | 0.00E+2 | passed | |
/welch/6/difference | tolerance | -0.0083333333333333037 | -0.008333333333333304 | 2.74E-20 | 17 | passed |
/welch/6/t_value | tolerance | -0.0259768624588647 | -0.025976862458864707 | 6.52E-18 | 15 | passed |
/welch/6/df | tolerance | 2.9555289566648146 | 2.9555289566648137 | 8.56E-16 | 15 | passed |
/welch/6/p_value | tail_probability | 0.98092994144196743 | 0.9809299414419674 | 4.56E-18 | 17 | passed |
/welch/6/adjusted_p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/em/status | exact | converged | converged | passed | ||
/em/cases_used | exact | 24 | 24 | 0.00E+2 | passed | |
/em/means/0 | tolerance | 5.7398331347312181 | 5.739830899758407 | 2.23E-6 | 6 | passed |
/em/means/1 | tolerance | 10.642187473578213 | 10.642190146666762 | 2.67E-6 | 6 | passed |
/em/means/2 | tolerance | 2.6016439119923782 | 2.6016438348521187 | 7.71E-8 | 7 | passed |
/em/covariance/0/0 | tolerance | 0.79335654135973499 | 0.7933583156071506 | 1.77E-6 | 5 | passed |
/em/covariance/0/1 | tolerance | 1.0089779038620392 | 1.0089776770248449 | 2.27E-7 | 6 | passed |
/em/covariance/1/2 | tolerance | 0.64395896434169941 | 0.6439591960506377 | 2.32E-7 | 6 | passed |
/em/correlations/0/2 | tolerance | 0.9802313931866643 | 0.9802317140856676 | 3.21E-7 | 6 | passed |
/em/log_likelihood | tolerance | -23.746389060077693 | -23.746389063731083 | 3.65E-9 | 9 | passed |
/little/status | exact | computed | computed | passed | ||
/little/statistic | tolerance | 13.602247198868017 | 13.602245712483736 | 1.49E-6 | 6 | passed |
/little/df | exact | 5 | 5 | 0.00E+2 | passed | |
/little/p_value | tail_probability | 0.018343510647349241 | 0.018343521679129074 | 1.10E-8 | 6 | passed |
/little/patterns | exact | 4 | 4 | 0.00E+2 | passed | |
/crosstabs/0/missing | exact | 2 | 2 | 0.00E+2 | passed | |
/crosstabs/0/present | exact | 9 | 9 | 0.00E+2 | passed | |
/crosstabs/2/missing | exact | 0 | 0 | 0.00E+2 | passed | |
/crosstabs/2/percent_missing | tolerance | 0 | 0.0 | 0.00E+2 | passed |
Convention
- Univariate: available-case mean and SD; fences from quantile(type = 7) (numpy linear).
- Welch rows are listed per indicator (x, y, g; z is filtered at 4.17% < 5%) and then per other quantitative variable; t.test(var.equal = FALSE), difference present minus missing; p.adjust(method = 'holm') over the six computed tests (g->y has one missing case and is not computed).
- EM is iterated in R to a scaled change of 1e-13 (tolerance 1e-13, 20000 iterations); the product stops at 1e-6, so EM estimates, Little's statistic and the log-likelihood carry relative tolerances 1e-4 and 1e-7.
- Little's test uses the EM maximum-likelihood mean and n-denominator covariance over the patterns of the three quantitative variables (every row has at least one value, so 24 cases enter).
- Expected computed from the exported CSV.
- docs/manual/chapters/89-missingness-diagnostics.tex:11-17: present/missing counts, mean, SD, counts outside Q1 - 1.5 IQR and Q3 + 1.5 IQR with interpolated quartiles; pattern table of distinct present/missing combinations.
- docs/manual/chapters/89-missingness-diagnostics.tex:19-24: a variable missing in at least the threshold percent splits the cases; Welch's test, difference = present minus missing; Holm over the whole computed family by default.
- docs/manual/chapters/89-missingness-diagnostics.tex:55-74: EM under the multivariate normal (tolerance 1e-6, 100 iterations; SPSS-style 1e-4, 25); Little's d^2 = sum_p n_p (ybar_p - mu)' Sigma_pp^-1 (ybar_p - mu), df = sum_p |O_p| - k.
Reference code
The lines of the reference script that produce this case's expected values.
262 gx_a_missing <- sum(d$g == "A" & is.na(d$x), na.rm = TRUE)
263 gx_null_missing <- sum(is.na(d$g) & is.na(d$x))
264 outputs[["/crosstabs/0/missing"]] <- exact(as.integer(gx_a_missing), "g = A cases missing x")
265 outputs[["/crosstabs/0/present"]] <- exact(as.integer(sum(d$g == "A" & !is.na(d$x), na.rm = TRUE)), "g = A cases present on x")
266 outputs[["/crosstabs/2/missing"]] <- exact(as.integer(gx_null_missing), "g missing cases missing x")
267 outputs[["/crosstabs/2/percent_missing"]] <- tol(100 * gx_null_missing / sum(is.na(d$g)), "percent of g-missing cases missing x")
268 emit("STAT-DESC-MVA-001", "Missing value analysis with the default settings", "nominal",
269 list(quantitative = list("x", "y", "z"), categorical = list("g")),
270 outputs,
271 list("Univariate: available-case mean and SD; fences from quantile(type = 7) (numpy linear).",
272 "Welch rows are listed per indicator (x, y, g; z is filtered at 4.17% < 5%) and then per other quantitative variable; t.test(var.equal = FALSE), difference present minus missing; p.adjust(method = 'holm') over the six computed tests (g->y has one missing case and is not computed).",
273 "EM is iterated in R to a scaled change of 1e-13 (tolerance 1e-13, 20000 iterations); the product stops at 1e-6, so EM estimates, Little's statistic and the log-likelihood carry relative tolerances 1e-4 and 1e-7.",
274 "Little's test uses the EM maximum-likelihood mean and n-denominator covariance over the patterns of the three quantitative variables (every row has at least one value, so 24 cases enter)."))
Raw p-values, 1% indicator threshold, SPSS-style EM
Case STAT-DESC-MVA-002 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) with a hand-written multivariate-normal EM
- Citation
- Little, R. J. A. (1988). A test of missing completely at random for multivariate data with missing values. JASA 83:1198-1202; Dempster, Laird and Rubin (1977) JRSS B 39:1-38; R stats: quantile (type 7), t.test, p.adjust, pchisq, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_missing_values.R · sha256 1c2458fc190a7995
- Dataset
- reference_data/datasets/DESC_MVA_01.json
Settings compared
adjustment= "none"categorical= ["g"]em_preset= "spss"min_percent= 1quantitative= ["x", "y", "z"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cases | exact | 24 | 24 | 0.00E+2 | passed | |
/em/status | exact | converged | converged | passed | ||
/em/tolerance | tolerance | 0.0001 | 0.0001 | 4.79E-21 | 16 | passed |
/em/max_iterations | exact | 25 | 25 | 0.00E+2 | passed | |
/em/means/0 | tolerance | 5.7398331347312181 | 5.739575380431794 | 2.58E-4 | 4 | passed |
/little/df | exact | 5 | 5 | 0.00E+2 | passed | |
/welch/0/present_count | exact | 15 | 15 | 0.00E+2 | passed | |
/welch/0/missing_count | exact | 5 | 5 | 0.00E+2 | passed | |
/welch/0/difference | tolerance | 0.34666666666666757 | 0.34666666666666934 | 1.77E-15 | 14 | passed |
/welch/0/t_value | tolerance | 0.65487488947616923 | 0.6548748894761727 | 3.44E-15 | 14 | passed |
/welch/0/df | tolerance | 11.543550101067417 | 11.543550101067417 | 3.02E-16 | 16 | passed |
/welch/0/p_value | tail_probability | 0.52538278122137905 | 0.525382781221377 | 2.00E-15 | 14 | passed |
/welch/1/present_count | exact | 19 | 19 | 0.00E+2 | passed | |
/welch/1/missing_count | exact | 4 | 4 | 0.00E+2 | passed | |
/welch/1/difference | tolerance | 0.33421052631578929 | 0.3342105263157893 | 1.37E-18 | 17 | passed |
/welch/1/t_value | tolerance | 1.5088073591886564 | 1.5088073591886564 | 1.71E-17 | 16 | passed |
/welch/1/df | tolerance | 7.8785468391037776 | 7.87854683910378 | 2.69E-15 | 15 | passed |
/welch/1/p_value | tail_probability | 0.17035788165279489 | 0.17035788165279483 | 5.53E-17 | 15 | passed |
/welch/2/present_count | exact | 15 | 15 | 0.00E+2 | passed | |
/welch/2/missing_count | exact | 4 | 4 | 0.00E+2 | passed | |
/welch/2/difference | tolerance | 0.37666666666666693 | 0.37666666666666604 | 8.91E-16 | 14 | passed |
/welch/2/t_value | tolerance | 0.86106998765791565 | 0.8610699876579135 | 2.11E-15 | 14 | passed |
/welch/2/df | tolerance | 7.0117718683739998 | 7.011771868374002 | 1.77E-15 | 15 | passed |
/welch/2/p_value | tail_probability | 0.41766888020344639 | 0.4176688802034474 | 1.00E-15 | 14 | passed |
/welch/3/present_count | exact | 19 | 19 | 0.00E+2 | passed | |
/welch/3/missing_count | exact | 4 | 4 | 0.00E+2 | passed | |
/welch/3/difference | tolerance | 0.061842105263157698 | 0.061842105263157254 | 4.44E-16 | 14 | passed |
/welch/3/t_value | tolerance | 0.21586980048900192 | 0.21586980048900037 | 1.55E-15 | 14 | passed |
/welch/3/df | tolerance | 5.1214660685228095 | 5.121466068522809 | 8.88E-16 | 15 | passed |
/welch/3/p_value | tail_probability | 0.83742432815470702 | 0.8374243281547082 | 1.22E-15 | 14 | passed |
/welch/4/present_count | exact | 19 | 19 | 0.00E+2 | passed | |
/welch/4/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/welch/4/status | exact | not computed: fewer than two cases in a group | not computed: fewer than two cases in a group | passed | ||
/welch/5/present_count | exact | 19 | 19 | 0.00E+2 | passed | |
/welch/5/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/welch/5/status | exact | not computed: fewer than two cases in a group | not computed: fewer than two cases in a group | passed | ||
/welch/6/present_count | exact | 16 | 16 | 0.00E+2 | passed | |
/welch/6/missing_count | exact | 3 | 3 | 0.00E+2 | passed | |
/welch/6/difference | tolerance | 0.29374999999999929 | 0.2937499999999993 | 5.43E-19 | 17 | passed |
/welch/6/t_value | tolerance | 0.6433850384639147 | 0.6433850384639147 | 4.64E-18 | 17 | passed |
/welch/6/df | tolerance | 4.1169108655431694 | 4.1169108655431685 | 8.59E-16 | 15 | passed |
/welch/6/p_value | tail_probability | 0.55406491411452952 | 0.5540649141145294 | 1.15E-16 | 15 | passed |
/welch/7/present_count | exact | 19 | 19 | 0.00E+2 | passed | |
/welch/7/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/welch/7/status | exact | not computed: fewer than two cases in a group | not computed: fewer than two cases in a group | passed | ||
/welch/8/present_count | exact | 20 | 20 | 0.00E+2 | passed | |
/welch/8/missing_count | exact | 3 | 3 | 0.00E+2 | passed | |
/welch/8/difference | tolerance | -0.0083333333333333037 | -0.008333333333333304 | 2.74E-20 | 17 | passed |
/welch/8/t_value | tolerance | -0.0259768624588647 | -0.025976862458864707 | 6.52E-18 | 15 | passed |
/welch/8/df | tolerance | 2.9555289566648146 | 2.9555289566648137 | 8.56E-16 | 15 | passed |
/welch/8/p_value | tail_probability | 0.98092994144196743 | 0.9809299414419674 | 4.56E-18 | 17 | passed |
Convention
- With the threshold at 1% the indicator z (one missing case) enters: its two comparisons have under two cases in the missing group and are reported as not computed, as is g->y; the nine rows are x->y, x->z, y->x, y->z, z->x, z->y, g->x, g->y, g->z.
- adjustment = none leaves the raw Welch p-values; no adjusted value is compared.
- The SPSS-style preset stops EM at a scaled change of 1e-4, so only the mean of x is compared, at relative tolerance 1e-3; the R EM is run to 1e-13.
- Expected computed from the exported CSV.
- docs/manual/chapters/89-missingness-diagnostics.tex:11-17: present/missing counts, mean, SD, counts outside Q1 - 1.5 IQR and Q3 + 1.5 IQR with interpolated quartiles; pattern table of distinct present/missing combinations.
- docs/manual/chapters/89-missingness-diagnostics.tex:19-24: a variable missing in at least the threshold percent splits the cases; Welch's test, difference = present minus missing; Holm over the whole computed family by default.
- docs/manual/chapters/89-missingness-diagnostics.tex:55-74: EM under the multivariate normal (tolerance 1e-6, 100 iterations; SPSS-style 1e-4, 25); Little's d^2 = sum_p n_p (ybar_p - mu)' Sigma_pp^-1 (ybar_p - mu), df = sum_p |O_p| - k.
Reference code
The lines of the reference script that produce this case's expected values.
277 w2 <- welch_rows(d, quant, "g", 1.0, "none")
278 stopifnot(identical(w2$indicators, c("x", "y", "z", "g")), length(w2$filtered) == 0)
279 not_computed <- which(vapply(w2$rows, function(r) r$status != "", TRUE))
280 stopifnot(identical(not_computed, c(5L, 6L, 8L))) # z->x, z->y and g->y have under two missing cases
281 outputs <- c(
282 list("/cases" = exact(nrow(d), "24 rows"),
283 "/em/status" = exact("converged", "EM converges under the SPSS-style preset (1e-4, 25 iterations)"),
284 "/em/tolerance" = tol(1e-4, "SPSS-style tolerance"),
285 "/em/max_iterations" = exact(25L, "SPSS-style iteration cap"),
286 "/em/means/0" = tol(em$mu[1], "EM mean of x (SPSS-style preset)", "1e-3"),
287 "/little/df" = exact(as.integer(lt$df), "Little df does not depend on the EM tolerance")),
288 welch_outputs(w2, seq_along(w2$rows))
289 )
290 emit("STAT-DESC-MVA-002", "Raw p-values, 1% indicator threshold, SPSS-style EM", "axis_coverage",
291 list(quantitative = list("x", "y", "z"), categorical = list("g"), min_percent = 1.0,
292 adjustment = "none", em_preset = "spss"),
293 outputs,
294 list("With the threshold at 1% the indicator z (one missing case) enters: its two comparisons have under two cases in the missing group and are reported as not computed, as is g->y; the nine rows are x->y, x->z, y->x, y->z, z->x, z->y, g->x, g->y, g->z.",
295 "adjustment = none leaves the raw Welch p-values; no adjusted value is compared.",
296 "The SPSS-style preset stops EM at a scaled change of 1e-4, so only the mean of x is compared, at relative tolerance 1e-3; the R EM is run to 1e-13."))
EM to a custom tolerance of 1e-10
Case STAT-DESC-MVA-003 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) with a hand-written multivariate-normal EM
- Citation
- Little, R. J. A. (1988). A test of missing completely at random for multivariate data with missing values. JASA 83:1198-1202; Dempster, Laird and Rubin (1977) JRSS B 39:1-38; R stats: quantile (type 7), t.test, p.adjust, pchisq, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_missing_values.R · sha256 1c2458fc190a7995
- Dataset
- reference_data/datasets/DESC_MVA_01.json
Settings compared
categorical= ["g"]em_max_iterations= 5000em_preset= "custom"em_tolerance= 1e-10quantitative= ["x", "y", "z"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cases | exact | 24 | 24 | 0.00E+2 | passed | |
/em/tolerance | tolerance | 1e-10 | 1e-10 | 3.64E-27 | passed | |
/em/max_iterations | exact | 5000 | 5000 | 0.00E+2 | passed | |
/em/status | exact | converged | converged | passed | ||
/em/cases_used | exact | 24 | 24 | 0.00E+2 | passed | |
/em/means/0 | tolerance | 5.7398331347312181 | 5.739833134505893 | 2.25E-10 | 10 | passed |
/em/means/1 | tolerance | 10.642187473578213 | 10.642187473847697 | 2.69E-10 | 10 | passed |
/em/means/2 | tolerance | 2.6016439119923782 | 2.6016439119846 | 7.78E-12 | 11 | passed |
/em/covariance/0/0 | tolerance | 0.79335654135973499 | 0.7933565415385857 | 1.79E-10 | 9 | passed |
/em/covariance/0/1 | tolerance | 1.0089779038620392 | 1.0089779038391669 | 2.29E-11 | 10 | passed |
/em/covariance/1/2 | tolerance | 0.64395896434169941 | 0.6439589643650621 | 2.34E-11 | 10 | passed |
/em/correlations/0/2 | tolerance | 0.9802313931866643 | 0.980231393219044 | 3.24E-11 | 10 | passed |
/em/log_likelihood | tolerance | -23.746389060077693 | -23.74638906007769 | 3.76E-15 | 15 | passed |
/little/status | exact | computed | computed | passed | ||
/little/statistic | tolerance | 13.602247198868017 | 13.602247198724152 | 1.44E-10 | 10 | passed |
/little/df | exact | 5 | 5 | 0.00E+2 | passed | |
/little/p_value | tail_probability | 0.018343510647349241 | 0.018343510648416994 | 1.07E-12 | 10 | passed |
/little/patterns | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Both EM runs stop near the same maximum (R at a scaled change of 1e-13, the product at 1e-10), so the EM estimates and Little's statistic are compared at relative tolerance 1e-7 and the p-value at 1e-6.
- The convergence check compares the largest scaled parameter change and the observed log-likelihood change with the tolerance.
- Expected computed from the exported CSV.
- docs/manual/chapters/89-missingness-diagnostics.tex:11-17: present/missing counts, mean, SD, counts outside Q1 - 1.5 IQR and Q3 + 1.5 IQR with interpolated quartiles; pattern table of distinct present/missing combinations.
- docs/manual/chapters/89-missingness-diagnostics.tex:19-24: a variable missing in at least the threshold percent splits the cases; Welch's test, difference = present minus missing; Holm over the whole computed family by default.
- docs/manual/chapters/89-missingness-diagnostics.tex:55-74: EM under the multivariate normal (tolerance 1e-6, 100 iterations; SPSS-style 1e-4, 25); Little's d^2 = sum_p n_p (ybar_p - mu)' Sigma_pp^-1 (ybar_p - mu), df = sum_p |O_p| - k.
Reference code
The lines of the reference script that produce this case's expected values.
299 outputs <- c(
300 list("/cases" = exact(nrow(d), "24 rows"),
301 "/em/tolerance" = tol(1e-10, "custom tolerance"),
302 "/em/max_iterations" = exact(5000L, "custom iteration cap")),
303 em_outputs(em, lt, "1e-7", "1e-6")
304 )
305 emit("STAT-DESC-MVA-003", "EM to a custom tolerance of 1e-10", "axis_coverage",
306 list(quantitative = list("x", "y", "z"), categorical = list("g"), em_preset = "custom",
307 em_tolerance = 1e-10, em_max_iterations = 5000L),
308 outputs,
309 list("Both EM runs stop near the same maximum (R at a scaled change of 1e-13, the product at 1e-10), so the EM estimates and Little's statistic are compared at relative tolerance 1e-7 and the p-value at 1e-6.",
310 "The convergence check compares the largest scaled parameter change and the observed log-likelihood change with the tolerance."))
Excluded rows leave the analysis population
Case STAT-DESC-MVA-004 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) with a hand-written multivariate-normal EM
- Citation
- Little, R. J. A. (1988). A test of missing completely at random for multivariate data with missing values. JASA 83:1198-1202; Dempster, Laird and Rubin (1977) JRSS B 39:1-38; R stats: quantile (type 7), t.test, p.adjust, pchisq, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_missing_values.R · sha256 1c2458fc190a7995
- Dataset
- reference_data/datasets/DESC_MVA_01.json
Settings compared
categorical= ["g"]quantitative= ["x", "y", "z"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cases | exact | 22 | 22 | 0.00E+2 | passed | |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed | |
/univariate/0/present | exact | 17 | 17 | 0.00E+2 | passed | |
/univariate/0/mean | tolerance | 5.7705882352941176 | 5.7705882352941185 | 8.62E-16 | 15 | passed |
/univariate/0/high_extremes | exact | 0 | 0 | 0.00E+2 | passed | |
/patterns_total | exact | 6 | 6 | 0.00E+2 | passed | |
/patterns/0/count | exact | 12 | 12 | 0.00E+2 | passed | |
/welch/0/present_count | exact | 13 | 13 | 0.00E+2 | passed | |
/welch/0/missing_count | exact | 5 | 5 | 0.00E+2 | passed | |
/welch/0/difference | tolerance | 0.17999999999999972 | 0.1800000000000015 | 1.77E-15 | 14 | passed |
/welch/0/t_value | tolerance | 0.34434634395378078 | 0.34434634395378416 | 3.38E-15 | 14 | passed |
/welch/0/df | tolerance | 10.886670231310807 | 10.88667023131081 | 2.24E-15 | 15 | passed |
/welch/0/p_value | tail_probability | 0.73714542320267062 | 0.737145423202668 | 2.66E-15 | 14 | passed |
/welch/0/adjusted_p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/welch/1/present_count | exact | 17 | 17 | 0.00E+2 | passed | |
/welch/1/missing_count | exact | 4 | 4 | 0.00E+2 | passed | |
/welch/1/difference | tolerance | 0.2852941176470587 | 0.28529411764705914 | 4.42E-16 | 14 | passed |
/welch/1/t_value | tolerance | 1.3013785491844536 | 1.3013785491844556 | 2.01E-15 | 14 | passed |
/welch/1/df | tolerance | 7.5511858359458586 | 7.5511858359458595 | 8.59E-16 | 15 | passed |
/welch/1/p_value | tail_probability | 0.23142699432530192 | 0.23142699432530142 | 4.98E-16 | 14 | passed |
/welch/1/adjusted_p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/em/status | exact | converged | converged | passed | ||
/em/cases_used | exact | 22 | 22 | 0.00E+2 | passed | |
/em/means/0 | tolerance | 5.6814495051234202 | 5.681447014617566 | 2.49E-6 | 6 | passed |
/em/means/1 | tolerance | 10.516616951521593 | 10.516619944179778 | 2.99E-6 | 6 | passed |
/em/means/2 | tolerance | 2.5570785814512855 | 2.5570784880638886 | 9.34E-8 | 7 | passed |
/em/covariance/0/0 | tolerance | 0.61998761134597657 | 0.6199889952898374 | 1.38E-6 | 5 | passed |
/em/covariance/0/1 | tolerance | 0.79799650419297308 | 0.7979958295209215 | 6.75E-7 | 6 | passed |
/em/covariance/1/2 | tolerance | 0.52062733844335085 | 0.5206275409229164 | 2.02E-7 | 6 | passed |
/em/correlations/0/2 | tolerance | 0.9741664948475296 | 0.9741670439787743 | 5.49E-7 | 6 | passed |
/em/log_likelihood | tolerance | -19.9840296172089 | -19.984029620795333 | 3.59E-9 | 9 | passed |
/little/status | exact | computed | computed | passed | ||
/little/statistic | tolerance | 13.664193894782329 | 13.664210583578015 | 1.67E-5 | 5 | passed |
/little/df | exact | 5 | 5 | 0.00E+2 | passed | |
/little/p_value | tail_probability | 0.017889257001353718 | 0.01788913609575424 | 1.21E-7 | 5 | passed |
/little/patterns | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Zero-based source rows 0 and 15 are excluded before every count, test and EM; the reference drops the same rows from the re-read CSV.
- Expected computed from the exported CSV.
- docs/manual/chapters/89-missingness-diagnostics.tex:11-17: present/missing counts, mean, SD, counts outside Q1 - 1.5 IQR and Q3 + 1.5 IQR with interpolated quartiles; pattern table of distinct present/missing combinations.
- docs/manual/chapters/89-missingness-diagnostics.tex:19-24: a variable missing in at least the threshold percent splits the cases; Welch's test, difference = present minus missing; Holm over the whole computed family by default.
- docs/manual/chapters/89-missingness-diagnostics.tex:55-74: EM under the multivariate normal (tolerance 1e-6, 100 iterations; SPSS-style 1e-4, 25); Little's d^2 = sum_p n_p (ybar_p - mu)' Sigma_pp^-1 (ybar_p - mu), df = sum_p |O_p| - k.
Reference code
The lines of the reference script that produce this case's expected values.
313 kept <- d[-c(1, 16), , drop = FALSE] # zero-based source rows 0 and 15 are excluded
314 ux4 <- univariate(kept$x)
315 w4 <- welch_rows(kept, quant, "g", 5.0, "holm")
316 stopifnot(identical(w4$indicators, c("x", "y", "g")))
317 pt4 <- pattern_table(kept, c(quant, "g"))
318 em4 <- em_mvn(as.matrix(kept[quant]), 1e-13, 20000)
319 lt4 <- little(em4)
320 outputs <- c(
321 list("/cases" = exact(nrow(kept), "22 rows after excluding two"),
322 "/excluded_count" = exact(2L, "two excluded rows"),
323 "/univariate/0/present" = exact(as.integer(ux4$present), "x present without the excluded rows"),
324 "/univariate/0/mean" = tol(ux4$mean, "x mean without the excluded rows"),
325 "/univariate/0/high_extremes" = exact(as.integer(ux4$high), "x high extremes without row 15 (7.9)"),
326 "/patterns_total" = exact(as.integer(pt4$total), "patterns without the excluded rows"),
327 "/patterns/0/count" = exact(pt4$first_count, "most frequent pattern count without the excluded rows")),
328 welch_outputs(w4, 1:2),
329 em_outputs(em4, lt4, "1e-4", "1e-4")
330 )
331 emit("STAT-DESC-MVA-004", "Excluded rows leave the analysis population", "missing_excluded",
332 list(quantitative = list("x", "y", "z"), categorical = list("g")),
333 outputs,
334 list("Zero-based source rows 0 and 15 are excluded before every count, test and EM; the reference drops the same rows from the re-read CSV."),
335 excluded = list(0L, 15L))
Probability calculator: normal
Case STAT-DESC-PROBCALC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "normal", "mean": 10, "standard_deviation": 2}interval= {"lower": 8, "upper": 12}probabilities= [0.025, 0.5, 0.95]x_values= [7, 10, 13.5, 20]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/density | tolerance | 0.064758797832945872 | 0.06475879783294587 | 1.14E-19 | 17 | passed |
/values/0/cdf | tail_probability | 0.066807201268858071 | 0.06680720126885807 | 3.08E-19 | 17 | passed |
/values/0/sf | tail_probability | 0.93319279873114191 | 0.9331927987311419 | 4.81E-18 | 17 | passed |
/values/0/log10_cdf | tolerance | -1.1751767216148163 | -1.1751767216148163 | 4.42E-17 | 16 | passed |
/values/0/log10_sf | tolerance | -0.030028621232115648 | -0.030028621232115648 | 1.54E-20 | 18 | passed |
/values/0/mass | absent | None | passed | |||
/values/1/density | tolerance | 0.19947114020071635 | 0.19947114020071635 | 1.43E-18 | 17 | passed |
/values/1/cdf | tail_probability | 0.5 | 0.5 | 0.00E+1 | passed | |
/values/1/sf | tail_probability | 0.5 | 0.5 | 0.00E+1 | passed | |
/values/1/log10_cdf | tolerance | -0.30102999566398114 | -0.30102999566398114 | 2.51E-18 | 17 | passed |
/values/1/log10_sf | tolerance | -0.30102999566398114 | -0.30102999566398114 | 2.51E-18 | 17 | passed |
/values/1/mass | absent | None | passed | |||
/values/2/density | tolerance | 0.043138659413255766 | 0.043138659413255766 | 2.49E-19 | 17 | passed |
/values/2/cdf | tail_probability | 0.95994084313618289 | 0.9599408431361829 | 3.60E-18 | 17 | passed |
/values/2/sf | tail_probability | 0.0400591568638171 | 0.040059156863817086 | 1.42E-17 | 15 | passed |
/values/2/log10_cdf | tolerance | -0.01775552976369445 | -0.017755529763694444 | 6.45E-18 | 15 | passed |
/values/2/log10_sf | tolerance | -1.3972981956626405 | -1.3972981956626407 | 1.85E-16 | 15 | passed |
/values/2/mass | absent | None | passed | |||
/values/3/density | tolerance | 7.4335975736714884e-07 | 7.433597573671489e-07 | 1.05E-22 | 15 | passed |
/values/3/cdf | tail_probability | 0.99999971334842808 | 0.9999997133484281 | 3.54E-18 | 17 | passed |
/values/3/sf | tail_probability | 2.8665157187919391e-07 | 2.866515718791933e-07 | 6.33E-22 | 14 | passed |
/values/3/log10_cdf | tolerance | -1.2449121373882915e-07 | -1.244912137388289e-07 | 2.63E-22 | 14 | passed |
/values/3/log10_sf | tolerance | -6.5426456723906536 | -6.5426456723906545 | 9.32E-16 | 15 | passed |
/values/3/mass | absent | None | passed | |||
/quantiles/0/lower_quantile | tolerance | 6.0800720309198919 | 6.080072030919891 | 8.87E-16 | 15 | passed |
/quantiles/0/upper_quantile | tolerance | 13.919927969080108 | 13.91992796908011 | 1.88E-15 | 15 | passed |
/quantiles/1/lower_quantile | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/quantiles/1/upper_quantile | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/quantiles/2/lower_quantile | tolerance | 13.289707253902943 | 13.289707253902945 | 1.83E-15 | 15 | passed |
/quantiles/2/upper_quantile | tolerance | 6.7102927460970569 | 6.710292746097055 | 1.73E-15 | 15 | passed |
/interval/probability | tolerance | 0.68268949213708585 | 0.6826894921370859 | 1.55E-18 | 17 | passed |
/interval/complement | tolerance | 0.31731050786291409 | 0.31731050786291415 | 5.84E-17 | 15 | passed |
/distribution/mean | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/distribution/variance | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/distribution/kind | exact | continuous | continuous | passed | ||
/distribution/support_upper | absent | None | passed |
Convention
- Family normal evaluated with R's d/p/q functions and log.p tails.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Probability calculator: t
Case STAT-DESC-PROBCALC-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "t", "degrees_of_freedom": 4.5}interval= {"lower": -1, "upper": 2}probabilities= [0.01, 0.5, 0.975]x_values= [-3, 0, 1.25, 6]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/density | tolerance | 0.018402946650727739 | 0.018402946650727735 | 3.53E-18 | 15 | passed |
/values/0/cdf | tail_probability | 0.017190433944379805 | 0.01719043394437981 | 3.48E-18 | 15 | passed |
/values/0/sf | tail_probability | 0.9828095660556202 | 0.9828095660556202 | 1.55E-18 | 17 | passed |
/values/0/log10_cdf | tolerance | -1.7647131601209227 | -1.7647131601209227 | 1.92E-17 | 16 | passed |
/values/0/log10_sf | tolerance | -0.0075306250196421074 | -0.007530625019642107 | 2.25E-20 | 17 | passed |
/values/0/mass | absent | None | passed | |||
/values/1/density | tolerance | 0.37754682083186558 | 0.3775468208318656 | 1.61E-18 | 17 | passed |
/values/1/cdf | tail_probability | 0.5 | 0.5 | 0.00E+1 | passed | |
/values/1/sf | tail_probability | 0.5 | 0.5 | 0.00E+1 | passed | |
/values/1/log10_cdf | tolerance | -0.30102999566398114 | -0.30102999566398114 | 2.51E-18 | 17 | passed |
/values/1/log10_sf | tolerance | -0.30102999566398114 | -0.30102999566398114 | 2.51E-18 | 17 | passed |
/values/1/mass | absent | None | passed | |||
/values/2/density | tolerance | 0.16634621119519663 | 0.16634621119519666 | 2.82E-17 | 15 | passed |
/values/2/cdf | tail_probability | 0.86381748079158527 | 0.8638174807915853 | 1.79E-18 | 17 | passed |
/values/2/sf | tail_probability | 0.13618251920841468 | 0.1361825192084147 | 2.40E-17 | 15 | passed |
/values/2/log10_cdf | tolerance | -0.06357801152432975 | -0.06357801152432975 | 3.84E-21 | 19 | passed |
/values/2/log10_sf | tolerance | -0.86587863617182126 | -0.8658786361718213 | 1.25E-18 | 17 | passed |
/values/2/mass | absent | None | passed | |||
/values/3/density | tolerance | 0.00089702369810273691 | 0.0008970236981027363 | 6.53E-19 | 15 | passed |
/values/3/cdf | tail_probability | 0.99867926209722424 | 0.9986792620972242 | 6.91E-19 | 18 | passed |
/values/3/sf | tail_probability | 0.0013207379027757908 | 0.0013207379027757914 | 6.02E-19 | 15 | passed |
/values/3/log10_cdf | tolerance | -0.0005739682975473237 | -0.0005739682975473239 | 2.15E-19 | 15 | passed |
/values/3/log10_sf | tolerance | -2.8791833585185782 | -2.879183358518578 | 6.29E-18 | 17 | passed |
/values/3/mass | absent | None | passed | |||
/quantiles/0/lower_quantile | tolerance | -3.5270508906260951 | -3.5270508906260924 | 2.65E-15 | 15 | passed |
/quantiles/0/upper_quantile | tolerance | 3.5270508906260951 | 3.5270508906260924 | 2.65E-15 | 15 | passed |
/quantiles/1/lower_quantile | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/quantiles/1/upper_quantile | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/quantiles/2/lower_quantile | tolerance | 2.6589123472044025 | 2.6589123472044034 | 8.92E-16 | 15 | passed |
/quantiles/2/upper_quantile | tolerance | -2.6589123472044025 | -2.6589123472044034 | 8.92E-16 | 15 | passed |
/interval/probability | tolerance | 0.7618685044693434 | 0.7618685044693433 | 1.12E-16 | 15 | passed |
/interval/complement | tolerance | 0.23813149553065663 | 0.23813149553065674 | 1.09E-16 | 15 | passed |
/distribution/mean | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/distribution/variance | tolerance | 1.8 | 1.8 | 4.44E-17 | 16 | passed |
/distribution/kind | exact | continuous | continuous | passed | ||
/distribution/support_upper | absent | None | passed |
Convention
- Family t evaluated with R's d/p/q functions and log.p tails.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Probability calculator: chi_square
Case STAT-DESC-PROBCALC-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "chi_square", "degrees_of_freedom": 7}interval= {"lower": 2, "upper": 12}probabilities= [0.05, 0.5, 0.95]x_values= [0.5, 7, 14, 30]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/density | tolerance | 0.0036615940788976859 | 0.0036615940788976894 | 3.48E-18 | 15 | passed |
/values/0/cdf | tail_probability | 0.00055351860957503435 | 0.000553518609575035 | 6.52E-19 | 14 | passed |
/values/0/sf | tail_probability | 0.99944648139042513 | 0.9994464813904249 | 2.18E-16 | 15 | passed |
/values/0/log10_cdf | tolerance | -3.256867773340117 | -3.256867773340117 | 1.16E-17 | 17 | passed |
/values/0/log10_sf | tolerance | -0.00024045663252066145 | -0.00024045663252066153 | 7.89E-20 | 15 | passed |
/values/0/mass | absent | None | passed | |||
/values/1/density | tolerance | 0.10411977480817197 | 0.10411977480817192 | 5.35E-17 | 15 | passed |
/values/1/cdf | tail_probability | 0.57112014244694531 | 0.5711201424469454 | 1.12E-16 | 15 | passed |
/values/1/sf | tail_probability | 0.42887985755305469 | 0.42887985755305486 | 1.65E-16 | 15 | passed |
/values/1/log10_cdf | tolerance | -0.24327252272911862 | -0.2432725227291187 | 8.09E-17 | 15 | passed |
/values/1/log10_sf | tolerance | -0.36766435002806902 | -0.36766435002806896 | 5.53E-17 | 15 | passed |
/values/1/mass | absent | None | passed | |||
/values/2/density | tolerance | 0.017785968656399271 | 0.017785968656399264 | 6.97E-18 | 15 | passed |
/values/2/cdf | tail_probability | 0.9488186465869346 | 0.9488186465869346 | 2.04E-19 | 18 | passed |
/values/2/sf | tail_probability | 0.051181353413065456 | 0.051181353413065414 | 4.19E-17 | 15 | passed |
/values/2/log10_cdf | tolerance | -0.022816788956374855 | -0.022816788956374845 | 1.01E-17 | 15 | passed |
/values/2/log10_sf | tolerance | -1.2908882340397962 | -1.2908882340397965 | 2.67E-16 | 15 | passed |
/values/2/mass | absent | None | passed | |||
/values/3/density | tolerance | 4.0105572021449396e-05 | 4.0105572021449416e-05 | 2.04E-20 | 15 | passed |
/values/3/cdf | tail_probability | 0.99990504027491867 | 0.9999050402749187 | 3.88E-18 | 17 | passed |
/values/3/sf | tail_probability | 9.4959725081341848e-05 | 9.495972508134177e-05 | 8.15E-20 | 15 | passed |
/values/3/log10_cdf | tolerance | -4.1242442822385615e-05 | -4.124244282238553e-05 | 8.82E-20 | 14 | passed |
/values/3/log10_sf | tolerance | -4.0224605513810658 | -4.022460551381067 | 9.29E-16 | 15 | passed |
/values/3/mass | absent | None | passed | |||
/quantiles/0/lower_quantile | tolerance | 2.1673499092980575 | 2.167349909298057 | 4.58E-16 | 15 | passed |
/quantiles/0/upper_quantile | tolerance | 14.067140449340167 | 14.067140449340167 | 5.21E-17 | 17 | passed |
/quantiles/1/lower_quantile | tolerance | 6.3458111955215166 | 6.345811195521515 | 1.75E-15 | 15 | passed |
/quantiles/1/upper_quantile | tolerance | 6.3458111955215166 | 6.345811195521515 | 1.75E-15 | 15 | passed |
/quantiles/2/lower_quantile | tolerance | 14.067140449340167 | 14.067140449340169 | 1.83E-15 | 15 | passed |
/quantiles/2/upper_quantile | tolerance | 2.1673499092980575 | 2.167349909298058 | 4.31E-16 | 15 | passed |
/interval/probability | tolerance | 0.85928150022174277 | 0.8592815002217428 | 3.32E-18 | 17 | passed |
/interval/complement | tolerance | 0.14071849977825729 | 0.1407184997782572 | 8.44E-17 | 15 | passed |
/distribution/mean | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/distribution/variance | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/distribution/kind | exact | continuous | continuous | passed | ||
/distribution/support_lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/distribution/support_upper | absent | None | passed |
Convention
- Family chi_square evaluated with R's d/p/q functions and log.p tails.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Probability calculator: f
Case STAT-DESC-PROBCALC-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "f", "numerator_df": 3, "denominator_df": 12}interval= {"lower": 0.5, "upper": 4}probabilities= [0.1, 0.5, 0.99]x_values= [0.25, 1, 3.49, 9]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/density | tolerance | 0.69794243270817158 | 0.6979424327081724 | 7.76E-16 | 14 | passed |
/values/0/cdf | tail_probability | 0.14019377157358107 | 0.14019377157358118 | 1.07E-16 | 15 | passed |
/values/0/sf | tail_probability | 0.85980622842641896 | 0.8598062284264189 | 1.10E-16 | 15 | passed |
/values/0/log10_cdf | tolerance | -0.85327128045859713 | -0.8532712804585968 | 3.37E-16 | 15 | passed |
/values/0/log10_sf | tolerance | -0.065599413183390506 | -0.06559941318339055 | 4.21E-17 | 15 | passed |
/values/0/mass | absent | None | passed | |||
/values/1/density | tolerance | 0.41256420166237401 | 0.41256420166237445 | 4.42E-16 | 14 | passed |
/values/1/cdf | tail_probability | 0.57377862073521035 | 0.57377862073521 | 3.29E-16 | 15 | passed |
/values/1/sf | tail_probability | 0.42622137926478965 | 0.4262213792647899 | 2.74E-16 | 15 | passed |
/values/1/log10_cdf | tolerance | -0.24125563780787154 | -0.24125563780787174 | 1.97E-16 | 15 | passed |
/values/1/log10_sf | tolerance | -0.37036476986382483 | -0.37036476986382455 | 2.80E-16 | 15 | passed |
/values/1/mass | absent | None | passed | |||
/values/2/density | tolerance | 0.037201945710318776 | 0.03720194571031878 | 7.11E-18 | 15 | passed |
/values/2/cdf | tail_probability | 0.94998903352822306 | 0.9499890335282232 | 1.10E-16 | 15 | passed |
/values/2/sf | tail_probability | 0.050010966471776913 | 0.05001096647177692 | 7.06E-18 | 15 | passed |
/values/2/log10_cdf | tolerance | -0.022281408085539842 | -0.022281408085539845 | 3.12E-18 | 15 | passed |
/values/2/log10_sf | tolerance | -1.3009347525448358 | -1.3009347525448358 | 1.52E-17 | 16 | passed |
/values/2/mass | absent | None | passed | |||
/values/3/density | tolerance | 0.0009556804157382241 | 0.0009556804157382265 | 2.39E-18 | 14 | passed |
/values/3/cdf | tail_probability | 0.99786532837513731 | 0.9978653283751374 | 1.07E-16 | 15 | passed |
/values/3/sf | tail_probability | 0.0021346716248626901 | 0.00213467162486269 | 1.40E-20 | 17 | passed |
/values/3/log10_cdf | tolerance | -0.00092806701931578397 | -0.0009280670193157838 | 2.12E-19 | 15 | passed |
/values/3/log10_sf | tolerance | -2.6706689227366072 | -2.670668922736607 | 3.52E-17 | 16 | passed |
/values/3/mass | absent | None | passed | |||
/quantiles/0/lower_quantile | tolerance | 0.19173183942408745 | 0.19173183942408747 | 2.46E-17 | 15 | passed |
/quantiles/0/upper_quantile | tolerance | 2.6055249208306783 | 2.6055249208306783 | 2.60E-17 | 17 | passed |
/quantiles/1/lower_quantile | tolerance | 0.8353058985682873 | 0.8353058985682879 | 5.52E-16 | 15 | passed |
/quantiles/1/upper_quantile | tolerance | 0.8353058985682873 | 0.8353058985682879 | 5.52E-16 | 15 | passed |
/quantiles/2/lower_quantile | tolerance | 5.9525446815458665 | 5.952544681545868 | 1.74E-15 | 15 | passed |
/quantiles/2/upper_quantile | tolerance | 0.036966090543907981 | 0.03696609054390817 | 1.88E-16 | 14 | passed |
/interval/probability | tolerance | 0.65467900670600476 | 0.6546790067060051 | 3.35E-16 | 15 | passed |
/interval/complement | tolerance | 0.34532099329399518 | 0.3453209932939951 | 5.35E-17 | 15 | passed |
/distribution/mean | tolerance | 1.2 | 1.2 | 4.44E-17 | 16 | passed |
/distribution/variance | tolerance | 1.5600000000000001 | 1.56 | 4.67E-17 | 16 | passed |
/distribution/kind | exact | continuous | continuous | passed | ||
/distribution/support_lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/distribution/support_upper | absent | None | passed |
Convention
- Family f evaluated with R's d/p/q functions and log.p tails.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Probability calculator: exponential
Case STAT-DESC-PROBCALC-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "exponential", "scale": 2.5}interval= {"lower": 1, "upper": 4}probabilities= [0.05, 0.5, 0.9]x_values= [0.1, 1, 2.5, 12]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/density | tolerance | 0.38431577566092928 | 0.3843157756609293 | 1.89E-18 | 17 | passed |
/values/0/cdf | tail_probability | 0.039210560847676795 | 0.03921056084767678 | 1.36E-17 | 15 | passed |
/values/0/sf | tail_probability | 0.96078943915232318 | 0.9607894391523232 | 3.04E-18 | 17 | passed |
/values/0/log10_cdf | tolerance | -1.406596945730672 | -1.4065969457306722 | 1.77E-16 | 15 | passed |
/values/0/log10_sf | tolerance | -0.017371779276130071 | -0.01737177927613007 | 4.15E-19 | 16 | passed |
/values/0/mass | absent | None | passed | |||
/values/1/density | tolerance | 0.26812801841425571 | 0.2681280184142557 | 1.19E-18 | 17 | passed |
/values/1/cdf | tail_probability | 0.32967995396436073 | 0.3296799539643607 | 5.75E-17 | 15 | passed |
/values/1/sf | tail_probability | 0.67032004603563933 | 0.6703200460356393 | 2.46E-18 | 17 | passed |
/values/1/log10_cdf | tolerance | -0.4819074591271999 | -0.4819074591272 | 1.11E-16 | 15 | passed |
/values/1/log10_sf | tolerance | -0.17371779276130073 | -0.17371779276130073 | 3.33E-18 | 16 | passed |
/values/1/mass | absent | None | passed | |||
/values/2/density | tolerance | 0.14715177646857694 | 0.14715177646857694 | 8.39E-19 | 17 | passed |
/values/2/cdf | tail_probability | 0.63212055882855767 | 0.6321205588285577 | 4.02E-18 | 17 | passed |
/values/2/sf | tail_probability | 0.36787944117144233 | 0.36787944117144233 | 4.02E-18 | 16 | passed |
/values/2/log10_cdf | tolerance | -0.19920008462778144 | -0.19920008462778144 | 2.57E-18 | 16 | passed |
/values/2/log10_sf | tolerance | -0.43429448190325176 | -0.43429448190325176 | 1.16E-18 | 17 | passed |
/values/2/mass | absent | None | passed | |||
/values/3/density | tolerance | 0.0032918988196080122 | 0.0032918988196080122 | 3.46E-20 | 16 | passed |
/values/3/cdf | tail_probability | 0.99177025295097998 | 0.99177025295098 | 2.55E-19 | 18 | passed |
/values/3/sf | tail_probability | 0.0082297470490200302 | 0.00822974704902003 | 4.71E-20 | 17 | passed |
/values/3/log10_cdf | tolerance | -0.0035889220309802627 | -0.0035889220309802627 | 4.16E-20 | 16 | passed |
/values/3/log10_sf | tolerance | -2.0846135131356087 | -2.0846135131356087 | 2.00E-17 | 17 | passed |
/values/3/mass | absent | None | passed | |||
/quantiles/0/lower_quantile | tolerance | 0.12823323596887634 | 0.12823323596887634 | 1.24E-18 | 17 | passed |
/quantiles/0/upper_quantile | tolerance | 7.4893306838849769 | 7.489330683884977 | 1.36E-17 | 17 | passed |
/quantiles/1/lower_quantile | tolerance | 1.7328679513998633 | 1.7328679513998633 | 2.89E-17 | 16 | passed |
/quantiles/1/upper_quantile | tolerance | 1.7328679513998633 | 1.7328679513998633 | 2.89E-17 | 16 | passed |
/quantiles/2/lower_quantile | tolerance | 5.7564627324851152 | 5.756462732485115 | 3.18E-18 | 18 | passed |
/quantiles/2/upper_quantile | tolerance | 0.26340128914456573 | 0.26340128914456573 | 1.17E-18 | 17 | passed |
/interval/probability | tolerance | 0.46842352804098392 | 0.46842352804098397 | 5.19E-17 | 15 | passed |
/interval/complement | tolerance | 0.53157647195901614 | 0.531576471959016 | 1.12E-16 | 15 | passed |
/distribution/mean | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/distribution/variance | tolerance | 6.25 | 6.25 | 0.00E+0 | passed | |
/distribution/kind | exact | continuous | continuous | passed | ||
/distribution/support_lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/distribution/support_upper | absent | None | passed |
Convention
- Family exponential evaluated with R's d/p/q functions and log.p tails.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Probability calculator: weibull
Case STAT-DESC-PROBCALC-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "weibull", "shape": 1.7, "scale": 3}interval= {"lower": 1, "upper": 5}probabilities= [0.1, 0.632, 0.99]x_values= [0.2, 1.5, 3, 9]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/density | tolerance | 0.084278032270239736 | 0.08427803227023974 | 9.01E-20 | 17 | passed |
/values/0/cdf | tail_probability | 0.0099648777577398817 | 0.00996487775773988 | 1.72E-18 | 15 | passed |
/values/0/sf | tail_probability | 0.99003512224226009 | 0.9900351222422601 | 5.30E-19 | 18 | passed |
/values/0/log10_cdf | tolerance | -2.0015280245565346 | -2.0015280245565346 | 4.26E-17 | 16 | passed |
/values/0/log10_sf | tolerance | -0.0043493982050363681 | -0.004349398205036368 | 2.84E-20 | 17 | passed |
/values/0/mass | absent | None | passed | |||
/values/1/density | tolerance | 0.25641112456594933 | 0.25641112456594933 | 3.22E-18 | 16 | passed |
/values/1/cdf | tail_probability | 0.26492746924321325 | 0.26492746924321325 | 3.86E-18 | 16 | passed |
/values/1/sf | tail_probability | 0.73507253075678669 | 0.7350725307567867 | 6.31E-19 | 18 | passed |
/values/1/log10_cdf | tolerance | -0.57687300915367401 | -0.576873009153674 | 1.08E-19 | 18 | passed |
/values/1/log10_sf | tolerance | -0.13366980628542832 | -0.13366980628542832 | 1.99E-18 | 16 | passed |
/values/1/mass | absent | None | passed | |||
/values/2/density | tolerance | 0.20846501666381731 | 0.2084650166638173 | 3.39E-19 | 17 | passed |
/values/2/cdf | tail_probability | 0.63212055882855767 | 0.6321205588285577 | 4.02E-18 | 17 | passed |
/values/2/sf | tail_probability | 0.36787944117144233 | 0.36787944117144233 | 4.02E-18 | 16 | passed |
/values/2/log10_cdf | tolerance | -0.19920008462778144 | -0.19920008462778144 | 2.57E-18 | 16 | passed |
/values/2/log10_sf | tolerance | -0.43429448190325176 | -0.43429448190325176 | 1.16E-18 | 17 | passed |
/values/2/mass | absent | None | passed | |||
/values/3/density | tolerance | 0.0018885172616293357 | 0.0018885172616293357 | 4.76E-20 | 16 | passed |
/values/3/cdf | tail_probability | 0.99845542708910351 | 0.9984554270891035 | 1.18E-18 | 17 | passed |
/values/3/sf | tail_probability | 0.0015445729108965209 | 0.0015445729108965209 | 1.27E-20 | 17 | passed |
/values/3/log10_cdf | tolerance | -0.00067131807552373403 | -0.000671318075523734 | 4.66E-21 | 17 | passed |
/values/3/log10_sf | tolerance | -2.8111915861953847 | -2.8111915861953847 | 2.71E-17 | 17 | passed |
/values/3/mass | absent | None | passed | |||
/quantiles/0/lower_quantile | tolerance | 0.79840986509023903 | 0.798409865090239 | 4.83E-18 | 17 | passed |
/quantiles/0/upper_quantile | tolerance | 4.8999235815954414 | 4.899923581595441 | 9.15E-18 | 17 | passed |
/quantiles/1/lower_quantile | tolerance | 2.9994217388932167 | 2.9994217388932167 | 2.68E-17 | 17 | passed |
/quantiles/1/upper_quantile | tolerance | 1.8971989885481144 | 1.8971989885481144 | 1.78E-17 | 17 | passed |
/quantiles/2/lower_quantile | tolerance | 7.3665777159567787 | 7.366577715956779 | 1.75E-17 | 17 | passed |
/quantiles/2/upper_quantile | tolerance | 0.20041644650915896 | 0.20041644650915896 | 3.09E-18 | 16 | passed |
/interval/probability | tolerance | 0.764590236422511 | 0.764590236422511 | 4.83E-18 | 17 | passed |
/interval/complement | tolerance | 0.235409763577489 | 0.235409763577489 | 4.83E-18 | 16 | passed |
/distribution/mean | tolerance | 2.6767335074979726 | 2.676733507497972 | 4.80E-16 | 15 | passed |
/distribution/variance | tolerance | 2.6266934452126831 | 2.626693445212684 | 8.97E-16 | 15 | passed |
/distribution/kind | exact | continuous | continuous | passed | ||
/distribution/support_lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/distribution/support_upper | absent | None | passed |
Convention
- Family weibull evaluated with R's d/p/q functions and log.p tails.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Binomial(10, 1/2): P(2 < X <= 5)
Case STAT-DESC-PROBCALC-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "binomial", "trials": 10, "probability": 0.5}interval= {"lower": 2, "upper": 5, "lower_inclusive": false}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/interval/probability | tolerance | 0.568359375 | 0.568359375 | 0.00E-7 | passed | |
/interval/integer_lower | exact | 3 | 3 | 0.00E+2 | passed | |
/interval/integer_upper | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- Manual chapter 61 line 65: for Binomial(10, 1/2) the probability P(2 < X <= 5) is 582/1024.
- R: sum(dbinom(3:5, 10, 0.5)) * 1024 = 582.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Binomial(10, 1/2): P(2 <= X < 5)
Case STAT-DESC-PROBCALC-008 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "binomial", "trials": 10, "probability": 0.5}interval= {"lower": 2, "upper": 5, "upper_inclusive": false}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/interval/probability | tolerance | 0.36621093749999994 | 0.3662109375 | 6.00E-17 | 15 | passed |
/interval/integer_lower | exact | 2 | 2 | 0.00E+2 | passed | |
/interval/integer_upper | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Manual chapter 61 line 66: for Binomial(10, 1/2) the probability P(2 <= X < 5) is 375/1024.
- R: sum(dbinom(2:4, 10, 0.5)) * 1024 = 375.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Poisson(3.7) values and discrete quantiles
Case STAT-DESC-PROBCALC-009 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "poisson", "mean": 3.7}probabilities= [0.05, 0.5, 0.95]x_values= [0, 2, 2.5, 9]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/mass | tolerance | 0.024723526470339388 | 0.024723526470339388 | 1.06E-19 | 17 | passed |
/values/0/cdf | tail_probability | 0.024723526470339388 | 0.02472352647033939 | 3.58E-18 | 15 | passed |
/values/0/sf | tail_probability | 0.97527647352966063 | 0.9752764735296606 | 4.23E-18 | 17 | passed |
/values/0/density | absent | None | passed | |||
/values/0/in_support | exact | True | True | passed | ||
/values/1/mass | tolerance | 0.16923253868947313 | 0.16923253868947313 | 3.16E-18 | 16 | passed |
/values/1/cdf | tail_probability | 0.28543311310006825 | 0.2854331131000683 | 5.31E-17 | 15 | passed |
/values/1/sf | tail_probability | 0.71456688689993175 | 0.7145668868999318 | 2.45E-18 | 17 | passed |
/values/1/density | absent | None | passed | |||
/values/1/in_support | exact | True | True | passed | ||
/values/2/mass | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/values/2/cdf | tail_probability | 0.28543311310006825 | 0.2854331131000683 | 5.31E-17 | 15 | passed |
/values/2/sf | tail_probability | 0.71456688689993175 | 0.7145668868999318 | 2.45E-18 | 17 | passed |
/values/2/density | absent | None | passed | |||
/values/2/in_support | exact | False | False | passed | ||
/values/3/mass | tolerance | 0.0088544767249640333 | 0.008854476724964042 | 8.64E-18 | 15 | passed |
/values/3/cdf | tail_probability | 0.99515166261084564 | 0.9951516626108456 | 4.25E-18 | 17 | passed |
/values/3/sf | tail_probability | 0.0048483373891543783 | 0.004848337389154387 | 8.67E-18 | 14 | passed |
/values/3/density | absent | None | passed | |||
/values/3/in_support | exact | True | True | passed | ||
/quantiles/0/lower_quantile | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/quantiles/0/upper_quantile | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/quantiles/0/achieved_cdf | tail_probability | 0.11620057441059516 | 0.11620057441059513 | 3.17E-17 | 15 | passed |
/quantiles/0/achieved_sf | tail_probability | 0.035240730472139034 | 0.035240730472139034 | 9.07E-20 | 17 | passed |
/quantiles/1/lower_quantile | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/quantiles/1/upper_quantile | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/quantiles/1/achieved_cdf | tail_probability | 0.68721936537199235 | 0.6872193653719924 | 2.29E-18 | 17 | passed |
/quantiles/1/achieved_sf | tail_probability | 0.31278063462800765 | 0.31278063462800765 | 2.29E-18 | 17 | passed |
/quantiles/2/lower_quantile | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/quantiles/2/upper_quantile | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/quantiles/2/achieved_cdf | tail_probability | 0.96475926952786095 | 0.964759269527861 | 2.03E-18 | 17 | passed |
/quantiles/2/achieved_sf | tail_probability | 0.88379942558940483 | 0.8837994255894048 | 1.06E-19 | 18 | passed |
/distribution/mean | tolerance | 3.7000000000000002 | 3.7 | 2.24E-17 | 17 | passed |
/distribution/variance | tolerance | 3.7000000000000002 | 3.7 | 2.24E-17 | 17 | passed |
Convention
- R qpois gives the smallest k with F(k) >= p; the upper value is found by increasing k until S(k) <= p.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Quantile at a cumulative step returns that step
Case STAT-DESC-PROBCALC-010 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "binomial", "trials": 4, "probability": 0.5}probabilities= [0.3125]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/quantiles/0/lower_quantile | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/quantiles/0/achieved_cdf | tail_probability | 0.31250000000000006 | 0.3125 | 6.00E-17 | 15 | passed |
Convention
- pbinom(1, 4, 0.5) = 0.31250000000000006 = 5/16, a binary-exact value.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Upper tail below the double range keeps its logarithm
Case STAT-DESC-PROBCALC-011 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "normal", "mean": 0, "standard_deviation": 1}x_values= [40]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/sf | representation_bound | 0.0 | passed | |||
/values/0/log10_sf | tolerance | -349.43700645934581 | -349.43700645934587 | 5.65E-14 | 15 | passed |
/values/0/cdf | tail_probability | 1 | 1.0 | 0.00E+2 | passed |
Convention
- R: pnorm(40, lower.tail = FALSE, log.p = TRUE) / log(10) = -349.43700645934581.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Student t with one degree of freedom has no mean
Case STAT-DESC-PROBCALC-012 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "t", "degrees_of_freedom": 1}x_values= [1]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/distribution/mean | absent | None | passed | |||
/distribution/variance | absent | None | passed | |||
/values/0/cdf | tail_probability | 0.75000000000000022 | 0.75 | 2.20E-16 | 15 | passed |
/warnings | contains | ['The mean is undefined'] | ['The mean is undefined for these parameters.'] | passed |
Convention
- Student t with df = 1 is the Cauchy distribution; pt(1, 1) = 0.75.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
Binomial with p = 0 is degenerate
Case STAT-DESC-PROBCALC-013 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "binomial", "trials": 5, "probability": 0}x_values= [0, 1]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/values/0/mass | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/values/1/mass | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/warnings | contains | ['degenerate'] | ['The binomial distribution is degenerate at a single value. | passed |
Convention
- dbinom(0, 5, 0) = 1 and dbinom(1, 5, 0) = 0.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
A quantile probability of 1 is refused
Case STAT-DESC-PROBCALC-014 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "normal"}probabilities= [1]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 54: each probability must lie strictly between 0 and 1.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
A negative standard deviation is refused
Case STAT-DESC-PROBCALC-015 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "normal", "standard_deviation": -1}x_values= [0]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 18: sigma must be positive.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
An empty request is refused
Case STAT-DESC-PROBCALC-016 · status: passed
Reference
- Evidence type
- R
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
distribution= {"family": "poisson", "mean": 2}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Method details line 138: an empty request fails.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
OLS profile, desirability and the best corner
Case STAT-DESC-PROFILER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm/glm coefficients with hand-coded desirability
- Citation
- R stats::lm, stats::glm and stats::qt/qnorm documentation; Derringer-Suich desirability as defined in manual chapter 54
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_profiler.R · sha256 f581b11f336b6b96
- Dataset
- None
Settings compared
goals= [{"response_name": "y", "goal": "maximize", "weight": 2, "low": 0, "high": 20}]models= [{"artifact": {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}}]predictors= [{"name": "x1", "kind": "numeric", "min_val": 1, "max_val": 9, "current_value": 5}, {"name": "grp", "kind": "categorical", "categories": ["A", "B", "C"], "current_value": "A"}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/charts/0/points/0/predictor_value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/charts/0/points/0/prediction | tolerance | 2.3921104844357353 | 2.392110484435737 | 1.74E-15 | 15 | passed |
/charts/0/points/0/lower | tolerance | 1.4648304736010651 | 1.4648304736010662 | 1.12E-15 | 15 | passed |
/charts/0/points/0/upper | tolerance | 3.3193904952704054 | 3.319390495270408 | 2.68E-15 | 15 | passed |
/charts/0/points/0/desirability | tolerance | 0.11960552422178676 | 0.11960552422178686 | 9.75E-17 | 15 | passed |
/charts/0/points/37/predictor_value | tolerance | 3.96 | 3.96 | 3.55E-17 | 17 | passed |
/charts/0/points/37/prediction | tolerance | 5.181781133352704 | 5.181781133352707 | 2.63E-15 | 15 | passed |
/charts/0/points/37/lower | tolerance | 4.5348463474907303 | 4.534846347490733 | 2.71E-15 | 15 | passed |
/charts/0/points/37/upper | tolerance | 5.8287159192146776 | 5.82871591921468 | 2.64E-15 | 15 | passed |
/charts/0/points/37/desirability | tolerance | 0.25908905666763521 | 0.2590890566676353 | 1.10E-16 | 15 | passed |
/charts/0/points/100/predictor_value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/charts/0/points/100/prediction | tolerance | 9.931760886914029 | 9.931760886914034 | 5.36E-15 | 15 | passed |
/charts/0/points/100/lower | tolerance | 9.0553954976626994 | 9.055395497662705 | 5.28E-15 | 15 | passed |
/charts/0/points/100/upper | tolerance | 10.808126276165359 | 10.808126276165364 | 5.03E-15 | 15 | passed |
/charts/0/points/100/desirability | tolerance | 0.49658804434570147 | 0.4965880443457017 | 2.26E-16 | 15 | passed |
/charts/1/points/0/predictor_value | exact | A | A | passed | ||
/charts/1/points/0/prediction | tolerance | 6.1619356856748819 | 6.161935685674885 | 2.69E-15 | 15 | passed |
/charts/1/points/0/desirability | tolerance | 0.3080967842837441 | 0.3080967842837442 | 1.07E-16 | 15 | passed |
/charts/1/points/1/predictor_value | exact | B | B | passed | ||
/charts/1/points/1/prediction | tolerance | 7.6343734214706913 | 7.634373421470695 | 3.56E-15 | 15 | passed |
/charts/1/points/1/desirability | tolerance | 0.38171867107353458 | 0.38171867107353474 | 1.63E-16 | 15 | passed |
/charts/1/points/2/predictor_value | exact | C | C | passed | ||
/charts/1/points/2/prediction | tolerance | 5.0860667517648057 | 5.086066751764805 | 8.73E-16 | 15 | passed |
/charts/1/points/2/desirability | tolerance | 0.25430333758824031 | 0.25430333758824025 | 5.75E-17 | 15 | passed |
/optimum_settings/x1 | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/optimum_settings/grp | exact | B | B | passed | ||
/optimum_outcomes/0/prediction | tolerance | 11.404198622709838 | 11.404198622709844 | 5.75E-15 | 15 | passed |
/optimum_outcomes/0/lower | tolerance | 10.433953434116008 | 10.433953434116017 | 8.72E-15 | 15 | passed |
/optimum_outcomes/0/upper | tolerance | 12.374443811303669 | 12.37444381130367 | 1.77E-15 | 15 | passed |
/combined_desirability | tolerance | 0.5702099311354919 | 0.5702099311354922 | 3.32E-16 | 15 | passed |
/categorical_combinations | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- The high threshold 20 lies above every prediction, so d rises strictly with x1 and with the B effect.
- Manual chapter 54 lines 60-99 define predictions, limits, desirability and the search.
Reference code
The lines of the reference script that produce this case's expected values.
126 goal_y <- list(response_name = "y", goal = "maximize", weight = 2, low = 0, high = 20)
127 config1 <- list(models = list(list(artifact = artifact_of(ols, "ols", "identity"))),
128 predictors = predictors_spec(), goals = list(goal_y))
129 best <- profile_point(ols, "ols", 9, "B", 0.95)
130 out <- c(chart_outputs(0L, ols, "ols", goal_y, 0.95), level_outputs(1L, ols, "ols", goal_y, 0.95),
131 list("/optimum_settings/x1" = tol(9, "The all-upper corner is always evaluated and is best for an increasing goal."),
132 "/optimum_settings/grp" = exact("B", "B has the largest level effect."),
133 "/optimum_outcomes/0/prediction" = tol(best[["fit"]], "Prediction at the best setting."),
134 "/optimum_outcomes/0/lower" = tol(best[["lo"]], "Mean-response lower limit there."),
135 "/optimum_outcomes/0/upper" = tol(best[["hi"]], "Mean-response upper limit there."),
136 "/combined_desirability" = tol(desire(best[["fit"]], goal_y), "D equals d for one response."),
137 "/categorical_combinations" = exact(3L, "Three permitted levels.")))
138 emit_profiler("STAT-DESC-PROFILER-001", "OLS profile, desirability and the best corner", config1, out,
139 c("The high threshold 20 lies above every prediction, so d rises strictly with x1 and with the B effect."))
Two models with weighted joint desirability
Case STAT-DESC-PROFILER-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm/glm coefficients with hand-coded desirability
- Citation
- R stats::lm, stats::glm and stats::qt/qnorm documentation; Derringer-Suich desirability as defined in manual chapter 54
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_profiler.R · sha256 f581b11f336b6b96
- Dataset
- None
Settings compared
goals= [{"response_name": "y", "goal": "maximize", "weight": 2, "low": 0, "high": 20}, {"response_name": "yb", "goal": "maximize", "weight": 1, "low": 0, "high": 1}]models= [{"artifact": {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}}, {"artifact": {"family": "logistic", "response": "yb", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [-5.0402717125001, 0.935845003964461, 2.74940723061125, -1.49498208580186], "covariance": [[4.76880710827408, -0.7283485404078, -2.95603934912518, -0.192923804145146], [-0.7283485404078, 0.128663126095284, 0.40812222863919, -0.0799834845686035], [-2.95603934912518, 0.40812222863919, 2.802302709578, 0.391992620853652], [-0.192923804145146, -0.0799834845686035, 0.391992620853652, 1.71085357184364]], "link": "logit", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "event_value": "yes", "reference_value": "no"}}]predictors= [{"name": "x1", "kind": "numeric", "min_val": 1, "max_val": 9, "current_value": 5}, {"name": "grp", "kind": "categorical", "categories": ["A", "B", "C"], "current_value": "A"}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/charts/1/points/0/predictor_value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/charts/1/points/0/prediction | tolerance | 0.016231661244639581 | 0.01623166124463955 | 3.14E-17 | 14 | passed |
/charts/1/points/0/lower | tolerance | 0.00043487069923546653 | 0.0004348706992354642 | 2.33E-18 | 14 | passed |
/charts/1/points/0/upper | tolerance | 0.38489401676627499 | 0.3848940167662755 | 5.03E-16 | 14 | passed |
/charts/1/points/0/desirability | tolerance | 0.016231661244639581 | 0.01623166124463955 | 3.14E-17 | 14 | passed |
/charts/1/points/37/predictor_value | tolerance | 3.96 | 3.96 | 3.55E-17 | 17 | passed |
/charts/1/points/37/prediction | tolerance | 0.20844477741229334 | 0.208444777412293 | 3.37E-16 | 14 | passed |
/charts/1/points/37/lower | tolerance | 0.035169173489664911 | 0.03516917348966462 | 2.92E-16 | 14 | passed |
/charts/1/points/37/upper | tolerance | 0.655461073171002 | 0.6554610731710029 | 8.84E-16 | 14 | passed |
/charts/1/points/37/desirability | tolerance | 0.20844477741229334 | 0.208444777412293 | 3.37E-16 | 14 | passed |
/charts/1/points/100/predictor_value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/charts/1/points/100/prediction | tolerance | 0.96714782253742559 | 0.9671478225374256 | 4.37E-18 | 17 | passed |
/charts/1/points/100/lower | tolerance | 0.63540269913008351 | 0.6354026991300811 | 2.44E-15 | 14 | passed |
/charts/1/points/100/upper | tolerance | 0.99799319216274496 | 0.997993192162745 | 2.41E-18 | 17 | passed |
/charts/1/points/100/desirability | tolerance | 0.96714782253742559 | 0.9671478225374256 | 4.37E-18 | 17 | passed |
/optimum_settings/x1 | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/optimum_settings/grp | exact | B | B | passed | ||
/combined_desirability | tolerance | 0.6871353867213863 | 0.6871353867213865 | 2.21E-16 | 15 | passed |
/categorical_combinations | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- Chart 1 is x1 against the logistic model (charts run predictor by predictor, then model by model).
- Logistic limits are Wald limits on the logit scale (line 72-74).
- Manual chapter 54 lines 60-99 define predictions, limits, desirability and the search.
Reference code
The lines of the reference script that produce this case's expected values.
141 goal_b <- list(response_name = "yb", goal = "maximize", weight = 1, low = 0, high = 1)
142 config2 <- list(models = list(list(artifact = artifact_of(ols, "ols", "identity")),
143 list(artifact = artifact_of(logit, "logistic", "logit", extra = list(event_value = "yes", reference_value = "no")))),
144 predictors = predictors_spec(), goals = list(goal_y, goal_b))
145 bl <- profile_point(logit, "logistic", 9, "B", 0.95)
146 dy <- desire(best[["fit"]], goal_y); db <- desire(bl[["fit"]], goal_b)
147 out <- c(chart_outputs(1L, logit, "logistic", goal_b, 0.95), list(
148 "/optimum_settings/x1" = tol(9, "Both responses increase with x1."),
149 "/optimum_settings/grp" = exact("B", "B is best for both responses."),
150 "/combined_desirability" = tol((dy^2 * db^1)^(1 / 3), "D = (d_y^2 d_yb^1)^(1/3) with weights 2 and 1."),
151 "/categorical_combinations" = exact(3L, "Three permitted levels.")))
152 emit_profiler("STAT-DESC-PROFILER-002", "Two models with weighted joint desirability", config2, out,
153 c("Chart 1 is x1 against the logistic model (charts run predictor by predictor, then model by model).",
154 "Logistic limits are Wald limits on the logit scale (line 72-74)."), kind = "axis_coverage")
Target goal at a 90% confidence level
Case STAT-DESC-PROFILER-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm/glm coefficients with hand-coded desirability
- Citation
- R stats::lm, stats::glm and stats::qt/qnorm documentation; Derringer-Suich desirability as defined in manual chapter 54
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_profiler.R · sha256 f581b11f336b6b96
- Dataset
- None
Settings compared
confidence_level= 0.9goals= [{"response_name": "y", "goal": "target", "weight": 1, "low": 4, "high": 12, "target": 7}]models= [{"artifact": {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}}]predictors= [{"name": "x1", "kind": "numeric", "min_val": 1, "max_val": 9, "current_value": 5}, {"name": "grp", "kind": "categorical", "categories": ["A", "B", "C"], "current_value": "A"}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/charts/0/points/0/predictor_value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/charts/0/points/0/prediction | tolerance | 2.3921104844357353 | 2.392110484435737 | 1.74E-15 | 15 | passed |
/charts/0/points/0/lower | tolerance | 1.6226807825880205 | 1.622680782588022 | 1.56E-15 | 15 | passed |
/charts/0/points/0/upper | tolerance | 3.16154018628345 | 3.1615401862834522 | 2.24E-15 | 15 | passed |
/charts/0/points/0/desirability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/charts/0/points/20/predictor_value | tolerance | 2.6000000000000001 | 2.6 | 1.12E-17 | 17 | passed |
/charts/0/points/20/prediction | tolerance | 3.9000405649313938 | 3.9000405649313965 | 2.70E-15 | 15 | passed |
/charts/0/points/20/lower | tolerance | 3.27805600232778 | 3.2780560023277827 | 2.71E-15 | 15 | passed |
/charts/0/points/20/upper | tolerance | 4.5220251275350076 | 4.52202512753501 | 2.69E-15 | 15 | passed |
/charts/0/points/20/desirability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/charts/0/points/45/predictor_value | tolerance | 4.5999999999999996 | 4.6 | 4.47E-17 | 17 | passed |
/charts/0/points/45/prediction | tolerance | 5.7849531655509665 | 5.78495316555097 | 3.56E-15 | 15 | passed |
/charts/0/points/45/lower | tolerance | 5.269416581210292 | 5.2694165812102955 | 3.55E-15 | 15 | passed |
/charts/0/points/45/upper | tolerance | 6.300489749891641 | 6.300489749891645 | 3.56E-15 | 15 | passed |
/charts/0/points/45/desirability | tolerance | 0.59498438851698887 | 0.59498438851699 | 1.11E-15 | 14 | passed |
/charts/0/points/70/predictor_value | tolerance | 6.6000000000000005 | 6.6000000000000005 | 3.29E-17 | 17 | passed |
/charts/0/points/70/prediction | tolerance | 7.6698657661705418 | 7.6698657661705445 | 2.70E-15 | 15 | passed |
/charts/0/points/70/lower | tolerance | 7.1266430880113107 | 7.126643088011314 | 3.60E-15 | 15 | passed |
/charts/0/points/70/upper | tolerance | 8.213088444329772 | 8.213088444329774 | 1.81E-15 | 15 | passed |
/charts/0/points/70/desirability | tolerance | 0.86602684676589159 | 0.8660268467658911 | 4.45E-16 | 15 | passed |
/charts/0/points/100/predictor_value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/charts/0/points/100/prediction | tolerance | 9.931760886914029 | 9.931760886914034 | 5.36E-15 | 15 | passed |
/charts/0/points/100/lower | tolerance | 9.2045786417642059 | 9.204578641764211 | 5.36E-15 | 15 | passed |
/charts/0/points/100/upper | tolerance | 10.658943132063852 | 10.658943132063857 | 5.46E-15 | 15 | passed |
/charts/0/points/100/desirability | tolerance | 0.41364782261719418 | 0.41364782261719313 | 1.05E-15 | 14 | passed |
/charts/1/points/0/predictor_value | exact | A | A | passed | ||
/charts/1/points/0/prediction | tolerance | 6.1619356856748819 | 6.161935685674885 | 2.69E-15 | 15 | passed |
/charts/1/points/0/desirability | tolerance | 0.72064522855829394 | 0.7206452285582948 | 8.86E-16 | 14 | passed |
/charts/1/points/1/predictor_value | exact | B | B | passed | ||
/charts/1/points/1/prediction | tolerance | 7.6343734214706913 | 7.634373421470695 | 3.56E-15 | 15 | passed |
/charts/1/points/1/desirability | tolerance | 0.87312531570586172 | 0.873125315705861 | 6.71E-16 | 15 | passed |
/charts/1/points/2/predictor_value | exact | C | C | passed | ||
/charts/1/points/2/prediction | tolerance | 5.0860667517648057 | 5.086066751764805 | 8.73E-16 | 15 | passed |
/charts/1/points/2/desirability | tolerance | 0.36202225058826859 | 0.36202225058826826 | 3.33E-16 | 15 | passed |
Convention
- Target 7 inside (4, 12): d rises linearly to 1 at 7 and falls to 0 at 12 (line 82-83).
- Manual chapter 54 lines 60-99 define predictions, limits, desirability and the search.
Reference code
The lines of the reference script that produce this case's expected values.
156 goal_t <- list(response_name = "y", goal = "target", weight = 1, low = 4, high = 12, target = 7)
157 config3 <- list(models = list(list(artifact = artifact_of(ols, "ols", "identity"))),
158 predictors = predictors_spec(), goals = list(goal_t), confidence_level = 0.9)
159 emit_profiler("STAT-DESC-PROFILER-003", "Target goal at a 90% confidence level", config3,
160 c(chart_outputs(0L, ols, "ols", goal_t, 0.9, points = c(0L, 20L, 45L, 70L, 100L)),
161 level_outputs(1L, ols, "ols", goal_t, 0.9)),
162 c("Target 7 inside (4, 12): d rises linearly to 1 at 7 and falls to 0 at 12 (line 82-83)."),
163 deferred = list(list(path = "/optimum_settings",
164 reason = "Many settings reach the target; the best setting found depends on the seeded search order (line 96-99).")))
Poisson profile at an entered exposure of 2.5
Case STAT-DESC-PROFILER-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm/glm coefficients with hand-coded desirability
- Citation
- R stats::lm, stats::glm and stats::qt/qnorm documentation; Derringer-Suich desirability as defined in manual chapter 54
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_profiler.R · sha256 f581b11f336b6b96
- Dataset
- None
Settings compared
goals= [{"response_name": "cnt", "goal": "minimize", "weight": 1, "low": 0, "high": 60}]models= [{"artifact": {"family": "poisson", "response": "cnt", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [0.173632334271003, 0.175152527192001, 0.324600384426855, -0.197708538849376], "covariance": [[0.0635247463932928, -0.00777180742702323, -0.0264421923237446, -0.023978983751601], [-0.00777180742702323, 0.00137534721715719, 0.00120944879635284, 0.000773544138808703], [-0.0264421923237446, 0.00120944879635284, 0.0370648472773776, 0.0202880801076409], [-0.023978983751601, 0.000773544138808703, 0.0202880801076409, 0.0392736810694172]], "link": "log", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "exposure_column": "expo"}, "exposure": 2.5}]predictors= [{"name": "x1", "kind": "numeric", "min_val": 1, "max_val": 9, "current_value": 5}, {"name": "grp", "kind": "categorical", "categories": ["A", "B", "C"], "current_value": "A"}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/charts/0/points/0/predictor_value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/charts/0/points/0/prediction | tolerance | 3.5433605804362651 | 3.5433605804362642 | 8.71E-16 | 15 | passed |
/charts/0/points/0/lower | tolerance | 2.2925019160201048 | 2.292501916020104 | 9.09E-16 | 15 | passed |
/charts/0/points/0/upper | tolerance | 5.4767257184179021 | 5.476725718417902 | 2.23E-17 | 17 | passed |
/charts/0/points/0/desirability | tolerance | 0.94094399032606224 | 0.9409439903260622 | 6.48E-19 | 18 | passed |
/charts/0/points/37/predictor_value | tolerance | 3.96 | 3.96 | 3.55E-17 | 17 | passed |
/charts/0/points/37/prediction | tolerance | 5.9508083878044946 | 5.950808387804488 | 6.20E-15 | 14 | passed |
/charts/0/points/37/lower | tolerance | 4.4053369610591648 | 4.4053369610591595 | 5.29E-15 | 14 | passed |
/charts/0/points/37/upper | tolerance | 8.0384589831353743 | 8.038458983135365 | 8.86E-15 | 14 | passed |
/charts/0/points/37/desirability | tolerance | 0.90081986020325844 | 0.9008198602032585 | 1.09E-16 | 15 | passed |
/charts/0/points/100/predictor_value | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/charts/0/points/100/prediction | tolerance | 14.386579759253186 | 14.38657975925315 | 3.56E-14 | 14 | passed |
/charts/0/points/100/lower | tolerance | 9.9685492999816638 | 9.968549299981648 | 1.60E-14 | 14 | passed |
/charts/0/points/100/upper | tolerance | 20.762667760466826 | 20.762667760466762 | 6.40E-14 | 14 | passed |
/charts/0/points/100/desirability | tolerance | 0.76022367067911356 | 0.7602236706791141 | 5.56E-16 | 15 | passed |
/charts/1/points/0/predictor_value | exact | A | A | passed | ||
/charts/1/points/0/prediction | tolerance | 7.1398066924980519 | 7.139806692498043 | 8.89E-15 | 14 | passed |
/charts/1/points/0/desirability | tolerance | 0.8810032217916991 | 0.8810032217916993 | 2.20E-16 | 15 | passed |
/charts/1/points/1/predictor_value | exact | B | B | passed | ||
/charts/1/points/1/prediction | tolerance | 9.877763171996456 | 9.877763171996449 | 7.07E-15 | 15 | passed |
/charts/1/points/1/desirability | tolerance | 0.83537061380005906 | 0.8353706138000592 | 1.10E-16 | 15 | passed |
/charts/1/points/2/predictor_value | exact | C | C | passed | ||
/charts/1/points/2/prediction | tolerance | 5.8589895867683426 | 5.8589895867683355 | 7.12E-15 | 14 | passed |
/charts/1/points/2/desirability | tolerance | 0.90235017355386093 | 0.902350173553861 | 1.16E-16 | 15 | passed |
Convention
- Expected counts are multiplied by the entered exposure; Wald limits include log(2.5) (line 62-63, 74).
- Manual chapter 54 lines 60-99 define predictions, limits, desirability and the search.
Reference code
The lines of the reference script that produce this case's expected values.
166 goal_p <- list(response_name = "cnt", goal = "minimize", weight = 1, low = 0, high = 60)
167 config4 <- list(models = list(list(artifact = artifact_of(pois, "poisson", "log", extra = list(exposure_column = "expo")), exposure = 2.5)),
168 predictors = predictors_spec(), goals = list(goal_p))
169 emit_profiler("STAT-DESC-PROFILER-004", "Poisson profile at an entered exposure of 2.5", config4,
170 c(chart_outputs(0L, pois, "poisson", goal_p, 0.95, exposure = 2.5), level_outputs(1L, pois, "poisson", goal_p, 0.95, exposure = 2.5)),
171 c("Expected counts are multiplied by the entered exposure; Wald limits include log(2.5) (line 62-63, 74)."),
172 deferred = list(list(path = "/optimum_settings", reason = "The minimizing corner depends on the signs of the fitted Poisson effects; charts carry the reference.")))
An unattainable goal gives joint desirability zero
Case STAT-DESC-PROFILER-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm/glm coefficients with hand-coded desirability
- Citation
- R stats::lm, stats::glm and stats::qt/qnorm documentation; Derringer-Suich desirability as defined in manual chapter 54
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_profiler.R · sha256 f581b11f336b6b96
- Dataset
- None
Settings compared
goals= [{"response_name": "y", "goal": "maximize", "weight": 1, "low": 100, "high": 200}]models= [{"artifact": {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}}]predictors= [{"name": "x1", "kind": "numeric", "min_val": 1, "max_val": 9, "current_value": 5}, {"name": "grp", "kind": "categorical", "categories": ["A", "B", "C"], "current_value": "A"}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/combined_desirability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/charts/0/points/100/desirability | tolerance | 0 | 0.0 | 0.00E+2 | passed |
Convention
- The largest prediction in the region is 11.4042, far below 100.
- Manual chapter 54 lines 60-99 define predictions, limits, desirability and the search.
Reference code
The lines of the reference script that produce this case's expected values.
174 goal_zero <- list(response_name = "y", goal = "maximize", weight = 1, low = 100, high = 200)
175 config5 <- list(models = list(list(artifact = artifact_of(ols, "ols", "identity"))),
176 predictors = predictors_spec(), goals = list(goal_zero))
177 emit_profiler("STAT-DESC-PROFILER-005", "An unattainable goal gives joint desirability zero", config5,
178 list("/combined_desirability" = tol(0, "Every prediction lies below the lower threshold 100 (line 99)."),
179 "/charts/0/points/100/desirability" = tol(0, "d is 0 at and below the lower threshold.")),
180 c(sprintf("The largest prediction in the region is %.6g, far below 100.", best[["fit"]])), kind = "boundary")
A target on a bound is refused
Case STAT-DESC-PROFILER-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm/glm coefficients with hand-coded desirability
- Citation
- R stats::lm, stats::glm and stats::qt/qnorm documentation; Derringer-Suich desirability as defined in manual chapter 54
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_profiler.R · sha256 f581b11f336b6b96
- Dataset
- None
Settings compared
goals= [{"response_name": "y", "goal": "target", "weight": 1, "low": 4, "high": 12, "target": 12}]models= [{"artifact": {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}}]predictors= [{"name": "x1", "kind": "numeric", "min_val": 1, "max_val": 9, "current_value": 5}, {"name": "grp", "kind": "categorical", "categories": ["A", "B", "C"], "current_value": "A"}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 43-44: an explicit target must lie strictly between the bounds.
- Manual chapter 54 lines 60-99 define predictions, limits, desirability and the search.
Reference code
The lines of the reference script that produce this case's expected values.
182 bad_target <- goal_t; bad_target$target <- 12
183 emit_profiler("STAT-DESC-PROFILER-006", "A target on a bound is refused",
184 list(models = config1$models, predictors = predictors_spec(), goals = list(bad_target)), list(),
185 c("Line 43-44: an explicit target must lie strictly between the bounds."), kind = "invalid_input",
186 error = list(error_class = "ValueError", message_contains = "strictly inside its desirability bounds"))
Predictors must cover every retained role
Case STAT-DESC-PROFILER-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm/glm coefficients with hand-coded desirability
- Citation
- R stats::lm, stats::glm and stats::qt/qnorm documentation; Derringer-Suich desirability as defined in manual chapter 54
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_profiler.R · sha256 f581b11f336b6b96
- Dataset
- None
Settings compared
goals= [{"response_name": "y", "goal": "maximize", "weight": 2, "low": 0, "high": 20}]models= [{"artifact": {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}}]predictors= [{"name": "x1", "kind": "numeric", "min_val": 1, "max_val": 9, "current_value": 5}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 19: all predictors must be specified.
- Manual chapter 54 lines 60-99 define predictions, limits, desirability and the search.
Reference code
The lines of the reference script that produce this case's expected values.
187 emit_profiler("STAT-DESC-PROFILER-007", "Predictors must cover every retained role",
188 list(models = config1$models, predictors = predictors_spec()[1], goals = list(goal_y)), list(),
189 c("Line 19: all predictors must be specified."), kind = "invalid_input",
190 error = list(error_class = "ValueError", message_contains = "exactly cover the retained model roles"))
Seeded normal table: shape, names and theoretical moments
Case STAT-DESC-RANDOM-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
column_names= ["a", "b"]distribution= {"family": "normal", "mean": 5, "standard_deviation": 2}rows= 50seed= 12345
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/summary/rows | exact | 50 | 50 | 0.00E+2 | passed | |
/summary/column_names | sequence | ['a', 'b'] | ['a', 'b'] | passed | ||
/summary/dtype | exact | float64 | float64 | passed | ||
/summary/algorithm | exact | pcg64-inverse-cdf-v1 | pcg64-inverse-cdf-v1 | passed | ||
/summary/seed | exact | 12345 | 12345 | 0.00E+2 | passed | |
/summary/distribution/mean | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/summary/distribution/standard_deviation | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/summary/columns/0/count | exact | 50 | 50 | 0.00E+2 | passed | |
/summary/columns/1/count | exact | 50 | 50 | 0.00E+2 | passed | |
/frame/50 | absent | None | passed |
Convention
- Draws are covered by the V27 simulation studies; repeat 2 checks that the same seed recreates the same table (line 113).
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
The lines of the reference script that produce this case's expected values.
251 gen <- "tabelz.analysis.distribution_sampling:generate_random_data"
252 normal_request <- list(distribution = list(family = "normal", mean = 5, standard_deviation = 2),
253 rows = 50L, column_names = list("a", "b"), seed = 12345L)
254 emit("STAT-DESC-RANDOM-001", gen, menu, "Seeded normal table: shape, names and theoretical moments",
255 normal_request,
256 list("/summary/rows" = exact(50L, "Requested rows."),
257 "/summary/column_names" = list(comparison = "sequence", values = list("a", "b"), rationale = "Requested names in order."),
258 "/summary/dtype" = exact("float64", "Continuous columns are floating point (line 103)."),
259 "/summary/algorithm" = exact("pcg64-inverse-cdf-v1", "The documented algorithm (line 106)."),
260 "/summary/seed" = exact(12345L, "The requested seed is recorded."),
261 "/summary/distribution/mean" = tol(5, "Theoretical mean."),
262 "/summary/distribution/standard_deviation" = tol(2, "Theoretical standard deviation."),
263 "/summary/columns/0/count" = exact(50L, "Every row is drawn."),
264 "/summary/columns/1/count" = exact(50L, "Every row is drawn."),
265 "/frame/50" = absent("Exactly 50 rows.")),
266 c("Draws are covered by the V27 simulation studies; repeat 2 checks that the same seed recreates the same table (line 113)."),
267 kind = "determinism", repeat_n = 2L, oracle_class = "analytic")
Seeded Poisson table uses integer columns
Case STAT-DESC-RANDOM-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
column_names= ["count"]distribution= {"family": "poisson", "mean": 3.5}rows= 20seed= 7
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/summary/dtype | exact | int64 | int64 | passed | ||
/summary/distribution/mean | tolerance | 3.5 | 3.5 | 0.00E+1 | passed | |
/summary/distribution/standard_deviation | tolerance | 1.8708286933869707 | 1.8708286933869707 | 3.53E-17 | 16 | passed |
/summary/columns/0/count | exact | 20 | 20 | 0.00E+2 | passed | |
/frame/20 | absent | None | passed |
Convention
- A discrete family produces int64 values (line 103-104).
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
The lines of the reference script that produce this case's expected values.
268 emit("STAT-DESC-RANDOM-002", gen, menu, "Seeded Poisson table uses integer columns",
269 list(distribution = list(family = "poisson", mean = 3.5), rows = 20L, column_names = list("count"), seed = 7L),
270 list("/summary/dtype" = exact("int64", "Poisson columns are integers (line 103-104)."),
271 "/summary/distribution/mean" = tol(3.5, "Theoretical mean."),
272 "/summary/distribution/standard_deviation" = tol(sqrt(3.5), "Theoretical standard deviation sqrt(lambda)."),
273 "/summary/columns/0/count" = exact(20L, "Every row is drawn."),
274 "/frame/20" = absent("Exactly 20 rows.")),
275 c("A discrete family produces int64 values (line 103-104)."), oracle_class = "analytic")
One row is the smallest table
Case STAT-DESC-RANDOM-003 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
column_names= ["x"]distribution= {"family": "exponential", "scale": 2}rows= 1seed= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/summary/rows | exact | 1 | 1 | 0.00E+2 | passed | |
/frame/1 | absent | None | passed | |||
/summary/distribution/mean | tolerance | 2 | 2.0 | 0.00E+2 | passed |
Convention
- rows has a minimum of 1.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
The lines of the reference script that produce this case's expected values.
276 emit("STAT-DESC-RANDOM-003", gen, menu, "One row is the smallest table",
277 list(distribution = list(family = "exponential", scale = 2), rows = 1L, column_names = list("x"), seed = 0L),
278 list("/summary/rows" = exact(1L, "A single row."), "/frame/1" = absent("Exactly one row."),
279 "/summary/distribution/mean" = tol(2, "The exponential mean is its scale.")),
280 c("rows has a minimum of 1."), kind = "boundary", oracle_class = "analytic")
Column names that differ only in case are refused
Case STAT-DESC-RANDOM-004 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
column_names= ["Value", "value"]distribution= {"family": "normal"}rows= 5seed= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 94: names must be distinct ignoring case.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
The lines of the reference script that produce this case's expected values.
281 emit("STAT-DESC-RANDOM-004", gen, menu, "Column names that differ only in case are refused",
282 list(distribution = list(family = "normal"), rows = 5L, column_names = list("Value", "value"), seed = 1L),
283 list(), c("Line 94: names must be distinct ignoring case."), kind = "invalid_input",
284 error = list(error_class = "ValueError", message_contains = "is repeated"), oracle_class = "analytic")
More than 1,000,000 cells is refused
Case STAT-DESC-RANDOM-005 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
column_names= ["a", "b"]distribution= {"family": "normal"}rows= 500001seed= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 93: at most 1,000,000 cells; 500,001 x 2 = 1,000,002.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
The lines of the reference script that produce this case's expected values.
285 emit("STAT-DESC-RANDOM-005", gen, menu, "More than 1,000,000 cells is refused",
286 list(distribution = list(family = "normal"), rows = 500001L, column_names = list("a", "b"), seed = 1L),
287 list(), c("Line 93: at most 1,000,000 cells; 500,001 x 2 = 1,000,002."), kind = "invalid_input",
288 error = list(error_class = "ValueError", message_contains = "the maximum is 1,000,000"), oracle_class = "analytic")
Replaying the recorded operation recreates the table
Case STAT-DESC-RANDTABLE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
column_names= ["a", "b"]distribution= {"family": "normal", "mean": 5, "standard_deviation": 2}recorded= truerows= 50seed= 12345
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/frame/50 | absent | None | passed | |||
/row_ids_unique | exact | True | True | passed | ||
/receipt/row_identity | exact | generated | generated | passed | ||
/receipt/seed | exact | 12345 | 12345 | 0.00E+2 | passed | |
/receipt/algorithm | exact | pcg64-inverse-cdf-v1 | pcg64-inverse-cdf-v1 | passed |
Convention
- Lines 115-121: creating the tab records one operation; replay regenerates the table and compares its fingerprint.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
The lines of the reference script that produce this case's expected values.
291 op <- "operation:tabelz.random_table"
292 emit("STAT-DESC-RANDTABLE-001", op, menu, "Replaying the recorded operation recreates the table",
293 c(normal_request, list(recorded = TRUE)),
294 list("/frame/50" = absent("Exactly the 50 requested rows."),
295 "/row_ids_unique" = exact(TRUE, "Generated row identities are stable and distinct (line 103)."),
296 "/receipt/row_identity" = exact("generated", "The table's rows have generated identities."),
297 "/receipt/seed" = exact(12345L, "The recorded seed (line 115-116)."),
298 "/receipt/algorithm" = exact("pcg64-inverse-cdf-v1", "The recorded algorithm.")),
299 c("Lines 115-121: creating the tab records one operation; replay regenerates the table and compares its fingerprint."),
300 kind = "determinism", repeat_n = 2L, oracle_class = "analytic")
A different recorded fingerprint is reported, not accepted
Case STAT-DESC-RANDTABLE-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R stats distribution functions
- Citation
- R stats::Normal, TDist, Chisquare, FDist, Binomial, Poisson, Exponential and Weibull documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_probability.R · sha256 b73a1190ef5b8394
- Dataset
- None
Settings compared
column_names= ["a", "b"]distribution= {"family": "normal", "mean": 5, "standard_deviation": 2}recorded= falserows= 50seed= 12345
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Lines 119-121: replay reports different values instead of accepting new numbers.
- Manual chapter 61 lines 13-60 define the parameters, tails and quantiles.
Reference code
The lines of the reference script that produce this case's expected values.
301 emit("STAT-DESC-RANDTABLE-002", op, menu, "A different recorded fingerprint is reported, not accepted",
302 c(normal_request, list(recorded = FALSE)), list(),
303 c("Lines 119-121: replay reports different values instead of accepting new numbers."),
304 kind = "invalid_input", oracle_class = "analytic",
305 error = list(error_class = "ValueError", message_contains = "produced different values than were recorded"))
Rater agreement: unweighted Cohen's kappa and nominal alpha
Case STAT-DESC-RATER-AGREE-001 · status: passed
Reference
- Evidence type
- R
- Source
- irr::kappa2, irr::kappam.fleiss, irr::kripp.alpha and base R (Fleiss, Cohen and Everitt 1969 variance)
- Citation
- Gamer, M., Lemon, J. and Fellows Puspendra Singh, I. (2019). irr: various coefficients of interrater reliability and agreement. R package version 0.85; Cohen (1960); Fleiss, Cohen and Everitt (1969) Psychological Bulletin 72:323-327; Fleiss, Nee and Landis (1979); Krippendorff (2004).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, psych 2.6.5, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reliability_agreement.R · sha256 6f498a9f8544f55b
- Dataset
- reference_data/datasets/DESC_RATERS_B7.json
Settings compared
alpha_metric= "nominal"categories= []confidence_level= 0.95kappa_bootstrap= falseraters= ["r1", "r2"]replicates= 500seed= 20260928weights= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cohen/units | exact | 29 | 29 | 0.00E+2 | passed | |
/cohen/kappa | tolerance | 0.34197730956239875 | 0.34197730956239875 | 4.22E-18 | 16 | passed |
/cohen/observed_agreement | tolerance | 0.51724137931034486 | 0.5172413793103449 | 2.04E-18 | 17 | passed |
/cohen/expected_agreement | tolerance | 0.26634958382877527 | 0.26634958382877527 | 1.50E-18 | 17 | passed |
/cohen/standard_error | tolerance | 0.12109684302185841 | 0.12109684302185843 | 1.74E-17 | 15 | passed |
/cohen/lower | tolerance | 0.10463185859805574 | 0.10463185859805565 | 8.52E-17 | 15 | passed |
/cohen/upper | tolerance | 0.5793227605267417 | 0.5793227605267418 | 1.09E-16 | 15 | passed |
/cohen/null_standard_error | tolerance | 0.10610879957878039 | 0.10610879957878039 | 1.63E-18 | 16 | passed |
/cohen/z_value | tolerance | 3.22289302037102 | 3.22289302037102 | 1.02E-17 | 17 | passed |
/cohen/p_value | tail_probability | 0.0012690293963641963 | 0.0012690293963641187 | 7.76E-17 | 13 | passed |
/table/0/0 | exact | 6 | 6 | 0.00E+2 | passed | |
/table/1/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/complete_units | exact | 29 | 29 | 0.00E+2 | passed | |
/percent_agreement | tolerance | 0.51724137931034486 | 0.5172413793103449 | 2.04E-18 | 17 | passed |
/krippendorff/alpha | tolerance | 0.33499999999999996 | 0.33499999999999996 | 4.47E-18 | 16 | passed |
/krippendorff/pairable_values | exact | 58 | 58 | 0.00E+2 | passed | |
/krippendorff/units | exact | 29 | 29 | 0.00E+2 | passed | |
/units | exact | 30 | 30 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/88-reliability-agreement.tex:100-110: Cohen's kappa over units rated by both raters; linear/quadratic weights need a declared category order.
- docs/manual/chapters/88-reliability-agreement.tex:112-119: Fleiss' kappa over complete sets; Krippendorff's alpha allows incomplete units with at least two ratings, with the nominal, ordinal or interval metric.
- Weights use category positions: linear 1 - |i - j|/(c - 1), quadratic 1 - (i - j)^2/(c - 1)^2 (irr::kappa2 'equal' and 'squared').
- Fleiss category kappa follows Fleiss (1971): kappa_j = 1 - sum_i n_ij (m - n_ij) / (N m (m - 1) p_j (1 - p_j)) with null SE sqrt(2 / (N m (m - 1))), the same quantities irr::kappam.fleiss prints rounded to three decimals.
- Two-sided normal p-values use 2 * pnorm(-|z|); irr computes 2 * (1 - pnorm(z)), which loses digits to cancellation in the far tail.
- The bootstrap limits are seed-dependent and not compared.
- Without declared categories the observed codes sort numerically: 1, 2, 3, 4.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
403 outputs <- c(cohen_outputs(rd$r1, rd$r2, "none", 0.95), alpha_outputs(c("r1", "r2"), "nominal"),
404 list("/units" = exact(nrow(rd), "rows")))
405 emit("STAT-DESC-RATER-AGREE-001", "Rater agreement: unweighted Cohen's kappa and nominal alpha",
406 RATER, "raterAgreementMenuItem", RATER_REQ, "DESC_RATERS_B7",
407 list(raters = list("r1", "r2"), categories = list(), weights = "none", alpha_metric = "nominal",
408 confidence_level = 0.95, replicates = 500L, seed = 20260928L, kappa_bootstrap = FALSE),
409 outputs, c(agreement_notes, "Without declared categories the observed codes sort numerically: 1, 2, 3, 4."),
410 RATER_SOURCE, RATER_CITATION)Whole script generators/r/descriptives_reliability_agreement.R
Rater agreement: linear-weighted kappa and ordinal alpha
Case STAT-DESC-RATER-AGREE-002 · status: passed
Reference
- Evidence type
- R
- Source
- irr::kappa2, irr::kappam.fleiss, irr::kripp.alpha and base R (Fleiss, Cohen and Everitt 1969 variance)
- Citation
- Gamer, M., Lemon, J. and Fellows Puspendra Singh, I. (2019). irr: various coefficients of interrater reliability and agreement. R package version 0.85; Cohen (1960); Fleiss, Cohen and Everitt (1969) Psychological Bulletin 72:323-327; Fleiss, Nee and Landis (1979); Krippendorff (2004).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, psych 2.6.5, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reliability_agreement.R · sha256 6f498a9f8544f55b
- Dataset
- reference_data/datasets/DESC_RATERS_B7.json
Settings compared
alpha_metric= "ordinal"categories= ["1", "2", "3", "4"]confidence_level= 0.95kappa_bootstrap= falseraters= ["r1", "r2"]replicates= 500seed= 20260928weights= "linear"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cohen/units | exact | 29 | 29 | 0.00E+2 | passed | |
/cohen/kappa | tolerance | 0.54586129753914969 | 0.5458612975391497 | 2.43E-18 | 17 | passed |
/cohen/observed_agreement | tolerance | 0.83908045977011503 | 0.8390804597701149 | 1.13E-16 | 15 | passed |
/cohen/expected_agreement | tolerance | 0.64565992865636157 | 0.6456599286563616 | 2.76E-19 | 18 | passed |
/cohen/standard_error | tolerance | 0.094831248080526842 | 0.09483124808052697 | 1.25E-16 | 14 | passed |
/cohen/lower | tolerance | 0.35999546669233429 | 0.35999546669233373 | 5.58E-16 | 14 | passed |
/cohen/upper | tolerance | 0.73172712838596576 | 0.7317271283859657 | 1.07E-16 | 15 | passed |
/cohen/null_standard_error | tolerance | 0.1239334333616075 | 0.12393343336160738 | 1.21E-16 | 15 | passed |
/cohen/z_value | tolerance | 4.4044716807486504 | 4.40447168074865 | 3.60E-17 | 17 | passed |
/cohen/p_value | tail_probability | 1.0604199179198304e-05 | 1.0604199179241333e-05 | 4.30E-17 | 11 | passed |
/table/0/0 | exact | 6 | 6 | 0.00E+2 | passed | |
/table/1/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/complete_units | exact | 29 | 29 | 0.00E+2 | passed | |
/percent_agreement | tolerance | 0.51724137931034486 | 0.5172413793103449 | 2.04E-18 | 17 | passed |
/krippendorff/alpha | tolerance | 0.74026361318785372 | 0.7402636131878537 | 4.34E-19 | 18 | passed |
/krippendorff/pairable_values | exact | 58 | 58 | 0.00E+2 | passed | |
/krippendorff/units | exact | 29 | 29 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/88-reliability-agreement.tex:100-110: Cohen's kappa over units rated by both raters; linear/quadratic weights need a declared category order.
- docs/manual/chapters/88-reliability-agreement.tex:112-119: Fleiss' kappa over complete sets; Krippendorff's alpha allows incomplete units with at least two ratings, with the nominal, ordinal or interval metric.
- Weights use category positions: linear 1 - |i - j|/(c - 1), quadratic 1 - (i - j)^2/(c - 1)^2 (irr::kappa2 'equal' and 'squared').
- Fleiss category kappa follows Fleiss (1971): kappa_j = 1 - sum_i n_ij (m - n_ij) / (N m (m - 1) p_j (1 - p_j)) with null SE sqrt(2 / (N m (m - 1))), the same quantities irr::kappam.fleiss prints rounded to three decimals.
- Two-sided normal p-values use 2 * pnorm(-|z|); irr computes 2 * (1 - pnorm(z)), which loses digits to cancellation in the far tail.
- The bootstrap limits are seed-dependent and not compared.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
413 outputs <- c(cohen_outputs(rd$r1, rd$r2, "linear", 0.95), alpha_outputs(c("r1", "r2"), "ordinal"))
414 emit("STAT-DESC-RATER-AGREE-002", "Rater agreement: linear-weighted kappa and ordinal alpha",
415 RATER, "raterAgreementMenuItem", RATER_REQ, "DESC_RATERS_B7",
416 list(raters = list("r1", "r2"), categories = as.list(CATS), weights = "linear",
417 alpha_metric = "ordinal", confidence_level = 0.95, replicates = 500L,
418 seed = 20260928L, kappa_bootstrap = FALSE),
419 outputs, agreement_notes, RATER_SOURCE, RATER_CITATION, kind = "axis_coverage")Whole script generators/r/descriptives_reliability_agreement.R
Rater agreement: quadratic-weighted kappa at 90% and interval alpha
Case STAT-DESC-RATER-AGREE-003 · status: passed
Reference
- Evidence type
- R
- Source
- irr::kappa2, irr::kappam.fleiss, irr::kripp.alpha and base R (Fleiss, Cohen and Everitt 1969 variance)
- Citation
- Gamer, M., Lemon, J. and Fellows Puspendra Singh, I. (2019). irr: various coefficients of interrater reliability and agreement. R package version 0.85; Cohen (1960); Fleiss, Cohen and Everitt (1969) Psychological Bulletin 72:323-327; Fleiss, Nee and Landis (1979); Krippendorff (2004).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, psych 2.6.5, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reliability_agreement.R · sha256 6f498a9f8544f55b
- Dataset
- reference_data/datasets/DESC_RATERS_B7.json
Settings compared
alpha_metric= "interval"categories= ["1", "2", "3", "4"]confidence_level= 0.9kappa_bootstrap= falseraters= ["r1", "r2"]replicates= 500seed= 20260928weights= "quadratic"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cohen/units | exact | 29 | 29 | 0.00E+2 | passed | |
/cohen/kappa | tolerance | 0.73359580052493445 | 0.7335958005249338 | 6.67E-16 | 15 | passed |
/cohen/observed_agreement | tolerance | 0.94636015325670497 | 0.9463601532567049 | 1.09E-16 | 15 | passed |
/cohen/expected_agreement | tolerance | 0.79865239793896159 | 0.7986523979389616 | 9.59E-19 | 17 | passed |
/cohen/standard_error | tolerance | 0.067150701968550969 | 0.06715070196855097 | 2.65E-19 | 17 | passed |
/cohen/lower | tolerance | 0.62314272483962596 | 0.6231427248396254 | 5.54E-16 | 15 | passed |
/cohen/upper | tolerance | 0.84404887621024272 | 0.8440488762102422 | 5.60E-16 | 15 | passed |
/cohen/null_standard_error | tolerance | 0.18073208989186815 | 0.18073208989186842 | 2.75E-16 | 14 | passed |
/cohen/z_value | tolerance | 4.0590235024883539 | 4.0590235024883645 | 1.06E-14 | 14 | passed |
/cohen/p_value | tail_probability | 4.9278354256276913e-05 | 4.927835425624207e-05 | 3.48E-17 | 12 | passed |
/table/0/0 | exact | 6 | 6 | 0.00E+2 | passed | |
/table/1/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/complete_units | exact | 29 | 29 | 0.00E+2 | passed | |
/percent_agreement | tolerance | 0.51724137931034486 | 0.5172413793103449 | 2.04E-18 | 17 | passed |
/krippendorff/alpha | tolerance | 0.73680738786279676 | 0.7368073878627968 | 1.22E-18 | 17 | passed |
/krippendorff/pairable_values | exact | 58 | 58 | 0.00E+2 | passed | |
/krippendorff/units | exact | 29 | 29 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/88-reliability-agreement.tex:100-110: Cohen's kappa over units rated by both raters; linear/quadratic weights need a declared category order.
- docs/manual/chapters/88-reliability-agreement.tex:112-119: Fleiss' kappa over complete sets; Krippendorff's alpha allows incomplete units with at least two ratings, with the nominal, ordinal or interval metric.
- Weights use category positions: linear 1 - |i - j|/(c - 1), quadratic 1 - (i - j)^2/(c - 1)^2 (irr::kappa2 'equal' and 'squared').
- Fleiss category kappa follows Fleiss (1971): kappa_j = 1 - sum_i n_ij (m - n_ij) / (N m (m - 1) p_j (1 - p_j)) with null SE sqrt(2 / (N m (m - 1))), the same quantities irr::kappam.fleiss prints rounded to three decimals.
- Two-sided normal p-values use 2 * pnorm(-|z|); irr computes 2 * (1 - pnorm(z)), which loses digits to cancellation in the far tail.
- The bootstrap limits are seed-dependent and not compared.
- Interval alpha uses the numeric codes' squared differences; the 90% kappa interval uses qnorm(0.95).
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
422 outputs <- c(cohen_outputs(rd$r1, rd$r2, "quadratic", 0.90), alpha_outputs(c("r1", "r2"), "interval"))
423 emit("STAT-DESC-RATER-AGREE-003", "Rater agreement: quadratic-weighted kappa at 90% and interval alpha",
424 RATER, "raterAgreementMenuItem", RATER_REQ, "DESC_RATERS_B7",
425 list(raters = list("r1", "r2"), categories = as.list(CATS), weights = "quadratic",
426 alpha_metric = "interval", confidence_level = 0.90, replicates = 500L,
427 seed = 20260928L, kappa_bootstrap = FALSE),
428 outputs, c(agreement_notes, "Interval alpha uses the numeric codes' squared differences; the 90% kappa interval uses qnorm(0.95)."),
429 RATER_SOURCE, RATER_CITATION, kind = "axis_coverage")Whole script generators/r/descriptives_reliability_agreement.R
Rater agreement: Fleiss' kappa for three raters with missing ratings
Case STAT-DESC-RATER-AGREE-004 · status: passed
Reference
- Evidence type
- R
- Source
- irr::kappa2, irr::kappam.fleiss, irr::kripp.alpha and base R (Fleiss, Cohen and Everitt 1969 variance)
- Citation
- Gamer, M., Lemon, J. and Fellows Puspendra Singh, I. (2019). irr: various coefficients of interrater reliability and agreement. R package version 0.85; Cohen (1960); Fleiss, Cohen and Everitt (1969) Psychological Bulletin 72:323-327; Fleiss, Nee and Landis (1979); Krippendorff (2004).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, psych 2.6.5, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reliability_agreement.R · sha256 6f498a9f8544f55b
- Dataset
- reference_data/datasets/DESC_RATERS_B7.json
Settings compared
alpha_metric= "nominal"categories= ["1", "2", "3", "4"]confidence_level= 0.95kappa_bootstrap= falseraters= ["r1", "r2", "r3"]replicates= 500seed= 20260928weights= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fleiss/units | exact | 25 | 25 | 0.00E+2 | passed | |
/fleiss/kappa | tolerance | 0.42218798151001541 | 0.4221879815100154 | 1.25E-18 | 17 | passed |
/fleiss/z_value | tolerance | 5.6284710828773985 | 5.6284710828773985 | 1.41E-18 | 18 | passed |
/fleiss/p_value | tail_probability | 1.8181397470801036e-08 | 1.8181397470801e-08 | 3.67E-23 | 14 | passed |
/category_kappas/[category=1]/kappa | tolerance | 0.69999999999999996 | 0.7 | 4.41E-18 | 17 | passed |
/category_kappas/[category=1]/null_standard_error | tolerance | 0.11547005383792516 | 0.11547005383792516 | 2.87E-18 | 16 | passed |
/category_kappas/[category=1]/z_value | tolerance | 6.0621778264910695 | 6.0621778264910695 | 9.98E-18 | 17 | passed |
/category_kappas/[category=1]/p_value | tail_probability | 1.342906179143749e-09 | 1.3429061791437452e-09 | 3.76E-24 | 14 | passed |
/category_kappas/[category=2]/kappa | tolerance | 0.30555555555555558 | 0.3055555555555556 | 2.27E-19 | 18 | passed |
/category_kappas/[category=2]/null_standard_error | tolerance | 0.11547005383792516 | 0.11547005383792516 | 2.87E-18 | 16 | passed |
/category_kappas/[category=2]/z_value | tolerance | 2.6461887337857846 | 2.6461887337857846 | 3.63E-17 | 16 | passed |
/category_kappas/[category=2]/p_value | tail_probability | 0.0081404384156780057 | 0.008140438415678006 | 4.58E-20 | 17 | passed |
/category_kappas/[category=3]/kappa | tolerance | 0.29511278195488722 | 0.2951127819548872 | 4.46E-18 | 16 | passed |
/category_kappas/[category=3]/null_standard_error | tolerance | 0.11547005383792516 | 0.11547005383792516 | 2.87E-18 | 16 | passed |
/category_kappas/[category=3]/z_value | tolerance | 2.5557516615443019 | 2.555751661544302 | 1.07E-17 | 17 | passed |
/category_kappas/[category=3]/p_value | tail_probability | 0.010595870975048842 | 0.010595870975048834 | 8.37E-18 | 15 | passed |
/category_kappas/[category=4]/kappa | tolerance | 0.20774647887323938 | 0.20774647887323938 | 1.89E-18 | 17 | passed |
/category_kappas/[category=4]/null_standard_error | tolerance | 0.11547005383792516 | 0.11547005383792516 | 2.87E-18 | 16 | passed |
/category_kappas/[category=4]/z_value | tolerance | 1.7991372825099248 | 1.7991372825099248 | 2.66E-17 | 16 | passed |
/category_kappas/[category=4]/p_value | tail_probability | 0.071996967398577125 | 0.07199696739857712 | 3.14E-19 | 17 | passed |
/krippendorff/alpha | tolerance | 0.4377952755905512 | 0.4377952755905512 | 2.78E-18 | 17 | passed |
/krippendorff/pairable_values | exact | 85 | 85 | 0.00E+2 | passed | |
/krippendorff/units | exact | 30 | 30 | 0.00E+2 | passed | |
/complete_units | exact | 25 | 25 | 0.00E+2 | passed | |
/percent_agreement | tolerance | 0.44 | 0.44 | 2.22E-18 | 17 | passed |
Convention
- docs/manual/chapters/88-reliability-agreement.tex:100-110: Cohen's kappa over units rated by both raters; linear/quadratic weights need a declared category order.
- docs/manual/chapters/88-reliability-agreement.tex:112-119: Fleiss' kappa over complete sets; Krippendorff's alpha allows incomplete units with at least two ratings, with the nominal, ordinal or interval metric.
- Weights use category positions: linear 1 - |i - j|/(c - 1), quadratic 1 - (i - j)^2/(c - 1)^2 (irr::kappa2 'equal' and 'squared').
- Fleiss category kappa follows Fleiss (1971): kappa_j = 1 - sum_i n_ij (m - n_ij) / (N m (m - 1) p_j (1 - p_j)) with null SE sqrt(2 / (N m (m - 1))), the same quantities irr::kappam.fleiss prints rounded to three decimals.
- Two-sided normal p-values use 2 * pnorm(-|z|); irr computes 2 * (1 - pnorm(z)), which loses digits to cancellation in the far tail.
- The bootstrap limits are seed-dependent and not compared.
- Fleiss' kappa uses the 25 units with all three ratings; Krippendorff's alpha also uses the units with two ratings.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
432 complete3 <- stats::complete.cases(rd)
433 outputs <- c(fleiss_outputs(c("r1", "r2", "r3")), alpha_outputs(c("r1", "r2", "r3"), "nominal"),
434 list("/complete_units" = exact(sum(complete3), "units rated by all three raters"),
435 "/percent_agreement" = tol(mean(apply(rd[complete3, ], 1, function(v) length(unique(v)) == 1)), "share of complete units where all three agree")))
436 emit("STAT-DESC-RATER-AGREE-004", "Rater agreement: Fleiss' kappa for three raters with missing ratings",
437 RATER, "raterAgreementMenuItem", RATER_REQ, "DESC_RATERS_B7",
438 list(raters = list("r1", "r2", "r3"), categories = as.list(CATS), weights = "none",
439 alpha_metric = "nominal", confidence_level = 0.95, replicates = 500L,
440 seed = 20260928L, kappa_bootstrap = FALSE),
441 outputs, c(agreement_notes, "Fleiss' kappa uses the 25 units with all three ratings; Krippendorff's alpha also uses the units with two ratings."),
442 RATER_SOURCE, RATER_CITATION, kind = "axis_coverage")Whole script generators/r/descriptives_reliability_agreement.R
Scale reliability with a reverse-coded item (halves split, ICC(3,1))
Case STAT-DESC-SCALE-REL-001 · status: passed
Reference
- Evidence type
- R
- Source
- psych::alpha, psych::ICC, stats::friedman.test and base R covariance algebra
- Citation
- Revelle, W. (2024). psych: procedures for psychological research. R package version 2.6.5; Cronbach (1951); Guttman (1945) Psychometrika 10:255-282; McGraw and Wong (1996) Psychological Methods 1:30-46; Shrout and Fleiss (1979).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, psych 2.6.5, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reliability_agreement.R · sha256 6f498a9f8544f55b
- Dataset
- reference_data/datasets/DESC_SCALE_B7.json
Settings compared
confidence_level= 0.95first_half= []icc_model= "two_way_mixed"icc_type= "consistency"items= ["i1", "i2", "i3", "i4", "i5"]reverse_items= ["i4"]scale_high= 5scale_low= 1split= "halves"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 19 | 19 | 0.00E+2 | passed | |
/k | exact | 5 | 5 | 0.00E+2 | passed | |
/alpha | tolerance | 0.81976524043922749 | 0.8197652404392275 | 3.85E-18 | 17 | passed |
/standardized_alpha | tolerance | 0.82483556149133297 | 0.8248355614913331 | 1.10E-16 | 15 | passed |
/guttman/0 | tolerance | 0.655812192351382 | 0.655812192351382 | 4.92E-18 | 17 | passed |
/guttman/1 | tolerance | 0.82888263585939947 | 0.8288826358593995 | 4.75E-18 | 17 | passed |
/guttman/2 | tolerance | 0.81976524043922749 | 0.8197652404392275 | 3.85E-18 | 17 | passed |
/guttman/3 | tolerance | 0.85422188564937529 | 0.8542218856493751 | 2.22E-16 | 15 | passed |
/guttman/4 | tolerance | 0.81030701734247013 | 0.8103070173424701 | 3.87E-18 | 17 | passed |
/guttman/5 | tolerance | 0.84080742630652094 | 0.8408074263065208 | 1.07E-16 | 15 | passed |
/split_half/correlation | tolerance | 0.79248194974477082 | 0.7924819497447708 | 5.78E-19 | 18 | passed |
/split_half/spearman_brown_equal | tolerance | 0.88422865274332196 | 0.884228652743322 | 3.39E-18 | 17 | passed |
/split_half/spearman_brown_unequal | tolerance | 0.88792768411852485 | 0.8879276841185249 | 1.44E-18 | 17 | passed |
/split_half/guttman_split_half | tolerance | 0.85422188564937529 | 0.8542218856493753 | 1.27E-19 | 18 | passed |
/summaries/0/mean | tolerance | 2.7999999999999998 | 2.8 | 2.24E-17 | 17 | passed |
/summaries/3/mean | tolerance | 0.48500973199015496 | 0.48500973199015496 | 2.49E-18 | 17 | passed |
/split_half/first_alpha | tolerance | 0.65745310957551828 | 0.6574531095755181 | 2.22E-16 | 15 | passed |
/split_half/second_alpha | tolerance | 0.6399999999999999 | 0.6399999999999999 | 2.30E-18 | 17 | passed |
/item_totals/0/mean | tolerance | 2.8947368421052633 | 2.8947368421052633 | 2.52E-17 | 17 | passed |
/item_totals/0/sd | tolerance | 1.1496249070460265 | 1.1496249070460265 | 1.04E-17 | 17 | passed |
/item_totals/0/corrected_item_total | tolerance | 0.4968756555518119 | 0.49687565555181173 | 1.65E-16 | 15 | passed |
/item_totals/0/scale_mean_if_deleted | tolerance | 11.105263157894736 | 11.105263157894736 | 2.81E-16 | 16 | passed |
/item_totals/0/scale_variance_if_deleted | tolerance | 10.432748538011696 | 10.432748538011698 | 1.55E-15 | 15 | passed |
/item_totals/0/alpha_if_deleted | tolerance | 0.82286995515695072 | 0.8228699551569507 | 3.54E-18 | 17 | passed |
/item_totals/1/mean | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/item_totals/1/sd | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/item_totals/1/corrected_item_total | tolerance | 0.49999999999999994 | 0.49999999999999994 | 4.49E-18 | 17 | passed |
/item_totals/1/scale_mean_if_deleted | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/item_totals/1/scale_variance_if_deleted | tolerance | 11.111111111111111 | 11.11111111111111 | 2.84E-16 | 16 | passed |
/item_totals/1/alpha_if_deleted | tolerance | 0.81543859649122796 | 0.815438596491228 | 2.74E-18 | 17 | passed |
/item_totals/2/mean | tolerance | 2.6842105263157894 | 2.6842105263157894 | 1.98E-17 | 17 | passed |
/item_totals/2/sd | tolerance | 1.0029197142425581 | 1.002919714242558 | 2.41E-18 | 17 | passed |
/item_totals/2/corrected_item_total | tolerance | 0.76400400818217784 | 0.7640040081821775 | 3.32E-16 | 15 | passed |
/item_totals/2/scale_mean_if_deleted | tolerance | 11.315789473684211 | 11.31578947368421 | 3.80E-16 | 16 | passed |
/item_totals/2/scale_variance_if_deleted | tolerance | 9.6725146198830405 | 9.67251461988304 | 9.76E-18 | 17 | passed |
/item_totals/2/alpha_if_deleted | tolerance | 0.73921805723498579 | 0.7392180572349858 | 2.55E-18 | 17 | passed |
/item_totals/3/mean | tolerance | 2.736842105263158 | 2.736842105263158 | 3.51E-17 | 16 | passed |
/item_totals/3/sd | tolerance | 1.0457376590053493 | 1.0457376590053493 | 1.82E-17 | 16 | passed |
/item_totals/3/corrected_item_total | tolerance | 0.62057992217368441 | 0.6205799221736844 | 3.76E-18 | 17 | passed |
/item_totals/3/scale_mean_if_deleted | tolerance | 11.263157894736842 | 11.263157894736842 | 4.79E-16 | 16 | passed |
/item_totals/3/scale_variance_if_deleted | tolerance | 10.2046783625731 | 10.2046783625731 | 9.66E-17 | 17 | passed |
/item_totals/3/alpha_if_deleted | tolerance | 0.78166189111747841 | 0.7816618911174784 | 3.45E-18 | 17 | passed |
/item_totals/4/mean | tolerance | 2.6842105263157894 | 2.6842105263157894 | 1.98E-17 | 17 | passed |
/item_totals/4/sd | tolerance | 0.94590530292691732 | 0.9459053029269173 | 4.06E-18 | 17 | passed |
/item_totals/4/corrected_item_total | tolerance | 0.7142887705807891 | 0.7142887705807888 | 3.32E-16 | 15 | passed |
/item_totals/4/scale_mean_if_deleted | tolerance | 11.315789473684211 | 11.31578947368421 | 3.80E-16 | 16 | passed |
/item_totals/4/scale_variance_if_deleted | tolerance | 10.228070175438596 | 10.228070175438596 | 1.32E-16 | 16 | passed |
/item_totals/4/alpha_if_deleted | tolerance | 0.75700400228702114 | 0.7570040022870211 | 1.75E-18 | 17 | passed |
/tests/[name=Friedman's chi-square]/statistic | tolerance | 3.3118279569892475 | 3.31182795698921 | 3.73E-14 | 13 | passed |
/tests/[name=Friedman's chi-square]/p_value | tail_probability | 0.50706040776655359 | 0.5070604077665597 | 6.11E-15 | 13 | passed |
/tests/[name=Hotelling's T-squared (equal item means)]/statistic | tolerance | 6.0523351442954656 | 6.052335144295474 | 7.99E-15 | 14 | passed |
/tests/[name=Hotelling's T-squared (equal item means)]/p_value | tail_probability | 0.32835771733752805 | 0.32835771733752767 | 3.84E-16 | 14 | passed |
/anova/0/1 | tolerance | 55.599999999999994 | 55.60000000000001 | 1.45E-14 | 15 | passed |
/anova/1/1 | tolerance | 1.515789473684209 | 1.5157894736842115 | 2.46E-15 | 14 | passed |
/anova/2/1 | tolerance | 40.084210526315786 | 40.0842105263158 | 1.44E-14 | 15 | passed |
/anova/2/3 | tolerance | 0.5567251461988304 | 0.5567251461988305 | 1.12E-16 | 15 | passed |
/icc/0/estimate | tolerance | 0.47634763476347614 | 0.47634763476347636 | 2.17E-16 | 15 | passed |
/icc/0/lower | tolerance | 0.27039040395021596 | 0.27039040395021624 | 2.80E-16 | 14 | passed |
/icc/0/upper | tolerance | 0.70168066380743332 | 0.7016806638074335 | 2.27E-16 | 15 | passed |
/icc/0/f_value | tolerance | 5.5483193277310887 | 5.548319327731092 | 3.57E-15 | 15 | passed |
/icc/0/df1 | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/icc/0/df2 | tolerance | 72 | 72.0 | 0.00E+2 | passed | |
/icc/0/p_value | tail_probability | 6.7726694227101891e-08 | 6.772669422710107e-08 | 8.20E-22 | 13 | passed |
/icc/1/estimate | tolerance | 0.81976524043922738 | 0.8197652404392276 | 2.25E-16 | 15 | passed |
/icc/1/lower | tolerance | 0.64948931104829555 | 0.6494893110482958 | 2.20E-16 | 15 | passed |
/icc/1/upper | tolerance | 0.92163355116435108 | 0.9216335511643511 | 3.61E-18 | 17 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/88-reliability-agreement.tex:14-17: reversal uses x* = L + U - x once; incomplete cases are omitted.
- docs/manual/chapters/88-reliability-agreement.tex:19-29: Cronbach's alpha from the covariance matrix; standardized alpha from the mean inter-item correlation; Guttman's coefficients are covariance-based summaries.
- docs/manual/chapters/88-reliability-agreement.tex:33-38: first/second half split; Spearman-Brown 2r/(1+r) and Guttman's split-half value.
- docs/manual/chapters/88-reliability-agreement.tex:54-72: ICC(C,1) = (MSR - MSE)/(MSR + (k-1) MSE), ICC(C,k) = (MSR - MSE)/MSR; consistency intervals use the F pivot.
- psych::ICC ICC3 / ICC3k are the two-way consistency coefficients ICC(C,1) and ICC(C,k) (McGraw and Wong).
- psych::ICC(lmer = FALSE) computes the classical McGraw and Wong (1996) two-way ANOVA mean squares; psych's default lmer = TRUE substitutes REML variance components, whose mean squares are different quantities and do not match the manual's ANOVA formulas. The hand-computed mean squares reproduce the lmer = FALSE rows exactly.
- Guttman lambda 6 is computed on the raw scores, 1 - sum_j 1/(S^-1)_jj / (1'S1); psych's G6(smc) is the correlation-matrix analogue of lambda 6 and is used only as a cross-check, because it equals the raw-score value only when the item variances are equal.
- Halves: first i1, i2, i3 ((k+1)/2 = 3 items); second i4, i5.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
210 m <- adjusted(ITEMS, "i4")
211 outputs <- c(scale_core(m, c("i1", "i2", "i3"), c("i4", "i5")),
212 icc_outputs(m, "two_way_mixed", "consistency", 0.95),
213 list("/missing_count" = exact(1L, "row 7 has a missing i2")))
214 emit("STAT-DESC-SCALE-REL-001", "Scale reliability with a reverse-coded item (halves split, ICC(3,1))",
215 SCALE, "scaleReliabilityMenuItem", SCALE_REQ, "DESC_SCALE_B7",
216 list(items = as.list(ITEMS), reverse_items = list("i4"), scale_low = 1, scale_high = 5,
217 split = "halves", first_half = list(), icc_model = "two_way_mixed",
218 icc_type = "consistency", confidence_level = 0.95),
219 outputs,
220 c(paste0(MANUAL_SCALE, ":14-17: reversal uses x* = L + U - x once; incomplete cases are omitted."),
221 paste0(MANUAL_SCALE, ":19-29: Cronbach's alpha from the covariance matrix; standardized alpha from the mean inter-item correlation; Guttman's coefficients are covariance-based summaries."),
222 paste0(MANUAL_SCALE, ":33-38: first/second half split; Spearman-Brown 2r/(1+r) and Guttman's split-half value."),
223 paste0(MANUAL_SCALE, ":54-72: ICC(C,1) = (MSR - MSE)/(MSR + (k-1) MSE), ICC(C,k) = (MSR - MSE)/MSR; consistency intervals use the F pivot."),
224 "psych::ICC ICC3 / ICC3k are the two-way consistency coefficients ICC(C,1) and ICC(C,k) (McGraw and Wong).",
225 ICC_PSYCH_NOTE,
226 GUTTMAN_L6_NOTE,
227 "Halves: first i1, i2, i3 ((k+1)/2 = 3 items); second i4, i5."),
228 SCALE_SOURCE, SCALE_CITATION)Whole script generators/r/descriptives_reliability_agreement.R
Scale reliability with an odd/even split and ICC(2,1) absolute agreement
Case STAT-DESC-SCALE-REL-002 · status: passed
Reference
- Evidence type
- R
- Source
- psych::alpha, psych::ICC, stats::friedman.test and base R covariance algebra
- Citation
- Revelle, W. (2024). psych: procedures for psychological research. R package version 2.6.5; Cronbach (1951); Guttman (1945) Psychometrika 10:255-282; McGraw and Wong (1996) Psychological Methods 1:30-46; Shrout and Fleiss (1979).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, psych 2.6.5, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reliability_agreement.R · sha256 6f498a9f8544f55b
- Dataset
- reference_data/datasets/DESC_SCALE_B7.json
Settings compared
confidence_level= 0.95first_half= []icc_model= "two_way_random"icc_type= "agreement"items= ["i1", "i2", "i3", "i4", "i5"]reverse_items= ["i4"]scale_high= 5scale_low= 1split= "odd_even"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 19 | 19 | 0.00E+2 | passed | |
/k | exact | 5 | 5 | 0.00E+2 | passed | |
/alpha | tolerance | 0.81976524043922749 | 0.8197652404392275 | 3.85E-18 | 17 | passed |
/standardized_alpha | tolerance | 0.82483556149133297 | 0.8248355614913331 | 1.10E-16 | 15 | passed |
/guttman/0 | tolerance | 0.655812192351382 | 0.655812192351382 | 4.92E-18 | 17 | passed |
/guttman/1 | tolerance | 0.82888263585939947 | 0.8288826358593995 | 4.75E-18 | 17 | passed |
/guttman/2 | tolerance | 0.81976524043922749 | 0.8197652404392275 | 3.85E-18 | 17 | passed |
/guttman/3 | tolerance | 0.79591063990912536 | 0.7959106399091256 | 2.23E-16 | 15 | passed |
/guttman/4 | tolerance | 0.81030701734247013 | 0.8103070173424701 | 3.87E-18 | 17 | passed |
/guttman/5 | tolerance | 0.84080742630652094 | 0.8408074263065208 | 1.07E-16 | 15 | passed |
/split_half/correlation | tolerance | 0.72340385582692968 | 0.7234038558269295 | 2.26E-16 | 15 | passed |
/split_half/spearman_brown_equal | tolerance | 0.83950590383218515 | 0.8395059038321848 | 3.31E-16 | 15 | passed |
/split_half/spearman_brown_unequal | tolerance | 0.84419842066189643 | 0.8441984206618959 | 5.54E-16 | 15 | passed |
/split_half/guttman_split_half | tolerance | 0.79591063990912536 | 0.7959106399091254 | 1.41E-18 | 17 | passed |
/summaries/0/mean | tolerance | 2.7999999999999998 | 2.8 | 2.24E-17 | 17 | passed |
/summaries/3/mean | tolerance | 0.48500973199015496 | 0.48500973199015496 | 2.49E-18 | 17 | passed |
/split_half/first_alpha | tolerance | 0.76073345259391778 | 0.7607334525939176 | 2.22E-16 | 15 | passed |
/split_half/second_alpha | tolerance | 0.48305084745762694 | 0.4830508474576267 | 2.20E-16 | 15 | passed |
/item_totals/0/mean | tolerance | 2.8947368421052633 | 2.8947368421052633 | 2.52E-17 | 17 | passed |
/item_totals/0/sd | tolerance | 1.1496249070460265 | 1.1496249070460265 | 1.04E-17 | 17 | passed |
/item_totals/0/corrected_item_total | tolerance | 0.4968756555518119 | 0.49687565555181173 | 1.65E-16 | 15 | passed |
/item_totals/0/scale_mean_if_deleted | tolerance | 11.105263157894736 | 11.105263157894736 | 2.81E-16 | 16 | passed |
/item_totals/0/scale_variance_if_deleted | tolerance | 10.432748538011696 | 10.432748538011698 | 1.55E-15 | 15 | passed |
/item_totals/0/alpha_if_deleted | tolerance | 0.82286995515695072 | 0.8228699551569507 | 3.54E-18 | 17 | passed |
/item_totals/1/mean | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/item_totals/1/sd | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/item_totals/1/corrected_item_total | tolerance | 0.49999999999999994 | 0.49999999999999994 | 4.49E-18 | 17 | passed |
/item_totals/1/scale_mean_if_deleted | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/item_totals/1/scale_variance_if_deleted | tolerance | 11.111111111111111 | 11.11111111111111 | 2.84E-16 | 16 | passed |
/item_totals/1/alpha_if_deleted | tolerance | 0.81543859649122796 | 0.815438596491228 | 2.74E-18 | 17 | passed |
/item_totals/2/mean | tolerance | 2.6842105263157894 | 2.6842105263157894 | 1.98E-17 | 17 | passed |
/item_totals/2/sd | tolerance | 1.0029197142425581 | 1.002919714242558 | 2.41E-18 | 17 | passed |
/item_totals/2/corrected_item_total | tolerance | 0.76400400818217784 | 0.7640040081821775 | 3.32E-16 | 15 | passed |
/item_totals/2/scale_mean_if_deleted | tolerance | 11.315789473684211 | 11.31578947368421 | 3.80E-16 | 16 | passed |
/item_totals/2/scale_variance_if_deleted | tolerance | 9.6725146198830405 | 9.67251461988304 | 9.76E-18 | 17 | passed |
/item_totals/2/alpha_if_deleted | tolerance | 0.73921805723498579 | 0.7392180572349858 | 2.55E-18 | 17 | passed |
/item_totals/3/mean | tolerance | 2.736842105263158 | 2.736842105263158 | 3.51E-17 | 16 | passed |
/item_totals/3/sd | tolerance | 1.0457376590053493 | 1.0457376590053493 | 1.82E-17 | 16 | passed |
/item_totals/3/corrected_item_total | tolerance | 0.62057992217368441 | 0.6205799221736844 | 3.76E-18 | 17 | passed |
/item_totals/3/scale_mean_if_deleted | tolerance | 11.263157894736842 | 11.263157894736842 | 4.79E-16 | 16 | passed |
/item_totals/3/scale_variance_if_deleted | tolerance | 10.2046783625731 | 10.2046783625731 | 9.66E-17 | 17 | passed |
/item_totals/3/alpha_if_deleted | tolerance | 0.78166189111747841 | 0.7816618911174784 | 3.45E-18 | 17 | passed |
/item_totals/4/mean | tolerance | 2.6842105263157894 | 2.6842105263157894 | 1.98E-17 | 17 | passed |
/item_totals/4/sd | tolerance | 0.94590530292691732 | 0.9459053029269173 | 4.06E-18 | 17 | passed |
/item_totals/4/corrected_item_total | tolerance | 0.7142887705807891 | 0.7142887705807888 | 3.32E-16 | 15 | passed |
/item_totals/4/scale_mean_if_deleted | tolerance | 11.315789473684211 | 11.31578947368421 | 3.80E-16 | 16 | passed |
/item_totals/4/scale_variance_if_deleted | tolerance | 10.228070175438596 | 10.228070175438596 | 1.32E-16 | 16 | passed |
/item_totals/4/alpha_if_deleted | tolerance | 0.75700400228702114 | 0.7570040022870211 | 1.75E-18 | 17 | passed |
/tests/[name=Friedman's chi-square]/statistic | tolerance | 3.3118279569892475 | 3.31182795698921 | 3.73E-14 | 13 | passed |
/tests/[name=Friedman's chi-square]/p_value | tail_probability | 0.50706040776655359 | 0.5070604077665597 | 6.11E-15 | 13 | passed |
/tests/[name=Hotelling's T-squared (equal item means)]/statistic | tolerance | 6.0523351442954656 | 6.052335144295474 | 7.99E-15 | 14 | passed |
/tests/[name=Hotelling's T-squared (equal item means)]/p_value | tail_probability | 0.32835771733752805 | 0.32835771733752767 | 3.84E-16 | 14 | passed |
/anova/0/1 | tolerance | 55.599999999999994 | 55.60000000000001 | 1.45E-14 | 15 | passed |
/anova/1/1 | tolerance | 1.515789473684209 | 1.5157894736842115 | 2.46E-15 | 14 | passed |
/anova/2/1 | tolerance | 40.084210526315786 | 40.0842105263158 | 1.44E-14 | 15 | passed |
/anova/2/3 | tolerance | 0.5567251461988304 | 0.5567251461988305 | 1.12E-16 | 15 | passed |
/icc/0/estimate | tolerance | 0.48057713651498318 | 0.4805771365149833 | 1.14E-16 | 15 | passed |
/icc/0/lower | tolerance | 0.27508342616620307 | 0.27508342616620324 | 1.68E-16 | 15 | passed |
/icc/0/upper | tolerance | 0.70475997031264137 | 0.7047599703126414 | 6.04E-19 | 18 | passed |
/icc/0/f_value | tolerance | 5.5483193277310887 | 5.548319327731092 | 3.57E-15 | 15 | passed |
/icc/0/df1 | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/icc/0/df2 | tolerance | 72 | 72.0 | 0.00E+2 | passed | |
/icc/0/p_value | tail_probability | 6.7726694227101891e-08 | 6.772669422710107e-08 | 8.20E-22 | 13 | passed |
/icc/1/estimate | tolerance | 0.82225598176984416 | 0.8222559817698444 | 2.20E-16 | 15 | passed |
/icc/1/lower | tolerance | 0.65485647722370632 | 0.6548564772237065 | 2.26E-16 | 15 | passed |
/icc/1/upper | tolerance | 0.92269260367328754 | 0.9226926036732875 | 3.09E-18 | 17 | passed |
Convention
- docs/manual/chapters/88-reliability-agreement.tex:54-72: ICC(A,1) = (MSR - MSE)/(MSR + (k-1) MSE + k (MSC - MSE)/n); agreement intervals use an approximate df calculation.
- psych::ICC ICC2 / ICC2k are the two-way random absolute-agreement coefficients ICC(A,1) and ICC(A,k); their bounds follow Shrout and Fleiss (1979) / McGraw and Wong (1996).
- psych::ICC(lmer = FALSE) computes the classical McGraw and Wong (1996) two-way ANOVA mean squares; psych's default lmer = TRUE substitutes REML variance components, whose mean squares are different quantities and do not match the manual's ANOVA formulas. The hand-computed mean squares reproduce the lmer = FALSE rows exactly.
- Guttman lambda 6 is computed on the raw scores, 1 - sum_j 1/(S^-1)_jj / (1'S1); psych's G6(smc) is the correlation-matrix analogue of lambda 6 and is used only as a cross-check, because it equals the raw-score value only when the item variances are equal.
- Odd/even split: first i1, i3, i5; second i2, i4.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
231 outputs <- c(scale_core(m, c("i1", "i3", "i5"), c("i2", "i4")),
232 icc_outputs(m, "two_way_random", "agreement", 0.95))
233 emit("STAT-DESC-SCALE-REL-002", "Scale reliability with an odd/even split and ICC(2,1) absolute agreement",
234 SCALE, "scaleReliabilityMenuItem", SCALE_REQ, "DESC_SCALE_B7",
235 list(items = as.list(ITEMS), reverse_items = list("i4"), scale_low = 1, scale_high = 5,
236 split = "odd_even", first_half = list(), icc_model = "two_way_random",
237 icc_type = "agreement", confidence_level = 0.95),
238 outputs,
239 c(paste0(MANUAL_SCALE, ":54-72: ICC(A,1) = (MSR - MSE)/(MSR + (k-1) MSE + k (MSC - MSE)/n); agreement intervals use an approximate df calculation."),
240 "psych::ICC ICC2 / ICC2k are the two-way random absolute-agreement coefficients ICC(A,1) and ICC(A,k); their bounds follow Shrout and Fleiss (1979) / McGraw and Wong (1996).",
241 ICC_PSYCH_NOTE,
242 GUTTMAN_L6_NOTE,
243 "Odd/even split: first i1, i3, i5; second i2, i4."),
244 SCALE_SOURCE, SCALE_CITATION, kind = "axis_coverage")Whole script generators/r/descriptives_reliability_agreement.R
Scale reliability with a declared split and one-way ICC at 90%
Case STAT-DESC-SCALE-REL-003 · status: passed
Reference
- Evidence type
- R
- Source
- psych::alpha, psych::ICC, stats::friedman.test and base R covariance algebra
- Citation
- Revelle, W. (2024). psych: procedures for psychological research. R package version 2.6.5; Cronbach (1951); Guttman (1945) Psychometrika 10:255-282; McGraw and Wong (1996) Psychological Methods 1:30-46; Shrout and Fleiss (1979).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, psych 2.6.5, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reliability_agreement.R · sha256 6f498a9f8544f55b
- Dataset
- reference_data/datasets/DESC_SCALE_B7.json
Settings compared
confidence_level= 0.9first_half= ["i2", "i5"]icc_model= "one_way"icc_type= "consistency"items= ["i1", "i2", "i3", "i4", "i5"]reverse_items= ["i4"]scale_high= 5scale_low= 1split= "custom"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 19 | 19 | 0.00E+2 | passed | |
/k | exact | 5 | 5 | 0.00E+2 | passed | |
/alpha | tolerance | 0.81976524043922749 | 0.8197652404392275 | 3.85E-18 | 17 | passed |
/standardized_alpha | tolerance | 0.82483556149133297 | 0.8248355614913331 | 1.10E-16 | 15 | passed |
/guttman/0 | tolerance | 0.655812192351382 | 0.655812192351382 | 4.92E-18 | 17 | passed |
/guttman/1 | tolerance | 0.82888263585939947 | 0.8288826358593995 | 4.75E-18 | 17 | passed |
/guttman/2 | tolerance | 0.81976524043922749 | 0.8197652404392275 | 3.85E-18 | 17 | passed |
/guttman/3 | tolerance | 0.64596743657705402 | 0.645967436577054 | 1.64E-18 | 17 | passed |
/guttman/4 | tolerance | 0.81030701734247013 | 0.8103070173424701 | 3.87E-18 | 17 | passed |
/guttman/5 | tolerance | 0.84080742630652094 | 0.8408074263065208 | 1.07E-16 | 15 | passed |
/split_half/correlation | tolerance | 0.51634533926474346 | 0.5163453392647436 | 1.15E-16 | 15 | passed |
/split_half/spearman_brown_equal | tolerance | 0.68103924072482425 | 0.6810392407248242 | 3.66E-18 | 17 | passed |
/split_half/spearman_brown_unequal | tolerance | 0.68774134512296003 | 0.6877413451229601 | 1.16E-16 | 15 | passed |
/split_half/guttman_split_half | tolerance | 0.64596743657705402 | 0.6459674365770538 | 2.20E-16 | 15 | passed |
/summaries/0/mean | tolerance | 2.7999999999999998 | 2.8 | 2.24E-17 | 17 | passed |
/summaries/3/mean | tolerance | 0.48500973199015496 | 0.48500973199015496 | 2.49E-18 | 17 | passed |
/split_half/first_alpha | tolerance | 0.82608695652173902 | 0.826086956521739 | 4.24E-18 | 17 | passed |
/split_half/second_alpha | tolerance | 0.79004854368932054 | 0.7900485436893205 | 2.90E-18 | 17 | passed |
/item_totals/0/mean | tolerance | 2.8947368421052633 | 2.8947368421052633 | 2.52E-17 | 17 | passed |
/item_totals/0/sd | tolerance | 1.1496249070460265 | 1.1496249070460265 | 1.04E-17 | 17 | passed |
/item_totals/0/corrected_item_total | tolerance | 0.4968756555518119 | 0.49687565555181173 | 1.65E-16 | 15 | passed |
/item_totals/0/scale_mean_if_deleted | tolerance | 11.105263157894736 | 11.105263157894736 | 2.81E-16 | 16 | passed |
/item_totals/0/scale_variance_if_deleted | tolerance | 10.432748538011696 | 10.432748538011698 | 1.55E-15 | 15 | passed |
/item_totals/0/alpha_if_deleted | tolerance | 0.82286995515695072 | 0.8228699551569507 | 3.54E-18 | 17 | passed |
/item_totals/1/mean | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/item_totals/1/sd | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/item_totals/1/corrected_item_total | tolerance | 0.49999999999999994 | 0.49999999999999994 | 4.49E-18 | 17 | passed |
/item_totals/1/scale_mean_if_deleted | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/item_totals/1/scale_variance_if_deleted | tolerance | 11.111111111111111 | 11.11111111111111 | 2.84E-16 | 16 | passed |
/item_totals/1/alpha_if_deleted | tolerance | 0.81543859649122796 | 0.815438596491228 | 2.74E-18 | 17 | passed |
/item_totals/2/mean | tolerance | 2.6842105263157894 | 2.6842105263157894 | 1.98E-17 | 17 | passed |
/item_totals/2/sd | tolerance | 1.0029197142425581 | 1.002919714242558 | 2.41E-18 | 17 | passed |
/item_totals/2/corrected_item_total | tolerance | 0.76400400818217784 | 0.7640040081821775 | 3.32E-16 | 15 | passed |
/item_totals/2/scale_mean_if_deleted | tolerance | 11.315789473684211 | 11.31578947368421 | 3.80E-16 | 16 | passed |
/item_totals/2/scale_variance_if_deleted | tolerance | 9.6725146198830405 | 9.67251461988304 | 9.76E-18 | 17 | passed |
/item_totals/2/alpha_if_deleted | tolerance | 0.73921805723498579 | 0.7392180572349858 | 2.55E-18 | 17 | passed |
/item_totals/3/mean | tolerance | 2.736842105263158 | 2.736842105263158 | 3.51E-17 | 16 | passed |
/item_totals/3/sd | tolerance | 1.0457376590053493 | 1.0457376590053493 | 1.82E-17 | 16 | passed |
/item_totals/3/corrected_item_total | tolerance | 0.62057992217368441 | 0.6205799221736844 | 3.76E-18 | 17 | passed |
/item_totals/3/scale_mean_if_deleted | tolerance | 11.263157894736842 | 11.263157894736842 | 4.79E-16 | 16 | passed |
/item_totals/3/scale_variance_if_deleted | tolerance | 10.2046783625731 | 10.2046783625731 | 9.66E-17 | 17 | passed |
/item_totals/3/alpha_if_deleted | tolerance | 0.78166189111747841 | 0.7816618911174784 | 3.45E-18 | 17 | passed |
/item_totals/4/mean | tolerance | 2.6842105263157894 | 2.6842105263157894 | 1.98E-17 | 17 | passed |
/item_totals/4/sd | tolerance | 0.94590530292691732 | 0.9459053029269173 | 4.06E-18 | 17 | passed |
/item_totals/4/corrected_item_total | tolerance | 0.7142887705807891 | 0.7142887705807888 | 3.32E-16 | 15 | passed |
/item_totals/4/scale_mean_if_deleted | tolerance | 11.315789473684211 | 11.31578947368421 | 3.80E-16 | 16 | passed |
/item_totals/4/scale_variance_if_deleted | tolerance | 10.228070175438596 | 10.228070175438596 | 1.32E-16 | 16 | passed |
/item_totals/4/alpha_if_deleted | tolerance | 0.75700400228702114 | 0.7570040022870211 | 1.75E-18 | 17 | passed |
/tests/[name=Friedman's chi-square]/statistic | tolerance | 3.3118279569892475 | 3.31182795698921 | 3.73E-14 | 13 | passed |
/tests/[name=Friedman's chi-square]/p_value | tail_probability | 0.50706040776655359 | 0.5070604077665597 | 6.11E-15 | 13 | passed |
/tests/[name=Hotelling's T-squared (equal item means)]/statistic | tolerance | 6.0523351442954656 | 6.052335144295474 | 7.99E-15 | 14 | passed |
/tests/[name=Hotelling's T-squared (equal item means)]/p_value | tail_probability | 0.32835771733752805 | 0.32835771733752767 | 3.84E-16 | 14 | passed |
/anova/0/1 | tolerance | 55.599999999999994 | 55.60000000000001 | 1.45E-14 | 15 | passed |
/anova/1/1 | tolerance | 1.515789473684209 | 1.5157894736842115 | 2.46E-15 | 14 | passed |
/anova/2/1 | tolerance | 40.084210526315786 | 40.0842105263158 | 1.44E-14 | 15 | passed |
/anova/2/3 | tolerance | 0.5567251461988304 | 0.5567251461988305 | 1.12E-16 | 15 | passed |
/icc/0/estimate | tolerance | 0.48149789497008627 | 0.48149789497008644 | 1.67E-16 | 15 | passed |
/icc/0/lower | tolerance | 0.30948590057254766 | 0.30948590057254793 | 2.74E-16 | 15 | passed |
/icc/0/upper | tolerance | 0.67248774236017961 | 0.6724877423601797 | 1.09E-16 | 15 | passed |
/icc/0/f_value | tolerance | 5.6431623931623909 | 5.643162393162393 | 1.75E-15 | 15 | passed |
/icc/0/df1 | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/icc/0/df2 | tolerance | 76 | 76.0 | 0.00E+2 | passed | |
/icc/0/p_value | tail_probability | 3.4707763146305469e-08 | 3.470776314630516e-08 | 3.11E-22 | 14 | passed |
/icc/1/estimate | tolerance | 0.82279439606209759 | 0.8227943960620977 | 1.09E-16 | 15 | passed |
/icc/1/lower | tolerance | 0.69145151883147649 | 0.6914515188314769 | 4.40E-16 | 15 | passed |
/icc/1/upper | tolerance | 0.91124211124966226 | 0.9112421112496623 | 3.39E-18 | 17 | passed |
Convention
- docs/manual/chapters/88-reliability-agreement.tex:66-72: one-way ICC(1,1) = (MSR - MSW)/(MSR + (k-1) MSW) and ICC(1,k) = (MSR - MSW)/MSR; F-pivot intervals.
- psych::ICC(alpha = 0.10, lmer = FALSE) ICC1 / ICC1k; the declared first half i2, i5 keeps the items' declared order within each half.
- psych::ICC(lmer = FALSE) computes the classical McGraw and Wong (1996) two-way ANOVA mean squares; psych's default lmer = TRUE substitutes REML variance components, whose mean squares are different quantities and do not match the manual's ANOVA formulas. The hand-computed mean squares reproduce the lmer = FALSE rows exactly.
- Guttman lambda 6 is computed on the raw scores, 1 - sum_j 1/(S^-1)_jj / (1'S1); psych's G6(smc) is the correlation-matrix analogue of lambda 6 and is used only as a cross-check, because it equals the raw-score value only when the item variances are equal.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
247 outputs <- c(scale_core(m, c("i2", "i5"), c("i1", "i3", "i4")),
248 icc_outputs(m, "one_way", "consistency", 0.90))
249 emit("STAT-DESC-SCALE-REL-003", "Scale reliability with a declared split and one-way ICC at 90%",
250 SCALE, "scaleReliabilityMenuItem", SCALE_REQ, "DESC_SCALE_B7",
251 list(items = as.list(ITEMS), reverse_items = list("i4"), scale_low = 1, scale_high = 5,
252 split = "custom", first_half = list("i2", "i5"), icc_model = "one_way",
253 icc_type = "consistency", confidence_level = 0.90),
254 outputs,
255 c(paste0(MANUAL_SCALE, ":66-72: one-way ICC(1,1) = (MSR - MSW)/(MSR + (k-1) MSW) and ICC(1,k) = (MSR - MSW)/MSR; F-pivot intervals."),
256 "psych::ICC(alpha = 0.10, lmer = FALSE) ICC1 / ICC1k; the declared first half i2, i5 keeps the items' declared order within each half.",
257 ICC_PSYCH_NOTE,
258 GUTTMAN_L6_NOTE),
259 SCALE_SOURCE, SCALE_CITATION, kind = "axis_coverage")Whole script generators/r/descriptives_reliability_agreement.R
Scale reliability of four items without reversal or ICC
Case STAT-DESC-SCALE-REL-004 · status: passed
Reference
- Evidence type
- R
- Source
- psych::alpha, psych::ICC, stats::friedman.test and base R covariance algebra
- Citation
- Revelle, W. (2024). psych: procedures for psychological research. R package version 2.6.5; Cronbach (1951); Guttman (1945) Psychometrika 10:255-282; McGraw and Wong (1996) Psychological Methods 1:30-46; Shrout and Fleiss (1979).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, psych 2.6.5, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reliability_agreement.R · sha256 6f498a9f8544f55b
- Dataset
- reference_data/datasets/DESC_SCALE_B7.json
Settings compared
confidence_level= 0.95first_half= []icc_model= "none"icc_type= "consistency"items= ["i1", "i2", "i3", "i5"]reverse_items= []split= "halves"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 19 | 19 | 0.00E+2 | passed | |
/k | exact | 4 | 4 | 0.00E+2 | passed | |
/alpha | tolerance | 0.78166189111747841 | 0.7816618911174784 | 3.45E-18 | 17 | passed |
/standardized_alpha | tolerance | 0.79242120476996392 | 0.7924212047699639 | 3.91E-18 | 17 | passed |
/guttman/0 | tolerance | 0.58624641833810887 | 0.5862464183381089 | 4.40E-18 | 17 | passed |
/guttman/1 | tolerance | 0.79565999497684725 | 0.7956599949768473 | 1.28E-18 | 17 | passed |
/guttman/2 | tolerance | 0.78166189111747841 | 0.7816618911174784 | 3.45E-18 | 17 | passed |
/guttman/3 | tolerance | 0.88710601719197713 | 0.8871060171919771 | 4.66E-18 | 17 | passed |
/guttman/4 | tolerance | 0.79069284946164964 | 0.7906928494616496 | 1.66E-18 | 17 | passed |
/guttman/5 | tolerance | 0.80631707954783172 | 0.8063170795478316 | 1.14E-16 | 15 | passed |
/split_half/correlation | tolerance | 0.80146385627685524 | 0.8014638562768551 | 1.16E-16 | 15 | passed |
/split_half/spearman_brown_equal | tolerance | 0.8897917696037122 | 0.8897917696037121 | 1.10E-16 | 15 | passed |
/split_half/spearman_brown_unequal | tolerance | 0.88979176960371231 | 0.8897917696037121 | 2.20E-16 | 15 | passed |
/split_half/guttman_split_half | tolerance | 0.88710601719197713 | 0.8871060171919769 | 2.27E-16 | 15 | passed |
/summaries/0/mean | tolerance | 2.8157894736842106 | 2.8157894736842106 | 1.98E-17 | 17 | passed |
/summaries/3/mean | tolerance | 0.48832405050988459 | 0.48832405050988464 | 5.40E-17 | 15 | passed |
/split_half/first_alpha | tolerance | 0.17471264367816075 | 0.17471264367816097 | 2.23E-16 | 14 | passed |
/split_half/second_alpha | tolerance | 0.78731343283582089 | 0.7873134328358209 | 2.21E-18 | 17 | passed |
/item_totals/0/mean | tolerance | 2.8947368421052633 | 2.8947368421052633 | 2.52E-17 | 17 | passed |
/item_totals/0/sd | tolerance | 1.1496249070460265 | 1.1496249070460265 | 1.04E-17 | 17 | passed |
/item_totals/0/corrected_item_total | tolerance | 0.39069310369939914 | 0.390693103699399 | 1.15E-16 | 15 | passed |
/item_totals/0/scale_mean_if_deleted | tolerance | 8.3684210526315788 | 8.368421052631579 | 3.96E-17 | 17 | passed |
/item_totals/0/scale_variance_if_deleted | tolerance | 6.5789473684210522 | 6.578947368421052 | 1.09E-17 | 17 | passed |
/item_totals/0/alpha_if_deleted | tolerance | 0.83866666666666667 | 0.8386666666666667 | 1.40E-18 | 17 | passed |
/item_totals/1/mean | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/item_totals/1/sd | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/item_totals/1/corrected_item_total | tolerance | 0.52145386409465677 | 0.5214538640946567 | 1.09E-16 | 15 | passed |
/item_totals/1/scale_mean_if_deleted | tolerance | 8.2631578947368425 | 8.263157894736842 | 2.08E-17 | 17 | passed |
/item_totals/1/scale_variance_if_deleted | tolerance | 6.5380116959064329 | 6.538011695906433 | 4.07E-17 | 17 | passed |
/item_totals/1/alpha_if_deleted | tolerance | 0.76073345259391778 | 0.7607334525939176 | 2.22E-16 | 15 | passed |
/item_totals/2/mean | tolerance | 2.6842105263157894 | 2.6842105263157894 | 1.98E-17 | 17 | passed |
/item_totals/2/sd | tolerance | 1.0029197142425581 | 1.002919714242558 | 2.41E-18 | 17 | passed |
/item_totals/2/corrected_item_total | tolerance | 0.76078510076344241 | 0.7607851007634422 | 2.20E-16 | 15 | passed |
/item_totals/2/scale_mean_if_deleted | tolerance | 8.5789473684210531 | 8.578947368421053 | 9.59E-19 | 18 | passed |
/item_totals/2/scale_variance_if_deleted | tolerance | 5.5906432748538011 | 5.5906432748538 | 9.07E-16 | 15 | passed |
/item_totals/2/alpha_if_deleted | tolerance | 0.63702928870292896 | 0.6370292887029285 | 4.40E-16 | 15 | passed |
/item_totals/3/mean | tolerance | 2.6842105263157894 | 2.6842105263157894 | 1.98E-17 | 17 | passed |
/item_totals/3/sd | tolerance | 0.94590530292691732 | 0.9459053029269173 | 4.06E-18 | 17 | passed |
/item_totals/3/corrected_item_total | tolerance | 0.73535682910090416 | 0.7353568291009042 | 3.53E-18 | 17 | passed |
/item_totals/3/scale_mean_if_deleted | tolerance | 8.5789473684210531 | 8.578947368421053 | 9.59E-19 | 18 | passed |
/item_totals/3/scale_variance_if_deleted | tolerance | 5.9239766081871341 | 5.923976608187134 | 1.86E-17 | 17 | passed |
/item_totals/3/alpha_if_deleted | tolerance | 0.65745310957551828 | 0.6574531095755181 | 2.22E-16 | 15 | passed |
/tests/[name=Friedman's chi-square]/statistic | tolerance | 3.8837209302325579 | 3.8837209302325553 | 2.63E-15 | 15 | passed |
/tests/[name=Friedman's chi-square]/p_value | tail_probability | 0.27429701508931909 | 0.2742970150893198 | 7.17E-16 | 14 | passed |
/tests/[name=Hotelling's T-squared (equal item means)]/statistic | tolerance | 5.8133333333333326 | 5.813333333333337 | 4.42E-15 | 15 | passed |
/tests/[name=Hotelling's T-squared (equal item means)]/p_value | tail_probability | 0.20258905966685584 | 0.20258905966685542 | 4.20E-16 | 14 | passed |
/anova/0/1 | tolerance | 45.921052631578902 | 45.92105263157895 | 5.02E-14 | 14 | passed |
/anova/1/1 | tolerance | 1.4210526315789451 | 1.4210526315789487 | 3.58E-15 | 14 | passed |
/anova/2/1 | tolerance | 30.078947368421058 | 30.078947368421044 | 1.38E-14 | 15 | passed |
/anova/2/3 | tolerance | 0.55701754385964919 | 0.557017543859649 | 2.23E-16 | 15 | passed |
/icc/0 | absent | None | passed |
Convention
- No reverse coding; halves i1, i2 and i3, i5; icc_model none leaves the ICC table empty.
- Guttman lambda 6 is computed on the raw scores, 1 - sum_j 1/(S^-1)_jj / (1'S1); psych's G6(smc) is the correlation-matrix analogue of lambda 6 and is used only as a cross-check, because it equals the raw-score value only when the item variances are equal.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
262 m4 <- adjusted(c("i1", "i2", "i3", "i5"))
263 outputs <- c(scale_core(m4, c("i1", "i2"), c("i3", "i5")),
264 list("/icc/0" = list(comparison = "absent", rationale = "icc_model none leaves the ICC table empty")))
265 emit("STAT-DESC-SCALE-REL-004", "Scale reliability of four items without reversal or ICC",
266 SCALE, "scaleReliabilityMenuItem", SCALE_REQ, "DESC_SCALE_B7",
267 list(items = list("i1", "i2", "i3", "i5"), reverse_items = list(), split = "halves",
268 first_half = list(), icc_model = "none", icc_type = "consistency",
269 confidence_level = 0.95),
270 outputs,
271 c("No reverse coding; halves i1, i2 and i3, i5; icc_model none leaves the ICC table empty.",
272 GUTTMAN_L6_NOTE),
273 SCALE_SOURCE, SCALE_CITATION, kind = "axis_coverage")Whole script generators/r/descriptives_reliability_agreement.R
Score a target with a frozen OLS artifact (mean)
Case STAT-DESC-SCORE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET.json
Settings compared
artifact= {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/predictions | sequence | ['7.2197878156661623', '7.547346447130268', '9.4486969658988 | [7.219787815666163, 7.547346447130272, 9.44869696589881, 10. | passed | ||
/lower | sequence | ['6.4521248456942617', '6.8999033557116123', '8.398392801404 | [6.452124845694263, 6.899903355711616, 8.398392801404185, 9. | passed | ||
/upper | sequence | ['7.987450785638063', '8.1947895385489247', '10.499001130393 | [7.987450785638064, 8.194789538548928, 10.499001130393435, 1 | passed |
Convention
- The artifact carries R's coefficients and covariance; target row 4 (0-based) has a missing x1 and row 2 is excluded, so neither is scored (line 94-97).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
314 score_case("STAT-DESC-SCORE-001", "Score a target with a frozen OLS artifact (mean)", ols, "ols", "identity")
Score a target with a frozen OLS artifact (individual)
Case STAT-DESC-SCORE-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET.json
Settings compared
artifact= {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "individual", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/predictions | sequence | ['7.2197878156661623', '7.547346447130268', '9.4486969658988 | [7.219787815666163, 7.547346447130272, 9.44869696589881, 10. | passed | ||
/lower | sequence | ['5.134655536448621', '5.5034157381788589', '7.2437912934666 | [5.134655536448621, 5.503415738178862, 7.243791293466627, 7. | passed | ||
/upper | sequence | ['9.3049200948837036', '9.5912771560816772', '11.65360263833 | [9.304920094883705, 9.59127715608168, 11.653602638330993, 12 | passed |
Convention
- The artifact carries R's coefficients and covariance; target row 4 (0-based) has a missing x1 and row 2 is excluded, so neither is scored (line 94-97).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
315 score_case("STAT-DESC-SCORE-002", "Score a target with a frozen OLS artifact (individual)", ols, "ols", "identity", "individual")
Score a target with a frozen WLS artifact
Case STAT-DESC-SCORE-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET.json
Settings compared
artifact= {"family": "wls", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.58872600140197, 0.914582454428315, 1.37239543550921, -1.00155841479902], "covariance": [[0.286428617160343, -0.0355477060164456, -0.109239580356717, -0.116921424757362], [-0.0355477060164456, 0.00685924890469312, 0.00135749115260557, 0.00283977197170454], [-0.109239580356717, 0.00135749115260557, 0.188536549355636, 0.102766461841458], [-0.116921424757362, 0.00283977197170454, 0.102766461841458, 0.181954795641454]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 1.46918899763086, "residual_df": 26, "weight_column": "w"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/predictions | sequence | ['7.2306945355702243', '7.5060744815531635', '9.393682040293 | [7.23069453557023, 7.506074481553167, 9.393682040293195, 9.8 | passed | ||
/lower | sequence | ['6.5148130933061825', '6.8133408296695643', '8.385372989442 | [6.514813093306186, 6.813340829669567, 8.385372989442352, 9. | passed | ||
/upper | sequence | ['7.9465759778342662', '8.1988081334367617', '10.40199109114 | [7.946575977834273, 8.198808133436767, 10.401991091144037, 1 | passed |
Convention
- The target needs no weight column to be scored.
- The artifact carries R's coefficients and covariance; target row 4 (0-based) has a missing x1 and row 2 is excluded, so neither is scored (line 94-97).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
316 score_case("STAT-DESC-SCORE-003", "Score a target with a frozen WLS artifact", wls, "wls", "identity",
317 extra = list(weight_column = "w"), notes = "The target needs no weight column to be scored.")
Score a target with a frozen logistic artifact
Case STAT-DESC-SCORE-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET.json
Settings compared
artifact= {"family": "logistic", "response": "yb", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [-5.0402717125001, 0.935845003964461, 2.74940723061125, -1.49498208580186], "covariance": [[4.76880710827408, -0.7283485404078, -2.95603934912518, -0.192923804145146], [-0.7283485404078, 0.128663126095284, 0.40812222863919, -0.0799834845686035], [-2.95603934912518, 0.40812222863919, 2.802302709578, 0.391992620853652], [-0.192923804145146, -0.0799834845686035, 0.391992620853652, 1.71085357184364]], "link": "logit", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "event_value": "yes", "reference_value": "no"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/predictions | sequence | ['0.56530586934621607', '0.73392828917432984', '0.9224419489 | [0.5653058693462151, 0.7339282891743292, 0.9224419489983366, | passed | ||
/lower | sequence | ['0.1383143552738369', '0.34076889503247665', '0.35531187244 | [0.13831435527383562, 0.34076889503247354, 0.355311872440902 | passed | ||
/upper | sequence | ['0.91331580226586473', '0.93638399592839727', '0.9961189705 | [0.9133158022658652, 0.9363839959283979, 0.996118970513382, | passed |
Convention
- The artifact carries R's coefficients and covariance; target row 4 (0-based) has a missing x1 and row 2 is excluded, so neither is scored (line 94-97).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
318 score_case("STAT-DESC-SCORE-004", "Score a target with a frozen logistic artifact", logit, "logistic", "logit",
319 extra = list(event_value = "yes", reference_value = "no"))
Score a target with a frozen Poisson artifact and exposure
Case STAT-DESC-SCORE-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET.json
Settings compared
artifact= {"family": "poisson", "response": "cnt", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [0.173632334271003, 0.175152527192001, 0.324600384426855, -0.197708538849376], "covariance": [[0.0635247463932928, -0.00777180742702323, -0.0264421923237446, -0.023978983751601], [-0.00777180742702323, 0.00137534721715719, 0.00120944879635284, 0.000773544138808703], [-0.0264421923237446, 0.00120944879635284, 0.0370648472773776, 0.0202880801076409], [-0.023978983751601, 0.000773544138808703, 0.0202880801076409, 0.0392736810694172]], "link": "log", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "exposure_column": "expo"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/predictions | sequence | ['11.825295455790158', '8.2537107396756717', '20.60416446653 | [11.825295455790132, 8.253710739675657, 20.604164466535728, | passed | ||
/lower | sequence | ['8.6346675577179006', '6.2328133322615829', '13.43601252975 | [8.634667557717886, 6.232813332261573, 13.43601252975934, 13 | passed | ||
/upper | sequence | ['16.194904051834708', '10.929854199486954', '31.59654640271 | [16.194904051834666, 10.929854199486929, 31.596546402718896, | passed |
Convention
- Predictions are expected counts at the target's entered exposure.
- The artifact carries R's coefficients and covariance; target row 4 (0-based) has a missing x1 and row 2 is excluded, so neither is scored (line 94-97).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
320 score_case("STAT-DESC-SCORE-005", "Score a target with a frozen Poisson artifact and exposure", pois, "poisson", "log",
321 extra = list(exposure_column = "expo"), offset = log(t$expo[scored]),
322 notes = "Predictions are expected counts at the target's entered exposure.")
An unseen categorical level is rejected
Case STAT-DESC-SCORE-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET_UNSEEN.json
Settings compared
artifact= {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Manual line 94-95: an unknown categorical level in a scoreable row is rejected explicitly.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
324 unseen <- read_dataset("DESC_SCORE_TARGET")
325 unseen$grp[3] <- "D"
326 export_dataset(unseen, "DESC_SCORE_TARGET_UNSEEN", "DESC_SCORE_TARGET with an unseen level D in row 3 (1-based)",
327 "Hand-constructed", "Constructed validation data; no third-party license.",
328 c(x1 = "Float64", grp = "String", expo = "Float64"))
329 emit("STAT-DESC-SCORE-006", score_entry, "An unseen categorical level is rejected", "DESC_SCORE_TARGET_UNSEEN",
330 list(artifact = artifact_of(ols, "ols", "identity")), list(),
331 c("Manual line 94-95: an unknown categorical level in a scoreable row is rejected explicitly."),
332 kind = "invalid_input", error = list(error_class = "ValueError", message_contains = "D"))
A target without a fitted predictor is refused
Case STAT-DESC-SCORE-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET_NO_X1.json
Settings compared
artifact= {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Manual line 90-91: the target needs every fitted predictor.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
333 no_x <- read_dataset("DESC_SCORE_TARGET")[c("grp", "expo")]
334 export_dataset(no_x, "DESC_SCORE_TARGET_NO_X1", "DESC_SCORE_TARGET without the x1 column",
335 "Hand-constructed", "Constructed validation data; no third-party license.",
336 c(grp = "String", expo = "Float64"))
337 emit("STAT-DESC-SCORE-007", score_entry, "A target without a fitted predictor is refused", "DESC_SCORE_TARGET_NO_X1",
338 list(artifact = artifact_of(ols, "ols", "identity")), list(),
339 c("Manual line 90-91: the target needs every fitted predictor."), kind = "invalid_input",
340 error = list(error_class = "ValueError", message_contains = "x1"))
OLS fit with mean-response intervals and influence
Case STAT-DESC-SCOREFIT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT.json
Settings compared
family= "ols"interval_kind= "mean"predictors= ["x1", "grp"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficient_names | sequence | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | passed | ||
/artifact/coefficients | sequence | ['1.4496541841259485', '0.94245630030978667', '1.47243773579 | [1.4496541841259485, 0.9424563003097871, 1.4724377357958096, | passed | ||
/artifact/covariance/0 | sequence | ['0.26438303400691682', '-0.033670376837922074', '-0.1145835 | [0.2643830340069169, -0.03367037683792208, -0.11458352745500 | passed | ||
/artifact/covariance/1 | sequence | ['-0.033670376837922074', '0.0064623962300721788', '0.004919 | [-0.03367037683792208, 0.006462396230072183, 0.0049191760103 | passed | ||
/artifact/covariance/2 | sequence | ['-0.11458352745500151', '0.0049191760103309487', '0.1816517 | [-0.11458352745500165, 0.004919176010330953, 0.1816517499910 | passed | ||
/artifact/covariance/3 | sequence | ['-0.11394379029508098', '0.004796390481959574', '0.09260464 | [-0.11394379029508112, 0.004796390481959576, 0.0926046490408 | passed | ||
/artifact/design_rank | exact | 4 | 4 | 0.00E+2 | passed | |
/artifact/residual_df | exact | 26 | 26 | 0.00E+2 | passed | |
/artifact/residual_variance | tolerance | 0.88953636605975273 | 0.8895363660597534 | 6.62E-16 | 15 | passed |
/predictions | sequence | ['5.3894425141327797', '6.8716052798081506', '1.577301945711 | [5.3894425141327815, 6.871605279808154, 1.57730194571147, 4. | passed | ||
/lower | sequence | ['4.7057843798594607', '6.2520151581426155', '0.768674159642 | [4.7057843798594625, 6.252015158142619, 0.7686741596423843, | passed | ||
/upper | sequence | ['6.0731006484060988', '7.4911954014736857', '2.385929731780 | [6.0731006484061005, 7.491195401473689, 2.385929731780556, 5 | passed | ||
/influence/0/leverage | tolerance | 0.12435603354077121 | 0.12435603354077117 | 4.13E-17 | 15 | passed |
/influence/0/studentized_residual | tolerance | -1.8349316966202853 | -1.8349316966202893 | 4.02E-15 | 14 | passed |
/influence/0/cooks_distance | tolerance | 0.11954161420262679 | 0.11954161420262727 | 4.77E-16 | 14 | passed |
/influence/0/dfbetas | sequence | ['-0.26199469388673396', '0.32163114812840865', '-0.40987677 | [-0.26199469388673424, 0.32163114812840915, -0.4098767733542 | passed | ||
/influence/1/leverage | tolerance | 0.10214047200847935 | 0.10214047200847926 | 9.50E-17 | 15 | passed |
/influence/1/studentized_residual | tolerance | 0.01454055156417847 | 0.014540551564176666 | 1.80E-15 | 12 | passed |
/influence/1/cooks_distance | tolerance | 6.0130004334173899e-06 | 6.0130004334158915e-06 | 1.50E-18 | 12 | passed |
/influence/1/dfbetas | sequence | ['0.0021930242248506481', '0.0006961720057348849', '-0.00322 | [0.0021930242248503744, 0.0006961720057347992, -0.0032298914 | passed | ||
/influence/2/leverage | tolerance | 0.173974746101343 | 0.17397474610134311 | 1.14E-16 | 15 | passed |
/influence/2/studentized_residual | tolerance | 1.2048608549823572 | 1.2048608549823567 | 4.67E-16 | 15 | passed |
/influence/2/cooks_distance | tolerance | 0.076437536952139895 | 0.07643753695213987 | 2.77E-17 | 15 | passed |
/influence/2/dfbetas | sequence | ['0.29639820587478877', '-0.36386574798313431', '-0.05224165 | [0.29639820587478877, -0.3638657479831343, -0.05224165822026 | passed | ||
/influence/3/leverage | tolerance | 0.15646969131196589 | 0.15646969131196595 | 5.72E-17 | 15 | passed |
/influence/3/studentized_residual | tolerance | 0.53448766901534706 | 0.5344876690153493 | 2.22E-15 | 14 | passed |
/influence/3/cooks_distance | tolerance | 0.01324783538778254 | 0.013247835387782653 | 1.13E-16 | 14 | passed |
/influence/3/dfbetas | sequence | ['0.11107386992797576', '-0.1363570222816993', '0.1074016662 | [0.1110738699279762, -0.13635702228169988, 0.107401666206341 | passed | ||
/influence/4/leverage | tolerance | 0.10399117431574932 | 0.10399117431574936 | 4.29E-17 | 15 | passed |
/influence/4/studentized_residual | tolerance | -1.1544912631849256 | -1.154491263184925 | 7.01E-16 | 15 | passed |
/influence/4/cooks_distance | tolerance | 0.038672790015303472 | 0.038672790015303445 | 2.74E-17 | 15 | passed |
/influence/4/dfbetas | sequence | ['-0.28840892032022025', '0.077570282418737938', '0.28284799 | [-0.28840892032022025, 0.07757028241873792, 0.28284799037219 | passed | ||
/influence/5/leverage | tolerance | 0.1203339502554128 | 0.12033395025541282 | 2.49E-17 | 15 | passed |
/influence/5/studentized_residual | tolerance | -1.1184316704427275 | -1.1184316704427264 | 1.10E-15 | 15 | passed |
/influence/5/cooks_distance | tolerance | 0.042778865642458697 | 0.04277886564245862 | 7.67E-17 | 14 | passed |
/influence/5/dfbetas | sequence | ['-0.13921499629656628', '0.1709037630926768', '0.0245373356 | [-0.13921499629656603, 0.17090376309267657, 0.02453733562318 | passed | ||
/influence/6/leverage | tolerance | 0.10909682935357344 | 0.10909682935357344 | 6.91E-19 | 17 | passed |
/influence/6/studentized_residual | tolerance | 0.26983389863341251 | 0.2698338986334123 | 2.26E-16 | 15 | passed |
/influence/6/cooks_distance | tolerance | 0.0022290235123239976 | 0.002229023512323993 | 4.79E-18 | 14 | passed |
/influence/6/dfbetas | sequence | ['-0.021809863956073289', '0.026774326917280513', '0.0659646 | [-0.021809863956073268, 0.02677432691728048, 0.0659646908510 | passed | ||
/influence/7/leverage | tolerance | 0.12791455086268788 | 0.12791455086268788 | 1.33E-18 | 16 | passed |
/influence/7/studentized_residual | tolerance | 0.53403734712788509 | 0.5340373471278852 | 1.08E-16 | 15 | passed |
/influence/7/cooks_distance | tolerance | 0.010457892622158746 | 0.01045789262215875 | 3.75E-18 | 15 | passed |
/influence/7/dfbetas | sequence | ['0.18016711217113252', '-0.094207575303941249', '-0.1383021 | [0.18016711217113254, -0.09420757530394126, -0.1383021902592 | passed | ||
/influence/8/leverage | tolerance | 0.17998022806997649 | 0.17998022806997654 | 5.44E-17 | 15 | passed |
/influence/8/studentized_residual | tolerance | 1.1153052936345982 | 1.115305293634598 | 2.39E-16 | 15 | passed |
/influence/8/cooks_distance | tolerance | 0.068253984502832765 | 0.06825398450283272 | 4.14E-17 | 15 | passed |
/influence/8/dfbetas | sequence | ['-0.28512562958559567', '0.35002725530043266', '0.050254810 | [-0.28512562958559556, 0.3500272553004325, 0.050254810573784 | passed | ||
/influence/9/leverage | tolerance | 0.10770733656551036 | 0.10770733656551038 | 1.54E-17 | 15 | passed |
/influence/9/studentized_residual | tolerance | -0.61021641484846989 | -0.6102164148484691 | 7.77E-16 | 14 | passed |
/influence/9/cooks_distance | tolerance | 0.011236880054525524 | 0.011236880054525498 | 2.59E-17 | 14 | passed |
/influence/9/dfbetas | sequence | ['-0.045628113508801985', '0.056014197528419581', '-0.133149 | [-0.04562811350880194, 0.056014197528419546, -0.133149144099 | passed | ||
/influence/10/leverage | tolerance | 0.11910840629762087 | 0.1191084062976209 | 3.01E-17 | 15 | passed |
/influence/10/studentized_residual | tolerance | 0.81188611594227156 | 0.8118861159422719 | 3.31E-16 | 15 | passed |
/influence/10/cooks_distance | tolerance | 0.022281795603743063 | 0.022281795603743076 | 1.34E-17 | 15 | passed |
/influence/10/dfbetas | sequence | ['0.060853251156399862', '0.11876968598699685', '-0.17307985 | [0.06085325115639993, 0.11876968598699686, -0.17307985782612 | passed | ||
/influence/11/leverage | tolerance | 0.10709159236912391 | 0.10709159236912394 | 2.91E-17 | 15 | passed |
/influence/11/studentized_residual | tolerance | 1.2311952711579415 | 1.2311952711579415 | 2.68E-17 | 16 | passed |
/influence/11/cooks_distance | tolerance | 0.045450885638489438 | 0.04545088563848946 | 2.11E-17 | 15 | passed |
/influence/11/dfbetas | sequence | ['0.090314436206185345', '-0.11087222942814014', '-0.0159183 | [0.0903144362061853, -0.11087222942814018, -0.01591836865109 | passed | ||
/influence/12/leverage | tolerance | 0.16727191327062388 | 0.16727191327062388 | 1.29E-18 | 17 | passed |
/influence/12/studentized_residual | tolerance | -1.1715081999470958 | -1.171508199947096 | 1.85E-16 | 15 | passed |
/influence/12/cooks_distance | tolerance | 0.068920827888150182 | 0.06892082788815021 | 2.81E-17 | 15 | passed |
/influence/12/dfbetas | sequence | ['0.27327773338541284', '-0.33548248570514283', '-0.33439647 | [0.27327773338541284, -0.33548248570514283, -0.3343964759665 | passed | ||
/influence/13/leverage | tolerance | 0.17468116676007489 | 0.17468116676007495 | 5.63E-17 | 15 | passed |
/influence/13/studentized_residual | tolerance | -1.7265305745225181 | -1.7265305745225161 | 1.97E-15 | 14 | passed |
/influence/13/cooks_distance | tolerance | 0.15772948461304681 | 0.15772948461304656 | 2.49E-16 | 14 | passed |
/influence/13/dfbetas | sequence | ['-0.80417975460810887', '0.54124618883967346', '0.515988585 | [-0.8041797546081082, 0.5412461888396729, 0.515988585569437, | passed | ||
/influence/14/leverage | tolerance | 0.17222338118427194 | 0.17222338118427202 | 8.30E-17 | 15 | passed |
/influence/14/studentized_residual | tolerance | -2.2758913109707288 | -2.275891310970729 | 3.14E-17 | 16 | passed |
/influence/14/cooks_distance | tolerance | 0.26941514161715008 | 0.2694151416171502 | 1.09E-16 | 15 | passed |
/influence/14/dfbetas | sequence | ['0.60005983798191775', '-0.73664825715633919', '-0.10576353 | [0.6000598379819181, -0.7366482571563392, -0.105763531445932 | passed | ||
/influence/15/leverage | tolerance | 0.18250678729460362 | 0.18250678729460368 | 5.84E-17 | 15 | passed |
/influence/15/studentized_residual | tolerance | 0.5529115681742105 | 0.5529115681742115 | 9.98E-16 | 14 | passed |
/influence/15/cooks_distance | tolerance | 0.017062639936989841 | 0.017062639936989903 | 6.23E-17 | 14 | passed |
/influence/15/dfbetas | sequence | ['0.14113818734189515', '-0.17326471985406383', '0.108607124 | [0.14113818734189537, -0.17326471985406422, 0.10860712404405 | passed | ||
/influence/16/leverage | tolerance | 0.10870761968172199 | 0.108707619681722 | 1.36E-17 | 15 | passed |
/influence/16/studentized_residual | tolerance | 1.0866393692040701 | 1.0866393692040701 | 1.58E-17 | 16 | passed |
/influence/16/cooks_distance | tolerance | 0.03600399331476898 | 0.03600399331476899 | 6.68E-18 | 15 | passed |
/influence/16/dfbetas | sequence | ['0.12408461614468061', '0.10779560383624696', '-0.240154275 | [0.12408461614468067, 0.10779560383624696, -0.24015427547930 | passed | ||
/influence/17/leverage | tolerance | 0.10616238936343206 | 0.10616238936343211 | 5.36E-17 | 15 | passed |
/influence/17/studentized_residual | tolerance | -0.24557763787301159 | -0.24557763787301132 | 2.73E-16 | 14 | passed |
/influence/17/cooks_distance | tolerance | 0.001790728327579931 | 0.0017907283275799277 | 3.30E-18 | 14 | passed |
/influence/17/dfbetas | sequence | ['-0.016306324009364093', '0.020018045537796167', '0.0028740 | [-0.016306324009364055, 0.020018045537796143, 0.002874070722 | passed | ||
/influence/18/leverage | tolerance | 0.15867836740080221 | 0.15867836740080227 | 5.71E-17 | 15 | passed |
/influence/18/studentized_residual | tolerance | 1.5601565898583083 | 1.5601565898583083 | 4.14E-18 | 17 | passed |
/influence/18/cooks_distance | tolerance | 0.11477097099125121 | 0.11477097099125126 | 5.16E-17 | 15 | passed |
/influence/18/dfbetas | sequence | ['0.34569130136507559', '-0.42437916778620233', '0.326753500 | [0.34569130136507564, -0.4243791677862025, 0.326753500080154 | passed | ||
/influence/19/leverage | tolerance | 0.12491254145419559 | 0.12491254145419561 | 2.36E-17 | 15 | passed |
/influence/19/studentized_residual | tolerance | -0.53132717108369842 | -0.5313271710836981 | 3.29E-16 | 15 | passed |
/influence/19/cooks_distance | tolerance | 0.01007438733715587 | 0.010074387337155861 | 8.86E-18 | 15 | passed |
/influence/19/dfbetas | sequence | ['-0.030719882408610271', '-0.088389225098364374', '0.111232 | [-0.030719882408610316, -0.08838922509836432, 0.111232734887 | passed | ||
/influence/20/leverage | tolerance | 0.11716238380142162 | 0.11716238380142163 | 1.23E-17 | 15 | passed |
/influence/20/studentized_residual | tolerance | 0.092830581834695669 | 0.09283058183469534 | 3.33E-16 | 14 | passed |
/influence/20/cooks_distance | tolerance | 0.00028591011719268021 | 0.0002859101171926781 | 2.12E-18 | 14 | passed |
/influence/20/dfbetas | sequence | ['-0.010340205539492416', '0.012693891354106833', '0.0018225 | [-0.010340205539492385, 0.012693891354106788, 0.001822512663 | passed | ||
/influence/21/leverage | tolerance | 0.1777304108302584 | 0.17773041083025837 | 3.26E-17 | 15 | passed |
/influence/21/studentized_residual | tolerance | 0.2668782276744166 | 0.2668782276744159 | 7.20E-16 | 14 | passed |
/influence/21/cooks_distance | tolerance | 0.0038486978258745227 | 0.003848697825874501 | 2.17E-17 | 14 | passed |
/influence/21/dfbetas | sequence | ['-0.065631888837938773', '0.080571325501379576', '0.0755189 | [-0.06563188883793858, 0.08057132550137931, 0.07551890974105 | passed | ||
/influence/22/leverage | tolerance | 0.10839238097095694 | 0.10839238097095696 | 2.41E-17 | 15 | passed |
/influence/22/studentized_residual | tolerance | 0.39323963491959174 | 0.3932396349195919 | 1.67E-16 | 15 | passed |
/influence/22/cooks_distance | tolerance | 0.0046998020066448352 | 0.0046998020066448395 | 4.31E-18 | 15 | passed |
/influence/22/dfbetas | sequence | ['0.044565013765092712', '0.037522492855971465', '-0.0852509 | [0.04456501376509277, 0.03752249285597148, -0.08525092020644 | passed | ||
/influence/23/leverage | tolerance | 0.1101843491454238 | 0.11018434914542385 | 5.44E-17 | 15 | passed |
/influence/23/studentized_residual | tolerance | 0.17967410707126608 | 0.1796741070712665 | 4.12E-16 | 14 | passed |
/influence/23/cooks_distance | tolerance | 0.00099938049613674629 | 0.000999380496136751 | 4.77E-18 | 14 | passed |
/influence/23/dfbetas | sequence | ['-0.015363480991025974', '0.018860588193930869', '0.0027078 | [-0.015363480991026014, 0.01886058819393091, 0.0027078899504 | passed | ||
/influence/24/leverage | tolerance | 0.12697697839708755 | 0.12697697839708755 | 2.37E-18 | 16 | passed |
/influence/24/studentized_residual | tolerance | -0.65293521414606248 | -0.6529352141460619 | 5.54E-16 | 15 | passed |
/influence/24/cooks_distance | tolerance | 0.015501705571131556 | 0.015501705571131527 | 2.92E-17 | 14 | passed |
/influence/24/dfbetas | sequence | ['0.092440379272324444', '-0.11348208957100837', '-0.1691878 | [0.09244037927232437, -0.11348208957100826, -0.1691878828404 | passed | ||
/influence/25/leverage | tolerance | 0.13456374981374963 | 0.1345637498137497 | 5.90E-17 | 15 | passed |
/influence/25/studentized_residual | tolerance | -0.66178705043461827 | -0.6617870504346178 | 4.40E-16 | 15 | passed |
/influence/25/cooks_distance | tolerance | 0.017024310703464909 | 0.017024310703464895 | 1.42E-17 | 15 | passed |
/influence/25/dfbetas | sequence | ['-0.23558532632282225', '0.13079267350834636', '0.174459225 | [-0.23558532632282217, 0.13079267350834634, 0.17445922522080 | passed | ||
/influence/26/leverage | tolerance | 0.10299433185803281 | 0.10299433185803285 | 3.76E-17 | 15 | passed |
/influence/26/studentized_residual | tolerance | -0.77975119470783782 | -0.7797511947078372 | 6.61E-16 | 15 | passed |
/influence/26/cooks_distance | tolerance | 0.017453006226141154 | 0.017453006226141127 | 2.73E-17 | 14 | passed |
/influence/26/dfbetas | sequence | ['-0.036413671249881423', '0.044702320943694508', '0.0064180 | [-0.036413671249881346, 0.04470232094369448, 0.0064180906978 | passed | ||
/influence/27/leverage | tolerance | 0.14544198126553315 | 0.14544198126553315 | 1.02E-18 | 17 | passed |
/influence/27/studentized_residual | tolerance | 1.1402327654367224 | 1.1402327654367204 | 2.04E-15 | 14 | passed |
/influence/27/cooks_distance | tolerance | 0.055319120938056382 | 0.0553191209380562 | 1.80E-16 | 14 | passed |
/influence/27/dfbetas | sequence | ['-0.21548073135107013', '0.26452946048577636', '0.312583942 | [-0.21548073135106977, 0.2645294604857759, 0.312583942023539 | passed | ||
/influence/28/leverage | tolerance | 0.12630365867477444 | 0.1263036586747745 | 5.94E-17 | 15 | passed |
/influence/28/studentized_residual | tolerance | 1.1793067379330984 | 1.1793067379330975 | 9.18E-16 | 15 | passed |
/influence/28/cooks_distance | tolerance | 0.050263066671338563 | 0.05026306667133852 | 4.14E-17 | 15 | passed |
/influence/28/dfbetas | sequence | ['0.065255586140101934', '0.20624125543150101', '-0.25179263 | [0.06525558614010198, 0.20624125543150093, -0.25179263862810 | passed | ||
/influence/29/leverage | tolerance | 0.12294059778082059 | 0.12294059778082063 | 3.91E-17 | 15 | passed |
/influence/29/studentized_residual | tolerance | 0.6035089077852982 | 0.603508907785299 | 7.76E-16 | 14 | passed |
/influence/29/cooks_distance | tolerance | 0.012763614827739246 | 0.012763614827739285 | 3.86E-17 | 14 | passed |
/influence/29/dfbetas | sequence | ['0.078515012125579736', '-0.096386965402373778', '-0.013838 | [0.07851501212557978, -0.09638696540237389, -0.0138386614605 | passed | ||
/influence_eligible | exact | True | True | passed |
Convention
- lm(y ~ x1 + grp) with levels A < B < C; predict(interval = 'confidence').
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
138 ols <- lm(y ~ x1 + grp, data = d)
139 emit("STAT-DESC-SCOREFIT-001", fit_entry, "OLS fit with mean-response intervals and influence", "DESC_SCORE_FIT",
140 config("ols", "y"), c(fit_outputs(ols, closed_tol, "mean"), influence_outputs(ols)),
141 c("lm(y ~ x1 + grp) with levels A < B < C; predict(interval = 'confidence')."))
OLS individual prediction intervals
Case STAT-DESC-SCOREFIT-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT.json
Settings compared
family= "ols"interval_kind= "individual"predictors= ["x1", "grp"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficient_names | sequence | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | passed | ||
/artifact/coefficients | sequence | ['1.4496541841259485', '0.94245630030978667', '1.47243773579 | [1.4496541841259485, 0.9424563003097871, 1.4724377357958096, | passed | ||
/artifact/covariance/0 | sequence | ['0.26438303400691682', '-0.033670376837922074', '-0.1145835 | [0.2643830340069169, -0.03367037683792208, -0.11458352745500 | passed | ||
/artifact/covariance/1 | sequence | ['-0.033670376837922074', '0.0064623962300721788', '0.004919 | [-0.03367037683792208, 0.006462396230072183, 0.0049191760103 | passed | ||
/artifact/covariance/2 | sequence | ['-0.11458352745500151', '0.0049191760103309487', '0.1816517 | [-0.11458352745500165, 0.004919176010330953, 0.1816517499910 | passed | ||
/artifact/covariance/3 | sequence | ['-0.11394379029508098', '0.004796390481959574', '0.09260464 | [-0.11394379029508112, 0.004796390481959576, 0.0926046490408 | passed | ||
/artifact/design_rank | exact | 4 | 4 | 0.00E+2 | passed | |
/artifact/residual_df | exact | 26 | 26 | 0.00E+2 | passed | |
/artifact/residual_variance | tolerance | 0.88953636605975273 | 0.8895363660597534 | 6.62E-16 | 15 | passed |
/predictions | sequence | ['5.3894425141327797', '6.8716052798081506', '1.577301945711 | [5.3894425141327815, 6.871605279808154, 1.57730194571147, 4. | passed | ||
/lower | sequence | ['3.3337531818340156', '4.8363259119486974', '-0.52325728524 | [3.333753181834016, 4.8363259119487, -0.5232572852486708, 2. | passed | ||
/upper | sequence | ['7.4451318464315435', '8.9068846476676029', '3.677861176671 | [7.445131846431547, 8.906884647667608, 3.6778611766716107, 6 | passed |
Convention
- predict(interval = 'prediction') adds s^2 to the mean variance (manual line 62).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
142 emit("STAT-DESC-SCOREFIT-002", fit_entry, "OLS individual prediction intervals", "DESC_SCORE_FIT",
143 config("ols", "y", "individual"), fit_outputs(ols, closed_tol, "individual"),
144 c("predict(interval = 'prediction') adds s^2 to the mean variance (manual line 62)."))
WLS fit with mean-response intervals
Case STAT-DESC-SCOREFIT-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT.json
Settings compared
family= "wls"interval_kind= "mean"predictors= ["x1", "grp"]response= "y"weight_column= "w"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficient_names | sequence | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | passed | ||
/artifact/coefficients | sequence | ['1.5887260014019653', '0.91458245442831509', '1.37239543550 | [1.5887260014019673, 0.9145824544283148, 1.3723954355092067, | passed | ||
/artifact/covariance/0 | sequence | ['0.28642861716034251', '-0.0355477060164456', '-0.109239580 | [0.2864286171603421, -0.03554770601644556, -0.10923958035671 | passed | ||
/artifact/covariance/1 | sequence | ['-0.0355477060164456', '0.0068592489046931217', '0.00135749 | [-0.03554770601644556, 0.006859248904693112, 0.0013574911526 | passed | ||
/artifact/covariance/2 | sequence | ['-0.10923958035671742', '0.0013574911526055733', '0.1885365 | [-0.10923958035671738, 0.001357491152605578, 0.1885365493556 | passed | ||
/artifact/covariance/3 | sequence | ['-0.11692142475736224', '0.0028397719717045355', '0.1027664 | [-0.11692142475736217, 0.0028397719717045363, 0.102766461841 | passed | ||
/artifact/design_rank | exact | 4 | 4 | 0.00E+2 | passed | |
/artifact/residual_df | exact | 26 | 26 | 0.00E+2 | passed | |
/artifact/residual_variance | tolerance | 1.4691889976308574 | 1.4691889976308568 | 6.48E-16 | 15 | passed |
/predictions | sequence | ['5.3554983026044987', '6.8503188617280619', '1.755089380907 | [5.355498302604502, 6.850318861728063, 1.7550893809079033, 4 | passed | ||
/lower | sequence | ['4.6302755556634665', '6.1860382293504825', '0.927269524330 | [4.63027555566347, 6.186038229350483, 0.9272695243302116, 3. | passed | ||
/upper | sequence | ['6.0807210495455308', '7.5145994941056413', '2.582909237485 | [6.080721049545534, 7.514599494105642, 2.582909237485595, 5. | passed | ||
/influence_eligible | exact | False | False | passed |
Convention
- lm(y ~ x1 + grp, weights = w): weights are relative precisions (line 64-65).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
145 wls <- lm(y ~ x1 + grp, data = d, weights = w)
146 emit("STAT-DESC-SCOREFIT-003", fit_entry, "WLS fit with mean-response intervals", "DESC_SCORE_FIT",
147 config("wls", "y", extra = list(weight_column = "w")),
148 c(fit_outputs(wls, closed_tol, "mean", family_name = "wls"),
149 list("/influence_eligible" = exact(FALSE, "WLS fits do not report OLS influence (line 80-81)."))),
150 c("lm(y ~ x1 + grp, weights = w): weights are relative precisions (line 64-65)."))
Binary logistic fit with Wald probability limits
Case STAT-DESC-SCOREFIT-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT.json
Settings compared
event_value= "yes"family= "logistic"interval_kind= "mean"predictors= ["x1", "grp"]response= "yb"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficient_names | sequence | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | passed | ||
/artifact/coefficients | sequence | ['-5.0402717125000986', '0.93584500396446113', '2.7494072306 | [-5.040271712499659, 0.9358450039643886, 2.749407230610945, | passed | ||
/artifact/covariance/0 | sequence | ['4.7688071082740757', '-0.72834854040780017', '-2.956039349 | [4.768807108274074, -0.7283485404078, -2.956039349125172, -0 | passed | ||
/artifact/covariance/1 | sequence | ['-0.72834854040780017', '0.12866312609528396', '0.408122228 | [-0.7283485404078, 0.1286631260952839, 0.40812222863918957, | passed | ||
/artifact/covariance/2 | sequence | ['-2.9560393491251755', '0.40812222863919012', '2.8023027095 | [-2.956039349125172, 0.40812222863918957, 2.802302709578001, | passed | ||
/artifact/covariance/3 | sequence | ['-0.19292380414514609', '-0.079983484568603477', '0.3919926 | [-0.19292380414514648, -0.07998348456860331, 0.3919926208536 | passed | ||
/artifact/design_rank | exact | 4 | 4 | 0.00E+2 | passed | |
/predictions | sequence | ['0.53971062251102653', '0.58507556616313416', '0.0047721264 | [0.5397106225110119, 0.5850755661631395, 0.00477212644588699 | passed | ||
/lower | sequence | ['0.15938340707420148', '0.22572206756121405', '8.4761279114 | [0.1593834070741935, 0.22572206756121796, 8.476127911444656e | passed | ||
/upper | sequence | ['0.87880673205963689', '0.87212902533358416', '0.2133629108 | [0.8788067320596307, 0.8721290253335866, 0.2133629108055825, | passed | ||
/influence_eligible | exact | False | False | passed |
Convention
- glm(binomial) with epsilon = 1e-14, maxit = 100; event 'yes'.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
151 logit <- glm(I(yb == "yes") ~ x1 + grp, data = d, family = binomial(),
152 control = glm.control(epsilon = 1e-14, maxit = 100))
153 emit("STAT-DESC-SCOREFIT-004", fit_entry, "Binary logistic fit with Wald probability limits", "DESC_SCORE_FIT",
154 config("logistic", "yb", extra = list(event_value = "yes")),
155 c(fit_outputs(logit, glm_tol, "mean", family_name = "logistic"),
156 list("/influence_eligible" = exact(FALSE, "Logistic fits do not report OLS influence."))),
157 c("glm(binomial) with epsilon = 1e-14, maxit = 100; event 'yes'."))
Poisson fit with an exposure offset
Case STAT-DESC-SCOREFIT-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT.json
Settings compared
exposure_column= "expo"family= "poisson"interval_kind= "mean"predictors= ["x1", "grp"]response= "cnt"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficient_names | sequence | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | passed | ||
/artifact/coefficients | sequence | ['0.17363233427100305', '0.17515252719200125', '0.3246003844 | [0.1736323342995671, 0.1751525271881041, 0.32460038442272976 | passed | ||
/artifact/covariance/0 | sequence | ['0.063524746393292753', '-0.0077718074270232262', '-0.02644 | [0.0635247464277806, -0.00777180743198422, -0.02644219232530 | passed | ||
/artifact/covariance/1 | sequence | ['-0.0077718074270232262', '0.0013753472171571914', '0.00120 | [-0.00777180743198422, 0.0013753472179059397, 0.001209448796 | passed | ||
/artifact/covariance/2 | sequence | ['-0.026442192323744628', '0.0012094487963528382', '0.037064 | [-0.02644219232530354, 0.0012094487961028923, 0.037064847289 | passed | ||
/artifact/covariance/3 | sequence | ['-0.023978983751600978', '0.00077354413880870339', '0.02028 | [-0.023978983756166233, 0.0007735441391317236, 0.02028808010 | passed | ||
/artifact/design_rank | exact | 4 | 4 | 0.00E+2 | passed | |
/predictions | sequence | ['6.1203715437494219', '4.0992661975501754', '1.506598556255 | [6.120371543836556, 4.09926619757536, 1.5065985563060778, 5. | passed | ||
/lower | sequence | ['4.5533423563872724', '3.1150886315618789', '1.021991677870 | [4.553342355827524, 3.115088631533335, 1.021991677806478, 3. | passed | ||
/upper | sequence | ['8.2266925923089342', '5.3943837064925173', '2.220995785837 | [8.226692593554494, 5.39438370660823, 2.2209957861255396, 7. | passed |
Convention
- glm(poisson) with offset log(expo), epsilon = 1e-14, maxit = 100; predictions are expected counts at the entered exposure.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
158 pois <- glm(cnt ~ x1 + grp + offset(log(expo)), data = d, family = poisson(),
159 control = glm.control(epsilon = 1e-14, maxit = 100))
160 emit("STAT-DESC-SCOREFIT-005", fit_entry, "Poisson fit with an exposure offset", "DESC_SCORE_FIT",
161 config("poisson", "cnt", extra = list(exposure_column = "expo")),
162 fit_outputs(pois, glm_tol, "mean", family_name = "poisson"),
163 c("glm(poisson) with offset log(expo), epsilon = 1e-14, maxit = 100; predictions are expected counts at the entered exposure."))
Poisson fit without exposure
Case STAT-DESC-SCOREFIT-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT.json
Settings compared
family= "poisson"interval_kind= "mean"predictors= ["x1", "grp"]response= "cnt"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficient_names | sequence | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | passed | ||
/artifact/coefficients | sequence | ['1.1035973738352829', '0.098058806231247159', '0.2385285152 | [1.1035973738136189, 0.09805880623531776, 0.2385285152998247 | passed | ||
/artifact/covariance/0 | sequence | ['0.060587330549453491', '-0.0074440842341056976', '-0.02296 | [0.06058733054819236, -0.007444084233863689, -0.022969698311 | passed | ||
/artifact/covariance/1 | sequence | ['-0.0074440842341056976', '0.0013522470285454438', '0.00061 | [-0.007444084233863689, 0.0013522470284986542, 0.00061069414 | passed | ||
/artifact/covariance/2 | sequence | ['-0.022969698311983144', '0.00061069414684996205', '0.03627 | [-0.022969698311764312, 0.0006106941468115813, 0.03627708399 | passed | ||
/artifact/covariance/3 | sequence | ['-0.024106532400062237', '0.00081720450718561456', '0.01997 | [-0.024106532399851128, 0.000817204507148207, 0.019976904409 | passed | ||
/artifact/design_rank | exact | 4 | 4 | 0.00E+2 | passed | |
/predictions | sequence | ['4.9473092541844244', '5.3001211886710449', '3.723543078153 | [4.947309254511192, 5.300121188680342, 3.723543078102783, 4. | passed | ||
/lower | sequence | ['3.6422530542224143', '4.0256978394467264', '2.554192482287 | [3.6422530544940677, 4.025697839454496, 2.5541924822585185, | passed | ||
/upper | sequence | ['6.7199803232134858', '6.9779913284451842', '5.428241274302 | [6.719980323599987, 6.977991328456198, 5.428241274215703, 6. | passed |
Convention
- No exposure is a zero offset (model_scoring.ModelScoringConfig).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
164 pois0 <- glm(cnt ~ x1 + grp, data = d, family = poisson(), control = glm.control(epsilon = 1e-14, maxit = 100))
165 emit("STAT-DESC-SCOREFIT-006", fit_entry, "Poisson fit without exposure", "DESC_SCORE_FIT",
166 config("poisson", "cnt"), fit_outputs(pois0, glm_tol, "mean", family_name = "poisson"),
167 c("No exposure is a zero offset (model_scoring.ModelScoringConfig)."))
OLS at a 90% confidence level
Case STAT-DESC-SCOREFIT-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT.json
Settings compared
confidence_level= 0.9family= "ols"interval_kind= "mean"predictors= ["x1", "grp"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficient_names | sequence | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | passed | ||
/artifact/coefficients | sequence | ['1.4496541841259485', '0.94245630030978667', '1.47243773579 | [1.4496541841259485, 0.9424563003097871, 1.4724377357958096, | passed | ||
/artifact/covariance/0 | sequence | ['0.26438303400691682', '-0.033670376837922074', '-0.1145835 | [0.2643830340069169, -0.03367037683792208, -0.11458352745500 | passed | ||
/artifact/covariance/1 | sequence | ['-0.033670376837922074', '0.0064623962300721788', '0.004919 | [-0.03367037683792208, 0.006462396230072183, 0.0049191760103 | passed | ||
/artifact/covariance/2 | sequence | ['-0.11458352745500151', '0.0049191760103309487', '0.1816517 | [-0.11458352745500165, 0.004919176010330953, 0.1816517499910 | passed | ||
/artifact/covariance/3 | sequence | ['-0.11394379029508098', '0.004796390481959574', '0.09260464 | [-0.11394379029508112, 0.004796390481959576, 0.0926046490408 | passed | ||
/artifact/design_rank | exact | 4 | 4 | 0.00E+2 | passed | |
/artifact/residual_df | exact | 26 | 26 | 0.00E+2 | passed | |
/artifact/residual_variance | tolerance | 0.88953636605975273 | 0.8895363660597534 | 6.62E-16 | 15 | passed |
/predictions | sequence | ['5.3894425141327797', '6.8716052798081506', '1.577301945711 | [5.3894425141327815, 6.871605279808154, 1.57730194571147, 4. | passed | ||
/lower | sequence | ['4.8221630858334539', '6.357487605523569', '0.9063263729922 | [4.822163085833456, 6.3574876055235725, 0.9063263729922104, | passed | ||
/upper | sequence | ['5.9567219424321056', '7.3857229540927323', '2.248277518430 | [5.956721942432107, 7.385722954092736, 2.2482775184307298, 5 | passed |
Convention
- A non-default confidence level of 0.90.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
168 emit("STAT-DESC-SCOREFIT-007", fit_entry, "OLS at a 90% confidence level", "DESC_SCORE_FIT",
169 config("ols", "y", level = 0.9), fit_outputs(ols, closed_tol, "mean", level = 0.9),
170 c("A non-default confidence level of 0.90."))
Missing values and excluded rows are left out of the fit
Case STAT-DESC-SCOREFIT-008 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT_MISSING.json
Settings compared
family= "ols"interval_kind= "mean"predictors= ["x1", "grp"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficient_names | sequence | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | ['Intercept', 'x1', 'grp = B (vs A)', 'grp = C (vs A)'] | passed | ||
/artifact/coefficients | sequence | ['1.7057540434087008', '0.87100058102761524', '1.68060597399 | [1.7057540434087053, 0.8710005810276148, 1.6806059739958343, | passed | ||
/artifact/covariance/0 | sequence | ['0.30495205974652789', '-0.04168424601215151', '-0.11147165 | [0.30495205974652817, -0.041684246012151566, -0.111471654434 | passed | ||
/artifact/covariance/1 | sequence | ['-0.04168424601215151', '0.0081917639607258872', '0.0036615 | [-0.041684246012151566, 0.008191763960725901, 0.003661588462 | passed | ||
/artifact/covariance/2 | sequence | ['-0.11147165443498296', '0.003661588462445103', '0.21384114 | [-0.11147165443498296, 0.0036615884624450973, 0.213841147630 | passed | ||
/artifact/covariance/3 | sequence | ['-0.13407444059404808', '0.0081034749491491788', '0.0964615 | [-0.13407444059404822, 0.008103474949149186, 0.0964615827979 | passed | ||
/artifact/design_rank | exact | 4 | 4 | 0.00E+2 | passed | |
/artifact/residual_df | exact | 21 | 21 | 0.00E+2 | passed | |
/artifact/residual_variance | tolerance | 0.83555512310024771 | 0.8355551231002487 | 9.99E-16 | 14 | passed |
/predictions | sequence | ['6.7166203860605709', '1.6731349157019493', '5.598255640021 | [6.716620386060573, 1.6731349157019524, 5.598255640021116, 2 | passed | ||
/lower | sequence | ['6.0707470614718915', '0.84626546588029639', '4.95396502712 | [6.070747061471892, 0.8462654658802989, 4.953965027125841, 2 | passed | ||
/upper | sequence | ['7.3624937106492503', '2.5000043655236022', '6.242546252916 | [7.362493710649253, 2.5000043655236057, 6.242546252916391, 3 | passed |
Convention
- Rows 0 and 21 (0-based) are excluded; rows with missing y or x1 are omitted and counted (line 50-53).
- 25 rows remain for the fit.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
173 m <- read_dataset("DESC_SCORE_FIT")
174 m$y[c(4, 17)] <- NA
175 m$x1[9] <- NA
176 export_dataset(m, "DESC_SCORE_FIT_MISSING", "DESC_SCORE_FIT with y missing in rows 4 and 17 and x1 in row 9 (1-based)",
177 "R stats::lm documentation", "Constructed validation data; no third-party license.",
178 c(x1 = "Float64", grp = "String", w = "Float64", expo = "Float64", y = "Float64",
179 yb = "String", cnt = "Int64"))
180 mm <- read_dataset("DESC_SCORE_FIT_MISSING")
181 excluded <- c(0L, 21L)
182 kept <- mm[-(excluded + 1L), ]
183 kept <- kept[stats::complete.cases(kept[c("y", "x1", "grp")]), ]
184 kept$grp <- factor(kept$grp, levels = sort(unique(kept$grp)))
185 olsm <- lm(y ~ x1 + grp, data = kept)
186 emit("STAT-DESC-SCOREFIT-008", fit_entry, "Missing values and excluded rows are left out of the fit",
187 "DESC_SCORE_FIT_MISSING", config("ols", "y"), fit_outputs(olsm, closed_tol, "mean", data = kept),
188 c("Rows 0 and 21 (0-based) are excluded; rows with missing y or x1 are omitted and counted (line 50-53).",
189 sprintf("%d rows remain for the fit.", nrow(kept))),
190 kind = "missing_excluded", excluded = excluded)
Predictor at a 1e6 offset
Case STAT-DESC-SCOREFIT-009 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT_OFFSET.json
Settings compared
family= "ols"interval_kind= "mean"predictors= ["x1", "grp"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficients | sequence | ['-942454.85065262951', '0.9424563003068136', '1.47243773580 | [-942454.8506508748, 0.9424563003050592, 1.4724377359817167, | passed | ||
/predictions | sequence | ['5.3894425140886852', '6.8716052797390148', '1.577301945681 | [5.389442514628172, 6.871605280088261, 1.57730194600299, 4.4 | passed | ||
/lower | sequence | ['4.705784379815702', '6.2520151580608756', '0.7686741595957 | [4.705784380381216, 6.252015158416386, 0.7686741599606299, 3 | passed | ||
/upper | sequence | ['6.0731006483616685', '7.491195401417154', '2.3859297317674 | [6.073100648875128, 7.491195401760136, 2.38592973204535, 5.2 | passed | ||
/artifact/residual_variance | tolerance | 0.88953636609542108 | 0.8895363660667758 | 2.86E-11 | 10 | passed |
Convention
- x1 + 1e6 leaves the slope and fitted values unchanged and moves the intercept; lm uses a QR decomposition.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
193 h <- read_dataset("DESC_SCORE_FIT")
194 h$x1 <- h$x1 + 1e6
195 export_dataset(h, "DESC_SCORE_FIT_OFFSET", "DESC_SCORE_FIT with x1 shifted by 1e6",
196 "R stats::lm documentation", "Constructed validation data; no third-party license.",
197 c(x1 = "Float64", grp = "String", w = "Float64", expo = "Float64", y = "Float64",
198 yb = "String", cnt = "Int64"))
199 ho <- read_dataset("DESC_SCORE_FIT_OFFSET")
200 ho$grp <- factor(ho$grp, levels = sort(unique(ho$grp)))
201 olsh <- lm(y ~ x1 + grp, data = ho)
202 out <- fit_outputs(olsh, closed_tol, "mean", data = ho)
203 emit("STAT-DESC-SCOREFIT-009", fit_entry, "Predictor at a 1e6 offset", "DESC_SCORE_FIT_OFFSET",
204 config("ols", "y"), out[c("/artifact/coefficients", "/predictions", "/lower", "/upper", "/artifact/residual_variance")],
205 c("x1 + 1e6 leaves the slope and fitted values unchanged and moves the intercept; lm uses a QR decomposition."),
206 kind = "hard_numeric")
Three rows leave one residual df and no deletion diagnostics
Case STAT-DESC-SCOREFIT-010 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_MIN.json
Settings compared
family= "ols"predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/coefficients | sequence | ['-0.050000000000001779', '2.0500000000000003'] | [-0.05000000000000076, 2.05] | passed | ||
/artifact/residual_df | exact | 1 | 1 | 0.00E+2 | passed | |
/predictions | sequence | ['1.9999999999999984', '4.0499999999999989', '8.149999999999 | [1.9999999999999991, 4.049999999999999, 8.149999999999999] | passed | ||
/lower | sequence | ['-0.0090273691365292397', '2.6294031236941908', '5.85935636 | [-0.009027369136545005, 2.6294031236941793, 5.85935636535893 | passed | ||
/upper | sequence | ['4.0090273691365264', '5.470596876305807', '10.440643634641 | [4.009027369136543, 5.470596876305819, 10.44064363464106] | passed | ||
/influence/0/leverage | tolerance | 0.71428571428571441 | 0.7142857142857143 | 1.08E-16 | 15 | passed |
/influence/0/studentized_residual | tolerance | 1.0000000000000007 | 1.0000000000000004 | 2.56E-16 | 15 | passed |
/influence/0/cooks_distance | tolerance | 1.2500000000000027 | 1.2500000000000009 | 1.81E-15 | 14 | passed |
/influence/0/deleted_studentized_residual | absent | None | passed | |||
/influence/0/dffits | absent | None | passed |
Convention
- With n = p + 1 the full-fit diagnostics are defined (standardized magnitudes are all 1); deleted-variance diagnostics are not (statistician's ruling on issue #8).
- Until 2026-09-25 this case expected every diagnostic but leverage to be absent.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
209 export_dataset(data.frame(x = c(1, 2, 4), y = c(2.1, 3.9, 8.2)), "DESC_SCORE_MIN",
210 "Constructed: three points for a straight line", "Hand-constructed",
211 "Constructed validation data; no third-party license.", c(x = "Float64", y = "Float64"))
212 s <- read_dataset("DESC_SCORE_MIN")
213 olss <- lm(y ~ x, data = s)
214 ps <- predict(olss, interval = "confidence")
215 emit("STAT-DESC-SCOREFIT-010", fit_entry, "Three rows leave one residual df and no deletion diagnostics", "DESC_SCORE_MIN",
216 list(family = "ols", response = "y", predictors = list("x")),
217 list("/artifact/coefficients" = seq_tol(coef(olss), "Least-squares line."),
218 "/artifact/residual_df" = exact(1L, "n - p = 3 - 2."),
219 "/predictions" = seq_tol(ps[, "fit"], "Fitted values."),
220 "/lower" = seq_tol(ps[, "lwr"], "t limits with 1 df."),
221 "/upper" = seq_tol(ps[, "upr"], "t limits with 1 df."),
222 "/influence/0/leverage" = tol(hatvalues(olss)[[1]], "Leverage needs no deletion (issue #8)."),
223 "/influence/0/studentized_residual" = tol(rstandard(olss)[[1]], "Internally standardized residual; defined with d = 1 (issue #8)."),
224 "/influence/0/cooks_distance" = tol(cooks.distance(olss)[[1]], "Cook's distance uses the full-fit variance; defined with d = 1 (issue #8)."),
225 "/influence/0/deleted_studentized_residual" = absent("The deleted fit has no residual df."),
226 "/influence/0/dffits" = absent("The deleted fit has no residual df.")),
227 c("With n = p + 1 the full-fit diagnostics are defined (standardized magnitudes are all 1); deleted-variance diagnostics are not (statistician's ruling on issue #8).",
228 "Until 2026-09-25 this case expected every diagnostic but leverage to be absent."),
229 kind = "boundary")
WLS does not offer individual prediction intervals
Case STAT-DESC-SCOREFIT-011 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT.json
Settings compared
family= "wls"interval_kind= "individual"predictors= ["x1", "grp"]response= "y"weight_column= "w"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Manual line 34-36: WLS reports mean uncertainty only.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
232 emit("STAT-DESC-SCOREFIT-011", fit_entry, "WLS does not offer individual prediction intervals", "DESC_SCORE_FIT",
233 config("wls", "y", "individual", extra = list(weight_column = "w")), list(),
234 c("Manual line 34-36: WLS reports mean uncertainty only."), kind = "invalid_input",
235 error = list(error_class = "ValueError", message_contains = "WLS supports mean-response intervals only"))
A constant numeric predictor stops the fit
Case STAT-DESC-SCOREFIT-012 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_FIT_CONSTANT.json
Settings compared
family= "ols"interval_kind= "mean"predictors= ["x1", "grp"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Manual line 54-55: a constant numeric predictor stops the fit with an error.
- The message fragment is the product's wording for this error (model_scoring._predictor_specs).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
236 c0 <- read_dataset("DESC_SCORE_FIT")
237 c0$x1 <- 5
238 export_dataset(c0, "DESC_SCORE_FIT_CONSTANT", "DESC_SCORE_FIT with a constant x1",
239 "Hand-constructed", "Constructed validation data; no third-party license.",
240 c(x1 = "Float64", grp = "String", w = "Float64", expo = "Float64", y = "Float64",
241 yb = "String", cnt = "Int64"))
242 emit("STAT-DESC-SCOREFIT-012", fit_entry, "A constant numeric predictor stops the fit", "DESC_SCORE_FIT_CONSTANT",
243 config("ols", "y"), list(),
244 c("Manual line 54-55: a constant numeric predictor stops the fit with an error.",
245 "The message fragment is the product's wording for this error (model_scoring._predictor_specs)."),
246 kind = "invalid_input",
247 error = list(error_class = "ModelScoringExecutionError", message_contains = "must be finite and vary"))
Score columns from the frozen OLS artifact
Case STAT-DESC-SCOREOP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET.json
Settings compared
artifact= {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}names= ["pred", "lo", "hi"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pred/0 | tolerance | 7.2197878156661623 | 7.219787815666163 | 9.33E-16 | 15 | passed |
/lo/0 | tolerance | 6.4521248456942617 | 6.452124845694263 | 8.89E-16 | 15 | passed |
/hi/0 | tolerance | 7.987450785638063 | 7.987450785638064 | 8.77E-16 | 15 | passed |
/pred/1 | tolerance | 7.547346447130268 | 7.547346447130272 | 3.59E-15 | 15 | passed |
/lo/1 | tolerance | 6.8999033557116123 | 6.899903355711616 | 3.54E-15 | 15 | passed |
/hi/1 | tolerance | 8.1947895385489247 | 8.194789538548928 | 3.52E-15 | 15 | passed |
/pred/2 | absent | None | passed | |||
/lo/2 | absent | None | passed | |||
/hi/2 | absent | None | passed | |||
/pred/3 | tolerance | 9.448696965898808 | 9.44869696589881 | 1.81E-15 | 15 | passed |
/lo/3 | tolerance | 8.3983928014041833 | 8.398392801404185 | 1.79E-15 | 15 | passed |
/hi/3 | tolerance | 10.499001130393433 | 10.499001130393435 | 1.52E-15 | 15 | passed |
/pred/4 | absent | None | passed | |||
/lo/4 | absent | None | passed | |||
/hi/4 | absent | None | passed | |||
/pred/5 | tolerance | 10.008420841951043 | 10.008420841951049 | 5.53E-15 | 15 | passed |
/lo/5 | tolerance | 9.2126864615299286 | 9.212686461529938 | 8.93E-15 | 15 | passed |
/hi/5 | tolerance | 10.804155222372158 | 10.80415522237216 | 1.53E-15 | 15 | passed |
/pred/6 | tolerance | 6.1896830794275655 | 6.1896830794275655 | 4.03E-17 | 17 | passed |
/lo/6 | tolerance | 5.5151187702438111 | 5.515118770243812 | 9.30E-16 | 15 | passed |
/hi/6 | tolerance | 6.8642473886113198 | 6.864247388611319 | 9.10E-16 | 15 | passed |
/pred/7 | tolerance | 5.155392356944029 | 5.1553923569440325 | 3.53E-15 | 15 | passed |
/lo/7 | tolerance | 4.5069652794950885 | 4.506965279495092 | 3.57E-15 | 15 | passed |
/hi/7 | tolerance | 5.8038194343929694 | 5.803819434392973 | 3.59E-15 | 15 | passed |
/pred/8 | tolerance | 10.217646140619816 | 10.21764614061982 | 4.02E-15 | 15 | passed |
/lo/8 | tolerance | 9.3980378823864097 | 9.398037882386417 | 7.10E-15 | 15 | passed |
/hi/8 | tolerance | 11.037254398853223 | 11.037254398853223 | 2.36E-16 | 16 | passed |
/pred/9 | tolerance | 8.2979578232205586 | 8.297957823220559 | 3.74E-17 | 17 | passed |
/lo/9 | tolerance | 7.4036884292836032 | 7.403688429283603 | 4.37E-17 | 17 | passed |
/hi/9 | tolerance | 9.1922272171575141 | 9.192227217157514 | 1.86E-17 | 17 | passed |
/pred/10 | tolerance | 8.611379610180018 | 8.611379610180022 | 3.52E-15 | 15 | passed |
/lo/10 | tolerance | 7.8822301757455024 | 7.882230175745506 | 3.60E-15 | 15 | passed |
/hi/10 | tolerance | 9.3405290446145344 | 9.340529044614538 | 3.52E-15 | 15 | passed |
/pred/11 | tolerance | 9.6436902537311564 | 9.643690253731162 | 5.33E-15 | 15 | passed |
/lo/11 | tolerance | 8.8871182351482698 | 8.887118235148279 | 8.90E-15 | 14 | passed |
/hi/11 | tolerance | 10.400262272314043 | 10.400262272314045 | 1.76E-15 | 15 | passed |
Convention
- Three columns: prediction, lower and upper; the excluded row 2 and the row with a missing x1 stay null.
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
358 emit("STAT-DESC-SCOREOP-001", op_entry, "Score columns from the frozen OLS artifact", "DESC_SCORE_TARGET",
359 list(artifact = artifact_of(ols, "ols", "identity"), names = list("pred", "lo", "hi")), op_out,
360 c("Three columns: prediction, lower and upper; the excluded row 2 and the row with a missing x1 stay null."),
361 kind = "row_alignment", excluded = target_excluded)
Repeated score column names are refused
Case STAT-DESC-SCOREOP-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm, glm, predict and influence measures
- Citation
- R stats::lm, stats::glm, stats::predict.lm, stats::predict.glm and stats::influence.measures documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_model_scoring.R · sha256 13a39b7b09c45297
- Dataset
- reference_data/datasets/DESC_SCORE_TARGET.json
Settings compared
artifact= {"family": "ols", "response": "y", "predictors": [{"name": "x1", "kind": "numeric"}, {"name": "grp", "kind": "categorical", "levels": ["A", "B", "C"], "reference_level": "A"}], "feature_order": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficient_names": ["Intercept", "x1", "grp = B (vs A)", "grp = C (vs A)"], "coefficients": [1.44965418412595, 0.942456300309787, 1.47243773579581, -1.07586893391008], "covariance": [[0.264383034006917, -0.0336703768379221, -0.114583527455002, -0.113943790295081], [-0.0336703768379221, 0.00646239623007218, 0.00491917601033095, 0.00479639048195957], [-0.114583527455002, 0.00491917601033095, 0.181651749991014, 0.0926046490408428], [-0.113943790295081, 0.00479639048195957, 0.0926046490408428, 0.181467154227661]], "link": "identity", "interval_kind": "mean", "confidence_level": 0.95, "design_rank": 4, "fitted_row_ids": ["fit-01", "fit-02", "fit-03", "fit-04", "fit-05", "fit-06", "fit-07", "fit-08", "fit-09", "fit-10", "fit-11", "fit-12", "fit-13", "fit-14", "fit-15", "fit-16", "fit-17", "fit-18", "fit-19", "fit-20", "fit-21", "fit-22", "fit-23", "fit-24", "fit-25", "fit-26", "fit-27", "fit-28", "fit-29", "fit-30"], "residual_variance": 0.889536366059753, "residual_df": 26}names= ["pred", "pred"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Score names must be distinct (ModelScoringScoreParameters).
- Manual chapter 37 lines 18-20, 61-67 and 74-78 fix the encoding, the intervals and the OLS diagnostics.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
362 emit("STAT-DESC-SCOREOP-002", op_entry, "Repeated score column names are refused", "DESC_SCORE_TARGET",
363 list(artifact = artifact_of(ols, "ols", "identity"), names = list("pred", "pred")), list(),
364 c("Score names must be distinct (ModelScoringScoreParameters)."), kind = "invalid_input",
365 error = list(error_class = "ValueError", message_contains = "must be distinct"))
Descriptive summary of a column with user-missing values masked
Case STAT-DESC-SUMMARY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base mean, median, sd, min, max
- Citation
- R stats::median and sd documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
column= "score"metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/column | exact | score | score | passed | ||
/status | exact | ok | ok | passed | ||
/sample_count | exact | 20 | 20 | 0.00E+2 | passed | |
/values/mean | tolerance | 20.414999999999999 | 20.415 | 1.47E-16 | 17 | passed |
/values/median | tolerance | 19.5 | 19.5 | 0.00E+1 | passed | |
/values/stdev | tolerance | 5.1096683381914128 | 5.109668338191413 | 4.91E-17 | 17 | passed |
/values/sample_variance | tolerance | 26.108710526315793 | 26.108710526315793 | 3.24E-17 | 17 | passed |
/values/min | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/values/max | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
Convention
- R: mean, median, sd, min and max of the 20 finite scores; the declared user-missing 999 is presented as missing, as the desktop masks it before the engine runs.
- docs/manual/chapters/06-analysis-foundations.tex:4-5: a descriptive summary characterizes the observed data.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
495 ds_source <- "R base mean, median, sd, min, max"
496 ds_cite <- "R stats::median and sd documentation"
497 ds_manual <- "docs/manual/chapters/06-analysis-foundations.tex:4-5: a descriptive summary characterizes the observed data."
498 emit("STAT-DESC-SUMMARY-001", "Descriptive summary of a column with user-missing values masked",
499 "nominal", "operation:descriptives", "descriptiveSummaryMenuItem", "SUMMARY",
500 list(column = "score", metadata = metadata),
501 list("/column" = exact("score", "the summarised column"),
502 "/status" = exact("ok", "a successful summary"),
503 "/sample_count" = exact(n, "finite values after masking 999 and NA"),
504 "/values/mean" = tol(mean(x), "mean"),
505 "/values/median" = tol(stats::median(x), "median (average of the two middle values)"),
506 "/values/stdev" = tol(sd(x), "sample SD (ddof 1)"),
507 "/values/sample_variance" = tol(var(x), "sample variance shown as stdev squared"),
508 "/values/min" = tol(min(x), "minimum"),
509 "/values/max" = tol(max(x), "maximum")),
510 c("R: mean, median, sd, min and max of the 20 finite scores; the declared user-missing 999 is presented as missing, as the desktop masks it before the engine runs.",
511 ds_manual),
512 ds_source, ds_cite)
Descriptive summary under a frequency weight after exclusions
Case STAT-DESC-SUMMARY-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base rep/mean/median/sd (literal replication)
- Citation
- R stats::median and sd documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nortest 1.0.4, e1071 1.7.17, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_reports.R · sha256 9e562f8ee4d0f2d0
- Dataset
- reference_data/datasets/DESC_REPORTS_01.json
Settings compared
column= "score"frequency_weight= "weight"metadata= {"score": {"variable_label": "Test score", "user_missing": {"values": [999]}}, "grade": {"variable_label": "Grade", "measurement_level": "nominal", "value_labels": [{"value": 1, "label": "Poor"}, {"value": 2, "label": "Fair"}, {"value": 3, "label": "Good"}, {"value": 4, "label": "Very good"}, {"value": 5, "label": "Excellent"}, {"value": 9, "label": "Not rated"}], "user_missing": {"values": [9]}}}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/status | exact | ok | ok | passed | ||
/sample_count | exact | 18 | 18 | 0.00E+2 | passed | |
/values/positive_weight_rows | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/values/frequency_total | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/values/mean | tolerance | 20.684000000000001 | 20.684 | 5.16E-17 | 17 | passed |
/values/median | tolerance | 19.600000000000001 | 19.6 | 4.21E-16 | 16 | passed |
/values/stdev | tolerance | 4.6009672896033509 | 4.600967289603351 | 1.51E-17 | 17 | passed |
/values/min | tolerance | 15.300000000000001 | 15.3 | 2.89E-16 | 16 | passed |
/values/max | tolerance | 33.200000000000003 | 33.2 | 1.58E-16 | 17 | passed |
Convention
- R: rep(score, weight) over the finite scores of the non-excluded rows with a positive weight (a missing weight counts 0); rows 1 and 2 excluded.
- docs/manual/chapters/06-analysis-foundations.tex:4-5: a descriptive summary characterizes the observed data.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
514 excluded3 <- c(0L, 1L)
515 kept3 <- !(seq_len(nrow(d)) %in% (excluded3 + 1L))
516 finite3 <- kept3 & valid_score
517 pos3 <- finite3 & w > 0
518 rep3 <- rep(d$score[pos3], w[pos3])
519 emit("STAT-DESC-SUMMARY-002", "Descriptive summary under a frequency weight after exclusions",
520 "axis_coverage", "operation:descriptives", "descriptiveSummaryMenuItem", "SUMMARY",
521 list(column = "score", frequency_weight = "weight", metadata = metadata),
522 list("/status" = exact("ok", "a successful summary"),
523 "/sample_count" = exact(sum(finite3), "finite scores among the non-excluded rows, whatever their weight"),
524 "/values/positive_weight_rows" = tol(sum(pos3), "finite scores with a positive weight"),
525 "/values/frequency_total" = tol(sum(w[pos3]), "W, the total weight of those rows"),
526 "/values/mean" = tol(mean(rep3), "mean of the replicated values"),
527 "/values/median" = tol(stats::median(rep3), "median of the replicated values"),
528 "/values/stdev" = tol(sd(rep3), "SD of the replicated values (W - 1)"),
529 "/values/min" = tol(min(rep3), "minimum"),
530 "/values/max" = tol(max(rep3), "maximum")),
531 c("R: rep(score, weight) over the finite scores of the non-excluded rows with a positive weight (a missing weight counts 0); rows 1 and 2 excluded.",
532 ds_manual),
533 "R base rep/mean/median/sd (literal replication)", ds_cite, excluded = as.list(excluded3))
Survey mean
Case STAT-DESC-SURVEY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey/stats/nortest
- Citation
- R survey::svydesign/svymean, stats::shapiro.test and nortest::ad.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, nortest 1.0.4, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_diagnostics.R · sha256 5427a49203331a27
- Dataset
- reference_data/datasets/DESC_SURVEY_01.json
Settings compared
mode= "mean"psu_column= "psu"response_column= "response"stratum_column= "stratum"weight_column= "weight"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 5.8085106382978724 | 5.808510638297872 | 2.88E-18 | 18 | passed |
/standard_error | tolerance | 0.65771945127943288 | 0.6577194512794328 | 1.15E-16 | 15 | passed |
/lower | tolerance | 2.9785722458411024 | 2.978572245841103 | 4.06E-16 | 15 | passed |
/upper | tolerance | 8.6384490307546429 | 8.638449030754643 | 2.33E-17 | 17 | passed |
/degrees_of_freedom | exact | 2 | 2 | 0.00E+2 | passed | |
/observations | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Manual chapter 28 lines 25-43: one-stage sampling with replacement, Taylor ratio variance and t interval.
- R svydesign sets nest=TRUE because PSU labels repeat across strata; four original PSUs in two strata.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
40 raw <- data.frame(
41 response = c(2.0, 3.0, 4.5, 5.0, 5.5, 7.0, 8.0, 9.5),
42 binary = c(0, 0, 1, 1, 0, 1, 1, 1),
43 weight = c(1, 1.5, 2, 0.75, 1.25, 2.5, 1, 1.75),
44 stratum = rep(c("A", "B"), each = 4),
45 psu = rep(c("1", "2"), each = 2, times = 2)
46 )
47 export_dataset(raw, "DESC_SURVEY_01", "Constructed two-stratum one-stage survey",
48 "R survey::svydesign and survey::svymean documentation",
49 "Constructed validation data; no third-party license.",
50 c(response = "Float64", binary = "Float64", weight = "Float64",
51 stratum = "String", psu = "String"))
52 d <- read_dataset("DESC_SURVEY_01")
53 design <- survey::svydesign(ids = ~psu, strata = ~stratum, weights = ~weight,
54 data = d, nest = TRUE)
55 for (mode in c("mean", "proportion")) {
56 response <- if (mode == "mean") "response" else "binary"
57 estimate <- survey::svymean(stats::as.formula(paste0("~", response)), design)
58 point <- as.double(coef(estimate)[[1]])
59 standard_error <- sqrt(as.double(stats::vcov(estimate)[1, 1]))
60 df <- as.integer(survey::degf(design))
61 bounds <- point + c(-1, 1) * stats::qt(0.975, df) * standard_error
62 id <- if (mode == "mean") "STAT-DESC-SURVEY-001" else "STAT-DESC-SURVEY-002"
63 emit(id, paste("Survey", mode), "tabelz.executor.survey_descriptives",
64 "surveyDescriptivesMenuItem", "DESC_SURVEY_01",
65 list(response_column = response, weight_column = "weight",
66 stratum_column = "stratum", psu_column = "psu", mode = mode),
67 list("/estimate" = tol(point, "Design-weighted ratio estimate; owner 1e-9 tier."),
68 "/standard_error" = tol(standard_error, "One-stage with-replacement Taylor SE; owner 1e-9 tier."),
69 "/lower" = tol(bounds[1], "Two-sided t interval lower bound; owner 1e-9 tier."),
70 "/upper" = tol(bounds[2], "Two-sided t interval upper bound; owner 1e-9 tier."),
71 "/degrees_of_freedom" = exact(df, "Four PSUs minus two strata give two design degrees of freedom."),
72 "/observations" = exact(nrow(d), "Every response is observed.")),
73 c("Manual chapter 28 lines 25-43: one-stage sampling with replacement, Taylor ratio variance and t interval.",
74 "R svydesign sets nest=TRUE because PSU labels repeat across strata; four original PSUs in two strata."))
Survey proportion
Case STAT-DESC-SURVEY-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey/stats/nortest
- Citation
- R survey::svydesign/svymean, stats::shapiro.test and nortest::ad.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, nortest 1.0.4, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_diagnostics.R · sha256 5427a49203331a27
- Dataset
- reference_data/datasets/DESC_SURVEY_01.json
Settings compared
mode= "proportion"psu_column= "psu"response_column= "binary"stratum_column= "stratum"weight_column= "weight"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.68085106382978722 | 0.6808510638297872 | 2.49E-18 | 17 | passed |
/standard_error | tolerance | 0.23341169717513377 | 0.23341169717513377 | 8.96E-20 | 18 | passed |
/lower | tolerance | -0.32343841217625691 | -0.3234384121762569 | 3.57E-18 | 16 | passed |
/upper | tolerance | 1.6851405398358312 | 1.6851405398358312 | 3.04E-17 | 16 | passed |
/degrees_of_freedom | exact | 2 | 2 | 0.00E+2 | passed | |
/observations | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Manual chapter 28 lines 25-43: one-stage sampling with replacement, Taylor ratio variance and t interval.
- R svydesign sets nest=TRUE because PSU labels repeat across strata; four original PSUs in two strata.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
40 raw <- data.frame(
41 response = c(2.0, 3.0, 4.5, 5.0, 5.5, 7.0, 8.0, 9.5),
42 binary = c(0, 0, 1, 1, 0, 1, 1, 1),
43 weight = c(1, 1.5, 2, 0.75, 1.25, 2.5, 1, 1.75),
44 stratum = rep(c("A", "B"), each = 4),
45 psu = rep(c("1", "2"), each = 2, times = 2)
46 )
47 export_dataset(raw, "DESC_SURVEY_01", "Constructed two-stratum one-stage survey",
48 "R survey::svydesign and survey::svymean documentation",
49 "Constructed validation data; no third-party license.",
50 c(response = "Float64", binary = "Float64", weight = "Float64",
51 stratum = "String", psu = "String"))
52 d <- read_dataset("DESC_SURVEY_01")
53 design <- survey::svydesign(ids = ~psu, strata = ~stratum, weights = ~weight,
54 data = d, nest = TRUE)
55 for (mode in c("mean", "proportion")) {
56 response <- if (mode == "mean") "response" else "binary"
57 estimate <- survey::svymean(stats::as.formula(paste0("~", response)), design)
58 point <- as.double(coef(estimate)[[1]])
59 standard_error <- sqrt(as.double(stats::vcov(estimate)[1, 1]))
60 df <- as.integer(survey::degf(design))
61 bounds <- point + c(-1, 1) * stats::qt(0.975, df) * standard_error
62 id <- if (mode == "mean") "STAT-DESC-SURVEY-001" else "STAT-DESC-SURVEY-002"
63 emit(id, paste("Survey", mode), "tabelz.executor.survey_descriptives",
64 "surveyDescriptivesMenuItem", "DESC_SURVEY_01",
65 list(response_column = response, weight_column = "weight",
66 stratum_column = "stratum", psu_column = "psu", mode = mode),
67 list("/estimate" = tol(point, "Design-weighted ratio estimate; owner 1e-9 tier."),
68 "/standard_error" = tol(standard_error, "One-stage with-replacement Taylor SE; owner 1e-9 tier."),
69 "/lower" = tol(bounds[1], "Two-sided t interval lower bound; owner 1e-9 tier."),
70 "/upper" = tol(bounds[2], "Two-sided t interval upper bound; owner 1e-9 tier."),
71 "/degrees_of_freedom" = exact(df, "Four PSUs minus two strata give two design degrees of freedom."),
72 "/observations" = exact(nrow(d), "Every response is observed.")),
73 c("Manual chapter 28 lines 25-43: one-stage sampling with replacement, Taylor ratio variance and t interval.",
74 "R svydesign sets nest=TRUE because PSU labels repeat across strata; four original PSUs in two strata."))
Survey mean, total, proportions and counts (Taylor)
Case STAT-DESC-SURVEY-EST-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
bounded_interval= "none"categorical_columns= ["g"]confidence_level= 0.95design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}design_effect= "none"numeric_columns= ["x"]weights_population_scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimates/0/estimate | tolerance | 5.2630443836045995 | 5.263044383604599 | 9.14E-16 | 15 | passed |
/estimates/0/standard_error | tolerance | 0.22197146884448918 | 0.22197146884448923 | 5.37E-17 | 15 | passed |
/estimates/0/lower | tolerance | 4.7198997658729631 | 4.71989976587296 | 3.54E-15 | 15 | passed |
/estimates/0/upper | tolerance | 5.8061890013362358 | 5.806189001336238 | 1.81E-15 | 15 | passed |
/estimates/0/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/1/estimate | tolerance | 261.82645830000001 | 261.82645829999996 | 5.39E-14 | 15 | passed |
/estimates/1/standard_error | tolerance | 39.64891079328801 | 39.64891079328801 | 2.68E-16 | 17 | passed |
/estimates/1/lower | tolerance | 164.80906859491392 | 164.80906859491347 | 4.51E-13 | 14 | passed |
/estimates/1/upper | tolerance | 358.8438480050861 | 358.84384800508644 | 3.43E-13 | 15 | passed |
/estimates/1/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/0/rows | exact | 22 | 22 | 0.00E+2 | passed | |
/estimates/0/missing_rows | exact | 2 | 2 | 0.00E+2 | passed | |
/estimates/1/rows | exact | 22 | 22 | 0.00E+2 | passed | |
/estimates/2/estimate | tolerance | 0.33742987692048382 | 0.3374298769204838 | 2.24E-18 | 17 | passed |
/estimates/2/standard_error | tolerance | 0.068036789756239932 | 0.06803678975623993 | 8.10E-20 | 17 | passed |
/estimates/2/lower | tolerance | 0.17094984975208172 | 0.17094984975208105 | 6.69E-16 | 14 | passed |
/estimates/2/upper | tolerance | 0.50390990408888592 | 0.5039099040888866 | 6.64E-16 | 14 | passed |
/estimates/2/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/3/estimate | tolerance | 18.4178 | 18.4178 | 2.73E-16 | 16 | passed |
/estimates/3/standard_error | tolerance | 4.3184165794111768 | 4.318416579411177 | 4.77E-17 | 16 | passed |
/estimates/3/lower | tolerance | 7.8510152936578734 | 7.851015293657831 | 4.26E-14 | 14 | passed |
/estimates/3/upper | tolerance | 28.984584706342126 | 28.98458470634217 | 4.27E-14 | 14 | passed |
/estimates/3/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/4/estimate | tolerance | 0.34483333516541903 | 0.34483333516541903 | 4.10E-19 | 17 | passed |
/estimates/4/standard_error | tolerance | 0.093278863297020287 | 0.09327886329702029 | 1.07E-19 | 17 | passed |
/estimates/4/lower | tolerance | 0.11658817910260863 | 0.11658817910260771 | 9.16E-16 | 14 | passed |
/estimates/4/upper | tolerance | 0.5730784912282294 | 0.5730784912282303 | 8.91E-16 | 14 | passed |
/estimates/4/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/7/estimate | tolerance | 17.3429 | 17.3429 | 2.05E-16 | 16 | passed |
/estimates/7/standard_error | tolerance | 6.761511427434943 | 6.761511427434944 | 9.33E-16 | 15 | passed |
/estimates/7/lower | tolerance | 0.79807755655730261 | 0.7980775565572351 | 6.75E-14 | 13 | passed |
/estimates/7/upper | tolerance | 33.887722443442698 | 33.88772244344277 | 7.08E-14 | 14 | passed |
/estimates/7/df | exact | 6 | 6 | 0.00E+2 | passed | |
/design/design_df | exact | 6 | 6 | 0.00E+2 | passed | |
/design/psus | exact | 8 | 8 | 0.00E+2 | passed | |
/design/strata | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- svymean/svytotal with na.rm=TRUE keep the design and drop the missing rows' contribution, as the engine's zero-contribution convention.
- Estimates are listed numeric columns first (Mean, Total per column), then each categorical level in natural order (Proportion, Count); g levels a, b, c give indices 2-7.
- Intervals: estimate +/- qt(0.975, D) * SE with D = PSUs - strata = 6.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
120 df_t <- as.integer(degf(taylor))
121 mean_x <- svymean(~x, taylor, na.rm = TRUE)
122 total_x <- svytotal(~x, taylor, na.rm = TRUE)
123 prop_g <- svymean(~g, taylor)
124 count_g <- svytotal(~g, taylor)
125 outputs <- c(
126 estimate_outputs("/estimates/0", coef(mean_x)[[1]], se_of(mean_x, 1), df_t, 0.95, "mean of x"),
127 estimate_outputs("/estimates/1", coef(total_x)[[1]], se_of(total_x, 1), df_t, 0.95, "total of x"),
128 list("/estimates/0/rows" = exact(sum(!is.na(d$x)), "rows with x observed"),
129 "/estimates/0/missing_rows" = exact(sum(is.na(d$x)), "rows with x missing"),
130 "/estimates/1/rows" = exact(sum(!is.na(d$x)), "rows with x observed")),
131 estimate_outputs("/estimates/2", coef(prop_g)[["ga"]], se_of(prop_g, "ga"), df_t, 0.95, "proportion g = a"),
132 estimate_outputs("/estimates/3", coef(count_g)[["ga"]], se_of(count_g, "ga"), df_t, 0.95, "count g = a"),
133 estimate_outputs("/estimates/4", coef(prop_g)[["gb"]], se_of(prop_g, "gb"), df_t, 0.95, "proportion g = b"),
134 estimate_outputs("/estimates/7", coef(count_g)[["gc"]], se_of(count_g, "gc"), df_t, 0.95, "count g = c"),
135 list("/design/design_df" = exact(df_t, "8 PSUs minus 2 strata"),
136 "/design/psus" = exact(8L, "eight PSUs"),
137 "/design/strata" = exact(2L, "two strata"))
138 )
139 emit("STAT-DESC-SURVEY-EST-001", "Survey mean, total, proportions and counts (Taylor)",
140 ESTIMATES, "surveyEstimatesMenuItem", EST_REQ,
141 list(design = design_taylor, numeric_columns = list("x"), categorical_columns = list("g"),
142 design_effect = "none", bounded_interval = "none", weights_population_scale = FALSE,
143 confidence_level = 0.95),
144 outputs,
145 c("svymean/svytotal with na.rm=TRUE keep the design and drop the missing rows' contribution, as the engine's zero-contribution convention.",
146 "Estimates are listed numeric columns first (Mean, Total per column), then each categorical level in natural order (Proportion, Count); g levels a, b, c give indices 2-7.",
147 "Intervals: estimate +/- qt(0.975, D) * SE with D = PSUs - strata = 6."))
Survey domain estimates with 90% intervals
Case STAT-DESC-SURVEY-EST-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
bounded_interval= "none"categorical_columns= ["b"]confidence_level= 0.9design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}design_effect= "none"domain_column= "dom"domain_values= ["A"]numeric_columns= ["y"]weights_population_scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimates/0/estimate | tolerance | 14.292641619854848 | 14.292641619854846 | 1.73E-15 | 15 | passed |
/estimates/0/standard_error | tolerance | 0.32255122669127295 | 0.32255122669127295 | 1.99E-18 | 17 | passed |
/estimates/0/lower | tolerance | 13.665866436692346 | 13.665866436692344 | 2.09E-15 | 15 | passed |
/estimates/0/upper | tolerance | 14.91941680301735 | 14.919416803017349 | 1.37E-15 | 16 | passed |
/estimates/0/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/1/estimate | tolerance | 359.00686000000002 | 359.00686 | 2.59E-15 | 17 | passed |
/estimates/1/standard_error | tolerance | 44.218420076992565 | 44.21842007699256 | 6.83E-15 | 15 | passed |
/estimates/1/lower | tolerance | 273.0824980708461 | 273.08249807084604 | 5.70E-14 | 15 | passed |
/estimates/1/upper | tolerance | 444.93122192915393 | 444.931221929154 | 6.18E-14 | 15 | passed |
/estimates/1/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/2/estimate | tolerance | 0.53722982845176626 | 0.5372298284517661 | 1.15E-16 | 15 | passed |
/estimates/2/standard_error | tolerance | 0.12618525955507462 | 0.12618525955507462 | 7.80E-19 | 17 | passed |
/estimates/2/lower | tolerance | 0.29202912039264012 | 0.2920291203926398 | 3.35E-16 | 14 | passed |
/estimates/2/upper | tolerance | 0.78243053651089234 | 0.7824305365108926 | 2.20E-16 | 15 | passed |
/estimates/2/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/5/estimate | tolerance | 11.624000000000001 | 11.623999999999999 | 2.22E-15 | 15 | passed |
/estimates/5/standard_error | tolerance | 3.611090393957666 | 3.611090393957666 | 4.40E-17 | 16 | passed |
/estimates/5/lower | tolerance | 4.6070003553032288 | 4.607000355303221 | 7.97E-15 | 14 | passed |
/estimates/5/upper | tolerance | 18.640999644696773 | 18.640999644696777 | 3.73E-15 | 15 | passed |
/estimates/5/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/0/rows | exact | 12 | 12 | 0.00E+2 | passed | |
/design/domain_rows | exact | 12 | 12 | 0.00E+2 | passed |
Convention
- subset(design, dom == 'A') keeps nondomain PSUs in the variance (R survey domain estimation).
- 90% intervals use qt(0.95, 6).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
150 domain_a <- subset(taylor, dom == "A")
151 mean_y <- svymean(~y, domain_a)
152 total_y <- svytotal(~y, domain_a)
153 prop_b <- svymean(~b, domain_a)
154 count_b <- svytotal(~b, domain_a)
155 outputs <- c(
156 estimate_outputs("/estimates/0", coef(mean_y)[[1]], se_of(mean_y, 1), df_t, 0.90, "domain mean of y"),
157 estimate_outputs("/estimates/1", coef(total_y)[[1]], se_of(total_y, 1), df_t, 0.90, "domain total of y"),
158 estimate_outputs("/estimates/2", coef(prop_b)[["bno"]], se_of(prop_b, "bno"), df_t, 0.90, "domain proportion b = no"),
159 estimate_outputs("/estimates/5", coef(count_b)[["byes"]], se_of(count_b, "byes"), df_t, 0.90, "domain count b = yes"),
160 list("/estimates/0/rows" = exact(sum(d$dom == "A"), "domain rows"),
161 "/design/domain_rows" = exact(sum(d$dom == "A"), "domain rows"))
162 )
163 emit("STAT-DESC-SURVEY-EST-002", "Survey domain estimates with 90% intervals",
164 ESTIMATES, "surveyEstimatesMenuItem", EST_REQ,
165 list(design = design_taylor, numeric_columns = list("y"), categorical_columns = list("b"),
166 design_effect = "none", bounded_interval = "none", weights_population_scale = FALSE,
167 domain_column = "dom", domain_values = list("A"), confidence_level = 0.90),
168 outputs,
169 c("subset(design, dom == 'A') keeps nondomain PSUs in the variance (R survey domain estimation).",
170 "90% intervals use qt(0.95, 6)."),
171 kind = "axis_coverage")
Survey mean and total with a first-stage FPC
Case STAT-DESC-SURVEY-EST-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
bounded_interval= "none"categorical_columns= []confidence_level= 0.95design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu", "fpc": "N", "fpc_kind": "count"}}design_effect= "none"numeric_columns= ["y"]weights_population_scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimates/0/estimate | tolerance | 13.868576097510928 | 13.86857609751093 | 2.01E-15 | 15 | passed |
/estimates/0/standard_error | tolerance | 0.35931508178838389 | 0.35931508178838395 | 5.98E-17 | 15 | passed |
/estimates/0/lower | tolerance | 12.989363765587807 | 12.989363765587806 | 1.41E-15 | 15 | passed |
/estimates/0/upper | tolerance | 14.747788429434049 | 14.747788429434054 | 5.44E-15 | 15 | passed |
/estimates/0/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/1/estimate | tolerance | 756.98294169999997 | 756.9829417000001 | 1.13E-13 | 15 | passed |
/estimates/1/standard_error | tolerance | 68.629301970053575 | 68.62930197005358 | 1.33E-16 | 17 | passed |
/estimates/1/lower | tolerance | 589.05308937366908 | 589.0530893736686 | 4.53E-13 | 15 | passed |
/estimates/1/upper | tolerance | 924.91279402633086 | 924.9127940263315 | 6.79E-13 | 15 | passed |
/estimates/1/df | exact | 6 | 6 | 0.00E+2 | passed |
Convention
- svydesign(fpc = ~N) with N the population count of PSUs per stratum (20 and 30); the (1 - n_h/N_h) factor applies per stratum.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
174 df_f <- as.integer(degf(with_fpc))
175 mean_yf <- svymean(~y, with_fpc)
176 total_yf <- svytotal(~y, with_fpc)
177 outputs <- c(
178 estimate_outputs("/estimates/0", coef(mean_yf)[[1]], se_of(mean_yf, 1), df_f, 0.95, "FPC mean of y"),
179 estimate_outputs("/estimates/1", coef(total_yf)[[1]], se_of(total_yf, 1), df_f, 0.95, "FPC total of y")
180 )
181 emit("STAT-DESC-SURVEY-EST-003", "Survey mean and total with a first-stage FPC",
182 ESTIMATES, "surveyEstimatesMenuItem", EST_REQ,
183 list(design = design_fpc, numeric_columns = list("y"), categorical_columns = list(),
184 design_effect = "none", bounded_interval = "none", weights_population_scale = FALSE,
185 confidence_level = 0.95),
186 outputs,
187 c("svydesign(fpc = ~N) with N the population count of PSUs per stratum (20 and 30); the (1 - n_h/N_h) factor applies per stratum."),
188 kind = "axis_coverage")
Survey mean and proportion from supplied replicate weights
Case STAT-DESC-SURVEY-EST-004 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
bounded_interval= "none"categorical_columns= ["b"]confidence_level= 0.95design= {"weight": "w", "variance": "replicate", "replicates": {"columns": ["rw1", "rw2", "rw3", "rw4"], "method": "other", "weight_type": "full", "scale": 0.75, "rscales": null, "fay_rho": null, "centering": "full_sample"}}design_effect= "none"numeric_columns= ["y"]weights_population_scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimates/0/estimate | tolerance | 13.868576097510928 | 13.86857609751093 | 2.01E-15 | 15 | passed |
/estimates/0/standard_error | tolerance | 0.12061980658628588 | 0.12061980658628807 | 2.19E-15 | 13 | passed |
/estimates/0/lower | tolerance | 13.484710039696367 | 13.484710039696362 | 5.49E-15 | 15 | passed |
/estimates/0/upper | tolerance | 14.25244215532549 | 14.252442155325499 | 8.52E-15 | 15 | passed |
/estimates/0/df | exact | 3 | 3 | 0.00E+2 | passed | |
/estimates/2/estimate | tolerance | 0.39455614060158362 | 0.3945561406015836 | 4.11E-18 | 16 | passed |
/estimates/2/standard_error | tolerance | 0.036594696118925948 | 0.03659469611892601 | 6.29E-17 | 14 | passed |
/estimates/2/lower | tolerance | 0.27809548514492771 | 0.2780954851449275 | 2.20E-16 | 15 | passed |
/estimates/2/upper | tolerance | 0.51101679605823958 | 0.5110167960582397 | 1.06E-16 | 15 | passed |
/estimates/2/df | exact | 3 | 3 | 0.00E+2 | passed | |
/design/design_df | exact | 3 | 3 | 0.00E+2 | passed | |
/design/replicates | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- svrepdesign(type = 'other', scale = 0.75, rscales = 1, mse = TRUE, combined.weights = TRUE): V = 0.75 * sum_r (theta_r - theta_full)^2.
- degf = qr(replicate weights, tol = 1e-5)$rank - 1 = 3.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
191 df_r <- as.integer(degf(replicate))
192 mean_yr <- svymean(~y, replicate)
193 prop_br <- svymean(~b, replicate)
194 outputs <- c(
195 estimate_outputs("/estimates/0", coef(mean_yr)[[1]], se_of(mean_yr, 1), df_r, 0.95, "replicate mean of y"),
196 estimate_outputs("/estimates/2", coef(prop_br)[["bno"]], se_of(prop_br, "bno"), df_r, 0.95, "replicate proportion b = no"),
197 list("/design/design_df" = exact(df_r, "rank of the four replicate-weight columns minus 1"),
198 "/design/replicates" = exact(4L, "four replicate columns"))
199 )
200 emit("STAT-DESC-SURVEY-EST-004", "Survey mean and proportion from supplied replicate weights",
201 ESTIMATES, "surveyEstimatesMenuItem", EST_REQ,
202 list(design = design_rep, numeric_columns = list("y"), categorical_columns = list("b"),
203 design_effect = "none", bounded_interval = "none", weights_population_scale = FALSE,
204 confidence_level = 0.95),
205 outputs,
206 c("svrepdesign(type = 'other', scale = 0.75, rscales = 1, mse = TRUE, combined.weights = TRUE): V = 0.75 * sum_r (theta_r - theta_full)^2.",
207 "degf = qr(replicate weights, tol = 1e-5)$rank - 1 = 3."),
208 kind = "axis_coverage")
Survey proportion with Korn-Graubard limits and SRS design effect
Case STAT-DESC-SURVEY-EST-005 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
bounded_interval= "korn_graubard"categorical_columns= ["b"]confidence_level= 0.95design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}design_effect= "srs_wr"numeric_columns= ["y"]weights_population_scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimates/2/estimate | tolerance | 0.39455614060158367 | 0.3945561406015836 | 5.41E-17 | 15 | passed |
/estimates/2/standard_error | tolerance | 0.052533098538309633 | 0.052533098538309626 | 6.66E-18 | 15 | passed |
/estimates/2/lower | tolerance | 0.26601227921082737 | 0.2660122792108268 | 5.51E-16 | 14 | passed |
/estimates/2/upper | tolerance | 0.52310000199233997 | 0.5231000019923404 | 4.43E-16 | 15 | passed |
/estimates/2/df | exact | 6 | 6 | 0.00E+2 | passed | |
/estimates/2/extensions/bounded_lower | tolerance | 0.27257092646139042 | 0.27257092646139003 | 3.92E-16 | 14 | passed |
/estimates/2/extensions/bounded_upper | tolerance | 0.52698639480288967 | 0.5269863948028899 | 2.20E-16 | 15 | passed |
/estimates/2/extensions/effective_n | tolerance | 61.866740100482467 | 61.866740100482026 | 4.41E-13 | 14 | passed |
/estimates/0/extensions/design_effect | tolerance | 1.110138555646377 | 1.1101385556463772 | 2.01E-16 | 15 | passed |
/estimates/0/extensions/deft_wr | tolerance | 1.0536311288332254 | 1.0536311288332256 | 2.28E-16 | 15 | passed |
Convention
- docs/manual/chapters/87-complex-surveys.tex:126-138: Korn-Graubard uses n_e = p(1-p)/V * (t_{n_s-1}/t_D)^2 and beta quantiles; n_s counts domain rows before item missingness.
- docs/manual/chapters/87-complex-surveys.tex:144-147: with-replacement SRS comparator divides the normalized weighted dispersion by the observed n - 1 (R svymean deff = 'replace').
- Estimates: y Mean (0), y Total (1), b = no Proportion (2), b = no Count (3), b = yes (4, 5).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
211 kg <- svyciprop(~I(b == "no"), taylor, method = "beta", level = 0.95)
212 p_no <- as.double(coef(prop_g <- svymean(~b, taylor))[["bno"]])
213 v_no <- as.double(vcov(prop_g)["bno", "bno"])
214 n_eff <- p_no * (1 - p_no) / v_no * (qt(0.025, nrow(d) - 1) / qt(0.025, df_t))^2
215 mean_y_deff <- svymean(~y, taylor, deff = "replace")
216 outputs <- c(
217 estimate_outputs("/estimates/2", p_no, sqrt(v_no), df_t, 0.95, "proportion b = no"),
218 list("/estimates/2/extensions/bounded_lower" = tol(attr(kg, "ci")[[1]], "svyciprop beta (Korn-Graubard) lower limit"),
219 "/estimates/2/extensions/bounded_upper" = tol(attr(kg, "ci")[[2]], "svyciprop beta (Korn-Graubard) upper limit"),
220 "/estimates/2/extensions/effective_n" = tol(n_eff, "p(1-p)/V times [qt(alpha/2, n-1)/qt(alpha/2, D)]^2 with n = 24 rows"),
221 "/estimates/0/extensions/design_effect" = tol(as.double(deff(mean_y_deff)[[1]]), "svymean deff = 'replace' for the mean of y"),
222 "/estimates/0/extensions/deft_wr" = tol(sqrt(as.double(deff(mean_y_deff)[[1]])), "square root of the with-replacement design effect"))
223 )
224 emit("STAT-DESC-SURVEY-EST-005", "Survey proportion with Korn-Graubard limits and SRS design effect",
225 ESTIMATES, "surveyEstimatesMenuItem", EST_REQ,
226 list(design = design_taylor, numeric_columns = list("y"), categorical_columns = list("b"),
227 design_effect = "srs_wr", bounded_interval = "korn_graubard",
228 weights_population_scale = FALSE, confidence_level = 0.95),
229 outputs,
230 c(paste0(MANUAL, ":126-138: Korn-Graubard uses n_e = p(1-p)/V * (t_{n_s-1}/t_D)^2 and beta quantiles; n_s counts domain rows before item missingness."),
231 paste0(MANUAL, ":144-147: with-replacement SRS comparator divides the normalized weighted dispersion by the observed n - 1 (R svymean deff = 'replace')."),
232 "Estimates: y Mean (0), y Total (1), b = no Proportion (2), b = no Count (3), b = yes (4, 5)."),
233 kind = "axis_coverage")
Survey proportion with a delta-logit interval
Case STAT-DESC-SURVEY-EST-006 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
bounded_interval= "delta_logit"categorical_columns= ["b"]confidence_level= 0.95design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}design_effect= "none"numeric_columns= []weights_population_scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimates/0/estimate | tolerance | 0.39455614060158367 | 0.3945561406015836 | 5.41E-17 | 15 | passed |
/estimates/0/extensions/bounded_lower | tolerance | 0.2756171231292191 | 0.2756171231292186 | 5.00E-16 | 14 | passed |
/estimates/0/extensions/bounded_upper | tolerance | 0.52744902861788034 | 0.5274490286178809 | 5.60E-16 | 14 | passed |
Convention
- docs/manual/chapters/87-complex-surveys.tex:122-125: delta-logit transforms logit(p) +/- t_{D} sqrt(V)/[p(1-p)] back to the probability scale (svyciprop method 'xlogit').
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
236 xl <- svyciprop(~I(b == "no"), taylor, method = "xlogit", level = 0.95)
237 emit("STAT-DESC-SURVEY-EST-006", "Survey proportion with a delta-logit interval",
238 ESTIMATES, "surveyEstimatesMenuItem", EST_REQ,
239 list(design = design_taylor, numeric_columns = list(), categorical_columns = list("b"),
240 design_effect = "none", bounded_interval = "delta_logit",
241 weights_population_scale = FALSE, confidence_level = 0.95),
242 list("/estimates/0/estimate" = tol(p_no, "proportion b = no"),
243 "/estimates/0/extensions/bounded_lower" = tol(attr(xl, "ci")[[1]], "svyciprop xlogit lower limit"),
244 "/estimates/0/extensions/bounded_upper" = tol(attr(xl, "ci")[[2]], "svyciprop xlogit upper limit")),
245 c(paste0(MANUAL, ":122-125: delta-logit transforms logit(p) +/- t_{D} sqrt(V)/[p(1-p)] back to the probability scale (svyciprop method 'xlogit').")),
246 kind = "axis_coverage")
Survey ratio of weighted totals (Taylor)
Case STAT-DESC-SURVEY-RATIO-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
confidence_level= 0.95denominator= "x"design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}numerators= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/ratios/0/ratio | tolerance | 2.638450465187383 | 2.638450465187384 | 9.09E-16 | 15 | passed |
/ratios/0/standard_error | tolerance | 0.065113809721445703 | 0.06511380972144579 | 8.37E-17 | 14 | passed |
/ratios/0/lower | tolerance | 2.4791227125067792 | 2.479122712506779 | 1.97E-17 | 17 | passed |
/ratios/0/upper | tolerance | 2.7977782178679869 | 2.7977782178679886 | 1.74E-15 | 15 | passed |
/ratios/0/df | exact | 6 | 6 | 0.00E+2 | passed | |
/ratios/0/rows | exact | 22 | 22 | 0.00E+2 | passed | |
/ratios/0/missing_rows | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- svyratio(~y, ~x, na.rm = TRUE): rows with a missing x stay in the design with zero contribution.
- Linearized contribution w (y - R x) / sum(w x); interval ratio +/- qt(0.975, 6) * SE.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
362 outputs <- c(ratio_outputs(0, taylor, "y", df_t, 0.95, "y / x"),
363 list("/ratios/0/rows" = exact(sum(!is.na(d$x)), "rows with both observed"),
364 "/ratios/0/missing_rows" = exact(sum(is.na(d$x)), "rows with x missing")))
365 emit("STAT-DESC-SURVEY-RATIO-001", "Survey ratio of weighted totals (Taylor)",
366 RATIOS, "surveyRatiosMenuItem", RATIO_REQ,
367 list(design = design_taylor, numerators = list("y"), denominator = "x", confidence_level = 0.95),
368 outputs,
369 c("svyratio(~y, ~x, na.rm = TRUE): rows with a missing x stay in the design with zero contribution.",
370 "Linearized contribution w (y - R x) / sum(w x); interval ratio +/- qt(0.975, 6) * SE."))
Survey ratios of two numerators in a domain
Case STAT-DESC-SURVEY-RATIO-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
confidence_level= 0.9denominator= "x"design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}domain_column= "dom"domain_values= ["A"]numerators= ["y", "z"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/ratios/0/ratio | tolerance | 2.3138843436808108 | 2.3138843436808103 | 4.93E-16 | 15 | passed |
/ratios/0/standard_error | tolerance | 0.13634278365214761 | 0.13634278365214753 | 8.44E-17 | 15 | passed |
/ratios/0/lower | tolerance | 2.0489457350973934 | 2.048945735097393 | 4.27E-16 | 15 | passed |
/ratios/0/upper | tolerance | 2.5788229522642281 | 2.5788229522642276 | 4.59E-16 | 15 | passed |
/ratios/0/df | exact | 6 | 6 | 0.00E+2 | passed | |
/ratios/1/ratio | tolerance | 1.3914811831350358 | 1.3914811831350355 | 2.51E-16 | 15 | passed |
/ratios/1/standard_error | tolerance | 0.0570559289826615 | 0.057055928982661465 | 3.51E-17 | 15 | passed |
/ratios/1/lower | tolerance | 1.2806112270494465 | 1.280611227049446 | 4.23E-16 | 15 | passed |
/ratios/1/upper | tolerance | 1.502351139220625 | 1.502351139220625 | 2.03E-17 | 16 | passed |
/ratios/1/df | exact | 6 | 6 | 0.00E+2 | passed | |
/ratios/1/rows | exact | 12 | 12 | 0.00E+2 | passed |
Convention
- Ratios are listed in numerator order (y then z); subset(design, dom == 'A') keeps the design.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
373 outputs <- c(ratio_outputs(0, domain_a, "y", df_t, 0.90, "domain y / x"),
374 ratio_outputs(1, domain_a, "z", df_t, 0.90, "domain z / x"),
375 list("/ratios/1/rows" = exact(sum(d$dom == "A" & !is.na(d$x)), "domain rows with x observed")))
376 emit("STAT-DESC-SURVEY-RATIO-002", "Survey ratios of two numerators in a domain",
377 RATIOS, "surveyRatiosMenuItem", RATIO_REQ,
378 list(design = design_taylor, numerators = list("y", "z"), denominator = "x",
379 domain_column = "dom", domain_values = list("A"), confidence_level = 0.90),
380 outputs,
381 c("Ratios are listed in numerator order (y then z); subset(design, dom == 'A') keeps the design."),
382 kind = "axis_coverage")
Survey ratio from supplied replicate weights
Case STAT-DESC-SURVEY-RATIO-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
confidence_level= 0.95denominator= "x"design= {"weight": "w", "variance": "replicate", "replicates": {"columns": ["rw1", "rw2", "rw3", "rw4"], "method": "other", "weight_type": "full", "scale": 0.75, "rscales": null, "fay_rho": null, "centering": "full_sample"}}numerators= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/ratios/0/ratio | tolerance | 2.638450465187383 | 2.638450465187384 | 9.09E-16 | 15 | passed |
/ratios/0/standard_error | tolerance | 0.038261232774066865 | 0.038261232774068024 | 1.16E-15 | 13 | passed |
/ratios/0/lower | tolerance | 2.5166861463099539 | 2.5166861463099512 | 2.66E-15 | 14 | passed |
/ratios/0/upper | tolerance | 2.7602147840648121 | 2.7602147840648166 | 4.47E-15 | 14 | passed |
/ratios/0/df | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- svyratio on svrepdesign(type = 'other', scale = 0.75, mse = TRUE): the ratio is recomputed under each replicate weight column.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
385 outputs <- ratio_outputs(0, replicate, "y", df_r, 0.95, "replicate y / x")
386 emit("STAT-DESC-SURVEY-RATIO-003", "Survey ratio from supplied replicate weights",
387 RATIOS, "surveyRatiosMenuItem", RATIO_REQ,
388 list(design = design_rep, numerators = list("y"), denominator = "x", confidence_level = 0.95),
389 outputs,
390 c("svyratio on svrepdesign(type = 'other', scale = 0.75, mse = TRUE): the ratio is recomputed under each replicate weight column."),
391 kind = "axis_coverage")
Survey crosstab with the second-order Rao-Scott F
Case STAT-DESC-SURVEY-XTAB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
column_column= "b"confidence_level= 0.95design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}row_column= "g"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/0/count | tolerance | 3.6332999999999998 | 3.6332999999999998 | 4.80E-17 | 16 | passed |
/cells/0/count_se | tolerance | 2.6443315922932205 | 2.6443315922932205 | 4.35E-17 | 16 | passed |
/cells/0/percent | tolerance | 6.6565169119829388 | 6.656516911982939 | 2.22E-17 | 17 | passed |
/cells/0/percent_se | tolerance | 5.1202828603750845 | 5.1202828603750845 | 1.05E-17 | 17 | passed |
/cells/0/percent_lower | tolerance | -5.8723639002833146 | -5.872363900283364 | 4.97E-14 | 14 | passed |
/cells/0/percent_upper | tolerance | 19.185397724249192 | 19.185397724249242 | 4.99E-14 | 14 | passed |
/cells/0/row_percent | tolerance | 19.727111815743463 | 19.727111815743463 | 1.58E-16 | 17 | passed |
/cells/0/row_percent_se | tolerance | 12.567011229235822 | 12.567011229235822 | 2.56E-16 | 16 | passed |
/cells/0/column_percent | tolerance | 16.870899289094023 | 16.870899289094023 | 3.25E-17 | 17 | passed |
/cells/0/column_percent_se | tolerance | 10.761480075576788 | 10.761480075576788 | 9.58E-17 | 17 | passed |
/cells/3/count | tolerance | 7.8809000000000005 | 7.8809000000000005 | 3.96E-17 | 17 | passed |
/cells/3/count_se | tolerance | 3.107458603103185 | 3.1074586031031854 | 4.46E-16 | 15 | passed |
/cells/3/percent | tolerance | 14.438484059022471 | 14.438484059022475 | 3.78E-15 | 15 | passed |
/cells/3/percent_se | tolerance | 5.9407483709770039 | 5.940748370977005 | 9.11E-16 | 15 | passed |
/cells/3/percent_lower | tolerance | -0.098003534591327934 | -0.098003534591383 | 5.51E-14 | 12 | passed |
/cells/3/percent_upper | tolerance | 28.97497165263627 | 28.974971652636334 | 6.43E-14 | 14 | passed |
/cells/3/row_percent | tolerance | 41.870905700274683 | 41.87090570027468 | 1.70E-16 | 17 | passed |
/cells/3/row_percent_se | tolerance | 12.898876764992961 | 12.89887676499296 | 1.79E-15 | 15 | passed |
/cells/3/column_percent | tolerance | 23.847766947985729 | 23.84776694798573 | 4.69E-17 | 17 | passed |
/cells/3/column_percent_se | tolerance | 9.6117566686053966 | 9.611756668605398 | 1.75E-15 | 15 | passed |
/test/f_statistic | tolerance | 1.7307168186032524 | 1.730716818603254 | 1.59E-15 | 15 | passed |
/test/numerator_df | tolerance | 1.8644587881885295 | 1.864458788188529 | 4.41E-16 | 15 | passed |
/test/denominator_df | tolerance | 11.186752729131177 | 11.186752729131175 | 1.76E-15 | 15 | passed |
/test/p_value | tail_probability | 0.22152287837336401 | 0.2215228783733636 | 4.14E-16 | 14 | passed |
/test/pearson | tolerance | 2.5290311786620947 | 2.529031178662096 | 1.34E-15 | 15 | passed |
/test/contingency_df | exact | 2 | 2 | 0.00E+2 | passed | |
/analysis_rows | exact | 24 | 24 | 0.00E+2 | passed | |
/cells/0/rows | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/87-complex-surveys.tex:73-75: survey crosstabs use design-adjusted Rao-Scott inference; the ordinary Pearson chi-square is an unadjusted comparison.
- Cells are row-major over row levels a, b, c and column levels no, yes: index = row * 2 + column.
- svychisq(statistic = 'F'): F = X2 / tr(Delta) on (d0, d0 * D) with d0 = tr(Delta)^2 / tr(Delta^2).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
288 outputs <- c(crosstab_outputs(taylor, df_t, 0.95, 0, "a", "no"),
289 crosstab_outputs(taylor, df_t, 0.95, 3, "b", "yes"),
290 rao_scott_outputs(taylor, nrow(d)),
291 list("/analysis_rows" = exact(nrow(d), "every row has g and b"),
292 "/cells/0/rows" = exact(sum(d$g == "a" & d$b == "no"), "unweighted rows in cell a/no")))
293 emit("STAT-DESC-SURVEY-XTAB-001", "Survey crosstab with the second-order Rao-Scott F",
294 CROSSTAB, "surveyCrosstabMenuItem", XTAB_REQ,
295 list(design = design_taylor, row_column = "g", column_column = "b", confidence_level = 0.95),
296 outputs,
297 c(paste0(MANUAL, ":73-75: survey crosstabs use design-adjusted Rao-Scott inference; the ordinary Pearson chi-square is an unadjusted comparison."),
298 "Cells are row-major over row levels a, b, c and column levels no, yes: index = row * 2 + column.",
299 "svychisq(statistic = 'F'): F = X2 / tr(Delta) on (d0, d0 * D) with d0 = tr(Delta)^2 / tr(Delta^2)."))
Survey one-way frequencies in a domain
Case STAT-DESC-SURVEY-XTAB-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
confidence_level= 0.95design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}domain_column= "dom"domain_values= ["B"]row_column= "g"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/0/count | tolerance | 10.475 | 10.475000000000001 | 1.42E-15 | 15 | passed |
/cells/0/count_se | tolerance | 5.4776957728592413 | 5.477695772859241 | 4.78E-17 | 17 | passed |
/cells/0/percent | tolerance | 35.551497914425248 | 35.551497914425255 | 6.98E-15 | 15 | passed |
/cells/0/percent_se | tolerance | 19.179786375415965 | 19.179786375415965 | 1.71E-17 | 18 | passed |
/cells/0/percent_lower | tolerance | -11.37974867000888 | -11.379748670009064 | 1.84E-13 | 13 | passed |
/cells/0/percent_upper | tolerance | 82.482744498859375 | 82.48274449885957 | 1.99E-13 | 14 | passed |
/cells/1/count | tolerance | 9.889800000000001 | 9.8898 | 1.74E-15 | 15 | passed |
/cells/1/count_se | tolerance | 4.1074643419024346 | 4.107464341902435 | 9.72E-18 | 17 | passed |
/cells/1/percent | tolerance | 33.565365544065187 | 33.56536554406519 | 4.64E-16 | 16 | passed |
/cells/1/percent_se | tolerance | 14.502047767505049 | 14.502047767505053 | 3.53E-15 | 15 | passed |
/cells/1/percent_lower | tolerance | -1.9198670041133568 | -1.919867004113506 | 1.49E-13 | 13 | passed |
/cells/1/percent_upper | tolerance | 69.050598092243732 | 69.05059809224389 | 1.56E-13 | 14 | passed |
/cells/2/count | tolerance | 9.0995000000000008 | 9.0995 | 1.00E-17 | 17 | passed |
/cells/2/count_se | tolerance | 7.8173033233973968 | 7.817303323397398 | 8.41E-16 | 15 | passed |
/cells/2/percent | tolerance | 30.883136541509554 | 30.883136541509558 | 3.56E-15 | 15 | passed |
/cells/2/percent_se | tolerance | 23.099589520805708 | 23.099589520805708 | 1.79E-16 | 17 | passed |
/cells/2/percent_lower | tolerance | -25.639522813534061 | -25.639522813534285 | 2.24E-13 | 14 | passed |
/cells/2/percent_upper | tolerance | 87.405795896553172 | 87.4057958965534 | 2.28E-13 | 14 | passed |
/analysis_rows | exact | 12 | 12 | 0.00E+2 | passed | |
/cells/0/rows | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- One column only: cells are the levels of g in natural order; no test of independence.
- subset(design, dom == 'B') keeps the whole design for the variance.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
319 outputs[["/analysis_rows"]] <- exact(sum(d$dom == "B"), "domain rows")
320 outputs[["/cells/0/rows"]] <- exact(sum(d$dom == "B" & d$g == "a"), "unweighted domain rows with g = a")
321 emit("STAT-DESC-SURVEY-XTAB-002", "Survey one-way frequencies in a domain",
322 CROSSTAB, "surveyCrosstabMenuItem", XTAB_REQ,
323 list(design = design_taylor, row_column = "g", domain_column = "dom",
324 domain_values = list("B"), confidence_level = 0.95),
325 outputs,
326 c("One column only: cells are the levels of g in natural order; no test of independence.",
327 "subset(design, dom == 'B') keeps the whole design for the variance."),
328 kind = "axis_coverage")
Survey crosstab with a first-stage FPC and 90% intervals
Case STAT-DESC-SURVEY-XTAB-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svymean, svytotal, svyratio, svyby, svychisq, svyciprop
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_survey_estimates.R · sha256 10511ae4153cc664
- Dataset
- reference_data/datasets/DESC_SURVEY_B7.json
Settings compared
column_column= "b"confidence_level= 0.9design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu", "fpc": "N", "fpc_kind": "count"}}row_column= "g"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/1/count | tolerance | 14.7845 | 14.784500000000001 | 1.31E-15 | 16 | passed |
/cells/1/count_se | tolerance | 3.4046515905612296 | 3.4046515905612296 | 3.17E-17 | 17 | passed |
/cells/1/percent | tolerance | 27.08647078006544 | 27.086470780065447 | 7.17E-15 | 15 | passed |
/cells/1/percent_se | tolerance | 4.2898610655302063 | 4.289861065530205 | 8.92E-16 | 15 | passed |
/cells/1/percent_lower | tolerance | 18.750497351376779 | 18.75049735137678 | 4.20E-16 | 16 | passed |
/cells/1/percent_upper | tolerance | 35.422444208754101 | 35.422444208754115 | 1.39E-14 | 15 | passed |
/cells/1/row_percent | tolerance | 80.27288818425653 | 80.27288818425654 | 1.43E-14 | 15 | passed |
/cells/1/row_percent_se | tolerance | 11.516377016188653 | 11.516377016188654 | 1.28E-15 | 15 | passed |
/cells/1/column_percent | tolerance | 44.738203814601754 | 44.73820381460176 | 6.66E-15 | 15 | passed |
/cells/1/column_percent_se | tolerance | 7.9796440187710154 | 7.979644018771016 | 8.56E-16 | 15 | passed |
/cells/4/count | tolerance | 6.9616000000000007 | 6.9616 | 9.12E-16 | 15 | passed |
/cells/4/count_se | tolerance | 3.9513851870789147 | 3.9513851870789147 | 2.91E-17 | 17 | passed |
/cells/4/percent | tolerance | 12.754247690655998 | 12.754247690655996 | 2.16E-15 | 15 | passed |
/cells/4/percent_se | tolerance | 6.5277499191974693 | 6.5277499191974675 | 1.80E-15 | 15 | passed |
/cells/4/percent_lower | tolerance | 0.069652771536116376 | 0.06965277153610572 | 1.07E-14 | 12 | passed |
/cells/4/percent_upper | tolerance | 25.438842609775879 | 25.438842609775886 | 6.96E-15 | 15 | passed |
/cells/4/row_percent | tolerance | 40.140922221773756 | 40.14092222177375 | 6.64E-15 | 15 | passed |
/cells/4/row_percent_se | tolerance | 12.280875036477234 | 12.280875036477234 | 3.36E-16 | 16 | passed |
/cells/4/column_percent | tolerance | 32.325558718233282 | 32.325558718233275 | 7.35E-15 | 15 | passed |
/cells/4/column_percent_se | tolerance | 17.767283673478069 | 17.76728367347807 | 1.94E-16 | 16 | passed |
/test/f_statistic | tolerance | 2.0845625052273942 | 2.084562505227395 | 8.57E-16 | 15 | passed |
/test/numerator_df | tolerance | 1.8721183567940665 | 1.872118356794066 | 4.81E-16 | 15 | passed |
/test/denominator_df | tolerance | 11.232710140764398 | 11.232710140764397 | 1.44E-15 | 15 | passed |
/test/p_value | tail_probability | 0.171171517463414 | 0.17117151746341414 | 1.36E-16 | 15 | passed |
/test/pearson | tolerance | 2.5290311786620947 | 2.529031178662096 | 1.34E-15 | 15 | passed |
/test/contingency_df | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- svydesign(fpc = ~N): finite population corrections enter the cell covariance and so the Rao-Scott design effects.
- 90% percent intervals use qt(0.95, 6).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:31-40: domain rows keep the design context; nondomain units still contribute to the variance.
- docs/manual/chapters/87-complex-surveys.tex:53-58: Taylor linearization aggregates influence contributions within PSUs within strata, applying declared FPCs.
- docs/manual/chapters/87-complex-surveys.tex:61-69: replicate variance is c * sum_r c_r (theta_r - theta)^2 centred at the full estimate or replicate mean as declared.
Reference code
The lines of the reference script that produce this case's expected values.
331 outputs <- c(crosstab_outputs(with_fpc, df_f, 0.90, 1, "a", "yes"),
332 crosstab_outputs(with_fpc, df_f, 0.90, 4, "c", "no"),
333 rao_scott_outputs(with_fpc, nrow(d)))
334 emit("STAT-DESC-SURVEY-XTAB-003", "Survey crosstab with a first-stage FPC and 90% intervals",
335 CROSSTAB, "surveyCrosstabMenuItem", XTAB_REQ,
336 list(design = design_fpc, row_column = "g", column_column = "b", confidence_level = 0.90),
337 outputs,
338 c("svydesign(fpc = ~N): finite population corrections enter the cell covariance and so the Rao-Scott design effects.",
339 "90% percent intervals use qt(0.95, 6)."),
340 kind = "axis_coverage")
Two-way counts and all percentage denominators
Case STAT-DESC-TABCAT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::quantile and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_tabulation.R · sha256 bb74c4a5af397aaa
- Dataset
- reference_data/datasets/DESC_TABULATION_01.json
Settings compared
column_column= "column"column_percentages= trueinclude_margins= truekind= "categorical"overall_percentages= truerow_column= "row"row_percentages= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/valid_n | exact | 10 | 10 | 0.00E+2 | passed | |
/cells/0/count | exact | 3 | 3 | 0.00E+2 | passed | |
/cells/0/row_total | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/0/column_total | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/0/overall_total | exact | 10 | 10 | 0.00E+2 | passed | |
/cells/0/row_percentage | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/cells/0/column_percentage | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/cells/0/overall_percentage | tolerance | 30 | 30.0 | 0.00E+2 | passed |
Convention
- Cells are ordered by observed X,Y and L,R labels; percentage outputs are in percent units (100 times the cell fraction).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
125 counts <- table(factor(d$row, levels = c("X", "Y")), factor(d$column, levels = c("L", "R")))
126 total <- sum(counts)
127 out <- list(
128 "/valid_n" = exact(total, "Ten rows have complete categorical roles."),
129 "/cells/0/count" = exact(counts["X", "L"], "X/L count is exact."),
130 "/cells/0/row_total" = exact(sum(counts["X", ]), "X row margin is exact."),
131 "/cells/0/column_total" = exact(sum(counts[, "L"]), "L column margin is exact."),
132 "/cells/0/overall_total" = exact(total, "Grand total is exact."),
133 "/cells/0/row_percentage" = tol(100 * counts["X", "L"] / sum(counts["X", ]),
134 "Cell / row total in percent units; owner 1e-9 tier."),
135 "/cells/0/column_percentage" = tol(100 * counts["X", "L"] / sum(counts[, "L"]),
136 "Cell / column total in percent units; owner 1e-9 tier."),
137 "/cells/0/overall_percentage" = tol(100 * counts["X", "L"] / total,
138 "Cell / grand total in percent units; owner 1e-9 tier.")
139 )
140 emit("STAT-DESC-TABCAT-001", "Two-way counts and all percentage denominators",
141 "DESC_TABULATION_01", list(kind = "categorical", row_column = "row",
142 column_column = "column", row_percentages = TRUE, column_percentages = TRUE,
143 overall_percentages = TRUE, include_margins = TRUE), out,
144 c("Cells are ordered by observed X,Y and L,R labels; percentage outputs are in percent units (100 times the cell fraction)."),
145 version = "2.0.0")
One-way table without margins
Case STAT-DESC-TABCAT-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::quantile and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_tabulation.R · sha256 bb74c4a5af397aaa
- Dataset
- reference_data/datasets/DESC_TABULATION_01.json
Settings compared
include_margins= falsekind= "categorical"row_column= "row"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/valid_n | exact | 10 | 10 | 0.00E+2 | passed | |
/cells/0/count | exact | 5 | 5 | 0.00E+2 | passed | |
/cells/0/row_percentage | absent | None | passed | |||
/cells/0/column_percentage | absent | None | passed |
Convention
- The one-way table counts each observed category once and omits margins.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
147 out <- list(
148 "/valid_n" = exact(nrow(d), "Every row has a row category."),
149 "/cells/0/count" = exact(sum(d$row == "X"), "One-way X count is exact."),
150 "/cells/0/row_percentage" = absent("Row percentages are disabled."),
151 "/cells/0/column_percentage" = absent("Column percentages are disabled.")
152 )
153 emit("STAT-DESC-TABCAT-002", "One-way table without margins", "DESC_TABULATION_01",
154 list(kind = "categorical", row_column = "row", include_margins = FALSE), out,
155 c("The one-way table counts each observed category once and omits margins."))
Ungrouped numeric summaries
Case STAT-DESC-TABNUM-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::quantile and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_tabulation.R · sha256 bb74c4a5af397aaa
- Dataset
- reference_data/datasets/DESC_TABULATION_01.json
Settings compared
kind= "numeric"value_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/valid_n | exact | 9 | 9 | 0.00E+2 | passed | |
/numeric_summaries/0/mean | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/numeric_summaries/0/median | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/numeric_summaries/0/first_quartile | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/numeric_summaries/0/third_quartile | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/numeric_summaries/0/standard_deviation | tolerance | 2.7386127875258306 | 2.7386127875258306 | 5.85E-18 | 17 | passed |
/numeric_summaries/0/standard_error | tolerance | 0.9128709291752769 | 0.9128709291752769 | 1.72E-18 | 17 | passed |
/numeric_summaries/0/confidence_lower | tolerance | 2.894915862414142 | 2.8949158624141424 | 4.49E-16 | 15 | passed |
/numeric_summaries/0/confidence_upper | tolerance | 7.1050841375858589 | 7.105084137585857 | 1.79E-15 | 15 | passed |
/source_count | exact | 10 | 10 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Manual chapter 29 lines 24-38: sample SD, type-7 quantiles and two-sided t interval.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
74 out <- summary_outputs(d$value)
75 out[["/source_count"]] <- exact(nrow(d), "All ten source rows are counted.")
76 out[["/missing_count"]] <- exact(sum(is.na(d$value)), "One response is missing.")
77 emit("STAT-DESC-TABNUM-001", "Ungrouped numeric summaries", "DESC_TABULATION_01",
78 list(kind = "numeric", value_column = "value"), out,
79 c("Manual chapter 29 lines 24-38: sample SD, type-7 quantiles and two-sided t interval."))
Two ordered groups
Case STAT-DESC-TABNUM-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::quantile and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_tabulation.R · sha256 bb74c4a5af397aaa
- Dataset
- reference_data/datasets/DESC_TABULATION_01.json
Settings compared
group_columns= ["group"]kind= "numeric"value_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/valid_n | exact | 5 | 5 | 0.00E+2 | passed | |
/numeric_summaries/0/mean | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/numeric_summaries/0/median | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/numeric_summaries/0/first_quartile | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/numeric_summaries/0/third_quartile | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/numeric_summaries/0/standard_deviation | tolerance | 1.5811388300841898 | 1.5811388300841898 | 3.86E-17 | 16 | passed |
/numeric_summaries/0/standard_error | tolerance | 0.70710678118654757 | 0.7071067811865476 | 2.74E-18 | 17 | passed |
/numeric_summaries/0/confidence_lower | tolerance | 1.0367568385224428 | 1.0367568385224428 | 2.51E-17 | 16 | passed |
/numeric_summaries/0/confidence_upper | tolerance | 4.963243161477557 | 4.963243161477557 | 4.72E-17 | 17 | passed |
/numeric_summaries/1/mean | tolerance | 7.5 | 7.5 | 0.00E+1 | passed | |
/numeric_summaries/1/missing_n | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Group labels are A then B in the manual's sorted string order.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
81 out <- summary_outputs(d$value[d$group == "A"])
82 out[["/numeric_summaries/1/mean"]] <- tol(mean(d$value[d$group == "B"], na.rm = TRUE),
83 "Second group mean; owner 1e-9 tier.")
84 out[["/numeric_summaries/1/missing_n"]] <- exact(1L, "The B group has one missing response.")
85 emit("STAT-DESC-TABNUM-002", "Two ordered groups", "DESC_TABULATION_01",
86 list(kind = "numeric", value_column = "value", group_columns = list("group")), out,
87 c("Group labels are A then B in the manual's sorted string order."))
Frequency-weighted order statistics
Case STAT-DESC-TABNUM-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::quantile and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_tabulation.R · sha256 bb74c4a5af397aaa
- Dataset
- reference_data/datasets/DESC_TABULATION_01.json
Settings compared
frequency_column= "frequency"kind= "numeric"value_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/valid_n | exact | 13 | 13 | 0.00E+2 | passed | |
/numeric_summaries/0/mean | tolerance | 5.6923076923076925 | 5.6923076923076925 | 1.27E-17 | 17 | passed |
/numeric_summaries/0/median | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/numeric_summaries/0/first_quartile | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/numeric_summaries/0/third_quartile | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/numeric_summaries/0/standard_deviation | tolerance | 2.8102376941169758 | 2.8102376941169758 | 2.93E-17 | 16 | passed |
/numeric_summaries/0/standard_error | tolerance | 0.77941970018311102 | 0.779419700183111 | 5.80E-19 | 18 | passed |
/numeric_summaries/0/confidence_lower | tolerance | 3.9940980498533456 | 3.9940980498533456 | 1.32E-20 | 20 | passed |
/numeric_summaries/0/confidence_upper | tolerance | 7.3905173347620394 | 7.390517334762039 | 2.53E-17 | 17 | passed |
/numeric_summaries/0/count | exact | 10 | 10 | 0.00E+2 | passed |
Convention
- Manual chapter 29 lines 28-36: integer frequencies are replication counts; zero-frequency rows remain in source count.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
89 replicated <- rep(d$value[!is.na(d$value)], d$frequency[!is.na(d$value)])
90 out <- summary_outputs(replicated)
91 out[["/numeric_summaries/0/count"]] <- exact(nrow(d), "Source rows include zero-frequency and missing rows.")
92 emit("STAT-DESC-TABNUM-003", "Frequency-weighted order statistics", "DESC_TABULATION_01",
93 list(kind = "numeric", value_column = "value", frequency_column = "frequency"), out,
94 c("Manual chapter 29 lines 28-36: integer frequencies are replication counts; zero-frequency rows remain in source count."))
Explicit row exclusions and missingness
Case STAT-DESC-TABNUM-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::quantile and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_tabulation.R · sha256 bb74c4a5af397aaa
- Dataset
- reference_data/datasets/DESC_TABULATION_01.json
Settings compared
kind= "numeric"value_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/valid_n | exact | 8 | 8 | 0.00E+2 | passed | |
/numeric_summaries/0/mean | tolerance | 5.375 | 5.375 | 0.00E-1 | passed | |
/numeric_summaries/0/median | tolerance | 5.5 | 5.5 | 0.00E+1 | passed | |
/numeric_summaries/0/first_quartile | tolerance | 3.75 | 3.75 | 0.00E+0 | passed | |
/numeric_summaries/0/third_quartile | tolerance | 7.25 | 7.25 | 0.00E+0 | passed | |
/numeric_summaries/0/standard_deviation | tolerance | 2.6692695630078278 | 2.669269563007828 | 5.73E-18 | 17 | passed |
/numeric_summaries/0/standard_error | tolerance | 0.94372930440884362 | 0.9437293044088436 | 3.31E-18 | 17 | passed |
/numeric_summaries/0/confidence_lower | tolerance | 3.1434347998560597 | 3.1434347998560597 | 3.07E-17 | 17 | passed |
/numeric_summaries/0/confidence_upper | tolerance | 7.6065652001439394 | 7.60656520014394 | 9.31E-16 | 15 | passed |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Excluded rows are zero-based positions 1 and 8 and contribute to neither valid nor missing N.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
96 retained <- d[-c(2, 9), ]
97 out <- summary_outputs(retained$value)
98 out[["/excluded_count"]] <- exact(2L, "Two zero-based source row indexes are excluded.")
99 out[["/missing_count"]] <- exact(0L, "The only missing response is excluded.")
100 emit("STAT-DESC-TABNUM-004", "Explicit row exclusions and missingness", "DESC_TABULATION_01",
101 list(kind = "numeric", value_column = "value"), out,
102 c("Excluded rows are zero-based positions 1 and 8 and contribute to neither valid nor missing N."),
103 kind = "missing_excluded", excluded = list(1L, 8L))
One valid value
Case STAT-DESC-TABNUM-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::quantile and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_tabulation.R · sha256 bb74c4a5af397aaa
- Dataset
- reference_data/datasets/DESC_TABULATION_ONE.json
Settings compared
kind= "numeric"value_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/valid_n | exact | 1 | 1 | 0.00E+2 | passed | |
/numeric_summaries/0/mean | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/numeric_summaries/0/median | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/numeric_summaries/0/first_quartile | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/numeric_summaries/0/third_quartile | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/numeric_summaries/0/standard_deviation | absent | None | passed | |||
/numeric_summaries/0/confidence_lower | absent | None | passed |
Convention
- For n=1, the mean and quantiles are seven; sample SD and t interval are unavailable.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
105 one <- data.frame(value = 7)
106 export_dataset(one, "DESC_TABULATION_ONE", "Constructed one-row boundary",
107 "R stats::quantile documentation", "Constructed validation data; no third-party license.",
108 c(value = "Float64"))
109 one <- read_dataset("DESC_TABULATION_ONE")
110 emit("STAT-DESC-TABNUM-005", "One valid value", "DESC_TABULATION_ONE",
111 list(kind = "numeric", value_column = "value"), summary_outputs(one$value),
112 c("For n=1, the mean and quantiles are seven; sample SD and t interval are unavailable."),
113 kind = "boundary")
Large offset and small spread
Case STAT-DESC-TABNUM-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::quantile and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/descriptives_tabulation.R · sha256 bb74c4a5af397aaa
- Dataset
- reference_data/datasets/DESC_TABULATION_OFFSET.json
Settings compared
kind= "numeric"value_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/valid_n | exact | 7 | 7 | 0.00E+2 | passed | |
/numeric_summaries/0/mean | tolerance | 1000000000 | 1000000000.0 | 0.00E+2 | passed | |
/numeric_summaries/0/median | tolerance | 1000000000 | 1000000000.0 | 0.00E+2 | passed | |
/numeric_summaries/0/first_quartile | tolerance | 999999998.5 | 999999998.5 | 0.00E+1 | passed | |
/numeric_summaries/0/third_quartile | tolerance | 1000000001.5 | 1000000001.5 | 0.00E+1 | passed | |
/numeric_summaries/0/standard_deviation | tolerance | 2.1602468994692869 | 2.160246899469287 | 4.08E-17 | 16 | passed |
/numeric_summaries/0/standard_error | tolerance | 0.81649658092772603 | 0.816496580927726 | 4.46E-18 | 17 | passed |
/numeric_summaries/0/confidence_lower | tolerance | 999999998.002105 | 999999998.0021049 | 1.22E-7 | 15 | passed |
/numeric_summaries/0/confidence_upper | tolerance | 1000000001.9978952 | 1000000001.9978951 | 7.84E-8 | 16 | passed |
Convention
- Seven values lie at 1e9 plus -3,-2,-1,0,1,2,3; mean is 1e9 and sample SD is sqrt(28/6).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
115 hard <- data.frame(value = 1e9 + c(-3, -2, -1, 0, 1, 2, 3))
116 export_dataset(hard, "DESC_TABULATION_OFFSET", "Constructed large-offset small-spread values",
117 "R stats::sd and stats::quantile documentation",
118 "Constructed validation data; no third-party license.", c(value = "Float64"))
119 hard <- read_dataset("DESC_TABULATION_OFFSET")
120 emit("STAT-DESC-TABNUM-006", "Large offset and small spread", "DESC_TABULATION_OFFSET",
121 list(kind = "numeric", value_column = "value"), summary_outputs(hard$value),
122 c("Seven values lie at 1e9 plus -3,-2,-1,0,1,2,3; mean is 1e9 and sample SD is sqrt(28/6)."),
123 kind = "hard_numeric")
Existing-table factorial with two-factor interactions
Case STAT-DOE-ANALYZE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_FACTORIAL.json
Settings compared
design= {"factors": [{"name": "A", "low": 10, "high": 20}, {"name": "B", "low": 1, "high": 3}, {"name": "C", "low": 100, "high": 200}], "response_name": "y", "model": "interactions"}response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/payload/terms/[term=A]/coefficient | tolerance | 4.3618499999999987 | 4.361849999999993 | 5.36E-15 | 14 | passed |
/payload/terms/[term=A]/effect | tolerance | 8.7236999999999973 | 8.723699999999987 | 1.06E-14 | 14 | passed |
/payload/terms/[term=A]/std_error | tolerance | 0.21257342787748321 | 0.21257342787748265 | 5.59E-16 | 14 | passed |
/payload/terms/[term=A]/p_value | tail_probability | 7.2415658667940198e-09 | 7.241565866793926e-09 | 9.34E-23 | 13 | passed |
/payload/terms/[term=B]/coefficient | tolerance | -2.5754375000000018 | -2.575437500000006 | 4.02E-15 | 14 | passed |
/payload/terms/[term=B]/effect | tolerance | -5.1508750000000036 | -5.150875000000012 | 8.04E-15 | 14 | passed |
/payload/terms/[term=B]/std_error | tolerance | 0.21257342787748321 | 0.21257342787748265 | 5.59E-16 | 14 | passed |
/payload/terms/[term=B]/p_value | tail_probability | 7.0961603671585962e-07 | 7.096160367158331e-07 | 2.65E-20 | 13 | passed |
/payload/terms/[term=C]/coefficient | tolerance | 0.94152499999999872 | 0.9415249999999962 | 2.55E-15 | 14 | passed |
/payload/terms/[term=C]/effect | tolerance | 1.8830499999999974 | 1.8830499999999923 | 5.06E-15 | 14 | passed |
/payload/terms/[term=C]/std_error | tolerance | 0.21257342787748326 | 0.21257342787748265 | 6.09E-16 | 14 | passed |
/payload/terms/[term=C]/p_value | tail_probability | 0.0016491235207918217 | 0.001649123520791821 | 6.22E-19 | 15 | passed |
/payload/terms/[term=A x B]/coefficient | tolerance | 1.8083125000000007 | 1.8083125000000047 | 3.95E-15 | 14 | passed |
/payload/terms/[term=A x B]/effect | tolerance | 3.6166250000000013 | 3.6166250000000093 | 8.00E-15 | 14 | passed |
/payload/terms/[term=A x B]/std_error | tolerance | 0.21257342787748321 | 0.21257342787748265 | 5.59E-16 | 14 | passed |
/payload/terms/[term=A x B]/p_value | tail_probability | 1.3506812233571844e-05 | 1.3506812233571331e-05 | 5.13E-19 | 13 | passed |
/payload/terms/[term=A x C]/coefficient | tolerance | 0.26557500000000067 | 0.2655750000000052 | 4.55E-15 | 13 | passed |
/payload/terms/[term=A x C]/effect | tolerance | 0.53115000000000134 | 0.5311500000000104 | 9.11E-15 | 13 | passed |
/payload/terms/[term=A x C]/std_error | tolerance | 0.21257342787748321 | 0.21257342787748265 | 5.59E-16 | 14 | passed |
/payload/terms/[term=A x C]/p_value | tail_probability | 0.24305685433021298 | 0.2430568543302043 | 8.68E-15 | 13 | passed |
/payload/terms/[term=B x C]/coefficient | tolerance | -0.15436249999999851 | -0.15436249999999618 | 2.33E-15 | 13 | passed |
/payload/terms/[term=B x C]/effect | tolerance | -0.30872499999999703 | -0.30872499999999237 | 4.66E-15 | 13 | passed |
/payload/terms/[term=B x C]/std_error | tolerance | 0.21257342787748321 | 0.21257342787748265 | 5.59E-16 | 14 | passed |
/payload/terms/[term=B x C]/p_value | tail_probability | 0.48619478722799747 | 0.4861947872280026 | 5.11E-15 | 13 | passed |
/payload/terms/[term=A]/lower_ci | tolerance | 3.8809754975063826 | 3.8809754975063786 | 4.00E-15 | 14 | passed |
/payload/terms/[term=A]/upper_ci | tolerance | 4.8427245024936152 | 4.842724502493608 | 7.11E-15 | 14 | passed |
Convention
- lm(y ~ (a + b + c)^2) on factors coded to -1/+1 from the declared Low/High (line 33-34).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
102 map <- c(a = "A", b = "B", c = "C", "a:b" = "A x B", "a:c" = "A x C", "b:c" = "B x C")
103 existing <- list(factors = list(list(name = "A", low = 10, high = 20), list(name = "B", low = 1, high = 3), list(name = "C", low = 100, high = 200)),
104 response_name = "y", model = "interactions")
105 emit("STAT-DOE-ANALYZE-001", "tabelz.analysis.doe_advanced:analyze_catalog_design", "Existing-table factorial with two-factor interactions", "DOE_FACTORIAL",
106 list(response = "y", design = existing),
107 c(term_out("/payload/terms/", map, " x "),
108 list("/payload/terms/[term=A]/lower_ci" = tol(ci["a", 1], "t interval lower limit."),
109 "/payload/terms/[term=A]/upper_ci" = tol(ci["a", 2], "t interval upper limit."))),
110 c("lm(y ~ (a + b + c)^2) on factors coded to -1/+1 from the declared Low/High (line 33-34)."))
Main-effects model at 90% confidence
Case STAT-DOE-ANALYZE-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_FACTORIAL.json
Settings compared
confidence_level= 0.9design= {"factors": [{"name": "A", "low": 10, "high": 20}, {"name": "B", "low": 1, "high": 3}, {"name": "C", "low": 100, "high": 200}], "response_name": "y", "model": "main_effects"}response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/payload/terms/[term=B]/coefficient | tolerance | -2.5754375000000014 | -2.5754375000000054 | 3.98E-15 | 14 | passed |
/payload/terms/[term=B]/lower_ci | tolerance | -3.5745575413773891 | -3.5745575413773913 | 2.25E-15 | 15 | passed |
Convention
- model = main_effects.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
111 fit3 <- lm(y ~ a + b + c, data = d); s3 <- summary(fit3)$coefficients
112 emit("STAT-DOE-ANALYZE-002", "tabelz.analysis.doe_advanced:analyze_catalog_design", "Main-effects model at 90% confidence", "DOE_FACTORIAL",
113 list(response = "y", design = modifyList(existing, list(model = "main_effects")), confidence_level = 0.9),
114 list("/payload/terms/[term=B]/coefficient" = tol(s3["b", 1], "Main-effects coefficient."),
115 "/payload/terms/[term=B]/lower_ci" = tol(confint(fit3, level = 0.9)["b", 1], "90% t interval.")),
116 c("model = main_effects."), kind = "axis_coverage")
Append two centre points
Case STAT-DOE-AUGMENT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_AUGMENT.json
Settings compared
center_count= 2design= {"family": "full_factorial", "factors": [{"name": "X", "low": 0, "high": 10}, {"name": "Y", "low": 50, "high": 70}], "response_name": "y"}kind= "center"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/added_runs | exact | 2 | 2 | 0.00E+2 | passed | |
/frame/4/X | tolerance | 5 | 5 | 0.00E+2 | passed | |
/frame/5/Y | tolerance | 60 | 60 | 0.00E+2 | passed | |
/frame/0/y | tolerance | 3.1000000000000001 | 3.1 | 1.12E-17 | 17 | passed |
Convention
- Centre points sit at each factor's midpoint (line 156-157).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
195 aug <- data.frame(RunOrder = 1:4, StdOrder = 1:4, Block = rep(1L, 4), PointType = rep("Factorial", 4),
196 X = c(0, 10, 0, 10), Y = c(50, 50, 70, 70), y = c(3.1, 4.2, 3.9, 5.3))
197 export_dataset(aug, "DOE_AUGMENT", "Constructed executed 2^2 run sheet with bookkeeping columns", "Hand-constructed",
198 "Constructed validation data; no third-party license.",
199 c(RunOrder = "Int64", StdOrder = "Int64", Block = "Int64", PointType = "String", X = "Float64", Y = "Float64", y = "Float64"))
200 aug_design <- list(family = "full_factorial", factors = list(list(name = "X", low = 0, high = 10), list(name = "Y", low = 50, high = 70)),
201 response_name = "y")
202 emit("STAT-DOE-AUGMENT-001", "tabelz.analysis.doe_augmentation:plan_design_augmentation", "Append two centre points", "DOE_AUGMENT",
203 list(design = aug_design, kind = "center", center_count = 2L),
204 list("/added_runs" = exact(2L, "Two appended centre runs."),
205 "/frame/4/X" = tol(5, "Centre of X."), "/frame/5/Y" = tol(60, "Centre of Y."),
206 "/frame/0/y" = tol(3.1, "The original runs and responses are unchanged (line 148-151).")),
207 c("Centre points sit at each factor's midpoint (line 156-157)."), kind = "nominal")
Zero centre points is an explicit no-op
Case STAT-DOE-AUGMENT-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_AUGMENT.json
Settings compared
center_count= 0design= {"family": "full_factorial", "factors": [{"name": "X", "low": 0, "high": 10}, {"name": "Y", "low": 50, "high": 70}], "response_name": "y"}kind= "center"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/no_op | exact | True | True | passed |
Convention
- Nothing is appended.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
208 emit("STAT-DOE-AUGMENT-002", "tabelz.analysis.doe_augmentation:plan_design_augmentation", "Zero centre points is an explicit no-op", "DOE_AUGMENT",
209 list(design = aug_design, kind = "center", center_count = 0L),
210 list("/no_op" = exact(TRUE, "Line 157-158: requesting zero centre points is an explicit no-op.")),
211 c("Nothing is appended."), kind = "boundary")
Binary response with a logit link
Case STAT-DOE-BINARY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_BINARY.json
Settings compared
design= {"factors": [{"name": "A", "low": 10, "high": 20}, {"name": "B", "low": 1, "high": 3}, {"name": "C", "low": 100, "high": 200}], "response_name": "event", "model": "main_effects", "response_kind": "binary"}response= "event"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/payload/terms/[term=A]/coefficient | tolerance | 0.4577116260224815 | 0.4577116260224813 | 2.23E-16 | 15 | passed |
/payload/terms/[term=A]/std_error | tolerance | 0.34732638407322153 | 0.34732638407954464 | 6.32E-12 | 10 | passed |
/payload/terms/[term=A]/p_value | tail_probability | 0.18756586759996616 | 0.18756586760799931 | 8.03E-12 | 10 | passed |
/payload/terms/[term=B]/coefficient | tolerance | -0.87228630644909266 | -0.8722863064490921 | 5.52E-16 | 15 | passed |
/payload/terms/[term=B]/std_error | tolerance | 0.36118579728702643 | 0.3611857972960321 | 9.01E-12 | 10 | passed |
/payload/terms/[term=B]/p_value | tail_probability | 0.015732506050048726 | 0.01573250605264975 | 2.60E-12 | 9 | passed |
/payload/terms/[term=C]/coefficient | tolerance | 0.87228630644909277 | 0.8722863064490924 | 3.29E-16 | 15 | passed |
/payload/terms/[term=C]/std_error | tolerance | 0.36118579728702643 | 0.36118579729603223 | 9.01E-12 | 10 | passed |
/payload/terms/[term=C]/p_value | tail_probability | 0.015732506050048705 | 0.01573250605264975 | 2.60E-12 | 9 | passed |
Convention
- glm(binomial) with epsilon 1e-14; one trial per run (line 110-111).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
142 emit("STAT-DOE-BINARY-001", "tabelz.analysis.doe_binomial:analyze_doe_binomial", "Binary response with a logit link", "DOE_BINARY",
143 list(response = "event", design = modifyList(existing, list(response_name = "event", model = "main_effects", response_kind = "binary"))),
144 bin_out, c("glm(binomial) with epsilon 1e-14; one trial per run (line 110-111)."))
Binary response with a probit link
Case STAT-DOE-BINARY-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_BINARY.json
Settings compared
design= {"factors": [{"name": "A", "low": 10, "high": 20}, {"name": "B", "low": 1, "high": 3}, {"name": "C", "low": 100, "high": 200}], "response_name": "event", "model": "main_effects", "response_kind": "binary", "link": "probit"}response= "event"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/payload/terms/[term=A]/coefficient | tolerance | 0.29971031813744137 | 0.2997103218836433 | 3.75E-9 | 7 | passed |
Convention
- Explicit probit link (line 113-114).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
145 gp <- glm(event ~ a + b + c, family = binomial(link = "probit"), data = b, control = glm.control(epsilon = 1e-14, maxit = 100))
146 emit("STAT-DOE-BINARY-002", "tabelz.analysis.doe_binomial:analyze_doe_binomial", "Binary response with a probit link", "DOE_BINARY",
147 list(response = "event", design = modifyList(existing, list(response_name = "event", model = "main_effects", response_kind = "binary", link = "probit"))),
148 list("/payload/terms/[term=A]/coefficient" = tol(coef(gp)[["a"]], "Probit coefficient.", "1e-6")),
149 c("Explicit probit link (line 113-114)."), kind = "axis_coverage")
Catalog full factorial with two centre points
Case STAT-DOE-CATALOG-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- None
Settings compared
center_points= 2factors= [{"name": "X", "low": 0, "high": 10}, {"name": "Y", "low": 50, "high": 70}]family= "full_factorial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 6 | 6 | 0.00E+2 | passed | |
/design_points | sequence | ['0|50', '0|70', '10|50', '10|70', '5|60', '5|60'] | ['0|50', '0|70', '10|50', '10|70', '5|60', '5|60'] | passed |
Convention
- Catalog family full_factorial.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
63 catalog <- "tabelz.analysis.doe_designs:generate_catalog_design"
64 emit("STAT-DOE-CATALOG-001", catalog, "Catalog full factorial with two centre points", NULL,
65 list(family = "full_factorial", factors = list(list(name = "X", low = 0, high = 10), list(name = "Y", low = 50, high = 70)), center_points = 2L),
66 list("/runs" = exact(6L, "4 corners + 2 centres."),
67 "/design_points" = points_of(rbind(corners(c(0, 50), c(10, 70)), c(5, 60), c(5, 60)))), c("Catalog family full_factorial."))
Face-centred central composite for two factors
Case STAT-DOE-CATALOG-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- None
Settings compared
axial_type= "face_centered"center_points= 3factors= [{"name": "X", "low": -1, "high": 1}, {"name": "Y", "low": -1, "high": 1}]family= "central_composite"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 11 | 11 | 0.00E+2 | passed | |
/design_points | sequence | ['-1|-1', '-1|0', '-1|1', '0|-1', '0|0', '0|0', '0|0', '0|1' | ['-1|-1', '-1|0', '-1|1', '0|-1', '0|0', '0|0', '0|0', '0|1' | passed |
Convention
- Face-centred axial points sit at +/-1 on one factor with the other at 0.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
68 face <- rbind(corners(c(-1, -1), c(1, 1)), c(-1, 0), c(1, 0), c(0, -1), c(0, 1), c(0, 0), c(0, 0), c(0, 0))
69 emit("STAT-DOE-CATALOG-002", catalog, "Face-centred central composite for two factors", NULL,
70 list(family = "central_composite", factors = list(list(name = "X", low = -1, high = 1), list(name = "Y", low = -1, high = 1)),
71 center_points = 3L, axial_type = "face_centered"),
72 list("/runs" = exact(11L, "4 corners + 4 face points + 3 centres."), "/design_points" = points_of(face)),
73 c("Face-centred axial points sit at +/-1 on one factor with the other at 0."), kind = "axis_coverage")
Full 2^3 factorial with two replicates and three centre points
Case STAT-DOE-CREATE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- None
Settings compared
center_points= 3factors= [{"name": "A", "low": 10, "high": 20}, {"name": "B", "low": 1, "high": 3}, {"name": "C", "low": 100, "high": 200}]replicates= 2seed= 7
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 19 | 19 | 0.00E+2 | passed | |
/design_points | sequence | ['10|1|100', '10|1|100', '10|1|200', '10|1|200', '10|3|100', | ['10|1|100', '10|1|100', '10|1|200', '10|1|200', '10|3|100', | passed |
Convention
- Each corner appears twice; centres sit at each factor's midpoint.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
48 create <- "tabelz.analysis.doe:create_factorial_design"
49 lows <- c(10, 1, 100); highs <- c(20, 3, 200)
50 pts <- rbind(corners(lows, highs), corners(lows, highs), matrix(rep((lows + highs) / 2, 3), 3, byrow = TRUE))
51 emit("STAT-DOE-CREATE-001", create, "Full 2^3 factorial with two replicates and three centre points", NULL,
52 list(factors = list(list(name = "A", low = 10, high = 20), list(name = "B", low = 1, high = 3), list(name = "C", low = 100, high = 200)),
53 replicates = 2L, center_points = 3L, seed = 7L),
54 list("/runs" = exact(19L, "8 corners x 2 replicates + 3 centres."), "/design_points" = points_of(pts)),
55 c("Each corner appears twice; centres sit at each factor's midpoint."))
The smallest design: two factors, one replicate
Case STAT-DOE-CREATE-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- None
Settings compared
factors= [{"name": "A", "low": 0, "high": 1}, {"name": "B", "low": -5, "high": 5}]randomize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 4 | 4 | 0.00E+2 | passed | |
/design_points | sequence | ['0|-5', '0|5', '1|-5', '1|5'] | ['0|-5', '0|5', '1|-5', '1|5'] | passed |
Convention
- Randomization off.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
56 emit("STAT-DOE-CREATE-002", create, "The smallest design: two factors, one replicate", NULL,
57 list(factors = list(list(name = "A", low = 0, high = 1), list(name = "B", low = -5, high = 5)), randomize = FALSE),
58 list("/runs" = exact(4L, "Four corners."), "/design_points" = points_of(corners(c(0, -5), c(1, 5)))),
59 c("Randomization off."), kind = "boundary")
A factor with low above high is refused
Case STAT-DOE-CREATE-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- None
Settings compared
factors= [{"name": "A", "low": 5, "high": 1}, {"name": "B", "low": 0, "high": 1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Low and High must be ordered.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
60 emit("STAT-DOE-CREATE-003", create, "A factor with low above high is refused", NULL,
61 list(factors = list(list(name = "A", low = 5, high = 1), list(name = "B", low = 0, high = 1))), list(),
62 c("Low and High must be ordered."), kind = "invalid_input", error = list(error_class = "ValueError", message_contains = "A"))
Legacy factorial analysis with interactions
Case STAT-DOE-LEGACY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_FACTORIAL.json
Settings compared
factors= ["A", "B", "C"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/terms/[term=A]/coefficient | tolerance | 4.3618499999999987 | 4.361849999999993 | 5.36E-15 | 14 | passed |
/terms/[term=A]/effect | tolerance | 8.7236999999999973 | 8.723699999999987 | 1.06E-14 | 14 | passed |
/terms/[term=A]/std_error | tolerance | 0.21257342787748321 | 0.21257342787748265 | 5.59E-16 | 14 | passed |
/terms/[term=A]/p_value | tail_probability | 7.2415658667940198e-09 | 7.241565866793926e-09 | 9.34E-23 | 13 | passed |
/terms/[term=B]/coefficient | tolerance | -2.5754375000000018 | -2.575437500000006 | 4.02E-15 | 14 | passed |
/terms/[term=B]/effect | tolerance | -5.1508750000000036 | -5.150875000000012 | 8.04E-15 | 14 | passed |
/terms/[term=B]/std_error | tolerance | 0.21257342787748321 | 0.21257342787748265 | 5.59E-16 | 14 | passed |
/terms/[term=B]/p_value | tail_probability | 7.0961603671585962e-07 | 7.096160367158331e-07 | 2.65E-20 | 13 | passed |
/terms/[term=C]/coefficient | tolerance | 0.94152499999999872 | 0.9415249999999962 | 2.55E-15 | 14 | passed |
/terms/[term=C]/effect | tolerance | 1.8830499999999974 | 1.8830499999999923 | 5.06E-15 | 14 | passed |
/terms/[term=C]/std_error | tolerance | 0.21257342787748326 | 0.21257342787748265 | 6.09E-16 | 14 | passed |
/terms/[term=C]/p_value | tail_probability | 0.0016491235207918217 | 0.001649123520791821 | 6.22E-19 | 15 | passed |
/terms/[term=A × B]/coefficient | tolerance | 1.8083125000000007 | 1.8083125000000047 | 3.95E-15 | 14 | passed |
/terms/[term=A × B]/effect | tolerance | 3.6166250000000013 | 3.6166250000000093 | 8.00E-15 | 14 | passed |
/terms/[term=A × B]/std_error | tolerance | 0.21257342787748321 | 0.21257342787748265 | 5.59E-16 | 14 | passed |
/terms/[term=A × B]/p_value | tail_probability | 1.3506812233571844e-05 | 1.3506812233571331e-05 | 5.13E-19 | 13 | passed |
Convention
- The legacy analysis codes each factor from its observed minimum and maximum, which here equal the declared levels; interactions are named with a multiplication sign.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
117 legacy_map <- c(a = "A", b = "B", c = "C", "a:b" = "A × B")
118 emit("STAT-DOE-LEGACY-001", "tabelz.analysis.doe:analyze_factorial", "Legacy factorial analysis with interactions", "DOE_FACTORIAL",
119 list(response = "y", factors = list("A", "B", "C")),
120 term_out("/terms/", legacy_map, " × "),
121 c("The legacy analysis codes each factor from its observed minimum and maximum, which here equal the declared levels; interactions are named with a multiplication sign."))
Two maximized responses that both peak at the high corner
Case STAT-DOE-OPT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_FACTORIAL_SHEET.json
Settings compared
design= {"family": "full_factorial", "factors": [{"name": "A", "low": 10, "high": 20}, {"name": "B", "low": 1, "high": 3}, {"name": "C", "low": 100, "high": 200}], "replicates": 2}goals= [{"response": "y2", "goal": "maximize", "weight": 1}, {"response": "y3", "goal": "maximize", "weight": 1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/settings/[factor=A]/value | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/settings/[factor=B]/value | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/settings/[factor=C]/value | tolerance | 200 | 200.0 | 0.00E+2 | passed |
Convention
- Under the interaction model both predictions are multilinear, so their maxima lie at vertices; R confirms the high corner is the best vertex for each, so any weighted geometric desirability of two increasing goals peaks there (line 101-105).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
179 sheet <- read_dataset("DOE_FACTORIAL")
180 export_dataset(data.frame(RunOrder = seq_len(16), StdOrder = seq_len(16), Block = rep(1L, 16), PointType = rep("Factorial", 16),
181 A = sheet$A, B = sheet$B, C = sheet$C, y2 = sheet$y2, y3 = sheet$y3),
182 "DOE_FACTORIAL_SHEET", "DOE_FACTORIAL's responses on a catalog run sheet with bookkeeping columns",
183 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
184 c(RunOrder = "Int64", StdOrder = "Int64", Block = "Int64", PointType = "String", A = "Float64", B = "Float64",
185 C = "Float64", y2 = "Float64", y3 = "Float64"))
186 emit("STAT-DOE-OPT-001", "tabelz.analysis.doe_advanced:optimize_multiple_responses", "Two maximized responses that both peak at the high corner", "DOE_FACTORIAL_SHEET",
187 list(design = cat_design, goals = list(list(response = "y2", goal = "maximize", weight = 1),
188 list(response = "y3", goal = "maximize", weight = 1))),
189 list("/settings/[factor=A]/value" = tol(20, "A at its high level."),
190 "/settings/[factor=B]/value" = tol(3, "B at its high level."),
191 "/settings/[factor=C]/value" = tol(200, "C at its high level.")),
192 c("Under the interaction model both predictions are multilinear, so their maxima lie at vertices; R confirms the high corner is the best vertex for each, so any weighted geometric desirability of two increasing goals peaks there (line 101-105)."),
193 kind = "axis_coverage")
One-sample t power at n = 30
Case STAT-DOE-POWER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
family= "raw_t"mean_difference= 1sample_size= 30solve_for= "power"standard_deviation= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/achieved_power | tolerance | 0.75396471574385138 | 0.75396471574379 | 6.14E-14 | 13 | passed |
Convention
- d = 1 / 2 = 0.5.
Reference code
The lines of the reference script that produce this case's expected values.
48 p30 <- t_power(0.5, 30)
49 emit("STAT-DOE-POWER-001", pw, pmenu, "One-sample t power at n = 30",
50 list(family = "raw_t", solve_for = "power", sample_size = 30L, mean_difference = 1, standard_deviation = 2),
51 list("/achieved_power" = tol(p30, "Two-sided noncentral t power with d = 0.5, ncp = d sqrt(n).")),
52 c("d = 1 / 2 = 0.5."))
One-sample t sample size for 80% power
Case STAT-DOE-POWER-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
family= "raw_t"mean_difference= 1solve_for= "sample_size"standard_deviation= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sample_size | exact | 34 | 34 | 0.00E+2 | passed | |
/achieved_power | tolerance | 0.80777750127944004 | 0.8077775012792738 | 1.66E-13 | 12 | passed |
Convention
- Linear search over n in R.
Reference code
The lines of the reference script that produce this case's expected values.
53 n <- 2L; while (t_power(0.5, n) < 0.8) n <- n + 1L
54 emit("STAT-DOE-POWER-002", pw, pmenu, "One-sample t sample size for 80% power",
55 list(family = "raw_t", solve_for = "sample_size", mean_difference = 1, standard_deviation = 2),
56 list("/sample_size" = exact(n, "Smallest n with power >= 0.8."), "/achieved_power" = tol(t_power(0.5, n), "Power at that n.")),
57 c("Linear search over n in R."), kind = "axis_coverage")
Independent t power with allocation ratio 1.5
Case STAT-DOE-POWER-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
design= "independent"family= "raw_t"mean_difference= 1.2ratio= 1.5sample_size= 20solve_for= "power"standard_deviation= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/achieved_power | tolerance | 0.530648119133181 | 0.5306481191328757 | 3.05E-13 | 12 | passed |
Convention
- Line 34-37.
Reference code
The lines of the reference script that produce this case's expected values.
58 n2 <- ceiling(20 * 1.5)
59 emit("STAT-DOE-POWER-003", pw, pmenu, "Independent t power with allocation ratio 1.5",
60 list(family = "raw_t", solve_for = "power", design = "independent", sample_size = 20L, ratio = 1.5, mean_difference = 1.2, standard_deviation = 2),
61 list("/achieved_power" = tol(t_power(0.6, 20, n2), "Pooled-df noncentral t with n1 = 20, n2 = ceiling(20 x 1.5) = 30.")),
62 c("Line 34-37."), kind = "axis_coverage")
Known-sigma Z power at n = 25
Case STAT-DOE-POWER-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
family= "z"known_sigma= 2mean_difference= 1sample_size= 25solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/achieved_power | tolerance | 0.70541800111380037 | 0.7054180011138003 | 1.06E-16 | 15 | passed |
Convention
- Line 48-49.
Reference code
The lines of the reference script that produce this case's expected values.
63 z <- qnorm(0.975); zp <- pnorm(0.5 * sqrt(25) - z) + pnorm(-0.5 * sqrt(25) - z)
64 emit("STAT-DOE-POWER-004", pw, pmenu, "Known-sigma Z power at n = 25",
65 list(family = "z", solve_for = "power", sample_size = 25L, mean_difference = 1, known_sigma = 2),
66 list("/achieved_power" = tol(zp, "Two-sided normal power.")), c("Line 48-49."), kind = "axis_coverage")
One-way ANOVA power from group means
Case STAT-DOE-POWER-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
family= "raw_anova"group_means= [10, 12, 13]group_sizes= [15, 15, 15]solve_for= "power"standard_deviation= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/achieved_power | tolerance | 0.47253303476050595 | 0.472533034760506 | 6.00E-17 | 15 | passed |
/effect_size | tolerance | 0.41573970964154899 | 0.415739709641549 | 3.44E-18 | 17 | passed |
Convention
- Manual chapter 36 lines 44-45: 'the supplied group sizes determine the weighting and the solve's N is total observations'; N is the entered sample size, 30 by default, and lambda = f^2 N with N - 3 denominator df.
- Corrected before first commit: the first draft took N as the sum of the group sizes, which the quoted line does not say.
Reference code
The lines of the reference script that produce this case's expected values.
78 fp <- ncf_upper(qf(0.95, 2, N - 3), 2, N - 3, f^2 * N)
79 emit("STAT-DOE-POWER-005", pw, pmenu, "One-way ANOVA power from group means",
80 list(family = "raw_anova", solve_for = "power", group_means = list(10, 12, 13), group_sizes = list(15L, 15L, 15L), standard_deviation = 3),
81 list("/achieved_power" = tol(fp, "Noncentral F with lambda = f^2 N, as a Poisson mixture of pbeta tails."), "/effect_size" = tol(f, "Cohen's f.")),
82 c("Manual chapter 36 lines 44-45: 'the supplied group sizes determine the weighting and the solve's N is total observations'; N is the entered sample size, 30 by default, and lambda = f^2 N with N - 3 denominator df.",
83 "Corrected before first commit: the first draft took N as the sum of the group sizes, which the quoted line does not say."),
84 kind = "axis_coverage")
Normal variance test power for a true ratio of 2
Case STAT-DOE-POWER-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
family= "normal_variance"sample_size= 20solve_for= "power"variance_ratio= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/achieved_power | tolerance | 0.62892316361274514 | 0.6289231636127456 | 4.44E-16 | 15 | passed |
Convention
- Line 49-51.
Reference code
The lines of the reference script that produce this case's expected values.
85 nv <- 20; lo <- qchisq(0.025, nv - 1); hi <- qchisq(0.975, nv - 1)
86 vp <- pchisq(lo / 2, nv - 1) + pchisq(hi / 2, nv - 1, lower.tail = FALSE)
87 emit("STAT-DOE-POWER-006", pw, pmenu, "Normal variance test power for a true ratio of 2",
88 list(family = "normal_variance", solve_for = "power", sample_size = 20L, variance_ratio = 2),
89 list("/achieved_power" = tol(vp, "(n-1) s^2 / sigma0^2 ~ ratio x chi2(n - 1) under the alternative.")),
90 c("Line 49-51."), kind = "axis_coverage")
Poisson rate power with an integer cutoff
Case STAT-DOE-POWER-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
alternative= "greater"exposure= 10family= "poisson_rate"null_rate= 0.1poisson_rate= 0.2sample_size= 15solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/achieved_power | tolerance | 0.91943097890502035 | 0.9194309789050202 | 1.15E-16 | 15 | passed |
Convention
- Total exposure 15 x 10; null mean 15, true mean 30, cutoff 23.
Reference code
The lines of the reference script that produce this case's expected values.
91 mu0 <- 0.1 * 10 * 15; mu1 <- 0.2 * 10 * 15
92 cut <- 0L; while (ppois(cut - 1, mu0, lower.tail = FALSE) > 0.05) cut <- cut + 1L
93 emit("STAT-DOE-POWER-007", pw, pmenu, "Poisson rate power with an integer cutoff",
94 list(family = "poisson_rate", solve_for = "power", sample_size = 15L, poisson_rate = 0.2, null_rate = 0.1, exposure = 10, alternative = "greater"),
95 list("/achieved_power" = tol(ppois(cut - 1, mu1, lower.tail = FALSE), "P(X >= c) under the true rate, with c the smallest cutoff whose null tail is at most alpha.")),
96 c(sprintf("Total exposure 15 x 10; null mean %g, true mean %g, cutoff %d.", mu0, mu1, cut)), kind = "axis_coverage")
One-sample proportion power with the arcsine effect
Case STAT-DOE-POWER-008 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
family= "raw_proportion"null_proportion= 0.5proportion= 0.6sample_size= 50solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/achieved_power | tolerance | 0.29628544807964835 | 0.2962854480796482 | 1.66E-16 | 15 | passed |
/effect_size | tolerance | 0.20135792079033066 | 0.20135792079033066 | 2.18E-18 | 16 | passed |
Convention
- Line 40-42.
Reference code
The lines of the reference script that produce this case's expected values.
97 h <- 2 * (asin(sqrt(0.6)) - asin(sqrt(0.5))); prp <- pnorm(abs(h) * sqrt(50) - z) + pnorm(-abs(h) * sqrt(50) - z)
98 emit("STAT-DOE-POWER-008", pw, pmenu, "One-sample proportion power with the arcsine effect",
99 list(family = "raw_proportion", solve_for = "power", sample_size = 50L, proportion = 0.6, null_proportion = 0.5),
100 list("/achieved_power" = tol(prp, "Two-sided normal power for h = 2 (asin sqrt 0.6 - asin sqrt 0.5)."), "/effect_size" = tol(h, "Cohen's h.")),
101 c("Line 40-42."), kind = "axis_coverage")
Paired proportion planning is refused
Case STAT-DOE-POWER-009 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
design= "paired"family= "raw_proportion"null_proportion= 0.5proportion= 0.6solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 23-25: no paired binary covariance model is declared.
Reference code
The lines of the reference script that produce this case's expected values.
102 emit("STAT-DOE-POWER-009", pw, pmenu, "Paired proportion planning is refused",
103 list(family = "raw_proportion", solve_for = "power", design = "paired", proportion = 0.6, null_proportion = 0.5), list(),
104 c("Line 23-25: no paired binary covariance model is declared."), kind = "invalid_input",
105 error = list(error_class = "ValueError", message_contains = "aired"))
POWER-WINDOW 1
Case STAT-DOE-POWER-WINDOW-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
alpha= 0.05delta= 1factors= 3model= "full"replicates= 2sigma= 1solve_for= "power"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_runs | exact | 16 | 16 | 0.00E+2 | passed | |
/corner_runs | exact | 16 | 16 | 0.00E+2 | passed | |
/rank | exact | 8 | 8 | 0.00E+2 | passed | |
/error_df | exact | 8 | 8 | 0.00E+2 | passed | |
/noncentrality | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/critical_t | tolerance | 2.3060041352041662 | 2.306004135204166 | 3.94E-16 | 15 | passed |
/power | tolerance | 0.42105193804890118 | 0.4210519380483821 | 5.19E-13 | 11 | passed |
/solved_replicates | exact | 2 | 2 | 0.00E+2 | passed | |
/target_met | exact | False | False | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:118-155: high-minus-low Delta=2 beta, actual rank, two tails of noncentral t.
- Balanced unblocked 2^3: X'X=N I, effect variance factor=1/N; eta=sqrt(N)/2; R qt and pt. Search returns first feasible replicate count.
- Expected values never use HypoNum output.
Reference code
POWER-WINDOW 2
Case STAT-DOE-POWER-WINDOW-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
alpha= 0.05delta= 1factors= 3model= "main"replicates= 2sigma= 1solve_for= "power"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_runs | exact | 16 | 16 | 0.00E+2 | passed | |
/corner_runs | exact | 16 | 16 | 0.00E+2 | passed | |
/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/error_df | exact | 12 | 12 | 0.00E+2 | passed | |
/noncentrality | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/critical_t | tolerance | 2.1788128296672284 | 2.1788128296672284 | 4.56E-17 | 16 | passed |
/power | tolerance | 0.45219370093637412 | 0.4521937009354807 | 8.93E-13 | 11 | passed |
/solved_replicates | exact | 2 | 2 | 0.00E+2 | passed | |
/target_met | exact | False | False | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:118-155: high-minus-low Delta=2 beta, actual rank, two tails of noncentral t.
- Balanced unblocked 2^3: X'X=N I, effect variance factor=1/N; eta=sqrt(N)/2; R qt and pt. Search returns first feasible replicate count.
- Expected values never use HypoNum output.
Reference code
POWER-WINDOW 3
Case STAT-DOE-POWER-WINDOW-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
alpha= 0.1delta= 1factors= 3model= "full"replicates= 2sigma= 1solve_for= "power"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_runs | exact | 16 | 16 | 0.00E+2 | passed | |
/corner_runs | exact | 16 | 16 | 0.00E+2 | passed | |
/rank | exact | 8 | 8 | 0.00E+2 | passed | |
/error_df | exact | 8 | 8 | 0.00E+2 | passed | |
/noncentrality | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/critical_t | tolerance | 1.8595480375308968 | 1.8595480375308973 | 4.58E-16 | 15 | passed |
/power | tolerance | 0.57274925465387938 | 0.5727492546536681 | 2.11E-13 | 12 | passed |
/solved_replicates | exact | 2 | 2 | 0.00E+2 | passed | |
/target_met | exact | False | False | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:118-155: high-minus-low Delta=2 beta, actual rank, two tails of noncentral t.
- Balanced unblocked 2^3: X'X=N I, effect variance factor=1/N; eta=sqrt(N)/2; R qt and pt. Search returns first feasible replicate count.
- Expected values never use HypoNum output.
Reference code
POWER-WINDOW 4
Case STAT-DOE-POWER-WINDOW-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
alpha= 0.05delta= 1factors= 3model= "full"replicates= 2sigma= 1solve_for= "replicates"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_runs | exact | 40 | 40 | 0.00E+2 | passed | |
/corner_runs | exact | 40 | 40 | 0.00E+2 | passed | |
/rank | exact | 8 | 8 | 0.00E+2 | passed | |
/error_df | exact | 32 | 32 | 0.00E+2 | passed | |
/noncentrality | tolerance | 3.1622776601683795 | 3.162277660168379 | 4.21E-16 | 15 | passed |
/critical_t | tolerance | 2.0369333434601016 | 2.0369333434601016 | 2.47E-17 | 16 | passed |
/power | tolerance | 0.86565966327284527 | 0.8656596632727721 | 7.32E-14 | 13 | passed |
/solved_replicates | exact | 5 | 5 | 0.00E+2 | passed | |
/target_met | exact | True | True | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:118-155: high-minus-low Delta=2 beta, actual rank, two tails of noncentral t.
- Balanced unblocked 2^3: X'X=N I, effect variance factor=1/N; eta=sqrt(N)/2; R qt and pt. Search returns first feasible replicate count.
- Expected values never use HypoNum output.
Reference code
Distribution-free full-range coverage
Case STAT-DOE-PREC-DF-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats analytic formulas
- Citation
- R stats::qt, stats::qnorm, stats::qchisq and stats::pbinom documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/design_precision_planning.R · sha256 bc33fc829853bb1d
- Dataset
- None
Settings compared
confidence= 0.95content= 0.9criterion= "coverage"max_n= 500mode= "distribution_free_tolerance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 46 | 46 | 0.00E+2 | passed | |
/achieved_confidence | tolerance | 0.95199620037551758 | 0.9519962003755176 | 3.88E-18 | 17 | passed |
/previous_n | exact | 45 | 45 | 0.00E+2 | passed |
Convention
- Manual chapter 35: maximum full-range confidence is P(Binomial(n,P)<=n-2), with P=0.9.
Reference code
The lines of the reference script that produce this case's expected values.
92 range_confidence <- stats::pbinom(n - 2L, size = n, prob = content)
93 range_n <- which(range_confidence >= confidence)[1] + 1L
94 stopifnot(!is.na(range_n), range_n >= 3L)
95 emit("STAT-DOE-PREC-DF-001", "Distribution-free full-range coverage",
96 list(mode = "distribution_free_tolerance", criterion = "coverage",
97 confidence = confidence, content = content, max_n = 500L),
98 list("/n" = exact(range_n, "First full-range order-statistic n reaching 95% confidence."),
99 "/achieved_confidence" = tol(range_confidence[range_n - 1L], "P(Binomial(n,P)<=n-2); owner 1e-9 tier."),
100 "/previous_n" = exact(range_n - 1L, "Immediate predecessor has inadequate confidence.")),
101 c("Manual chapter 35: maximum full-range confidence is P(Binomial(n,P)<=n-2), with P=0.9."))
Student-t mean half-width
Case STAT-DOE-PREC-MEAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats analytic formulas
- Citation
- R stats::qt, stats::qnorm, stats::qchisq and stats::pbinom documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/design_precision_planning.R · sha256 bc33fc829853bb1d
- Dataset
- None
Settings compared
assumed_sd= 2.4confidence= 0.95criterion= "absolute"max_n= 500mode= "mean"target= 0.75
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 42 | 42 | 0.00E+2 | passed | |
/achieved_precision | tolerance | 0.7478926490995158 | 0.7478926490995159 | 1.16E-16 | 15 | passed |
/previous_n | exact | 41 | 41 | 0.00E+2 | passed | |
/previous_achieved_precision | tolerance | 0.75753347223507239 | 0.7575334722350722 | 2.21E-16 | 15 | passed |
Convention
- Manual chapter 35: h_n=t_(0.975,n-1)*s0/sqrt(n); search smallest n with h_n<=0.75.
- R verified h_(n-1)>0.75 and h_n<=0.75 with assumed SD 2.4.
Reference code
The lines of the reference script that produce this case's expected values.
45 n <- 2L:500L
46 confidence <- 0.95
47 sd0 <- 2.4
48 mean_half <- stats::qt((1 + confidence) / 2, df = n - 1) * sd0 / sqrt(n)
49 mean_target <- 0.75
50 mean_n <- first(mean_half, mean_target)
51 stopifnot(mean_half[mean_n - 1L] <= mean_target, mean_half[mean_n - 2L] > mean_target)
52 emit("STAT-DOE-PREC-MEAN-001", "Student-t mean half-width",
53 list(mode = "mean", criterion = "absolute", target = mean_target,
54 confidence = confidence, assumed_sd = sd0, max_n = 500L),
55 list("/n" = exact(mean_n, "First integer meeting the Student-t half-width target."),
56 "/achieved_precision" = tol(mean_half[mean_n - 1L], "t_(0.975,n-1)*2.4/sqrt(n); owner 1e-9 tier."),
57 "/previous_n" = exact(mean_n - 1L, "Immediate predecessor does not meet the target."),
58 "/previous_achieved_precision" = tol(mean_half[mean_n - 2L], "Predecessor t half-width; owner 1e-9 tier.")),
59 c("Manual chapter 35: h_n=t_(0.975,n-1)*s0/sqrt(n); search smallest n with h_n<=0.75.",
60 "R verified h_(n-1)>0.75 and h_n<=0.75 with assumed SD 2.4."))
Wilson proportion half-width
Case STAT-DOE-PREC-PROP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats analytic formulas
- Citation
- R stats::qt, stats::qnorm, stats::qchisq and stats::pbinom documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/design_precision_planning.R · sha256 bc33fc829853bb1d
- Dataset
- None
Settings compared
assumed_proportion= 0.35confidence= 0.95criterion= "absolute"max_n= 500mode= "proportion"target= 0.1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 84 | 84 | 0.00E+2 | passed | |
/achieved_precision | tolerance | 0.099959985273674001 | 0.09995998527367402 | 1.42E-17 | 15 | passed |
/previous_n | exact | 83 | 83 | 0.00E+2 | passed |
Convention
- Manual chapter 35: Wilson score half-width uses entered p0=0.35, z=qnorm(0.975), and D=1+z^2/n.
Reference code
The lines of the reference script that produce this case's expected values.
62 p0 <- 0.35
63 z <- stats::qnorm((1 + confidence) / 2)
64 denominator <- 1 + z^2 / n
65 proportion_half <- z / denominator * sqrt(p0 * (1 - p0) / n + z^2 / (4 * n^2))
66 proportion_target <- 0.1
67 proportion_n <- first(proportion_half, proportion_target)
68 emit("STAT-DOE-PREC-PROP-001", "Wilson proportion half-width",
69 list(mode = "proportion", criterion = "absolute", target = proportion_target,
70 confidence = confidence, assumed_proportion = p0, max_n = 500L),
71 list("/n" = exact(proportion_n, "First integer meeting Wilson half-width target."),
72 "/achieved_precision" = tol(proportion_half[proportion_n - 1L], "Wilson half-width at entered p0; owner 1e-9 tier."),
73 "/previous_n" = exact(proportion_n - 1L, "Immediate predecessor misses the target.")),
74 c("Manual chapter 35: Wilson score half-width uses entered p0=0.35, z=qnorm(0.975), and D=1+z^2/n."))
Howe two-sided normal tolerance factor
Case STAT-DOE-PREC-TOL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R tolerance::K.factor 3.0.0, explicit HE2
- Citation
- Howe (1969), equation (2.13); R tolerance 3.0.0 K.factor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/design_precision_planning.R · sha256 bc33fc829853bb1d
- Dataset
- None
Settings compared
assumed_sd= 2.4confidence= 0.95content= 0.9criterion= "factor"max_n= 500mode= "normal_tolerance"sided= "two_sided"target= 2.5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 15 | 15 | 0.00E+2 | passed | |
/achieved_precision | tolerance | 2.4797168012248769 | 2.4797168012248783 | 1.35E-15 | 15 | passed |
/previous_n | exact | 14 | 14 | 0.00E+2 | passed |
Convention
- Howe (1969) equation 2.13; tolerance::K.factor(method='HE2', f=n-1, alpha=1-C, P=content).
- P=0.9 and C=0.95 are separate content and confidence inputs.
Reference code
The lines of the reference script that produce this case's expected values.
11 emit <- function(id, title, config, outputs, notes) {
12 write_expected("design", id, list(
13 schema_version = "2.0.0", case_id = id, outputs = outputs,
14 expected_error = NULL, deferred_outputs = list(), generator_run = run
15 ))
16 write_case("design", id, list(
17 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "design",
18 entry_point = "tabelz.executor.precision_planning",
19 menu_items = list("precisionPlanningMenuItem"), title = title,
20 case_kind = "nominal", dataset = NULL, excluded_rows = list(),
21 configuration = config, "repeat" = 1L,
22 expected = list(path = paste0("reference_data/expected/design/", id, ".json"), sha256 = ""),
23 oracle = list(
24 oracle_class = "independent_implementation",
25 source = if (id == "STAT-DOE-PREC-TOL-001")
26 "R tolerance::K.factor 3.0.0, explicit HE2" else "R stats analytic formulas",
27 citation = if (id == "STAT-DOE-PREC-TOL-001")
28 "Howe (1969), equation (2.13); R tolerance 3.0.0 K.factor documentation" else
29 "R stats::qt, stats::qnorm, stats::qchisq and stats::pbinom documentation",
30 generator = list(path = "generators/r/design_precision_planning.R", sha256 = ""),
31 independent = TRUE,
32 convention_notes = as.list(notes)
33 ), supported = TRUE, unsupported_reason = NULL,
34 requirement_ids = list("REQ-STAT-DOE-001"), risk_ids = list("RISK-REFERENCE-001"),
35 review_reference = NULL
36 ))
Zero-failure binomial demonstration
Case STAT-DOE-RELPLAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
confidence= 0.95mission_time= 1000mode= "binomial"target_reliability= 0.9
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chosen_n | exact | 29 | 29 | 0.00E+2 | passed | |
/achieved_confidence | tolerance | 0.95289871302753759 | 0.9528987130275375 | 1.09E-16 | 15 | passed |
/achieved_criterion | tolerance | 0.047101286972462422 | 0.047101286972462485 | 6.27E-17 | 14 | passed |
Convention
- ceiling(log(0.05) / log(0.9)) = 29.
- Until 2026-09-25 the achieved confidence was compared with the criterion field.
Reference code
The lines of the reference script that produce this case's expected values.
108 rp <- "tabelz.executor.reliability_planning"; rmenu <- "reliabilityPlanningMenuItem"
109 binom_n <- function(R, C, f) { n <- f + 1L; while (pbinom(f, n, 1 - R) > 1 - C) n <- n + 1L; n }
110 n0 <- binom_n(0.9, 0.95, 0)
111 emit("STAT-DOE-RELPLAN-001", rp, rmenu, "Zero-failure binomial demonstration",
112 list(mode = "binomial", target_reliability = 0.9, mission_time = 1000, confidence = 0.95),
113 list("/chosen_n" = exact(n0, "Smallest n with 0.9^n <= 0.05; the manual's worked example gives 29."),
114 "/achieved_confidence" = tol(1 - pbinom(0, n0, 0.1), "Achieved confidence 1 - P(X <= 0) (manual chapter 58)."),
115 "/achieved_criterion" = tol(pbinom(0, n0, 0.1), "Criterion P(X <= 0) at the chosen n.")),
116 c(sprintf("ceiling(log(0.05) / log(0.9)) = %d.", ceiling(log(0.05) / log(0.9))),
117 "Until 2026-09-25 the achieved confidence was compared with the criterion field."))
One allowed failure at 90% confidence
Case STAT-DOE-RELPLAN-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
allowed_failures= 1confidence= 0.9mission_time= 1000mode= "binomial"target_reliability= 0.95
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chosen_n | exact | 77 | 77 | 0.00E+2 | passed |
Convention
- Line 131-132.
Reference code
The lines of the reference script that produce this case's expected values.
118 n1 <- binom_n(0.95, 0.90, 1)
119 emit("STAT-DOE-RELPLAN-002", rp, rmenu, "One allowed failure at 90% confidence",
120 list(mode = "binomial", target_reliability = 0.95, mission_time = 1000, confidence = 0.9, allowed_failures = 1L),
121 list("/chosen_n" = exact(n1, "Smallest n with P(X <= 1) <= 0.10; the manual's worked example gives 77.")),
122 c("Line 131-132."), kind = "axis_coverage")
Duration for ten units with an exponential model
Case STAT-DOE-RELPLAN-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
confidence= 0.95mission_time= 1000mode= "duration"sample_size= 10search_dimension= "test_duration"target_reliability= 0.9
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chosen_test_duration | tolerance | 2843.3158805743419 | 2843.3158805746643 | 3.22E-10 | 12 | passed |
Convention
- Root of the binomial rule: 2843.315881.
Reference code
The lines of the reference script that produce this case's expected values.
123 t_needed <- uniroot(function(t) pbinom(0, 10, 1 - 0.9^(t / 1000)) - 0.05, c(1000, 10000), tol = 1e-12)$root
124 emit("STAT-DOE-RELPLAN-003", rp, rmenu, "Duration for ten units with an exponential model",
125 list(mode = "duration", target_reliability = 0.9, mission_time = 1000, confidence = 0.95, search_dimension = "test_duration", sample_size = 10L),
126 list("/chosen_test_duration" = tol(1000 * log(0.05) / (10 * log(0.9)), "t = t0 ln(1-C) / (n ln R0); the manual gives about 2843 h.")),
127 c(sprintf("Root of the binomial rule: %.10g.", t_needed)), kind = "axis_coverage")
Failure-terminated exponential chi-square rule
Case STAT-DOE-RELPLAN-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
allowed_failures= 1confidence= 0.95mission_time= 1000mode= "duration"sample_size= 10scheme= "failure_terminated"target_reliability= 0.9
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_test_time | tolerance | 45025.069294430679 | 45025.06929443068 | 2.92E-13 | 17 | passed |
Convention
- Line 81-92.
Reference code
The lines of the reference script that produce this case's expected values.
128 theta0 <- -1000 / log(0.9)
129 emit("STAT-DOE-RELPLAN-004", rp, rmenu, "Failure-terminated exponential chi-square rule",
130 list(mode = "duration", target_reliability = 0.9, mission_time = 1000, confidence = 0.95, allowed_failures = 1L,
131 scheme = "failure_terminated", sample_size = 10L),
132 list("/total_test_time" = tol(theta0 / 2 * qchisq(0.95, 4), "theta0 / 2 chi2_(0.95, 4); the manual gives about 45025.")),
133 c("Line 81-92."), kind = "axis_coverage")
A Weibull plan without a shape is refused
Case STAT-DOE-RELPLAN-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats noncentral t, F, chi-square, binomial and Poisson functions
- Citation
- R stats::TDist, stats::FDist, stats::Chisquare, stats::Binomial and stats::Poisson documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_planning.R · sha256 bae913190e25a0a5
- Dataset
- None
Settings compared
confidence= 0.95distribution= "weibull"mission_time= 1000mode= "duration"sample_size= 10search_dimension= "test_duration"target_reliability= 0.9
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 112-113.
Reference code
The lines of the reference script that produce this case's expected values.
134 emit("STAT-DOE-RELPLAN-005", rp, rmenu, "A Weibull plan without a shape is refused",
135 list(mode = "duration", target_reliability = 0.9, mission_time = 1000, confidence = 0.95, distribution = "weibull", sample_size = 10L,
136 search_dimension = "test_duration"), list(),
137 c("Line 112-113."), kind = "invalid_input", error = list(error_class = "ValueError", message_contains = "shape"))
ROBUST-ANALYSIS 1
Case STAT-DOE-ROBUST-ANALYSIS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_ROBUST.json
Settings compared
bootstrap_replicates= 99bootstrap_seed= 11design= {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}], "replicates": 3, "seed": 19}objective= "target"preference_weight= 1.5response_column= "Response"target= 10
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/run_count | exact | 12 | 12 | 0.00E+2 | passed | |
/residual_df | exact | 8 | 8 | 0.00E+2 | passed | |
/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/term_count | exact | 4 | 4 | 0.00E+2 | passed | |
/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/r_squared | tolerance | 0.9545454545454547 | 0.9545454545454546 | 1.14E-16 | 15 | passed |
/coefficients/0/estimate | tolerance | 10.000000000000004 | 10.0 | 4.00E-15 | 15 | passed |
/coefficients/0/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/0/t_value | tolerance | 34.641016151377642 | 34.64101615137755 | 9.28E-14 | 14 | passed |
/coefficients/0/p_value | tolerance | 5.2735611365661297e-10 | 5.273561136566244e-10 | 1.15E-23 | 13 | passed |
/coefficients/0/lower | tolerance | 9.3343139458937472 | 9.334313945893742 | 5.34E-15 | 15 | passed |
/coefficients/0/upper | tolerance | 10.66568605410626 | 10.665686054106258 | 1.86E-15 | 15 | passed |
/coefficients/1/estimate | tolerance | 1.9999999999999993 | 2.0 | 7.00E-16 | 15 | passed |
/coefficients/1/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/1/t_value | tolerance | 6.928203230275523 | 6.92820323027551 | 1.33E-14 | 14 | passed |
/coefficients/1/p_value | tolerance | 0.00012104020555529851 | 0.00012104020555530014 | 1.63E-18 | 13 | passed |
/coefficients/1/lower | tolerance | 1.3343139458937432 | 1.3343139458937423 | 8.96E-16 | 15 | passed |
/coefficients/1/upper | tolerance | 2.6656860541062555 | 2.6656860541062577 | 2.20E-15 | 15 | passed |
/coefficients/2/estimate | tolerance | 2.9999999999999978 | 2.9999999999999996 | 1.76E-15 | 15 | passed |
/coefficients/2/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/2/t_value | tolerance | 10.39230484541328 | 10.392304845413262 | 1.77E-14 | 14 | passed |
/coefficients/2/p_value | tolerance | 6.3640368981107531e-06 | 6.364036898110831e-06 | 7.80E-20 | 13 | passed |
/coefficients/2/lower | tolerance | 2.3343139458937414 | 2.334313945893742 | 4.60E-16 | 15 | passed |
/coefficients/2/upper | tolerance | 3.6656860541062541 | 3.6656860541062573 | 3.15E-15 | 15 | passed |
/coefficients/3/estimate | tolerance | 1.0000000000000011 | 0.9999999999999996 | 1.54E-15 | 14 | passed |
/coefficients/3/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/3/t_value | tolerance | 3.4641016151377668 | 3.464101615137753 | 1.37E-14 | 14 | passed |
/coefficients/3/p_value | tolerance | 0.0085162633709011185 | 0.008516263370901292 | 1.73E-16 | 13 | passed |
/coefficients/3/lower | tolerance | 0.33431394589374486 | 0.33431394589374197 | 2.89E-15 | 14 | passed |
/coefficients/3/upper | tolerance | 1.6656860541062573 | 1.6656860541062573 | 4.77E-17 | 16 | passed |
/settings/0/rank | exact | 1 | 1 | 0.00E+2 | passed | |
/settings/0/controls/0/value | tolerance | -1 | -1.0 | 0.00E+2 | passed | |
/settings/0/mean | tolerance | 8.0000000000000036 | 8.0 | 3.60E-15 | 15 | passed |
/settings/0/noise_variance | tolerance | 3.9999999999999876 | 4.0 | 1.24E-14 | 14 | passed |
/settings/0/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/settings/0/total_sd | tolerance | 2.2360679774997858 | 2.23606797749979 | 4.01E-15 | 14 | passed |
/settings/0/objective | tolerance | 8.999999999999968 | 9.0 | 3.20E-14 | 14 | passed |
/settings/1/rank | exact | 2 | 2 | 0.00E+2 | passed | |
/settings/1/controls/0/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/settings/1/mean | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/settings/1/noise_variance | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/settings/1/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/settings/1/total_sd | tolerance | 4.1231056256176597 | 4.123105625617661 | 8.86E-16 | 15 | passed |
/settings/1/objective | tolerance | 21.000000000000011 | 21.0 | 1.10E-14 | 15 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:14-34: whole-run OLS, declared normalized noise weights and objective formulas.
- R lm(Response~C*Z); confidence intervals use residual t reference. Pointwise bootstrap intervals are deferred, not compared.
- Expected values never use HypoNum output.
Reference code
ROBUST-ANALYSIS 2
Case STAT-DOE-ROBUST-ANALYSIS-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_ROBUST.json
Settings compared
bootstrap_replicates= 99bootstrap_seed= 11design= {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.75, "high_probability": 0.25}], "replicates": 3, "seed": 19}objective= "minimize"preference_weight= 1.5response_column= "Response"target= 10
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/run_count | exact | 12 | 12 | 0.00E+2 | passed | |
/residual_df | exact | 8 | 8 | 0.00E+2 | passed | |
/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/term_count | exact | 4 | 4 | 0.00E+2 | passed | |
/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/r_squared | tolerance | 0.9545454545454547 | 0.9545454545454546 | 1.14E-16 | 15 | passed |
/coefficients/0/estimate | tolerance | 10.000000000000004 | 10.0 | 4.00E-15 | 15 | passed |
/coefficients/0/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/0/t_value | tolerance | 34.641016151377642 | 34.64101615137755 | 9.28E-14 | 14 | passed |
/coefficients/0/p_value | tolerance | 5.2735611365661297e-10 | 5.273561136566244e-10 | 1.15E-23 | 13 | passed |
/coefficients/0/lower | tolerance | 9.3343139458937472 | 9.334313945893742 | 5.34E-15 | 15 | passed |
/coefficients/0/upper | tolerance | 10.66568605410626 | 10.665686054106258 | 1.86E-15 | 15 | passed |
/coefficients/1/estimate | tolerance | 1.9999999999999993 | 2.0 | 7.00E-16 | 15 | passed |
/coefficients/1/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/1/t_value | tolerance | 6.928203230275523 | 6.92820323027551 | 1.33E-14 | 14 | passed |
/coefficients/1/p_value | tolerance | 0.00012104020555529851 | 0.00012104020555530014 | 1.63E-18 | 13 | passed |
/coefficients/1/lower | tolerance | 1.3343139458937432 | 1.3343139458937423 | 8.96E-16 | 15 | passed |
/coefficients/1/upper | tolerance | 2.6656860541062555 | 2.6656860541062577 | 2.20E-15 | 15 | passed |
/coefficients/2/estimate | tolerance | 2.9999999999999978 | 2.9999999999999996 | 1.76E-15 | 15 | passed |
/coefficients/2/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/2/t_value | tolerance | 10.39230484541328 | 10.392304845413262 | 1.77E-14 | 14 | passed |
/coefficients/2/p_value | tolerance | 6.3640368981107531e-06 | 6.364036898110831e-06 | 7.80E-20 | 13 | passed |
/coefficients/2/lower | tolerance | 2.3343139458937414 | 2.334313945893742 | 4.60E-16 | 15 | passed |
/coefficients/2/upper | tolerance | 3.6656860541062541 | 3.6656860541062573 | 3.15E-15 | 15 | passed |
/coefficients/3/estimate | tolerance | 1.0000000000000011 | 0.9999999999999996 | 1.54E-15 | 14 | passed |
/coefficients/3/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/3/t_value | tolerance | 3.4641016151377668 | 3.464101615137753 | 1.37E-14 | 14 | passed |
/coefficients/3/p_value | tolerance | 0.0085162633709011185 | 0.008516263370901292 | 1.73E-16 | 13 | passed |
/coefficients/3/lower | tolerance | 0.33431394589374486 | 0.33431394589374197 | 2.89E-15 | 14 | passed |
/coefficients/3/upper | tolerance | 1.6656860541062573 | 1.6656860541062573 | 4.77E-17 | 16 | passed |
/settings/0/rank | exact | 1 | 1 | 0.00E+2 | passed | |
/settings/0/controls/0/value | tolerance | -1 | -1.0 | 0.00E+2 | passed | |
/settings/0/mean | tolerance | 7.0000000000000044 | 7.0 | 4.40E-15 | 15 | passed |
/settings/0/noise_variance | tolerance | 2.9999999999999907 | 3.0 | 9.30E-15 | 14 | passed |
/settings/0/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/settings/0/total_sd | tolerance | 1.9999999999999964 | 2.0 | 3.60E-15 | 14 | passed |
/settings/0/objective | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/settings/1/rank | exact | 2 | 2 | 0.00E+2 | passed | |
/settings/1/controls/0/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/settings/1/mean | tolerance | 10.000000000000004 | 10.0 | 4.00E-15 | 15 | passed |
/settings/1/noise_variance | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/settings/1/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/settings/1/total_sd | tolerance | 3.6055512754639887 | 3.605551275463989 | 4.25E-16 | 15 | passed |
/settings/1/objective | tolerance | 15.408326913195987 | 15.408326913195983 | 3.53E-15 | 15 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:14-34: whole-run OLS, declared normalized noise weights and objective formulas.
- R lm(Response~C*Z); confidence intervals use residual t reference. Pointwise bootstrap intervals are deferred, not compared.
- Expected values never use HypoNum output.
Reference code
ROBUST-ANALYSIS 3
Case STAT-DOE-ROBUST-ANALYSIS-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_ROBUST.json
Settings compared
bootstrap_replicates= 99bootstrap_seed= 11design= {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}], "replicates": 3, "seed": 19}objective= "maximize"preference_weight= 1.5response_column= "Response"target= 10
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/run_count | exact | 12 | 12 | 0.00E+2 | passed | |
/residual_df | exact | 8 | 8 | 0.00E+2 | passed | |
/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/term_count | exact | 4 | 4 | 0.00E+2 | passed | |
/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/r_squared | tolerance | 0.9545454545454547 | 0.9545454545454546 | 1.14E-16 | 15 | passed |
/coefficients/0/estimate | tolerance | 10.000000000000004 | 10.0 | 4.00E-15 | 15 | passed |
/coefficients/0/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/0/t_value | tolerance | 34.641016151377642 | 34.64101615137755 | 9.28E-14 | 14 | passed |
/coefficients/0/p_value | tolerance | 5.2735611365661297e-10 | 5.273561136566244e-10 | 1.15E-23 | 13 | passed |
/coefficients/0/lower | tolerance | 9.3343139458937472 | 9.334313945893742 | 5.34E-15 | 15 | passed |
/coefficients/0/upper | tolerance | 10.66568605410626 | 10.665686054106258 | 1.86E-15 | 15 | passed |
/coefficients/1/estimate | tolerance | 1.9999999999999993 | 2.0 | 7.00E-16 | 15 | passed |
/coefficients/1/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/1/t_value | tolerance | 6.928203230275523 | 6.92820323027551 | 1.33E-14 | 14 | passed |
/coefficients/1/p_value | tolerance | 0.00012104020555529851 | 0.00012104020555530014 | 1.63E-18 | 13 | passed |
/coefficients/1/lower | tolerance | 1.3343139458937432 | 1.3343139458937423 | 8.96E-16 | 15 | passed |
/coefficients/1/upper | tolerance | 2.6656860541062555 | 2.6656860541062577 | 2.20E-15 | 15 | passed |
/coefficients/2/estimate | tolerance | 2.9999999999999978 | 2.9999999999999996 | 1.76E-15 | 15 | passed |
/coefficients/2/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/2/t_value | tolerance | 10.39230484541328 | 10.392304845413262 | 1.77E-14 | 14 | passed |
/coefficients/2/p_value | tolerance | 6.3640368981107531e-06 | 6.364036898110831e-06 | 7.80E-20 | 13 | passed |
/coefficients/2/lower | tolerance | 2.3343139458937414 | 2.334313945893742 | 4.60E-16 | 15 | passed |
/coefficients/2/upper | tolerance | 3.6656860541062541 | 3.6656860541062573 | 3.15E-15 | 15 | passed |
/coefficients/3/estimate | tolerance | 1.0000000000000011 | 0.9999999999999996 | 1.54E-15 | 14 | passed |
/coefficients/3/std_error | tolerance | 0.2886751345948122 | 0.28867513459481287 | 6.66E-16 | 14 | passed |
/coefficients/3/t_value | tolerance | 3.4641016151377668 | 3.464101615137753 | 1.37E-14 | 14 | passed |
/coefficients/3/p_value | tolerance | 0.0085162633709011185 | 0.008516263370901292 | 1.73E-16 | 13 | passed |
/coefficients/3/lower | tolerance | 0.33431394589374486 | 0.33431394589374197 | 2.89E-15 | 14 | passed |
/coefficients/3/upper | tolerance | 1.6656860541062573 | 1.6656860541062573 | 4.77E-17 | 16 | passed |
/settings/0/rank | exact | 1 | 1 | 0.00E+2 | passed | |
/settings/0/controls/0/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/settings/0/mean | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/settings/0/noise_variance | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/settings/0/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/settings/0/total_sd | tolerance | 4.1231056256176597 | 4.123105625617661 | 8.86E-16 | 15 | passed |
/settings/0/objective | tolerance | 5.815341561573514 | 5.81534156157351 | 4.43E-15 | 15 | passed |
/settings/1/rank | exact | 2 | 2 | 0.00E+2 | passed | |
/settings/1/controls/0/value | tolerance | -1 | -1.0 | 0.00E+2 | passed | |
/settings/1/mean | tolerance | 8.0000000000000036 | 8.0 | 3.60E-15 | 15 | passed |
/settings/1/noise_variance | tolerance | 3.9999999999999876 | 4.0 | 1.24E-14 | 14 | passed |
/settings/1/residual_variance | tolerance | 0.99999999999999523 | 1.0 | 4.77E-15 | 14 | passed |
/settings/1/total_sd | tolerance | 2.2360679774997858 | 2.23606797749979 | 4.01E-15 | 14 | passed |
/settings/1/objective | tolerance | 4.6458980337503251 | 4.645898033750315 | 9.81E-15 | 14 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:14-34: whole-run OLS, declared normalized noise weights and objective formulas.
- R lm(Response~C*Z); confidence intervals use residual t reference. Pointwise bootstrap intervals are deferred, not compared.
- Expected values never use HypoNum output.
Reference code
ROBUST-CONFIRM 1
Case STAT-DOE-ROBUST-CONFIRM-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_CONFIRM.json
Settings compared
analysis= {"design": {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}], "replicates": 3, "seed": 19}, "response_column": "Response", "objective": "target", "target": 10, "preference_weight": 1.5, "bootstrap_replicates": 99, "bootstrap_seed": 11}predicted_mean= 8predicted_objective= 9response_column= "Response"runs_per_condition= 2seed= 23selected= [{"factor": "C", "value": -1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/run_count | exact | 12 | 12 | 0.00E+2 | passed | |
/residual_df | exact | 10 | 10 | 0.00E+2 | passed | |
/mean_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/rmse | tolerance | 0.81649658092772603 | 0.816496580927726 | 4.46E-18 | 17 | passed |
/observed_mean | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/observed_noise_variance | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/observed_residual_variance | tolerance | 0.80000000000000004 | 0.8 | 4.41E-18 | 17 | passed |
/observed_objective | tolerance | 8.8000000000000007 | 8.8 | 1.05E-17 | 17 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:60-64: fresh confirmation errors and observed objective; design data not refitted.
- Condition means and pooled within-condition variance from re-read fresh CSV; descriptive plug-in objective, not unbiased expected loss.
- Expected values never use HypoNum output.
Reference code
ROBUST-CONFIRM 2
Case STAT-DOE-ROBUST-CONFIRM-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_CONFIRM.json
Settings compared
analysis= {"design": {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.75, "high_probability": 0.25}], "replicates": 3, "seed": 19}, "response_column": "Response", "objective": "minimize", "target": 10, "preference_weight": 1.5, "bootstrap_replicates": 99, "bootstrap_seed": 11}predicted_mean= 8predicted_objective= 9response_column= "Response"runs_per_condition= 2seed= 23selected= [{"factor": "C", "value": -1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/run_count | exact | 12 | 12 | 0.00E+2 | passed | |
/residual_df | exact | 10 | 10 | 0.00E+2 | passed | |
/mean_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/rmse | tolerance | 0.81649658092772603 | 0.816496580927726 | 4.46E-18 | 17 | passed |
/observed_mean | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/observed_noise_variance | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/observed_residual_variance | tolerance | 0.80000000000000004 | 0.8 | 4.41E-18 | 17 | passed |
/observed_objective | tolerance | 9.9240383034426891 | 9.92403830344269 | 1.29E-17 | 17 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:60-64: fresh confirmation errors and observed objective; design data not refitted.
- Condition means and pooled within-condition variance from re-read fresh CSV; descriptive plug-in objective, not unbiased expected loss.
- Expected values never use HypoNum output.
Reference code
ROBUST-CONFIRM 3
Case STAT-DOE-ROBUST-CONFIRM-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_CONFIRM.json
Settings compared
analysis= {"design": {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}], "replicates": 3, "seed": 19}, "response_column": "Response", "objective": "maximize", "target": 10, "preference_weight": 1.5, "bootstrap_replicates": 99, "bootstrap_seed": 11}predicted_mean= 8predicted_objective= 9response_column= "Response"runs_per_condition= 2seed= 23selected= [{"factor": "C", "value": -1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/run_count | exact | 12 | 12 | 0.00E+2 | passed | |
/residual_df | exact | 10 | 10 | 0.00E+2 | passed | |
/mean_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/rmse | tolerance | 0.81649658092772603 | 0.816496580927726 | 4.46E-18 | 17 | passed |
/observed_mean | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/observed_noise_variance | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/observed_residual_variance | tolerance | 0.80000000000000004 | 0.8 | 4.41E-18 | 17 | passed |
/observed_objective | tolerance | 4.7136646549690031 | 4.713664654969003 | 9.39E-18 | 17 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:60-64: fresh confirmation errors and observed objective; design data not refitted.
- Condition means and pooled within-condition variance from re-read fresh CSV; descriptive plug-in objective, not unbiased expected loss.
- Expected values never use HypoNum output.
Reference code
ROBUST-GENERATE 1
Case STAT-DOE-ROBUST-GENERATE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand-checkable full crossing and fixed-input arithmetic
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
factors= [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}]replicates= 3seed= 19
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 12 | 12 | 0.00E+2 | passed | |
/design_points | sequence | ['-1|-1', '-1|-1', '-1|-1', '-1|1', '-1|1', '-1|1', '1|-1', | ['-1|-1', '-1|-1', '-1|-1', '-1|1', '-1|1', '-1|1', '1|-1', | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:7-16: every control/noise/signal cell crossed with independent replicates.
- Cartesian product enumerated analytically; randomized run order not compared.
- Expected values never use HypoNum output.
Reference code
ROBUST-GENERATE 2
Case STAT-DOE-ROBUST-GENERATE-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand-checkable full crossing and fixed-input arithmetic
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
factors= [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}]replicates= 2seed= 19
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 8 | 8 | 0.00E+2 | passed | |
/design_points | sequence | ['-1|-1', '-1|-1', '-1|1', '-1|1', '1|-1', '1|-1', '1|1', '1 | ['-1|-1', '-1|-1', '-1|1', '-1|1', '1|-1', '1|-1', '1|1', '1 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:7-16: every control/noise/signal cell crossed with independent replicates.
- Cartesian product enumerated analytically; randomized run order not compared.
- Expected values never use HypoNum output.
Reference code
ROBUST-GENERATE 3
Case STAT-DOE-ROBUST-GENERATE-003 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand-checkable full crossing and fixed-input arithmetic
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
factors= [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}]replicates= 3seed= 19signal= {"name": "S", "levels": [1, 2, 3]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 36 | 36 | 0.00E+2 | passed | |
/design_points | sequence | ['-1|-1|1', '-1|-1|1', '-1|-1|1', '-1|-1|2', '-1|-1|2', '-1| | ['-1|-1|1', '-1|-1|1', '-1|-1|1', '-1|-1|2', '-1|-1|2', '-1| | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:7-16: every control/noise/signal cell crossed with independent replicates.
- Cartesian product enumerated analytically; randomized run order not compared.
- Expected values never use HypoNum output.
Reference code
ROBUST-PLAN 1
Case STAT-DOE-ROBUST-PLAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_ROBUST.json
Settings compared
confirmation= {"analysis": {"design": {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}], "replicates": 3, "seed": 19}, "response_column": "Response", "objective": "target", "target": 10, "preference_weight": 1.5, "bootstrap_replicates": 99, "bootstrap_seed": 11}, "selected": [{"factor": "C", "value": -1}], "predicted_mean": 8, "predicted_objective": 9, "runs_per_condition": 2, "seed": 23, "response_column": "Response"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 4 | 4 | 0.00E+2 | passed | |
/design_points | sequence | ['-1|-1|6', '-1|-1|6', '-1|1|10', '-1|1|10'] | ['-1|-1|6', '-1|-1|6', '-1|1|10', '-1|1|10'] | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:60-64: selected setting across every declared noise condition, fresh runs, recorded design predictions.
- R OLS fitted coefficients are exactly (10,2,3,1); selected C=-1 predicts 6 and 10 at Z=-1,+1.
- Expected values never use HypoNum output.
Reference code
ROBUST-PLAN 2
Case STAT-DOE-ROBUST-PLAN-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_ROBUST.json
Settings compared
confirmation= {"analysis": {"design": {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}], "replicates": 3, "seed": 19}, "response_column": "Response", "objective": "target", "target": 10, "preference_weight": 1.5, "bootstrap_replicates": 99, "bootstrap_seed": 11}, "selected": [{"factor": "C", "value": -1}], "predicted_mean": 8, "predicted_objective": 9, "runs_per_condition": 3, "seed": 23, "response_column": "Response"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 6 | 6 | 0.00E+2 | passed | |
/design_points | sequence | ['-1|-1|6', '-1|-1|6', '-1|-1|6', '-1|1|10', '-1|1|10', '-1| | ['-1|-1|6', '-1|-1|6', '-1|-1|6', '-1|1|10', '-1|1|10', '-1| | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:60-64: selected setting across every declared noise condition, fresh runs, recorded design predictions.
- R OLS fitted coefficients are exactly (10,2,3,1); selected C=-1 predicts 6 and 10 at Z=-1,+1.
- Expected values never use HypoNum output.
Reference code
ROBUST-PLAN 3
Case STAT-DOE-ROBUST-PLAN-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_ROBUST.json
Settings compared
confirmation= {"analysis": {"design": {"factors": [{"name": "C", "role": "control", "low": -1, "high": 1}, {"name": "Z", "role": "noise", "low": -1, "high": 1, "low_probability": 0.5, "high_probability": 0.5}], "replicates": 3, "seed": 19}, "response_column": "Response", "objective": "target", "target": 10, "preference_weight": 1.5, "bootstrap_replicates": 99, "bootstrap_seed": 11}, "selected": [{"factor": "C", "value": -1}], "predicted_mean": 8, "predicted_objective": 9, "runs_per_condition": 4, "seed": 23, "response_column": "Response"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 8 | 8 | 0.00E+2 | passed | |
/design_points | sequence | ['-1|-1|6', '-1|-1|6', '-1|-1|6', '-1|-1|6', '-1|1|10', '-1| | ['-1|-1|6', '-1|-1|6', '-1|-1|6', '-1|-1|6', '-1|1|10', '-1| | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:60-64: selected setting across every declared noise condition, fresh runs, recorded design predictions.
- R OLS fitted coefficients are exactly (10,2,3,1); selected C=-1 predicts 6 and 10 at Z=-1,+1.
- Expected values never use HypoNum output.
Reference code
SIMULATION-FIXED 1
Case STAT-DOE-SIMULATION-FIXED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
confidence_level= 0.95draws= 100inputs= [{"name": "C", "source": "fixed", "value": 1}]model_kind= "stored"percentiles= [25, 50, 75]stored_model= {"family": "ols", "response": "Response", "predictors": [{"name": "C", "kind": "numeric"}], "feature_order": ["Intercept", "C"], "coefficient_names": ["Intercept", "C"], "coefficients": [10, 2], "covariance": [[1.06666666666667, 0], [0, 1.06666666666667]], "link": "identity", "design_rank": 2, "fitted_row_ids": ["R01", "R02", "R03", "R04", "R05", "R06", "R07", "R08", "R09", "R10", "R11", "R12"], "residual_variance": 12.8, "residual_df": 10}thresholds= [11, 12, 13]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/draws | exact | 100 | 100 | 0.00E+2 | passed | |
/mean | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/standard_deviation | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/mean_monte_carlo_standard_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/minimum | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/maximum | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/percentiles/0/value | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/thresholds/0/exceedances | exact | 100 | 100 | 0.00E+2 | passed | |
/thresholds/0/probability | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/thresholds/0/lower | tolerance | 0.96378330735482354 | 0.9637833073548236 | 1.08E-16 | 15 | passed |
/thresholds/0/upper | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/percentiles/1/value | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/thresholds/1/exceedances | exact | 0 | 0 | 0.00E+2 | passed | |
/thresholds/1/probability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/1/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/1/upper | tolerance | 0.036216692645176463 | 0.03621669264517641 | 5.59E-17 | 14 | passed |
/percentiles/2/value | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/thresholds/2/exceedances | exact | 0 | 0 | 0.00E+2 | passed | |
/thresholds/2/probability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/2/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/2/upper | tolerance | 0.036216692645176463 | 0.03621669264517641 | 5.59E-17 | 14 | passed |
Convention
- docs/manual/chapters/95-input-simulation.tex:4-9,46-64: fixed inputs/formula, percentiles and strict-threshold binomial intervals.
- Stored artifact fitted independently by R lm(Response~C) from DOE_B10_ROBUST; fixed input and conditional mean give identical outcomes. R binom.test gives Clopper-Pearson intervals at k=0,n. Seeded random draws and fitted-parameter mixtures are deferred.
- Expected values never use HypoNum output.
Reference code
SIMULATION-FIXED 2
Case STAT-DOE-SIMULATION-FIXED-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
confidence_level= 0.95draws= 200inputs= [{"name": "C", "source": "fixed", "value": -1}]model_kind= "stored"percentiles= [25, 50, 75]stored_model= {"family": "ols", "response": "Response", "predictors": [{"name": "C", "kind": "numeric"}], "feature_order": ["Intercept", "C"], "coefficient_names": ["Intercept", "C"], "coefficients": [10, 2], "covariance": [[1.06666666666667, 0], [0, 1.06666666666667]], "link": "identity", "design_rank": 2, "fitted_row_ids": ["R01", "R02", "R03", "R04", "R05", "R06", "R07", "R08", "R09", "R10", "R11", "R12"], "residual_variance": 12.8, "residual_df": 10}thresholds= [7, 8, 9]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/draws | exact | 200 | 200 | 0.00E+2 | passed | |
/mean | tolerance | 8.0000000000000036 | 8.0 | 3.60E-15 | 15 | passed |
/standard_deviation | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/mean_monte_carlo_standard_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/minimum | tolerance | 8.0000000000000036 | 8.0 | 3.60E-15 | 15 | passed |
/maximum | tolerance | 8.0000000000000036 | 8.0 | 3.60E-15 | 15 | passed |
/percentiles/0/value | tolerance | 8.0000000000000036 | 8.0 | 3.60E-15 | 15 | passed |
/thresholds/0/exceedances | exact | 200 | 200 | 0.00E+2 | passed | |
/thresholds/0/probability | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/thresholds/0/lower | tolerance | 0.98172465964486377 | 0.9817246596448638 | 2.99E-18 | 17 | passed |
/thresholds/0/upper | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/percentiles/1/value | tolerance | 8.0000000000000036 | 8.0 | 3.60E-15 | 15 | passed |
/thresholds/1/exceedances | exact | 0 | 0 | 0.00E+2 | passed | |
/thresholds/1/probability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/1/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/1/upper | tolerance | 0.018275340355136227 | 0.018275340355136237 | 1.04E-17 | 15 | passed |
/percentiles/2/value | tolerance | 8.0000000000000036 | 8.0 | 3.60E-15 | 15 | passed |
/thresholds/2/exceedances | exact | 0 | 0 | 0.00E+2 | passed | |
/thresholds/2/probability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/2/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/2/upper | tolerance | 0.018275340355136227 | 0.018275340355136237 | 1.04E-17 | 15 | passed |
Convention
- docs/manual/chapters/95-input-simulation.tex:4-9,46-64: fixed inputs/formula, percentiles and strict-threshold binomial intervals.
- Stored artifact fitted independently by R lm(Response~C) from DOE_B10_ROBUST; fixed input and conditional mean give identical outcomes. R binom.test gives Clopper-Pearson intervals at k=0,n. Seeded random draws and fitted-parameter mixtures are deferred.
- Expected values never use HypoNum output.
Reference code
SIMULATION-FIXED 3
Case STAT-DOE-SIMULATION-FIXED-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
confidence_level= 0.9draws= 100inputs= [{"name": "C", "source": "fixed", "value": 1}]model_kind= "stored"percentiles= [25, 50, 75]stored_model= {"family": "ols", "response": "Response", "predictors": [{"name": "C", "kind": "numeric"}], "feature_order": ["Intercept", "C"], "coefficient_names": ["Intercept", "C"], "coefficients": [10, 2], "covariance": [[1.06666666666667, 0], [0, 1.06666666666667]], "link": "identity", "design_rank": 2, "fitted_row_ids": ["R01", "R02", "R03", "R04", "R05", "R06", "R07", "R08", "R09", "R10", "R11", "R12"], "residual_variance": 12.8, "residual_df": 10}thresholds= [11, 12, 13]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/draws | exact | 100 | 100 | 0.00E+2 | passed | |
/mean | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/standard_deviation | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/mean_monte_carlo_standard_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/minimum | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/maximum | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/percentiles/0/value | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/thresholds/0/exceedances | exact | 100 | 100 | 0.00E+2 | passed | |
/thresholds/0/probability | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/thresholds/0/lower | tolerance | 0.97048695039296007 | 0.9704869503929601 | 1.74E-18 | 17 | passed |
/thresholds/0/upper | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/percentiles/1/value | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/thresholds/1/exceedances | exact | 0 | 0 | 0.00E+2 | passed | |
/thresholds/1/probability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/1/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/1/upper | tolerance | 0.029513049607039932 | 0.02951304960703994 | 6.68E-18 | 15 | passed |
/percentiles/2/value | tolerance | 12.000000000000004 | 12.0 | 4.00E-15 | 15 | passed |
/thresholds/2/exceedances | exact | 0 | 0 | 0.00E+2 | passed | |
/thresholds/2/probability | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/2/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/thresholds/2/upper | tolerance | 0.029513049607039932 | 0.02951304960703994 | 6.68E-18 | 15 | passed |
Convention
- docs/manual/chapters/95-input-simulation.tex:4-9,46-64: fixed inputs/formula, percentiles and strict-threshold binomial intervals.
- Stored artifact fitted independently by R lm(Response~C) from DOE_B10_ROBUST; fixed input and conditional mean give identical outcomes. R binom.test gives Clopper-Pearson intervals at k=0,n. Seeded random draws and fitted-parameter mixtures are deferred.
- Expected values never use HypoNum output.
Reference code
SIMULATION-FIXED 4
Case STAT-DOE-SIMULATION-FIXED-004 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand-checkable full crossing and fixed-input arithmetic
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
draws= 100inputs= [{"name": "C", "source": "entered", "distribution": {"family": "normal", "mean": 0, "standard_deviation": 1}}]model_kind= "stored"stored_model= {"family": "ols", "response": "Response", "predictors": [{"name": "C", "kind": "numeric"}], "feature_order": ["Intercept", "C"], "coefficient_names": ["Intercept", "C"], "coefficients": [10, 2], "covariance": [[1.06666666666667, 0], [0, 1.06666666666667]], "link": "identity", "design_rank": 2, "fitted_row_ids": ["R01", "R02", "R03", "R04", "R05", "R06", "R07", "R08", "R09", "R10", "R11", "R12"], "residual_variance": 12.8, "residual_df": 10}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/draws | exact | 100 | 100 | 0.00E+2 | passed | |
/inputs/0/name | exact | C | C | passed | ||
/inputs/0/role | exact | random | random | passed |
Convention
- docs/manual/chapters/95-input-simulation.tex:4-9,39-50: retained model and declared random input, conditional-mean target.
- This setting exercises random-input execution; finite-sample simulated values are explicitly deferred, not compared to population limits.
- Expected values never use HypoNum output.
Reference code
TAGUCHI-ANALYSIS 1
Case STAT-DOE-TAGUCHI-ANALYSIS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_TAGUCHI.json
Settings compared
anova_summary= "mean"factors= ["A", "B"]predict_levels= ["2", "1"]predict_terms= ["A", "B"]responses= ["y1", "y2", "y3"]sn= "larger"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs/0/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/0/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/0/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/0/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/0/sn | tolerance | 6.2247789679917522 | 6.224778967991753 | 9.20E-16 | 15 | passed |
/runs/1/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/1/mean | tolerance | 4.333333333333333 | 4.333333333333333 | 3.73E-17 | 17 | passed |
/runs/1/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/1/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/1/sn | tolerance | 12.440861126316506 | 12.440861126316506 | 3.53E-16 | 16 | passed |
/runs/2/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/2/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/2/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/2/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/2/sn | tolerance | 6.2247789679917522 | 6.224778967991753 | 9.20E-16 | 15 | passed |
/runs/3/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/3/mean | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/runs/3/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/3/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/3/sn | tolerance | 18.340212180595195 | 18.340212180595195 | 2.04E-17 | 17 | passed |
/runs/4/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/4/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/4/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/4/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/4/sn | tolerance | 9.0041852003206078 | 9.004185200320608 | 3.74E-17 | 17 | passed |
/runs/5/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/5/mean | tolerance | 5.0333333333333332 | 5.033333333333334 | 9.03E-16 | 15 | passed |
/runs/5/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/5/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/5/sn | tolerance | 13.821253345603807 | 13.821253345603807 | 3.61E-16 | 16 | passed |
/runs/6/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/6/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/6/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/6/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/6/sn | tolerance | 9.0041852003206078 | 9.004185200320608 | 3.74E-17 | 17 | passed |
/runs/7/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/7/mean | tolerance | 9.0333333333333332 | 9.033333333333333 | 1.49E-17 | 17 | passed |
/runs/7/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/7/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/7/sn | tolerance | 19.052381957136404 | 19.052381957136404 | 3.67E-16 | 16 | passed |
/runs/8/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/8/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/8/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/8/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/8/sn | tolerance | 10.776441587445447 | 10.776441587445447 | 1.12E-16 | 16 | passed |
/runs/9/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/9/mean | tolerance | 5.6333333333333329 | 5.633333333333333 | 4.04E-17 | 17 | passed |
/runs/9/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/9/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/9/sn | tolerance | 14.844592558088792 | 14.844592558088792 | 3.66E-16 | 16 | passed |
/runs/10/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/10/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/10/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/10/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/10/sn | tolerance | 10.776441587445447 | 10.776441587445447 | 1.12E-16 | 16 | passed |
/runs/11/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/11/mean | tolerance | 9.6333333333333346 | 9.633333333333335 | 3.60E-17 | 17 | passed |
/runs/11/sd | tolerance | 0.76376261582597338 | 0.763762615825974 | 6.65E-16 | 15 | passed |
/runs/11/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634256 | 8.88E-16 | 14 | passed |
/runs/11/sn | tolerance | 19.618899212132007 | 19.618899212132007 | 6.27E-17 | 17 | passed |
/tables/[summary=mean]/averages/0/0 | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/0/1 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/0 | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/1 | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/predictions/[summary=mean]/value | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/tables/[summary=sd]/averages/0/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/0/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/predictions/[summary=sd]/value | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/tables/[summary=log_sd]/averages/1/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/1/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/predictions/[summary=log_sd]/value | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=sn]/averages/0/0 | tolerance | 8.6684685852526027 | 8.668468585252603 | 3.50E-17 | 17 | passed |
/tables/[summary=sn]/averages/0/1 | tolerance | 16.353033396645451 | 16.35303339664545 | 3.63E-16 | 16 | passed |
/tables/[summary=sn]/averages/1/0 | tolerance | 11.185352130961151 | 11.185352130961151 | 2.18E-16 | 16 | passed |
/tables/[summary=sn]/averages/1/1 | tolerance | 13.836149850936902 | 13.8361498509369 | 1.69E-15 | 15 | passed |
/predictions/[summary=sn]/value | tolerance | 15.027634536657573 | 15.027634536657573 | 4.61E-16 | 16 | passed |
/anova/[source=A]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=A]/ss | tolerance | 48.000000000000007 | 48.0 | 7.00E-15 | 15 | passed |
/anova/[source=A]/f | tolerance | 28.076256499133446 | 28.076256499133418 | 2.80E-14 | 15 | passed |
/anova/[source=A]/p | tolerance | 0.00049470457391323638 | 0.0004947045739132381 | 1.73E-18 | 14 | passed |
/anova/[source=B]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=B]/ss | tolerance | 12.000000000000005 | 12.0 | 5.00E-15 | 15 | passed |
/anova/[source=B]/f | tolerance | 7.0190641247833634 | 7.0190641247833545 | 8.89E-15 | 14 | passed |
/anova/[source=B]/p | tolerance | 0.026504350360172357 | 0.02650435036017246 | 1.04E-16 | 14 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:83-116: static S/N formulas, sample n-1 SD, dynamic slope/MSE and orthogonal level averages.
- R lm/ANOVA uses orthogonal additive main effects; prediction is level-A2 mean + level-B1 mean - grand mean.
- Dynamic reference is lm(y~signal) with SSE/(3-2) or lm(y~0+signal) with SSE/(3-1).
- Expected values never use HypoNum output.
Reference code
TAGUCHI-ANALYSIS 2
Case STAT-DOE-TAGUCHI-ANALYSIS-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_TAGUCHI.json
Settings compared
anova_summary= "mean"factors= ["A", "B"]predict_levels= ["2", "1"]predict_terms= ["A", "B"]responses= ["y1", "y2", "y3"]sn= "smaller"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs/0/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/0/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/0/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/0/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/0/sn | tolerance | -7.659167939666319 | -7.659167939666319 | 3.60E-17 | 17 | passed |
/runs/1/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/1/mean | tolerance | 4.333333333333333 | 4.333333333333333 | 3.73E-17 | 17 | passed |
/runs/1/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/1/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/1/sn | tolerance | -12.825465899699681 | -12.825465899699681 | 3.16E-16 | 16 | passed |
/runs/2/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/2/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/2/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/2/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/2/sn | tolerance | -7.659167939666319 | -7.659167939666319 | 3.60E-17 | 17 | passed |
/runs/3/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/3/mean | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/runs/3/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/3/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/3/sn | tolerance | -18.440627725826516 | -18.440627725826516 | 3.25E-16 | 16 | passed |
/runs/4/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/4/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/4/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/4/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/4/sn | tolerance | -9.8181860717066378 | -9.818186071706638 | 1.86E-17 | 17 | passed |
/runs/5/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/5/mean | tolerance | 5.0333333333333332 | 5.033333333333334 | 9.03E-16 | 15 | passed |
/runs/5/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/5/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/5/sn | tolerance | -14.103272455302914 | -14.103272455302914 | 6.79E-17 | 17 | passed |
/runs/6/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/6/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/6/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/6/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/6/sn | tolerance | -9.8181860717066378 | -9.818186071706638 | 1.86E-17 | 17 | passed |
/runs/7/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/7/mean | tolerance | 9.0333333333333332 | 9.033333333333333 | 1.49E-17 | 17 | passed |
/runs/7/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/7/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/7/sn | tolerance | -19.13760886412323 | -19.13760886412323 | 3.47E-17 | 17 | passed |
/runs/8/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/8/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/8/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/8/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/8/sn | tolerance | -11.332194567324942 | -11.332194567324942 | 1.39E-17 | 17 | passed |
/runs/9/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/9/mean | tolerance | 5.6333333333333329 | 5.633333333333333 | 4.04E-17 | 17 | passed |
/runs/9/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/9/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/9/sn | tolerance | -15.068206042642258 | -15.068206042642258 | 2.86E-16 | 16 | passed |
/runs/10/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/10/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/10/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/10/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/10/sn | tolerance | -11.332194567324942 | -11.332194567324942 | 1.39E-17 | 17 | passed |
/runs/11/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/11/mean | tolerance | 9.6333333333333346 | 9.633333333333335 | 3.60E-17 | 17 | passed |
/runs/11/sd | tolerance | 0.76376261582597338 | 0.763762615825974 | 6.65E-16 | 15 | passed |
/runs/11/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634256 | 8.88E-16 | 14 | passed |
/runs/11/sn | tolerance | -19.693693117335275 | -19.693693117335275 | 3.89E-16 | 16 | passed |
/tables/[summary=mean]/averages/0/0 | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/0/1 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/0 | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/1 | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/predictions/[summary=mean]/value | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/tables/[summary=sd]/averages/0/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/0/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/predictions/[summary=sd]/value | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/tables/[summary=log_sd]/averages/1/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/1/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/predictions/[summary=log_sd]/value | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=sn]/averages/0/0 | tolerance | -9.6031828595659654 | -9.603182859565967 | 1.78E-15 | 15 | passed |
/tables/[summary=sn]/averages/0/1 | tolerance | -16.544812350821644 | -16.544812350821644 | 3.14E-17 | 17 | passed |
/tables/[summary=sn]/averages/1/0 | tolerance | -11.801082162723793 | -11.801082162723793 | 2.66E-16 | 16 | passed |
/tables/[summary=sn]/averages/1/1 | tolerance | -14.34691304766382 | -14.346913047663818 | 1.53E-15 | 15 | passed |
/predictions/[summary=sn]/value | tolerance | -15.271896908351632 | -15.271896908351632 | 4.95E-17 | 17 | passed |
/anova/[source=A]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=A]/ss | tolerance | 48.000000000000007 | 48.0 | 7.00E-15 | 15 | passed |
/anova/[source=A]/f | tolerance | 28.076256499133446 | 28.076256499133418 | 2.80E-14 | 15 | passed |
/anova/[source=A]/p | tolerance | 0.00049470457391323638 | 0.0004947045739132381 | 1.73E-18 | 14 | passed |
/anova/[source=B]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=B]/ss | tolerance | 12.000000000000005 | 12.0 | 5.00E-15 | 15 | passed |
/anova/[source=B]/f | tolerance | 7.0190641247833634 | 7.0190641247833545 | 8.89E-15 | 14 | passed |
/anova/[source=B]/p | tolerance | 0.026504350360172357 | 0.02650435036017246 | 1.04E-16 | 14 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:83-116: static S/N formulas, sample n-1 SD, dynamic slope/MSE and orthogonal level averages.
- R lm/ANOVA uses orthogonal additive main effects; prediction is level-A2 mean + level-B1 mean - grand mean.
- Dynamic reference is lm(y~signal) with SSE/(3-2) or lm(y~0+signal) with SSE/(3-1).
- Expected values never use HypoNum output.
Reference code
TAGUCHI-ANALYSIS 3
Case STAT-DOE-TAGUCHI-ANALYSIS-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_TAGUCHI.json
Settings compared
anova_summary= "mean"factors= ["A", "B"]predict_levels= ["2", "1"]predict_terms= ["A", "B"]responses= ["y1", "y2", "y3"]sn= "nominal_variance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs/0/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/0/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/0/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/0/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/0/sn | tolerance | 2.3408320603336796 | 2.3408320603336805 | 9.20E-16 | 15 | passed |
/runs/1/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/1/mean | tolerance | 4.333333333333333 | 4.333333333333333 | 3.73E-17 | 17 | passed |
/runs/1/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/1/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/1/sn | tolerance | 2.3408320603336796 | 2.3408320603336796 | 3.17E-17 | 16 | passed |
/runs/2/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/2/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/2/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/2/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/2/sn | tolerance | 2.3408320603336796 | 2.3408320603336805 | 9.20E-16 | 15 | passed |
/runs/3/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/3/mean | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/runs/3/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/3/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/3/sn | tolerance | 2.3408320603336796 | 2.3408320603336805 | 9.20E-16 | 15 | passed |
/runs/4/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/4/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/4/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/4/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/4/sn | tolerance | 2.3408320603336796 | 2.3408320603336805 | 9.20E-16 | 15 | passed |
/runs/5/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/5/mean | tolerance | 5.0333333333333332 | 5.033333333333334 | 9.03E-16 | 15 | passed |
/runs/5/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/5/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/5/sn | tolerance | 2.3408320603336796 | 2.3408320603336805 | 9.20E-16 | 15 | passed |
/runs/6/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/6/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/6/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/6/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/6/sn | tolerance | 2.3408320603336796 | 2.3408320603336805 | 9.20E-16 | 15 | passed |
/runs/7/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/7/mean | tolerance | 9.0333333333333332 | 9.033333333333333 | 1.49E-17 | 17 | passed |
/runs/7/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/7/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/7/sn | tolerance | 2.3408320603336796 | 2.3408320603336805 | 9.20E-16 | 15 | passed |
/runs/8/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/8/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/8/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/8/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/8/sn | tolerance | 2.3408320603336796 | 2.3408320603336796 | 3.17E-17 | 16 | passed |
/runs/9/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/9/mean | tolerance | 5.6333333333333329 | 5.633333333333333 | 4.04E-17 | 17 | passed |
/runs/9/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/9/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/9/sn | tolerance | 2.3408320603336796 | 2.3408320603336796 | 3.17E-17 | 16 | passed |
/runs/10/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/10/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/10/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/10/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/10/sn | tolerance | 2.3408320603336796 | 2.3408320603336796 | 3.17E-17 | 16 | passed |
/runs/11/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/11/mean | tolerance | 9.6333333333333346 | 9.633333333333335 | 3.60E-17 | 17 | passed |
/runs/11/sd | tolerance | 0.76376261582597338 | 0.763762615825974 | 6.65E-16 | 15 | passed |
/runs/11/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634256 | 8.88E-16 | 14 | passed |
/runs/11/sn | tolerance | 2.3408320603336796 | 2.340832060333671 | 8.41E-15 | 14 | passed |
/tables/[summary=mean]/averages/0/0 | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/0/1 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/0 | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/1 | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/predictions/[summary=mean]/value | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/tables/[summary=sd]/averages/0/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/0/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/predictions/[summary=sd]/value | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/tables/[summary=log_sd]/averages/1/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/1/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/predictions/[summary=log_sd]/value | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=sn]/averages/0/0 | tolerance | 2.3408320603336796 | 2.3408320603336805 | 9.20E-16 | 15 | passed |
/tables/[summary=sn]/averages/0/1 | tolerance | 2.3408320603336796 | 2.3408320603336787 | 8.56E-16 | 15 | passed |
/tables/[summary=sn]/averages/1/0 | tolerance | 2.3408320603336796 | 2.34083206033368 | 4.76E-16 | 15 | passed |
/tables/[summary=sn]/averages/1/1 | tolerance | 2.3408320603336796 | 2.3408320603336787 | 8.56E-16 | 15 | passed |
/predictions/[summary=sn]/value | tolerance | 2.3408320603336796 | 2.34083206033368 | 4.76E-16 | 15 | passed |
/anova/[source=A]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=A]/ss | tolerance | 48.000000000000007 | 48.0 | 7.00E-15 | 15 | passed |
/anova/[source=A]/f | tolerance | 28.076256499133446 | 28.076256499133418 | 2.80E-14 | 15 | passed |
/anova/[source=A]/p | tolerance | 0.00049470457391323638 | 0.0004947045739132381 | 1.73E-18 | 14 | passed |
/anova/[source=B]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=B]/ss | tolerance | 12.000000000000005 | 12.0 | 5.00E-15 | 15 | passed |
/anova/[source=B]/f | tolerance | 7.0190641247833634 | 7.0190641247833545 | 8.89E-15 | 14 | passed |
/anova/[source=B]/p | tolerance | 0.026504350360172357 | 0.02650435036017246 | 1.04E-16 | 14 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:83-116: static S/N formulas, sample n-1 SD, dynamic slope/MSE and orthogonal level averages.
- R lm/ANOVA uses orthogonal additive main effects; prediction is level-A2 mean + level-B1 mean - grand mean.
- Dynamic reference is lm(y~signal) with SSE/(3-2) or lm(y~0+signal) with SSE/(3-1).
- Expected values never use HypoNum output.
Reference code
TAGUCHI-ANALYSIS 4
Case STAT-DOE-TAGUCHI-ANALYSIS-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_TAGUCHI.json
Settings compared
anova_summary= "mean"factors= ["A", "B"]predict_levels= ["2", "1"]predict_terms= ["A", "B"]responses= ["y1", "y2", "y3"]sn= "nominal_mean_sd"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs/0/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/0/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/0/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/0/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/0/sn | tolerance | 9.7003677662255683 | 9.70036776622557 | 1.77E-15 | 15 | passed |
/runs/1/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/1/mean | tolerance | 4.333333333333333 | 4.333333333333333 | 3.73E-17 | 17 | passed |
/runs/1/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/1/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/1/sn | tolerance | 15.077274012077167 | 15.077274012077167 | 1.13E-16 | 17 | passed |
/runs/2/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/2/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/2/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/2/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/2/sn | tolerance | 9.7003677662255683 | 9.70036776622557 | 1.77E-15 | 15 | passed |
/runs/3/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/3/mean | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/runs/3/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/3/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/3/sn | tolerance | 20.757207139381183 | 20.757207139381183 | 2.25E-16 | 16 | passed |
/runs/4/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/4/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/4/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/4/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/4/sn | tolerance | 11.979234812362304 | 11.979234812362305 | 1.36E-15 | 15 | passed |
/runs/5/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/5/mean | tolerance | 5.0333333333333332 | 5.033333333333334 | 9.03E-16 | 15 | passed |
/runs/5/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/5/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/5/sn | tolerance | 16.37794591180382 | 16.37794591180382 | 4.22E-16 | 16 | passed |
/runs/6/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/6/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/6/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/6/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/6/sn | tolerance | 11.979234812362304 | 11.979234812362305 | 1.36E-15 | 15 | passed |
/runs/7/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/7/mean | tolerance | 9.0333333333333332 | 9.033333333333333 | 1.49E-17 | 17 | passed |
/runs/7/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/7/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/7/sn | tolerance | 21.457792783428545 | 21.457792783428545 | 3.19E-16 | 16 | passed |
/runs/8/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/8/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/8/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/8/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/8/sn | tolerance | 13.546936924752904 | 13.546936924752902 | 1.66E-15 | 15 | passed |
/runs/9/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/9/mean | tolerance | 5.6333333333333329 | 5.633333333333333 | 4.04E-17 | 17 | passed |
/runs/9/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/9/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/9/sn | tolerance | 17.3561410582139 | 17.3561410582139 | 4.08E-16 | 16 | passed |
/runs/10/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/10/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/10/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/10/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/10/sn | tolerance | 13.546936924752904 | 13.546936924752902 | 1.66E-15 | 15 | passed |
/runs/11/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/11/mean | tolerance | 9.6333333333333346 | 9.633333333333335 | 3.60E-17 | 17 | passed |
/runs/11/sd | tolerance | 0.76376261582597338 | 0.763762615825974 | 6.65E-16 | 15 | passed |
/runs/11/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634256 | 8.88E-16 | 14 | passed |
/runs/11/sn | tolerance | 22.016363821071391 | 22.01636382107138 | 1.11E-14 | 15 | passed |
/tables/[summary=mean]/averages/0/0 | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/0/1 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/0 | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/1 | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/predictions/[summary=mean]/value | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/tables/[summary=sd]/averages/0/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/0/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/predictions/[summary=sd]/value | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/tables/[summary=log_sd]/averages/1/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/1/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/predictions/[summary=log_sd]/value | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=sn]/averages/0/0 | tolerance | 11.742179834446926 | 11.742179834446924 | 1.85E-15 | 15 | passed |
/tables/[summary=sn]/averages/0/1 | tolerance | 18.840454120996 | 18.840454120995997 | 3.41E-15 | 15 | passed |
/tables/[summary=sn]/averages/1/0 | tolerance | 14.00631674757261 | 14.006316747572612 | 1.80E-15 | 15 | passed |
/tables/[summary=sn]/averages/1/1 | tolerance | 16.576317207870314 | 16.576317207870314 | 2.63E-16 | 16 | passed |
/predictions/[summary=sn]/value | tolerance | 17.555453890847147 | 17.555453890847144 | 3.42E-15 | 15 | passed |
/anova/[source=A]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=A]/ss | tolerance | 48.000000000000007 | 48.0 | 7.00E-15 | 15 | passed |
/anova/[source=A]/f | tolerance | 28.076256499133446 | 28.076256499133418 | 2.80E-14 | 15 | passed |
/anova/[source=A]/p | tolerance | 0.00049470457391323638 | 0.0004947045739132381 | 1.73E-18 | 14 | passed |
/anova/[source=B]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=B]/ss | tolerance | 12.000000000000005 | 12.0 | 5.00E-15 | 15 | passed |
/anova/[source=B]/f | tolerance | 7.0190641247833634 | 7.0190641247833545 | 8.89E-15 | 14 | passed |
/anova/[source=B]/p | tolerance | 0.026504350360172357 | 0.02650435036017246 | 1.04E-16 | 14 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:83-116: static S/N formulas, sample n-1 SD, dynamic slope/MSE and orthogonal level averages.
- R lm/ANOVA uses orthogonal additive main effects; prediction is level-A2 mean + level-B1 mean - grand mean.
- Dynamic reference is lm(y~signal) with SSE/(3-2) or lm(y~0+signal) with SSE/(3-1).
- Expected values never use HypoNum output.
Reference code
TAGUCHI-ANALYSIS 5
Case STAT-DOE-TAGUCHI-ANALYSIS-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_TAGUCHI.json
Settings compared
anova_summary= "mean"dynamic_reference= "intercept"factors= ["A", "B"]predict_levels= ["2", "1"]predict_terms= ["A", "B"]responses= ["y1", "y2", "y3"]signal_values= [1, 2, 3]sn= "dynamic"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs/0/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/0/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/0/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/0/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/0/sn | tolerance | -4.2596873227227814 | -4.259687322722808 | 2.66E-14 | 14 | passed |
/runs/0/slope | tolerance | -0.50000000000000122 | -0.5000000000000003 | 8.87E-16 | 14 | passed |
/runs/1/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/1/mean | tolerance | 4.333333333333333 | 4.333333333333333 | 3.73E-17 | 17 | passed |
/runs/1/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/1/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/1/sn | tolerance | -4.2596873227228009 | -4.259687322722816 | 1.51E-14 | 14 | passed |
/runs/1/slope | tolerance | -0.50000000000000044 | -0.49999999999999983 | 6.07E-16 | 14 | passed |
/runs/2/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/2/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/2/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/2/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/2/sn | tolerance | -4.2596873227227814 | -4.259687322722808 | 2.66E-14 | 14 | passed |
/runs/2/slope | tolerance | -0.50000000000000122 | -0.5000000000000003 | 8.87E-16 | 14 | passed |
/runs/3/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/3/mean | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/runs/3/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/3/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/3/sn | tolerance | -4.2596873227227441 | -4.259687322722813 | 6.93E-14 | 13 | passed |
/runs/3/slope | tolerance | -0.50000000000000266 | -0.4999999999999994 | 3.27E-15 | 14 | passed |
/runs/4/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/4/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/4/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/4/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/4/sn | tolerance | -4.259687322722792 | -4.2596873227228125 | 2.05E-14 | 14 | passed |
/runs/4/slope | tolerance | -0.50000000000000078 | -0.49999999999999983 | 9.47E-16 | 14 | passed |
/runs/5/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/5/mean | tolerance | 5.0333333333333332 | 5.033333333333334 | 9.03E-16 | 15 | passed |
/runs/5/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/5/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/5/sn | tolerance | -4.2596873227227814 | -4.259687322722813 | 3.20E-14 | 14 | passed |
/runs/5/slope | tolerance | -0.50000000000000122 | -0.49999999999999967 | 1.55E-15 | 14 | passed |
/runs/6/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/6/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/6/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/6/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/6/sn | tolerance | -4.259687322722792 | -4.2596873227228125 | 2.05E-14 | 14 | passed |
/runs/6/slope | tolerance | -0.50000000000000078 | -0.49999999999999983 | 9.47E-16 | 14 | passed |
/runs/7/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/7/mean | tolerance | 9.0333333333333332 | 9.033333333333333 | 1.49E-17 | 17 | passed |
/runs/7/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/7/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/7/sn | tolerance | -4.2596873227227814 | -4.259687322722787 | 5.32E-15 | 14 | passed |
/runs/7/slope | tolerance | -0.50000000000000122 | -0.500000000000001 | 2.21E-16 | 15 | passed |
/runs/8/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/8/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/8/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/8/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/8/sn | tolerance | -4.2596873227227814 | -4.2596873227228125 | 3.11E-14 | 14 | passed |
/runs/8/slope | tolerance | -0.50000000000000122 | -0.5 | 1.22E-15 | 14 | passed |
/runs/9/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/9/mean | tolerance | 5.6333333333333329 | 5.633333333333333 | 4.04E-17 | 17 | passed |
/runs/9/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/9/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/9/sn | tolerance | -4.259687322722761 | -4.259687322722804 | 4.26E-14 | 14 | passed |
/runs/9/slope | tolerance | -0.500000000000002 | -0.5000000000000004 | 1.56E-15 | 14 | passed |
/runs/10/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/10/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/10/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/10/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/10/sn | tolerance | -4.2596873227227814 | -4.2596873227228125 | 3.11E-14 | 14 | passed |
/runs/10/slope | tolerance | -0.50000000000000122 | -0.5 | 1.22E-15 | 14 | passed |
/runs/11/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/11/mean | tolerance | 9.6333333333333346 | 9.633333333333335 | 3.60E-17 | 17 | passed |
/runs/11/sd | tolerance | 0.76376261582597338 | 0.763762615825974 | 6.65E-16 | 15 | passed |
/runs/11/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634256 | 8.88E-16 | 14 | passed |
/runs/11/sn | tolerance | -4.2596873227227441 | -4.259687322722822 | 7.81E-14 | 13 | passed |
/runs/11/slope | tolerance | -0.50000000000000266 | -0.5000000000000002 | 2.44E-15 | 14 | passed |
/tables/[summary=mean]/averages/0/0 | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/0/1 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/0 | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/1 | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/predictions/[summary=mean]/value | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/tables/[summary=sd]/averages/0/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/0/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/predictions/[summary=sd]/value | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/tables/[summary=log_sd]/averages/1/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/1/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/predictions/[summary=log_sd]/value | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=sn]/averages/0/0 | tolerance | -4.2596873227227849 | -4.259687322722811 | 2.58E-14 | 14 | passed |
/tables/[summary=sn]/averages/0/1 | tolerance | -4.259687322722769 | -4.25968732272281 | 4.08E-14 | 14 | passed |
/tables/[summary=sn]/averages/1/0 | tolerance | -4.2596873227227832 | -4.259687322722811 | 2.75E-14 | 14 | passed |
/tables/[summary=sn]/averages/1/1 | tolerance | -4.2596873227227707 | -4.259687322722809 | 3.82E-14 | 14 | passed |
/predictions/[summary=sn]/value | tolerance | -4.2596873227227752 | -4.25968732272281 | 3.46E-14 | 14 | passed |
/anova/[source=A]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=A]/ss | tolerance | 48.000000000000007 | 48.0 | 7.00E-15 | 15 | passed |
/anova/[source=A]/f | tolerance | 28.076256499133446 | 28.076256499133418 | 2.80E-14 | 15 | passed |
/anova/[source=A]/p | tolerance | 0.00049470457391323638 | 0.0004947045739132381 | 1.73E-18 | 14 | passed |
/anova/[source=B]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=B]/ss | tolerance | 12.000000000000005 | 12.0 | 5.00E-15 | 15 | passed |
/anova/[source=B]/f | tolerance | 7.0190641247833634 | 7.0190641247833545 | 8.89E-15 | 14 | passed |
/anova/[source=B]/p | tolerance | 0.026504350360172357 | 0.02650435036017246 | 1.04E-16 | 14 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:83-116: static S/N formulas, sample n-1 SD, dynamic slope/MSE and orthogonal level averages.
- R lm/ANOVA uses orthogonal additive main effects; prediction is level-A2 mean + level-B1 mean - grand mean.
- Dynamic reference is lm(y~signal) with SSE/(3-2) or lm(y~0+signal) with SSE/(3-1).
- Expected values never use HypoNum output.
Reference code
TAGUCHI-ANALYSIS 6
Case STAT-DOE-TAGUCHI-ANALYSIS-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lm, anova, pf, pt, qt, binom.test; base mean/var/log10
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- reference_data/datasets/DOE_B10_TAGUCHI.json
Settings compared
anova_summary= "mean"dynamic_reference= "origin"factors= ["A", "B"]predict_levels= ["2", "1"]predict_terms= ["A", "B"]responses= ["y1", "y2", "y3"]signal_values= [1, 2, 3]sn= "dynamic"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs/0/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/0/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/0/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/0/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/0/sn | tolerance | -4.9802492768137476 | -4.980249276813746 | 1.75E-15 | 15 | passed |
/runs/0/slope | tolerance | 0.9285714285714286 | 0.9285714285714286 | 3.15E-18 | 17 | passed |
/runs/1/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/1/mean | tolerance | 4.333333333333333 | 4.333333333333333 | 3.73E-17 | 17 | passed |
/runs/1/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/1/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/1/sn | tolerance | -3.0449052777348786 | -3.044905277734877 | 1.75E-15 | 15 | passed |
/runs/1/slope | tolerance | 1.7857142857142854 | 1.7857142857142858 | 4.09E-16 | 15 | passed |
/runs/2/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/2/mean | tolerance | 2.3333333333333335 | 2.3333333333333335 | 1.86E-17 | 17 | passed |
/runs/2/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/2/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/2/sn | tolerance | -4.9802492768137476 | -4.980249276813746 | 1.75E-15 | 15 | passed |
/runs/2/slope | tolerance | 0.9285714285714286 | 0.9285714285714286 | 3.15E-18 | 17 | passed |
/runs/3/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/3/mean | tolerance | 8.3333333333333339 | 8.333333333333334 | 2.55E-17 | 17 | passed |
/runs/3/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/3/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/3/sn | tolerance | -1.9061751225227783 | -1.906175122522777 | 1.31E-15 | 15 | passed |
/runs/3/slope | tolerance | 3.5 | 3.5 | 0.00E+1 | passed | |
/runs/4/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/4/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/4/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/4/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/4/sn | tolerance | -4.0318132596348093 | -4.031813259634807 | 2.67E-15 | 15 | passed |
/runs/4/slope | tolerance | 1.2285714285714286 | 1.2285714285714289 | 2.70E-16 | 15 | passed |
/runs/5/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/5/mean | tolerance | 5.0333333333333332 | 5.033333333333334 | 9.03E-16 | 15 | passed |
/runs/5/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/5/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/5/sn | tolerance | -2.7177165343131948 | -2.717716534313194 | 8.68E-16 | 15 | passed |
/runs/5/slope | tolerance | 2.0857142857142854 | 2.085714285714286 | 4.54E-16 | 15 | passed |
/runs/6/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/6/mean | tolerance | 3.0333333333333337 | 3.0333333333333337 | 4.10E-17 | 16 | passed |
/runs/6/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/6/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/6/sn | tolerance | -4.0318132596348093 | -4.031813259634807 | 2.67E-15 | 15 | passed |
/runs/6/slope | tolerance | 1.2285714285714286 | 1.2285714285714289 | 2.70E-16 | 15 | passed |
/runs/7/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/7/mean | tolerance | 9.0333333333333332 | 9.033333333333333 | 1.49E-17 | 17 | passed |
/runs/7/sd | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/runs/7/log_sd | tolerance | -0.26949825036634345 | -0.2694982503663436 | 1.67E-16 | 15 | passed |
/runs/7/sn | tolerance | -1.8097606428057389 | -1.8097606428057376 | 1.34E-15 | 15 | passed |
/runs/7/slope | tolerance | 3.7999999999999994 | 3.8 | 4.22E-16 | 15 | passed |
/runs/8/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/8/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/8/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/8/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/8/sn | tolerance | -3.4929082175886195 | -3.4929082175886195 | 3.17E-17 | 17 | passed |
/runs/8/slope | tolerance | 1.4857142857142853 | 1.4857142857142855 | 2.43E-16 | 15 | passed |
/runs/9/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/9/mean | tolerance | 5.6333333333333329 | 5.633333333333333 | 4.04E-17 | 17 | passed |
/runs/9/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/9/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/9/sn | tolerance | -2.5005354267411701 | -2.5005354267411684 | 1.75E-15 | 15 | passed |
/runs/9/slope | tolerance | 2.3428571428571425 | 2.3428571428571425 | 2.72E-17 | 16 | passed |
/runs/10/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/10/mean | tolerance | 3.6333333333333333 | 3.633333333333333 | 4.40E-16 | 15 | passed |
/runs/10/sd | tolerance | 0.76376261582597338 | 0.7637626158259734 | 1.15E-18 | 17 | passed |
/runs/10/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634345 | 3.24E-19 | 17 | passed |
/runs/10/sn | tolerance | -3.4929082175886195 | -3.4929082175886195 | 3.17E-17 | 17 | passed |
/runs/10/slope | tolerance | 1.4857142857142853 | 1.4857142857142855 | 2.43E-16 | 15 | passed |
/runs/11/count | exact | 3 | 3 | 0.00E+2 | passed | |
/runs/11/mean | tolerance | 9.6333333333333346 | 9.633333333333335 | 3.60E-17 | 17 | passed |
/runs/11/sd | tolerance | 0.76376261582597338 | 0.763762615825974 | 6.65E-16 | 15 | passed |
/runs/11/log_sd | tolerance | -0.26949825036634345 | -0.26949825036634256 | 8.88E-16 | 14 | passed |
/runs/11/sn | tolerance | -1.738256528936456 | -1.7382565289364524 | 3.56E-15 | 14 | passed |
/runs/11/slope | tolerance | 4.0571428571428569 | 4.057142857142858 | 9.28E-16 | 15 | passed |
/tables/[summary=mean]/averages/0/0 | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/0/1 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/0 | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/tables/[summary=mean]/averages/1/1 | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/predictions/[summary=mean]/value | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/tables/[summary=sd]/averages/0/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/0/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/0 | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=sd]/averages/1/1 | tolerance | 0.76376261582597338 | 0.7637626158259735 | 1.10E-16 | 15 | passed |
/predictions/[summary=sd]/value | tolerance | 0.76376261582597338 | 0.7637626158259733 | 1.12E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/0/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/tables/[summary=log_sd]/averages/1/0 | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=log_sd]/averages/1/1 | tolerance | -0.26949825036634345 | -0.2694982503663434 | 5.52E-17 | 15 | passed |
/predictions/[summary=log_sd]/value | tolerance | -0.26949825036634345 | -0.26949825036634356 | 1.11E-16 | 15 | passed |
/tables/[summary=sn]/averages/0/0 | tolerance | -4.1683235846790589 | -4.168323584679057 | 1.73E-15 | 15 | passed |
/tables/[summary=sn]/averages/0/1 | tolerance | -2.2862249221757027 | -2.286224922175701 | 1.75E-15 | 15 | passed |
/tables/[summary=sn]/averages/1/0 | tolerance | -3.4613546654710698 | -3.461354665471069 | 8.41E-16 | 15 | passed |
/tables/[summary=sn]/averages/1/1 | tolerance | -2.9931938413836914 | -2.99319384138369 | 1.35E-15 | 15 | passed |
/predictions/[summary=sn]/value | tolerance | -2.5203053342193913 | -2.5203053342193904 | 8.97E-16 | 15 | passed |
/anova/[source=A]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=A]/ss | tolerance | 48.000000000000007 | 48.0 | 7.00E-15 | 15 | passed |
/anova/[source=A]/f | tolerance | 28.076256499133446 | 28.076256499133418 | 2.80E-14 | 15 | passed |
/anova/[source=A]/p | tolerance | 0.00049470457391323638 | 0.0004947045739132381 | 1.73E-18 | 14 | passed |
/anova/[source=B]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/anova/[source=B]/ss | tolerance | 12.000000000000005 | 12.0 | 5.00E-15 | 15 | passed |
/anova/[source=B]/f | tolerance | 7.0190641247833634 | 7.0190641247833545 | 8.89E-15 | 14 | passed |
/anova/[source=B]/p | tolerance | 0.026504350360172357 | 0.02650435036017246 | 1.04E-16 | 14 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:83-116: static S/N formulas, sample n-1 SD, dynamic slope/MSE and orthogonal level averages.
- R lm/ANOVA uses orthogonal additive main effects; prediction is level-A2 mean + level-B1 mean - grand mean.
- Dynamic reference is lm(y~signal) with SSE/(3-2) or lm(y~0+signal) with SSE/(3-1).
- Expected values never use HypoNum output.
Reference code
TAGUCHI-DESIGN 1
Case STAT-DOE-TAGUCHI-DESIGN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand-checkable full crossing and fixed-input arithmetic
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
array= "L4"factors= ["A", "B", "C"]randomize= falserepeats= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 4 | 4 | 0.00E+2 | passed | |
/rows/0/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/0/3 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/0/4 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/1/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/1/3 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/1/4 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/2/2 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/2/3 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/2/4 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/3/2 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/3/3 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/3/4 | exact | 1 | 1 | 0.00E+2 | passed | |
/response_columns | sequence | ['Y_R1', 'Y_R2'] | ['Y_R1', 'Y_R2'] | passed | ||
/assignment/0/levels | exact | 2 | 2 | 0.00E+2 | passed | |
/assignment/1/levels | exact | 2 | 2 | 0.00E+2 | passed | |
/assignment/2/levels | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:67-81: orthogonal arrays, repeats/outer array and signal/response correspondence.
- Analytic derivation: enumerate a then b in GF(2), columns a,b,a+b (mod 2), then add one. Pairwise 2x2 determinants equal one, so all four level pairs occur once; rows are 111,122,212,221. In GF(3), use columns a,b,a+b,2a+b (mod 3), plus one; pairwise determinants are nonzero mod 3, so all nine pairs occur once. Outer L4 supplies four noise rows per signal.
- Expected values never use HypoNum output.
Reference code
TAGUCHI-DESIGN 2
Case STAT-DOE-TAGUCHI-DESIGN-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand-checkable full crossing and fixed-input arithmetic
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
array= "L9"factors= ["A", "B", "C"]randomize= falserepeats= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 9 | 9 | 0.00E+2 | passed | |
/rows/0/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/0/3 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/0/4 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/1/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/1/3 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/1/4 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/2/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/2/3 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/2/4 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/3/2 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/3/3 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/3/4 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/4/2 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/4/3 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/4/4 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/5/2 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/5/3 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/5/4 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/6/2 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/6/3 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/6/4 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/7/2 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/7/3 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/7/4 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/8/2 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/8/3 | exact | 3 | 3 | 0.00E+2 | passed | |
/rows/8/4 | exact | 2 | 2 | 0.00E+2 | passed | |
/response_columns | sequence | ['Y_R1', 'Y_R2'] | ['Y_R1', 'Y_R2'] | passed | ||
/assignment/0/levels | exact | 3 | 3 | 0.00E+2 | passed | |
/assignment/1/levels | exact | 3 | 3 | 0.00E+2 | passed | |
/assignment/2/levels | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:67-81: orthogonal arrays, repeats/outer array and signal/response correspondence.
- Analytic derivation: enumerate a then b in GF(2), columns a,b,a+b (mod 2), then add one. Pairwise 2x2 determinants equal one, so all four level pairs occur once; rows are 111,122,212,221. In GF(3), use columns a,b,a+b,2a+b (mod 3), plus one; pairwise determinants are nonzero mod 3, so all nine pairs occur once. Outer L4 supplies four noise rows per signal.
- Expected values never use HypoNum output.
Reference code
TAGUCHI-DESIGN 3
Case STAT-DOE-TAGUCHI-DESIGN-003 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand-checkable full crossing and fixed-input arithmetic
- Citation
- R Core Team, stats package documentation: lm, anova, FDist, TDistr, binom.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_window_coverage.R · sha256 994610a525207dcf
- Dataset
- None
Settings compared
array= "L4"factors= ["A", "B", "C"]noise= "outer"noise_factors= ["Z"]outer_array= "L4"randomize= falserepeats= 2signal_levels= [1, 2, 3]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 4 | 4 | 0.00E+2 | passed | |
/rows/0/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/0/3 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/0/4 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/1/2 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/1/3 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/1/4 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/2/2 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/2/3 | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/2/4 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/3/2 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/3/3 | exact | 2 | 2 | 0.00E+2 | passed | |
/rows/3/4 | exact | 1 | 1 | 0.00E+2 | passed | |
/response_columns | sequence | ['Y_M1_O1', 'Y_M1_O2', 'Y_M1_O3', 'Y_M1_O4', 'Y_M2_O1', 'Y_M | ['Y_M1_O1', 'Y_M1_O2', 'Y_M1_O3', 'Y_M1_O4', 'Y_M2_O1', 'Y_M | passed | ||
/assignment/0/levels | exact | 2 | 2 | 0.00E+2 | passed | |
/assignment/1/levels | exact | 2 | 2 | 0.00E+2 | passed | |
/assignment/2/levels | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/97-robust-taguchi-design.tex:67-81: orthogonal arrays, repeats/outer array and signal/response correspondence.
- Analytic derivation: enumerate a then b in GF(2), columns a,b,a+b (mod 2), then add one. Pairwise 2x2 determinants equal one, so all four level pairs occur once; rows are 111,122,212,221. In GF(3), use columns a,b,a+b,2a+b (mod 3), plus one; pairwise determinants are nonzero mod 3, so all nine pairs occur once. Outer L4 supplies four noise rows per signal.
- Expected values never use HypoNum output.
Reference code
Log-variance model slopes with equal replication
Case STAT-DOE-VAR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::glm on coded factors; enumerated design points
- Citation
- R stats::lm and stats::glm documentation; coding rules from manual chapter 13
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/design_doe.R · sha256 ec14480ae0666aea
- Dataset
- reference_data/datasets/DOE_VARIABILITY.json
Settings compared
design= {"factors": [{"name": "A", "low": 10, "high": 20}, {"name": "B", "low": 1, "high": 3}], "response_name": "y", "model": "main_effects"}response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/payload/variability/terms/[term=A]/coefficient | tolerance | 0.69242863727569226 | 0.6924286372756924 | 1.11E-16 | 15 | passed |
/payload/variability/terms/[term=B]/coefficient | tolerance | -0.70814748653806969 | -0.7081474865380695 | 2.19E-16 | 15 | passed |
Convention
- Five runs at every setting: equal df, so weighting and the digamma bias correction shift only the intercept.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
152 set.seed(20261103)
153 dv <- data.frame(A = rep(c(10, 20, 10, 20), each = 5), B = rep(c(1, 1, 3, 3), each = 5))
154 sdv <- exp(0.2 + 0.35 * code(dv$A, 10, 20) - 0.25 * code(dv$B, 1, 3))
155 dv$y <- round(30 + rnorm(20, 0, sdv), 4)
156 export_dataset(dv, "DOE_VARIABILITY", "Constructed 2^2 design with five runs per setting and a settings-dependent SD, seed 20261103",
157 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(A = "Float64", B = "Float64", y = "Float64"))
158 v <- read_dataset("DOE_VARIABILITY")
159 agg <- aggregate(y ~ A + B, data = v, FUN = var)
160 agg$a <- code(agg$A, 10, 20); agg$b <- code(agg$B, 1, 3)
161 lv <- coef(lm(log(y) ~ a + b, data = agg))
162 emit("STAT-DOE-VAR-001", "tabelz.analysis.doe_dispersion:analyze_doe_variability", "Log-variance model slopes with equal replication", "DOE_VARIABILITY",
163 list(response = "y", design = list(factors = list(list(name = "A", low = 10, high = 20), list(name = "B", low = 1, high = 3)),
164 response_name = "y", model = "main_effects")),
165 list("/payload/variability/terms/[term=A]/coefficient" = tol(lv[["a"]], "Slope of log s^2 on coded A."),
166 "/payload/variability/terms/[term=B]/coefficient" = tol(lv[["b"]], "Slope of log s^2 on coded B.")),
167 c("Five runs at every setting: equal df, so weighting and the digamma bias correction shift only the intercept."),
168 deferred = list(list(path = "/payload/variability/terms/[term=Intercept]/coefficient",
169 reason = "The manual does not give the bias correction or weights that set the intercept.")))
Crossed worksheet: 3 parts x 2 operators x 2 trials
Case STAT-DOE-WORKSHEET-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation of the worksheet design
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/design_worksheets.R · sha256 536f8a134b709491
- Dataset
- None
Settings compared
layout= "crossed"operator_labels= ["Ann", "Bob"]part_labels= ["P1", "P2", "P3"]seed= 11trials= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows | exact | 12 | 12 | 0.00E+2 | passed | |
/cells | sequence | ['P1|Ann|1', 'P1|Ann|2', 'P1|Bob|1', 'P1|Bob|2', 'P2|Ann|1', | ['P1|Ann|1', 'P1|Ann|2', 'P1|Bob|1', 'P1|Bob|2', 'P2|Ann|1', | passed |
Convention
- Line 17-18: crossed assigns every operator to every part for every trial.
Reference code
The lines of the reference script that produce this case's expected values.
40 parts <- c("P1", "P2", "P3"); ops <- c("Ann", "Bob")
41 crossed <- list(layout = "crossed", part_labels = as.list(parts), operator_labels = as.list(ops), trials = 2L, seed = 11L)
42 emit("STAT-DOE-WORKSHEET-001", ws, "Crossed worksheet: 3 parts x 2 operators x 2 trials", crossed,
43 list("/rows" = exact(12L, "3 x 2 x 2 rows."), "/cells" = cells_of(parts, ops, 2)),
44 c("Line 17-18: crossed assigns every operator to every part for every trial."))
The same seed reproduces the sheet
Case STAT-DOE-WORKSHEET-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation of the worksheet design
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/design_worksheets.R · sha256 536f8a134b709491
- Dataset
- None
Settings compared
layout= "crossed"operator_labels= ["Ann", "Bob"]part_labels= ["P1", "P2", "P3"]seed= 11trials= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows | exact | 12 | 12 | 0.00E+2 | passed |
Convention
- Line 43-45: the same design and seed reproduce the exact run order.
Reference code
The lines of the reference script that produce this case's expected values.
45 emit("STAT-DOE-WORKSHEET-002", ws, "The same seed reproduces the sheet", crossed,
46 list("/rows" = exact(12L, "Twelve rows.")), c("Line 43-45: the same design and seed reproduce the exact run order."),
47 kind = "determinism", repeat_n = 2L)
Nested worksheet: two parts per operator
Case STAT-DOE-WORKSHEET-003 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation of the worksheet design
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/design_worksheets.R · sha256 536f8a134b709491
- Dataset
- None
Settings compared
layout= "nested"operator_labels= ["Ann", "Bob", "Cy"]part_count= 2seed= 5trials= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows | exact | 18 | 18 | 0.00E+2 | passed |
Convention
- Line 19-21: each operator gets a distinct set of parts.
Reference code
The lines of the reference script that produce this case's expected values.
48 emit("STAT-DOE-WORKSHEET-003", ws, "Nested worksheet: two parts per operator",
49 list(layout = "nested", part_count = 2L, operator_labels = list("Ann", "Bob", "Cy"), trials = 3L, seed = 5L),
50 list("/rows" = exact(18L, "3 operators x 2 own parts x 3 trials.")),
51 c("Line 19-21: each operator gets a distinct set of parts."), kind = "axis_coverage")
Attribute agreement worksheet with standards
Case STAT-DOE-WORKSHEET-004 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation of the worksheet design
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/design_worksheets.R · sha256 536f8a134b709491
- Dataset
- None
Settings compared
layout= "attribute_agreement"operator_labels= ["Ann", "Bob"]part_labels= ["P1", "P2", "P3"]standard_values= ["G", "NG", "G"]trials= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows | exact | 6 | 6 | 0.00E+2 | passed | |
/cells | sequence | ['P1|Ann|1', 'P1|Bob|1', 'P2|Ann|1', 'P2|Bob|1', 'P3|Ann|1', | ['P1|Ann|1', 'P1|Bob|1', 'P2|Ann|1', 'P2|Bob|1', 'P3|Ann|1', | passed | ||
/columns | set | ['Part', 'Operator', 'Trial', 'TrialID', 'Value', 'StandardV | ['Part', 'Operator', 'Trial', 'TrialID', 'Value', 'StandardV | passed |
Convention
- One rating row per part/operator/trial.
Reference code
The lines of the reference script that produce this case's expected values.
52 emit("STAT-DOE-WORKSHEET-004", ws, "Attribute agreement worksheet with standards",
53 list(layout = "attribute_agreement", part_labels = as.list(parts), operator_labels = as.list(ops), trials = 1L,
54 standard_values = list("G", "NG", "G")),
55 list("/rows" = exact(6L, "3 x 2 x 1 rating rows."), "/cells" = cells_of(parts, ops, 1),
56 "/columns" = list(comparison = "set", values = list("Part", "Operator", "Trial", "TrialID", "Value", "StandardValue"),
57 rationale = "Line 45-48: Value replaces Measurement, plus StandardValue when declared.")),
58 c("One rating row per part/operator/trial."), kind = "axis_coverage")
Part labels are refused for nested designs
Case STAT-DOE-WORKSHEET-005 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation of the worksheet design
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/design_worksheets.R · sha256 536f8a134b709491
- Dataset
- None
Settings compared
layout= "nested"operator_count= 2part_labels= ["P1", "P2"]trials= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 20-21: part labels cannot be declared for nested designs.
Reference code
The lines of the reference script that produce this case's expected values.
59 emit("STAT-DOE-WORKSHEET-005", ws, "Part labels are refused for nested designs",
60 list(layout = "nested", part_labels = list("P1", "P2"), operator_count = 2L, trials = 2L), list(),
61 c("Line 20-21: part labels cannot be declared for nested designs."), kind = "invalid_input",
62 error = list(error_class = "ValueError", message_contains = "ested"))
The recorded operation recreates the worksheet
Case STAT-DOE-WORKSHEET-006 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation of the worksheet design
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/design_worksheets.R · sha256 536f8a134b709491
- Dataset
- None
Settings compared
layout= "crossed"operator_labels= ["Ann", "Bob"]part_labels= ["P1", "P2", "P3"]seed= 11trials= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows | exact | 12 | 12 | 0.00E+2 | passed | |
/cells | sequence | ['P1|Ann|1', 'P1|Ann|2', 'P1|Bob|1', 'P1|Bob|2', 'P2|Ann|1', | ['P1|Ann|1', 'P1|Ann|2', 'P1|Bob|1', 'P1|Bob|2', 'P2|Ann|1', | passed |
Convention
- Line 50-54: the adopted sheet is a separate table with its own recorded operation.
Reference code
The lines of the reference script that produce this case's expected values.
63 emit("STAT-DOE-WORKSHEET-006", op, "The recorded operation recreates the worksheet", crossed,
64 list("/rows" = exact(12L, "Twelve rows."), "/cells" = cells_of(parts, ops, 2)),
65 c("Line 50-54: the adopted sheet is a separate table with its own recorded operation."), kind = "determinism", repeat_n = 2L)
One categorical column separates the two modes
Case STAT-EXP-MODEEXPLAIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 base and stats
- Citation
- R stats::lm, stats::quantile (type 7), stats::t.test, stats::ecdf documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/explore_plots.R · sha256 15466ea60c37fc33
- Dataset
- reference_data/datasets/EXP_MODES_01.json
Settings compared
column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/mode_count | exact | 2 | 2 | 0.00E+2 | passed | |
/root/split_feature | exact | driver | driver | passed | ||
/candidates/0/feature | exact | driver | driver | passed | ||
/candidates/0/gain_normalized | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/rules/[mode=0]/conditions/[feature=driver]/label | exact | = A | = A | passed | ||
/rules/[mode=0]/support | exact | 48 | 48 | 0.00E+2 | passed | |
/rules/[mode=0]/purity | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/rules/[mode=0]/validation_purity | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/rules/[mode=1]/conditions/[feature=driver]/label | exact | = B | = B | passed | ||
/rules/[mode=1]/support | exact | 48 | 48 | 0.00E+2 | passed | |
/rules/[mode=1]/purity | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/rules/2 | absent | None | passed |
Convention
- Chapter 11: rows are labelled by density basin, modes numbered from the lowest values upward; each leaf is one rule.
- A column that separates the modes exactly has normalized information gain 1 and yields pure rules.
Reference code
The lines of the reference script that produce this case's expected values.
258 me <- "tabelz.analysis.mode_explainer:explain_modes"; mm <- "explainMultimodalityMenuItem"
259 cells1 <- expand.grid(i = 1:12, driver = c("A", "B"), kind = c("CAT", "DOG"), shift = c("day", "night"),
260 stringsAsFactors = FALSE)
261 single <- data.frame(value = ifelse(cells1$driver == "B", 12, -12) + 1.2 * qnorm(ppoints(12))[cells1$i],
262 driver = cells1$driver, unrelated = c("p", "q", "r")[(cells1$i - 1) %% 3 + 1])
263 export_dataset(single, "EXP_MODES_01",
264 "Constructed: 96 rows, two modes at -12 and 12 separated exactly by driver; unrelated is balanced within each mode",
265 "Hand-constructed", "Constructed validation data; no third-party license.",
266 c(value = "Float64", driver = "String", unrelated = "String"))
267 emit("STAT-EXP-MODEEXPLAIN-001", me, mm, "One categorical column separates the two modes",
268 list(column = "value"),
269 list("/mode_count" = exact(2L, "Two constructed modes 24 units apart."),
270 "/root/split_feature" = exact("driver", "driver alone separates the modes."),
271 "/candidates/0/feature" = exact("driver", "Ranked first by its own gain."),
272 "/candidates/0/gain_normalized" = num(1, "Perfect separation removes all mode entropy."),
273 "/rules/[mode=0]/conditions/[feature=driver]/label" = exact("= A", "Lower mode is driver A."),
274 "/rules/[mode=0]/support" = exact(48L, "All 48 A rows."),
275 "/rules/[mode=0]/purity" = num(1, "Pure on training rows."),
276 "/rules/[mode=0]/validation_purity" = num(1, "Pure on held-out rows."),
277 "/rules/[mode=1]/conditions/[feature=driver]/label" = exact("= B", "Upper mode is driver B."),
278 "/rules/[mode=1]/support" = exact(48L, "All 48 B rows."),
279 "/rules/[mode=1]/purity" = num(1, "Pure on training rows."),
280 "/rules/2" = absent("One rule per driver level.")),
281 c("Chapter 11: rows are labelled by density basin, modes numbered from the lowest values upward; each leaf is one rule.",
282 "A column that separates the modes exactly has normalized information gain 1 and yields pure rules."),
283 oracle_class = "analytic", dataset = "EXP_MODES_01")
Only a two-column conjunction identifies the upper mode
Case STAT-EXP-MODEEXPLAIN-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 base and stats
- Citation
- R stats::lm, stats::quantile (type 7), stats::t.test, stats::ecdf documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/explore_plots.R · sha256 15466ea60c37fc33
- Dataset
- reference_data/datasets/EXP_MODES_02.json
Settings compared
column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/mode_count | exact | 2 | 2 | 0.00E+2 | passed | |
/rules/[mode=1]/conditions/[feature=kind]/label | exact | = CAT | = CAT | passed | ||
/rules/[mode=1]/conditions/[feature=shift]/label | exact | = night | = night | passed | ||
/rules/[mode=1]/conditions/2 | absent | None | passed | |||
/rules/[mode=1]/support | exact | 40 | 40 | 0.00E+2 | passed | |
/rules/[mode=1]/purity | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/rules/[mode=1]/validation_purity | tolerance | 1 | 1.0 | 0.00E+2 | passed |
Convention
- Chapter 11: a mode identified only by a combination of columns appears as one rule with both conditions.
- Neither column separates the modes alone; the split order is not asserted.
Reference code
The lines of the reference script that produce this case's expected values.
284 per <- 40
285 cells2 <- expand.grid(i = 1:per, kind = c("CAT", "DOG"), shift = c("day", "night"), stringsAsFactors = FALSE)
286 upper <- cells2$kind == "CAT" & cells2$shift == "night"
287 inter_value <- numeric(nrow(cells2))
288 inter_value[upper] <- 12 + 1.2 * qnorm(ppoints(sum(upper)))
289 inter_value[!upper] <- -12 + 1.2 * qnorm(ppoints(sum(!upper)))
290 inter <- data.frame(value = inter_value, kind = cells2$kind, shift = cells2$shift)
291 export_dataset(inter, "EXP_MODES_02",
292 "Constructed: 160 rows; only kind = CAT AND shift = night (40 rows) forms the upper mode at 12",
293 "Hand-constructed", "Constructed validation data; no third-party license.",
294 c(value = "Float64", kind = "String", shift = "String"))
295 emit("STAT-EXP-MODEEXPLAIN-002", me, mm, "Only a two-column conjunction identifies the upper mode",
296 list(column = "value"),
297 list("/mode_count" = exact(2L, "Upper mode of 40 rows, lower mode of 120."),
298 "/rules/[mode=1]/conditions/[feature=kind]/label" = exact("= CAT", "Part of the conjunction."),
299 "/rules/[mode=1]/conditions/[feature=shift]/label" = exact("= night", "Part of the conjunction."),
300 "/rules/[mode=1]/conditions/2" = absent("Exactly two conditions."),
301 "/rules/[mode=1]/support" = exact(as.integer(sum(upper)), "The 40 constructed rows."),
302 "/rules/[mode=1]/purity" = num(1, "Pure on training rows."),
303 "/rules/[mode=1]/validation_purity" = num(1, "Pure on held-out rows.")),
304 c("Chapter 11: a mode identified only by a combination of columns appears as one rule with both conditions.",
305 "Neither column separates the modes alone; the split order is not asserted."),
306 oracle_class = "analytic", dataset = "EXP_MODES_02")
Retained single-Gaussian fit: exact MLE, likelihood, BIC and row allocations
Case STAT-EXP-MODEFIT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R diptest::dip and base/stats closed-form likelihood calculations
- Citation
- https://stat.ethz.ch/R-manual/R-devel/library/stats/html/Normal.html; one-Gaussian MLE mu=mean(x), variance=mean((x-mu)^2).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, diptest 0.77.2, jsonlite 2.0.0
- Reference script
- generators/r/explore_mode_screen_fit.R · sha256 6b0f4af3271659ab
- Dataset
- reference_data/datasets/EXP_MODE_CURRENT.json
Settings compared
column= "x"config= {"build_tree": false, "component_config": {"gaussian_k": 1}}implementation= "em-v2"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/variable | exact | x | x | passed | ||
/mode_count | exact | 1 | 1 | 0.00E+2 | passed | |
/row_count | exact | 32 | 32 | 0.00E+2 | passed | |
/root | absent | None | passed | |||
/training_count | exact | 0 | 0 | 0.00E+2 | passed | |
/validation_count | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/selected_key | exact | gaussian:1 | gaussian:1 | passed | ||
/component_fit/candidates/0/parameter_count | exact | 2 | 2 | 0.00E+2 | passed | |
/component_fit/candidates/0/log_likelihood | tolerance | -90.007421827624981 | -90.00742182762498 | 1.08E-16 | 17 | passed |
/component_fit/candidates/0/bic | tolerance | 186.94631546084941 | 186.9463154608494 | 4.90E-15 | 16 | passed |
/component_fit/candidates/0/components/0/family | exact | gaussian | gaussian | passed | ||
/component_fit/candidates/0/components/0/weight | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/candidates/0/components/0/mean | tolerance | 4.163336342344337e-17 | -1.6820483361490517e-16 | 2.10E-16 | passed | |
/component_fit/candidates/0/components/0/variance | tolerance | 16.241777777777777 | 16.241777777777777 | 2.03E-16 | 16 | passed |
/investigation/source_row_count | exact | 34 | 34 | 0.00E+2 | passed | |
/investigation/eligible_count | exact | 32 | 32 | 0.00E+2 | passed | |
/investigation/sampled | exact | False | False | passed | ||
/component_fit/posteriors/0/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/0 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/1/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/1 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/2/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/2 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/3/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/3 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/4/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/4 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/5/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/5 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/6/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/6 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/7/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/7 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/8/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/8 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/9/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/9 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/10/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/10 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/11/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/11 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/12/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/12 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/13/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/13 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/14/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/14 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/15/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/15 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/16/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/16 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/17/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/17 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/18/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/18 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/19/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/19 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/20/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/20 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/21/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/21 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/22/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/22 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/23/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/23 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/24/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/24 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/25/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/25 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/26/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/26 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/27/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/27 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/28/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/28 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/29/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/29 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/30/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/30 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/31/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/31 | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/110-multimodality.tex:98-117: declared Gaussian/count candidates, likelihood, posteriors and BIC; fixed K is distinct from BIC selection.
- docs/manual/chapters/110-multimodality.tex:119-124: every included finite observation is fitted unless sampling is explicitly enabled.
- em-v2 is the recorded NumPy implementation of the same fit contract; these closed-form one-component cases do not qualify multi-component starts, local optima or BIC comparisons.
- All references use re-read CSV data, omit excluded zero-based row 33, and remove missing observations per column.
Reference code
The lines of the reference script that produce this case's expected values.
157 x <- finite("x")
158 variance <- mean((x - mean(x))^2)
159 ll <- sum(dnorm(x, mean(x), sqrt(variance), log = TRUE))
160 fit_notes <- c(paste0(manual, ":98-117: declared Gaussian/count candidates, likelihood, posteriors and BIC; fixed K is distinct from BIC selection."),
161 paste0(manual, ":119-124: every included finite observation is fitted unless sampling is explicitly enabled."),
162 "em-v2 is the recorded NumPy implementation of the same fit contract; these closed-form one-component cases do not qualify multi-component starts, local optima or BIC comparisons.")
163 emit("STAT-EXP-MODEFIT-001", "Retained single-Gaussian fit: exact MLE, likelihood, BIC and row allocations", "nominal",
164 fit_entry, list(column = "x", implementation = "em-v2", config = list(build_tree = FALSE,
165 component_config = list(gaussian_k = 1L))),
166 fit_outputs("x", "gaussian", variance, ll, 2L), list(), fit_notes,
167 "https://stat.ethz.ch/R-manual/R-devel/library/stats/html/Normal.html; one-Gaussian MLE mu=mean(x), variance=mean((x-mu)^2).")
Retained Poisson fit: exact rate, likelihood, BIC and row allocations
Case STAT-EXP-MODEFIT-002 · status: passed
Reference
- Evidence type
- R
- Source
- R diptest::dip and base/stats closed-form likelihood calculations
- Citation
- https://stat.ethz.ch/R-manual/R-devel/library/stats/html/Poisson.html; one-Poisson MLE lambda=sum(y)/n, variance=lambda.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, diptest 0.77.2, jsonlite 2.0.0
- Reference script
- generators/r/explore_mode_screen_fit.R · sha256 6b0f4af3271659ab
- Dataset
- reference_data/datasets/EXP_MODE_CURRENT.json
Settings compared
column= "count"config= {"build_tree": false, "component_config": {"measurement": "count", "count_candidates": ["poisson"]}}implementation= "em-v2"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/variable | exact | count | count | passed | ||
/mode_count | exact | 1 | 1 | 0.00E+2 | passed | |
/row_count | exact | 32 | 32 | 0.00E+2 | passed | |
/root | absent | None | passed | |||
/training_count | exact | 0 | 0 | 0.00E+2 | passed | |
/validation_count | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/selected_key | exact | poisson | poisson | passed | ||
/component_fit/candidates/0/parameter_count | exact | 1 | 1 | 0.00E+2 | passed | |
/component_fit/candidates/0/log_likelihood | tolerance | -73.910006712492816 | -73.91000671249282 | 4.99E-17 | 18 | passed |
/component_fit/candidates/0/bic | tolerance | 151.28574932778537 | 151.28574932778537 | 2.23E-15 | 16 | passed |
/component_fit/candidates/0/components/0/family | exact | poisson | poisson | passed | ||
/component_fit/candidates/0/components/0/weight | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/candidates/0/components/0/mean | tolerance | 3.5 | 3.5 | 0.00E+1 | passed | |
/component_fit/candidates/0/components/0/variance | tolerance | 3.5 | 3.5 | 0.00E+1 | passed | |
/investigation/source_row_count | exact | 34 | 34 | 0.00E+2 | passed | |
/investigation/eligible_count | exact | 32 | 32 | 0.00E+2 | passed | |
/investigation/sampled | exact | False | False | passed | ||
/component_fit/posteriors/0/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/0 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/1/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/1 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/2/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/2 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/3/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/3 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/4/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/4 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/5/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/5 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/6/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/6 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/7/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/7 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/8/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/8 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/9/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/9 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/10/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/10 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/11/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/11 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/12/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/12 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/13/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/13 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/14/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/14 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/15/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/15 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/16/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/16 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/17/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/17 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/18/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/18 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/19/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/19 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/20/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/20 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/21/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/21 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/22/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/22 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/23/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/23 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/24/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/24 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/25/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/25 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/26/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/26 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/27/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/27 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/28/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/28 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/29/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/29 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/30/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/30 | exact | 0 | 0 | 0.00E+2 | passed | |
/component_fit/posteriors/31/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/component_fit/labels/31 | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/110-multimodality.tex:98-117: declared Gaussian/count candidates, likelihood, posteriors and BIC; fixed K is distinct from BIC selection.
- docs/manual/chapters/110-multimodality.tex:119-124: every included finite observation is fitted unless sampling is explicitly enabled.
- em-v2 is the recorded NumPy implementation of the same fit contract; these closed-form one-component cases do not qualify multi-component starts, local optima or BIC comparisons.
- All references use re-read CSV data, omit excluded zero-based row 33, and remove missing observations per column.
Reference code
The lines of the reference script that produce this case's expected values.
169 y <- finite("count")
170 lambda <- mean(y)
171 ll <- sum(dpois(y, lambda, log = TRUE))
172 emit("STAT-EXP-MODEFIT-002", "Retained Poisson fit: exact rate, likelihood, BIC and row allocations", "axis_coverage",
173 fit_entry, list(column = "count", implementation = "em-v2", config = list(build_tree = FALSE,
174 component_config = list(measurement = "count", count_candidates = list("poisson")))),
175 fit_outputs("count", "poisson", lambda, ll, 1L), list(), fit_notes,
176 "https://stat.ethz.ch/R-manual/R-devel/library/stats/html/Poisson.html; one-Poisson MLE lambda=sum(y)/n, variance=lambda.")
Current screen: independent dip and bandwidth on two continuous columns
Case STAT-EXP-MODESCREEN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R diptest::dip and base/stats closed-form likelihood calculations
- Citation
- https://cran.r-project.org/web/packages/diptest/diptest.pdf (dip, min.is.0=FALSE); Hartigan and Hartigan (1985), Annals of Statistics 13:70-84. Bandwidth formula: manual section 110.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, diptest 0.77.2, jsonlite 2.0.0
- Reference script
- generators/r/explore_mode_screen_fit.R · sha256 6b0f4af3271659ab
- Dataset
- reference_data/datasets/EXP_MODE_CURRENT.json
Settings compared
columns= ["x", "z"]measurement= "continuous"replicates= 999seed= 17
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 34 | 34 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/family_size | exact | 2 | 2 | 0.00E+2 | passed | |
/family_alpha | tolerance | 0.050000000000000003 | 0.05 | 2.24E-19 | 17 | passed |
/columns/[column=x]/observations | exact | 32 | 32 | 0.00E+2 | passed | |
/columns/[column=x]/missing | exact | 1 | 1 | 0.00E+2 | passed | |
/columns/[column=x]/dip/available | exact | True | True | passed | ||
/columns/[column=x]/dip/statistic | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/columns/[column=x]/dip/adjusted_p_value | absent | None | passed | |||
/columns/[column=x]/kde/available | exact | True | True | passed | ||
/columns/[column=x]/kde/standard_deviation | tolerance | 4.0945947410201615 | 4.0945947410201615 | 2.13E-17 | 17 | passed |
/columns/[column=x]/kde/interquartile_range | tolerance | 7.9466666666666672 | 7.946666666666667 | 1.14E-17 | 17 | passed |
/columns/[column=x]/kde/reference_bandwidth | tolerance | 1.8425676334590728 | 1.8425676334590728 | 1.78E-17 | 17 | passed |
/columns/[column=z]/observations | exact | 32 | 32 | 0.00E+2 | passed | |
/columns/[column=z]/missing | exact | 1 | 1 | 0.00E+2 | passed | |
/columns/[column=z]/dip/available | exact | True | True | passed | ||
/columns/[column=z]/dip/statistic | tolerance | 0.015625 | 0.015625 | 0.00E-4 | passed | |
/columns/[column=z]/dip/adjusted_p_value | absent | None | passed | |||
/columns/[column=z]/kde/available | exact | True | True | passed | ||
/columns/[column=z]/kde/standard_deviation | tolerance | 0.99607135474820041 | 0.9960713547482004 | 4.34E-19 | 18 | passed |
/columns/[column=z]/kde/interquartile_range | tolerance | 1.3014057102658145 | 1.3014057102658145 | 3.04E-17 | 16 | passed |
/columns/[column=z]/kde/reference_bandwidth | tolerance | 0.43412347636739557 | 0.43412347636739557 | 3.44E-18 | 17 | passed |
Convention
- docs/manual/chapters/110-multimodality.tex:3-27: finite included population; dip on continuous measurements and new unadjusted screens.
- docs/manual/chapters/110-multimodality.tex:37-44: h0 uses sample SD, type-7 IQR and multiplier 0.9; bounded support prevents automatic KDE interpretation.
- All references use re-read CSV data, omit excluded zero-based row 33, and remove missing observations per column.
Reference code
The lines of the reference script that produce this case's expected values.
99 screen_notes <- c(paste0(manual, ":3-27: finite included population; dip on continuous measurements and new unadjusted screens."),
100 paste0(manual, ":37-44: h0 uses sample SD, type-7 IQR and multiplier 0.9; bounded support prevents automatic KDE interpretation."))
101 dip_citation <- "https://cran.r-project.org/web/packages/diptest/diptest.pdf (dip, min.is.0=FALSE); Hartigan and Hartigan (1985), Annals of Statistics 13:70-84. Bandwidth formula: manual section 110."
102 emit("STAT-EXP-MODESCREEN-001", "Current screen: independent dip and bandwidth on two continuous columns", "nominal",
103 screen_entry, list(columns = list("x", "z"), measurement = "continuous", replicates = 999L, seed = 17L),
104 c(screen_base(c("x", "z")), screen_column("x"), screen_column("z")),
105 screen_deferred(c("x", "z")), screen_notes, dip_citation)
Bounded support: dip remains available and automatic KDE signal is refused
Case STAT-EXP-MODESCREEN-002 · status: passed
Reference
- Evidence type
- R
- Source
- R diptest::dip and base/stats closed-form likelihood calculations
- Citation
- https://cran.r-project.org/web/packages/diptest/diptest.pdf (dip, min.is.0=FALSE); Hartigan and Hartigan (1985), Annals of Statistics 13:70-84. Bandwidth formula: manual section 110.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, diptest 0.77.2, jsonlite 2.0.0
- Reference script
- generators/r/explore_mode_screen_fit.R · sha256 6b0f4af3271659ab
- Dataset
- reference_data/datasets/EXP_MODE_CURRENT.json
Settings compared
columns= ["x"]measurement= "continuous"replicates= 999seed= 17support= "bounded"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 34 | 34 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/family_size | exact | 1 | 1 | 0.00E+2 | passed | |
/family_alpha | tolerance | 0.050000000000000003 | 0.05 | 2.24E-19 | 17 | passed |
/columns/[column=x]/observations | exact | 32 | 32 | 0.00E+2 | passed | |
/columns/[column=x]/missing | exact | 1 | 1 | 0.00E+2 | passed | |
/columns/[column=x]/dip/available | exact | True | True | passed | ||
/columns/[column=x]/dip/statistic | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/columns/[column=x]/dip/adjusted_p_value | absent | None | passed | |||
/columns/[column=x]/kde/available | exact | False | False | passed | ||
/columns/[column=x]/kde/standard_deviation | tolerance | 4.0945947410201615 | 4.0945947410201615 | 2.13E-17 | 17 | passed |
/columns/[column=x]/kde/interquartile_range | tolerance | 7.9466666666666672 | 7.946666666666667 | 1.14E-17 | 17 | passed |
/columns/[column=x]/kde/reference_bandwidth | tolerance | 1.8425676334590728 | 1.8425676334590728 | 1.78E-17 | 17 | passed |
/columns/0/available_methods | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/110-multimodality.tex:3-27: finite included population; dip on continuous measurements and new unadjusted screens.
- docs/manual/chapters/110-multimodality.tex:37-44: h0 uses sample SD, type-7 IQR and multiplier 0.9; bounded support prevents automatic KDE interpretation.
- All references use re-read CSV data, omit excluded zero-based row 33, and remove missing observations per column.
Reference code
The lines of the reference script that produce this case's expected values.
107 emit("STAT-EXP-MODESCREEN-002", "Bounded support: dip remains available and automatic KDE signal is refused", "axis_coverage",
108 screen_entry, list(columns = list("x"), measurement = "continuous", support = "bounded", replicates = 999L, seed = 17L),
109 c(screen_base("x"), screen_column("x", restricted = TRUE),
110 list("/columns/0/available_methods" = exact(1L, "Only dip is available under the declared restricted support"))),
111 screen_deferred("x"), screen_notes, dip_citation)
Declared discrete counts refuse both continuous screen methods
Case STAT-EXP-MODESCREEN-003 · status: passed
Reference
- Evidence type
- R
- Source
- R diptest::dip and base/stats closed-form likelihood calculations
- Citation
- Analytic eligibility contract in docs/manual/chapters/110-multimodality.tex; counts constructed in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, diptest 0.77.2, jsonlite 2.0.0
- Reference script
- generators/r/explore_mode_screen_fit.R · sha256 6b0f4af3271659ab
- Dataset
- reference_data/datasets/EXP_MODE_CURRENT.json
Settings compared
columns= ["count"]measurement= "discrete"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 34 | 34 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/family_size | exact | 1 | 1 | 0.00E+2 | passed | |
/family_alpha | tolerance | 0.050000000000000003 | 0.05 | 2.24E-19 | 17 | passed |
/columns/0/observations | exact | 32 | 32 | 0.00E+2 | passed | |
/columns/0/missing | exact | 1 | 1 | 0.00E+2 | passed | |
/columns/0/dip/available | exact | False | False | passed | ||
/columns/0/dip/statistic | absent | None | passed | |||
/columns/0/dip/p_value | absent | None | passed | |||
/columns/0/kde/available | exact | False | False | passed | ||
/columns/0/available_methods | exact | 0 | 0 | 0.00E+2 | passed | |
/columns/0/positive_methods | exact | 0 | 0 | 0.00E+2 | passed | |
/columns/0/explain_positive | exact | False | False | passed |
Convention
- docs/manual/chapters/110-multimodality.tex:3-27: finite included population; dip on continuous measurements and new unadjusted screens.
- docs/manual/chapters/110-multimodality.tex:37-44: h0 uses sample SD, type-7 IQR and multiplier 0.9; bounded support prevents automatic KDE interpretation.
- docs/manual/chapters/110-multimodality.tex:10-17,92-94: known discrete data are ineligible for the continuous screen.
- All references use re-read CSV data, omit excluded zero-based row 33, and remove missing observations per column.
Reference code
The lines of the reference script that produce this case's expected values.
113 emit("STAT-EXP-MODESCREEN-003", "Declared discrete counts refuse both continuous screen methods", "boundary",
114 screen_entry, list(columns = list("count"), measurement = "discrete"),
115 c(screen_base("count"), list(
116 "/columns/0/observations" = exact(length(finite("count")), "Included finite count observations"),
117 "/columns/0/missing" = exact(1L, "One included missing count"),
118 "/columns/0/dip/available" = exact(FALSE, "Known discrete data are ineligible"),
119 "/columns/0/dip/statistic" = exact(NULL, "No continuous dip statistic is reported"),
120 "/columns/0/dip/p_value" = exact(NULL, "No continuous p-value is reported"),
121 "/columns/0/kde/available" = exact(FALSE, "Known discrete data are ineligible"),
122 "/columns/0/available_methods" = exact(0L, "Neither continuous method is eligible"),
123 "/columns/0/positive_methods" = exact(0L, "Unavailable methods cannot be positive"),
124 "/columns/0/explain_positive" = exact(FALSE, "No positive screen gate")
125 )), list(), c(screen_notes, paste0(manual, ":10-17,92-94: known discrete data are ineligible for the continuous screen.")),
126 "Analytic eligibility contract in docs/manual/chapters/110-multimodality.tex; counts constructed in R.")
Bimodality coefficient of two separated modes
Case STAT-EXP-MULTIMODAL-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 base and stats
- Citation
- R stats::lm, stats::quantile (type 7), stats::t.test, stats::ecdf documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/explore_plots.R · sha256 15466ea60c37fc33
- Dataset
- reference_data/datasets/EXP_PLOTS_01.json
Settings compared
active_methods= ["BC"]columns= ["m"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/columns/0/finite_count | exact | 24 | 24 | 0.00E+2 | passed | |
/columns/0/bc_value | tolerance | 0.59904644491418324 | 0.5990464449141829 | 3.33E-16 | 15 | passed |
/columns/0/passed | contains | ['BC'] | ['BC'] | passed |
Convention
- Sarle's bimodality coefficient (SAS definition); the manual does not define it.
- The column is two normal-score blocks of 12, 6 units apart.
Reference code
The lines of the reference script that produce this case's expected values.
196 w <- d$m
197 n <- length(w)
198 m2 <- mean((w - mean(w))^2); m3 <- mean((w - mean(w))^3); m4 <- mean((w - mean(w))^4)
199 skew <- m3 / m2^1.5 * sqrt(n * (n - 1)) / (n - 2)
200 kurt <- ((n + 1) * (m4 / m2^2 - 3) + 6) * (n - 1) / ((n - 2) * (n - 3))
201 bc <- (skew^2 + 1) / (kurt + 3 * (n - 1)^2 / ((n - 2) * (n - 3)))
202 stopifnot(bc > 0.555)
203 emit("STAT-EXP-MULTIMODAL-001", "tabelz.analysis.multimodality:compute_multimodality", "multimodalityMenuItem",
204 "Bimodality coefficient of two separated modes", list(columns = list("m"), active_methods = list("BC")),
205 list("/columns/0/finite_count" = exact(24L, "All values are finite."),
206 "/columns/0/bc_value" = num(bc, "Sarle's coefficient with adjusted skewness G1 and excess kurtosis G2."),
207 "/columns/0/passed" = contains("BC", "BC exceeds the 5/9 uniform benchmark.")),
208 c("Sarle's bimodality coefficient (SAS definition); the manual does not define it.",
209 "The column is two normal-score blocks of 12, 6 units apart."), oracle_class = "analytic")
test six mp table matches the published greenwood log log values
Case STAT-HARV-GEHAN-KM-001 · status: imprecise_reference
Reference
- Evidence type
- Published example
- Source
- Freireich et al. (1963); Gehan (1965), 6-MP/placebo remission data.
- Citation
- Freireich et al. (1963); Gehan (1965), 6-MP/placebo remission data.
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/HARVEST_GEHAN_MP.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/curves/0/n | exact | 21 | 21 | 0.00E+2 | passed | |
/curves/0/events | exact | 9 | 9 | 0.00E+2 | passed | |
/curves/0/censored | exact | 12 | 12 | 0.00E+2 | passed | |
/curves/0/median/time | tolerance | 23.0 | 23.0 | 0.00E+1 | 15 | passed |
/curves/0/at_risk/0 | exact | 21 | 21 | 0.00E+2 | passed | |
/curves/0/event_counts/0 | exact | 3 | 3 | 0.00E+2 | passed | |
/curves/0/survival/0 | tolerance | 0.8571 | 0.8571428571428572 | 4.29E-5 | 4 | passed |
/curves/0/standard_error/0 | tolerance | 0.0764 | 0.07636035483212125 | imprecise_reference | ||
/curves/0/lower/0 | tolerance | 0.6197 | 0.6197179552659838 | 1.80E-5 | 4 | passed |
/curves/0/upper/0 | tolerance | 0.9516 | 0.951551747646997 | 4.83E-5 | 4 | passed |
/curves/0/at_risk/1 | exact | 17 | 17 | 0.00E+2 | passed | |
/curves/0/event_counts/1 | exact | 1 | 1 | 0.00E+2 | passed | |
/curves/0/survival/1 | tolerance | 0.8067 | 0.8067226890756303 | 2.27E-5 | 4 | passed |
/curves/0/standard_error/1 | tolerance | 0.0869 | 0.0869352851800572 | imprecise_reference | ||
/curves/0/lower/1 | tolerance | 0.5631 | 0.5631465646222334 | 4.66E-5 | 4 | passed |
/curves/0/upper/1 | tolerance | 0.9228 | 0.9228090192028805 | 9.02E-6 | 5 | passed |
/curves/0/at_risk/3 | exact | 15 | 15 | 0.00E+2 | passed | |
/curves/0/event_counts/3 | exact | 1 | 1 | 0.00E+2 | passed | |
/curves/0/survival/3 | tolerance | 0.7529 | 0.7529411764705882 | 4.12E-5 | 4 | passed |
/curves/0/standard_error/3 | tolerance | 0.0963 | 0.09634965299432051 | imprecise_reference | ||
/curves/0/lower/3 | tolerance | 0.5032 | 0.5031995107999565 | 4.89E-7 | 6 | passed |
/curves/0/upper/3 | tolerance | 0.8894 | 0.8893618351692655 | 3.82E-5 | 4 | passed |
/curves/0/at_risk/5 | exact | 12 | 12 | 0.00E+2 | passed | |
/curves/0/event_counts/5 | exact | 1 | 1 | 0.00E+2 | passed | |
/curves/0/survival/5 | tolerance | 0.6902 | 0.6901960784313725 | 3.92E-6 | 5 | passed |
/curves/0/standard_error/5 | tolerance | 0.1068 | 0.10681470777500983 | imprecise_reference | ||
/curves/0/lower/5 | tolerance | 0.4316 | 0.43161022248618414 | 1.02E-5 | 4 | passed |
/curves/0/upper/5 | tolerance | 0.8491 | 0.8490659633494507 | 3.40E-5 | 4 | passed |
/curves/0/at_risk/6 | exact | 11 | 11 | 0.00E+2 | passed | |
/curves/0/event_counts/6 | exact | 1 | 1 | 0.00E+2 | passed | |
/curves/0/survival/6 | tolerance | 0.6275 | 0.6274509803921569 | 4.90E-5 | 4 | passed |
/curves/0/standard_error/6 | tolerance | 0.1141 | 0.11405386525675254 | imprecise_reference | ||
/curves/0/lower/6 | tolerance | 0.3675 | 0.3675108559875021 | 1.09E-5 | 4 | passed |
/curves/0/upper/6 | tolerance | 0.8049 | 0.8049121894718413 | 1.22E-5 | 4 | passed |
/curves/0/at_risk/10 | exact | 7 | 7 | 0.00E+2 | passed | |
/curves/0/event_counts/10 | exact | 1 | 1 | 0.00E+2 | passed | |
/curves/0/survival/10 | tolerance | 0.5378 | 0.5378151260504203 | 1.51E-5 | 4 | passed |
/curves/0/standard_error/10 | tolerance | 0.1282 | 0.12823375169303403 | imprecise_reference | ||
/curves/0/lower/10 | tolerance | 0.2678 | 0.2677789367671351 | 2.11E-5 | 4 | passed |
/curves/0/upper/10 | tolerance | 0.7468 | 0.7467907176353946 | 9.28E-6 | 4 | passed |
/curves/0/at_risk/11 | exact | 6 | 6 | 0.00E+2 | passed | |
/curves/0/event_counts/11 | exact | 1 | 1 | 0.00E+2 | passed | |
/curves/0/survival/11 | tolerance | 0.4482 | 0.44817927170868355 | 2.07E-5 | 4 | passed |
/curves/0/standard_error/11 | tolerance | 0.1346 | 0.13459145675576048 | 8.54E-6 | 4 | passed |
/curves/0/lower/11 | tolerance | 0.1881 | 0.18805200595923244 | imprecise_reference | ||
/curves/0/upper/11 | tolerance | 0.6801 | 0.6801426284952415 | 4.26E-5 | 4 | passed |
Convention
- Transcribed from tests/unit/analysis/test_survival_nonparametric.py::test_six_mp_table_matches_the_published_greenwood_log_log_values; not yet re-checked against the original source.
- R also distributes Gehan 6-MP data as MASS::gehan; cross-check in V16-V22.
test gehan log rank matches the published chi square
Case STAT-HARV-GEHAN-LOGRANK-001 · status: imprecise_reference
Reference
- Evidence type
- Published example
- Source
- Freireich et al. (1963); Gehan (1965), 6-MP/placebo remission data.
- Citation
- Freireich et al. (1963); Gehan (1965), 6-MP/placebo remission data.
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/HARVEST_GEHAN_BOTH.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"group_column= "arm"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/log_rank/observed/0 | exact | 9 | 9 | 0.00E+2 | passed | |
/log_rank/observed/1 | exact | 21 | 21 | 0.00E+2 | passed | |
/log_rank/expected/0 | tolerance | 19.25 | 19.25050094803113 | 5.01E-4 | 4 | passed |
/log_rank/expected/1 | tolerance | 10.75 | 10.749499051968868 | 5.01E-4 | 4 | passed |
/log_rank/statistic | tolerance | 16.79 | 16.79294098921654 | imprecise_reference | ||
/log_rank/degrees_of_freedom | exact | 1 | 1 | 0.00E+2 | passed | |
/log_rank/p_value | tolerance | 4.17e-5 | 4.1688091093345274e-05 | imprecise_reference | ||
/curves/1/median/time | tolerance | 8.0 | 8.0 | 0.00E+1 | 15 | passed |
Convention
- Transcribed from tests/unit/analysis/test_survival_nonparametric.py::test_gehan_log_rank_matches_the_published_chi_square; not yet re-checked against the original source.
- R also distributes Gehan 6-MP data as MASS::gehan; cross-check in V16-V22.
test grubbs matches nist fixture and preserves candidate
Case STAT-HARV-NIST-GRUBBS-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- NIST e-Handbook 1.3.5.17.1, Grubbs' Test for Outliers, https://www.itl.nist.gov/div898/handbook/eda/section3/eda35h1.htm
- Citation
- NIST e-Handbook 1.3.5.17.1, Grubbs' Test for Outliers, https://www.itl.nist.gov/div898/handbook/eda/section3/eda35h1.htm
- Reference software
- not recorded
- Reference script
- generators/build_harvested_cases.py · sha256 24024e79e196b541
- Dataset
- reference_data/datasets/HARVEST_NIST_GRUBBS_PRIMARY.json
Settings compared
column= "x"method= "grubbs"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 2.46876461121245051092e+0 | 2.46876461121245 | 3.45E-16 | 15 | passed |
/critical_value | tolerance | 2.12664508719546529412e+0 | 2.1266450871954667 | 1.45E-15 | 15 | passed |
/p_value | tolerance | 3.00263868207083747264e-7 | 3.002638682071362e-07 | 5.25E-20 | 12 | passed |
Convention
- Eight uranium-isotope measurements verified against NIST e-Handbook 1.3.5.17.1.
- This case uses NIST's two-sided critical-value formula; its worked example instead prints the upper one-sided critical value 2.032.
- Expected values are computed here in 60-digit decimal from the exact even-df Student t series (Abramowitz and Stegun 26.7.3), independent of SciPy.
- Until 2026-09-25 the expectations were the unit test's 14-digit values, which were SciPy output: the critical value was truncated and the p-value 1.7e-13 off.
Reference code
The lines of the reference script that produce this case's expected values.
184 def _grubbs() -> None:
185 dataset_id = "HARVEST_NIST_GRUBBS_PRIMARY"
186 source = (
187 "NIST e-Handbook 1.3.5.17.1, Grubbs' Test for Outliers, "
188 "https://www.itl.nist.gov/div898/handbook/eda/section3/eda35h1.htm"
189 )
190 values = (199.31, 199.53, 200.19, 200.82, 201.92, 201.95, 202.18, 245.57)
191 _dataset(dataset_id, [("x", "Float64")], [(x,) for x in values], source, source)
192 g, critical, p_value = _grubbs_exact(values, "0.05")
193 _case(
194 "STAT-HARV-NIST-GRUBBS-001",
195 dataset_id,
196 "tabelz.executor.distribution_diagnostics",
197 "distributionDiagnosticsMenuItem",
198 {"column": "x", "method": "grubbs"},
199 {
200 "/statistic": _relative(g, "G = max|x - mean| / s in 60-digit decimal."),
201 "/critical_value": _relative(
202 critical, "(n-1)/sqrt(n) sqrt(t^2/(n-2+t^2)), t the alpha/(2n) upper quantile."
203 ),
204 "/p_value": _relative(p_value, "min(1, 2n P(T > t_G)) with n - 2 = 6 df."),
205 },
206 source,
207 "test_grubbs_matches_nist_fixture_and_preserves_candidate",
208 ["tests/unit/analysis/test_distribution_diagnostics.py"],
209 oracle_class="analytic",
210 oracle_notes=[
211 "Eight uranium-isotope measurements verified against NIST e-Handbook 1.3.5.17.1.",
212 "This case uses NIST's two-sided critical-value formula; its worked "
213 "example instead prints the upper one-sided critical value 2.032.",
214 "Expected values are computed here in 60-digit decimal from the exact even-df "
ANOM normal two groups
Case STAT-HYP-ANALYSIS-OF-MEANS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::qt
- Citation
- Nelson LS (1982), Journal of Quality Technology 14, 172-173 (two-group ANOM reduces to the t quantile); R Core Team, stats package help: qt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_analysis_of_means.R · sha256 d1cae03fb86acee1
- Dataset
- reference_data/datasets/HYP_ANOM.json
Settings compared
alpha= "0.05"analysis= "normal_one_way"group= "g2"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/panels/0/center | tolerance | 11.34375 | 11.34375 | 0.00E-3 | passed | |
/panels/0/critical_value | tolerance | 2.1447866879178039 | 2.144786687917794 | 9.76E-15 | 14 | passed |
/panels/0/critical_df | exact | 14 | 14 | 0.00E+2 | passed | |
/panels/0/groups/0/label | exact | A | A | passed | ||
/panels/0/groups/0/size | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/panels/0/groups/0/rows | exact | 7 | 7 | 0.00E+2 | passed | |
/panels/0/groups/0/statistic | tolerance | 10.214285714285714 | 10.214285714285714 | 4.76E-16 | 16 | passed |
/panels/0/groups/0/standard_error | tolerance | 0.2501748659574965 | 0.2501748659574966 | 1.06E-16 | 15 | passed |
/panels/0/groups/0/lower | tolerance | 10.807178277842741 | 10.807178277842743 | 1.99E-15 | 15 | passed |
/panels/0/groups/0/upper | tolerance | 11.880321722157259 | 11.880321722157257 | 1.99E-15 | 15 | passed |
/panels/0/groups/0/decision | exact | below | below | passed | ||
/panels/0/groups/1/label | exact | B | B | passed | ||
/panels/0/groups/1/size | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/panels/0/groups/1/rows | exact | 9 | 9 | 0.00E+2 | passed | |
/panels/0/groups/1/statistic | tolerance | 12.222222222222221 | 12.222222222222221 | 4.33E-16 | 16 | passed |
/panels/0/groups/1/standard_error | tolerance | 0.19458045130027504 | 0.19458045130027515 | 1.13E-16 | 15 | passed |
/panels/0/groups/1/lower | tolerance | 10.926416438322132 | 10.926416438322134 | 1.83E-15 | 15 | passed |
/panels/0/groups/1/upper | tolerance | 11.761083561677868 | 11.761083561677866 | 1.83E-15 | 15 | passed |
/panels/0/groups/1/decision | exact | above | above | passed | ||
/panels/0/signals | exact | 2 | 2 | 0.00E+2 | passed | |
/pooled_sd | tolerance | 0.88253397280327273 | 0.8825339728032732 | 4.40E-16 | 15 | passed |
/residual_df | exact | 14 | 14 | 0.00E+2 | passed | |
/observations | exact | 16 | 16 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Two groups: the two deviations are exactly anticorrelated, so P(max |T_i| <= h) = P(|t_df| <= h) and h = qt(1 - alpha/2, N - k) in closed form.
- Groups in sorted label order; centre is the weighted grand mean (pooled proportion or rate); limits are centre +/- h SE_i; a group is 'above', 'below' or 'within'.
- docs/manual/chapters/99-analysis-of-means.tex:10-19: limits ybar +/- h s_p sqrt((N - n_i)/(N n_i)) with pooled SD s_p and the joint critical value depending on the group sizes and residual df.
- docs/manual/chapters/99-analysis-of-means.tex:53-60: two-factor ANOM with alpha per chart; binomial ANOM pools successes and trials; Poisson ANOM pools counts and exposure.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
46 emit <- function(id, title, kind, config, outputs, notes, source_ref, citation, oracle_class = "independent_implementation") {
47 write_expected("hypothesis", id, list(
48 schema_version = "2.0.0", case_id = id, outputs = outputs, expected_error = NULL,
49 deferred_outputs = list(), generator_run = run))
50 write_case("hypothesis", id, list(
51 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "hypothesis",
52 entry_point = entry, menu_items = list(menu), title = title, case_kind = kind,
53 dataset = list(path = "reference_data/datasets/HYP_ANOM.json", sha256 = ""),
54 excluded_rows = list(), configuration = config, "repeat" = 1L,
55 expected = list(path = paste0("reference_data/expected/hypothesis/", id, ".json"), sha256 = ""),
56 oracle = list(oracle_class = oracle_class, source = source_ref, citation = citation,
57 generator = list(path = "generators/r/hypothesis_analysis_of_means.R", sha256 = ""),
58 independent = TRUE,
59 convention_notes = c(notes, notes_common, "Expected computed from the exported CSV.")),
60 supported = TRUE, unsupported_reason = NULL,
61 requirement_ids = list("REQ-STAT-HYP-ANALYSIS-OF-MEANS-001"),
62 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
ANOM normal three groups
Case STAT-HYP-ANALYSIS-OF-MEANS-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::integrate, uniroot
- Citation
- Nelson LS (1982), Journal of Quality Technology 14, 172-173 (the max |T_i| distribution of ANOM); R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_analysis_of_means.R · sha256 d1cae03fb86acee1
- Dataset
- reference_data/datasets/HYP_ANOM.json
Settings compared
alpha= "0.05"analysis= "normal_one_way"group= "g3"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/panels/0/center | tolerance | 11.34375 | 11.34375 | 0.00E-3 | passed | |
/panels/0/critical_value | tolerance | 2.6401054524430605 | 2.6401054524430996 | 3.91E-14 | 13 | passed |
/panels/0/critical_df | exact | 13 | 13 | 0.00E+2 | passed | |
/panels/0/groups/0/label | exact | A | A | passed | ||
/panels/0/groups/0/size | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/panels/0/groups/0/rows | exact | 5 | 5 | 0.00E+2 | passed | |
/panels/0/groups/0/statistic | tolerance | 10.08 | 10.08 | 7.11E-17 | 17 | passed |
/panels/0/groups/0/standard_error | tolerance | 0.38957899695927523 | 0.3895789969592754 | 1.62E-16 | 15 | passed |
/panels/0/groups/0/lower | tolerance | 10.31522036597052 | 10.315220365970504 | 1.63E-14 | 14 | passed |
/panels/0/groups/0/upper | tolerance | 12.37227963402948 | 12.372279634029496 | 1.63E-14 | 14 | passed |
/panels/0/groups/0/decision | exact | below | below | passed | ||
/panels/0/groups/1/label | exact | B | B | passed | ||
/panels/0/groups/1/size | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/panels/0/groups/1/rows | exact | 5 | 5 | 0.00E+2 | passed | |
/panels/0/groups/1/statistic | tolerance | 11.620000000000001 | 11.620000000000001 | 5.24E-18 | 18 | passed |
/panels/0/groups/1/standard_error | tolerance | 0.38957899695927523 | 0.3895789969592754 | 1.62E-16 | 15 | passed |
/panels/0/groups/1/lower | tolerance | 10.31522036597052 | 10.315220365970504 | 1.63E-14 | 14 | passed |
/panels/0/groups/1/upper | tolerance | 12.37227963402948 | 12.372279634029496 | 1.63E-14 | 14 | passed |
/panels/0/groups/1/decision | exact | within | within | passed | ||
/panels/0/groups/2/label | exact | C | C | passed | ||
/panels/0/groups/2/size | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/panels/0/groups/2/rows | exact | 6 | 6 | 0.00E+2 | passed | |
/panels/0/groups/2/statistic | tolerance | 12.166666666666666 | 12.166666666666666 | 7.45E-17 | 17 | passed |
/panels/0/groups/2/standard_error | tolerance | 0.33908499300121281 | 0.339084993001213 | 1.65E-16 | 15 | passed |
/panels/0/groups/2/lower | tolerance | 10.448529861135881 | 10.448529861135867 | 1.38E-14 | 14 | passed |
/panels/0/groups/2/upper | tolerance | 12.238970138864119 | 12.238970138864133 | 1.38E-14 | 14 | passed |
/panels/0/groups/2/decision | exact | within | within | passed | ||
/panels/0/signals | exact | 1 | 1 | 0.00E+2 | passed | |
/pooled_sd | tolerance | 1.0506164246740446 | 1.050616424674045 | 4.35E-16 | 15 | passed |
/residual_df | exact | 13 | 13 | 0.00E+2 | passed | |
/observations | exact | 16 | 16 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Three groups: h solves P(max |T_i| <= h) = 1 - alpha with T = Z / S, Z jointly normal with the singular deviation correlation -sqrt(n_i n_j / ((N - n_i)(N - n_j))) and S the scaled chi on N - k df; the probability is a deterministic quadrature (closed-form inner normal interval, integrate over Z_1 and over S, rel.tol 1e-11) and h a uniroot to 1e-12. Both sides are numerical integrations, hence 1e-6 relative on h and the limits.
- Groups in sorted label order; centre is the weighted grand mean (pooled proportion or rate); limits are centre +/- h SE_i; a group is 'above', 'below' or 'within'.
- docs/manual/chapters/99-analysis-of-means.tex:10-19: limits ybar +/- h s_p sqrt((N - n_i)/(N n_i)) with pooled SD s_p and the joint critical value depending on the group sizes and residual df.
- docs/manual/chapters/99-analysis-of-means.tex:53-60: two-factor ANOM with alpha per chart; binomial ANOM pools successes and trials; Poisson ANOM pools counts and exposure.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
159 normal_one_way("STAT-HYP-ANALYSIS-OF-MEANS-002", "ANOM normal three groups", "axis_coverage", "g3", 0.05)
ANOM normal two groups alpha 0.01
Case STAT-HYP-ANALYSIS-OF-MEANS-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::qt
- Citation
- Nelson LS (1982), Journal of Quality Technology 14, 172-173 (two-group ANOM reduces to the t quantile); R Core Team, stats package help: qt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_analysis_of_means.R · sha256 d1cae03fb86acee1
- Dataset
- reference_data/datasets/HYP_ANOM.json
Settings compared
alpha= "0.01"analysis= "normal_one_way"group= "g2"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/panels/0/center | tolerance | 11.34375 | 11.34375 | 0.00E-3 | passed | |
/panels/0/critical_value | tolerance | 2.9768427343708339 | 2.976842734370781 | 5.28E-14 | 13 | passed |
/panels/0/critical_df | exact | 14 | 14 | 0.00E+2 | passed | |
/panels/0/groups/0/label | exact | A | A | passed | ||
/panels/0/groups/0/size | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/panels/0/groups/0/rows | exact | 7 | 7 | 0.00E+2 | passed | |
/panels/0/groups/0/statistic | tolerance | 10.214285714285714 | 10.214285714285714 | 4.76E-16 | 16 | passed |
/panels/0/groups/0/standard_error | tolerance | 0.2501748659574965 | 0.2501748659574966 | 1.06E-16 | 15 | passed |
/panels/0/groups/0/lower | tolerance | 10.599018767952229 | 10.599018767952241 | 1.24E-14 | 14 | passed |
/panels/0/groups/0/upper | tolerance | 12.088481232047771 | 12.088481232047759 | 1.24E-14 | 14 | passed |
/panels/0/groups/0/decision | exact | below | below | passed | ||
/panels/0/groups/1/label | exact | B | B | passed | ||
/panels/0/groups/1/size | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/panels/0/groups/1/rows | exact | 9 | 9 | 0.00E+2 | passed | |
/panels/0/groups/1/statistic | tolerance | 12.222222222222221 | 12.222222222222221 | 4.33E-16 | 16 | passed |
/panels/0/groups/1/standard_error | tolerance | 0.19458045130027504 | 0.19458045130027515 | 1.13E-16 | 15 | passed |
/panels/0/groups/1/lower | tolerance | 10.764514597296179 | 10.764514597296188 | 8.76E-15 | 15 | passed |
/panels/0/groups/1/upper | tolerance | 11.922985402703821 | 11.922985402703812 | 8.76E-15 | 15 | passed |
/panels/0/groups/1/decision | exact | above | above | passed | ||
/panels/0/signals | exact | 2 | 2 | 0.00E+2 | passed | |
/pooled_sd | tolerance | 0.88253397280327273 | 0.8825339728032732 | 4.40E-16 | 15 | passed |
/residual_df | exact | 14 | 14 | 0.00E+2 | passed | |
/observations | exact | 16 | 16 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Two groups: the two deviations are exactly anticorrelated, so P(max |T_i| <= h) = P(|t_df| <= h) and h = qt(1 - alpha/2, N - k) in closed form.
- Groups in sorted label order; centre is the weighted grand mean (pooled proportion or rate); limits are centre +/- h SE_i; a group is 'above', 'below' or 'within'.
- docs/manual/chapters/99-analysis-of-means.tex:10-19: limits ybar +/- h s_p sqrt((N - n_i)/(N n_i)) with pooled SD s_p and the joint critical value depending on the group sizes and residual df.
- docs/manual/chapters/99-analysis-of-means.tex:53-60: two-factor ANOM with alpha per chart; binomial ANOM pools successes and trials; Poisson ANOM pools counts and exposure.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
160 normal_one_way("STAT-HYP-ANALYSIS-OF-MEANS-003", "ANOM normal two groups alpha 0.01", "axis_coverage", "g2", 0.01)
ANOM normal two-way 2 x 2
Case STAT-HYP-ANALYSIS-OF-MEANS-004 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::qt
- Citation
- Nelson PR, Wludyka PS, Copeland KAF (2005), The Analysis of Means, SIAM, ch. 6 (two-way ANOM; a 2 x 2 interaction reduces to a t quantile); R Core Team, stats package help: qt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_analysis_of_means.R · sha256 d1cae03fb86acee1
- Dataset
- reference_data/datasets/HYP_ANOM.json
Settings compared
alpha= "0.05"analysis= "normal_two_way"factor_a= "fa"factor_b= "fb"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/panels/0/center | tolerance | 11.34375 | 11.343749999999998 | 1.78E-15 | 15 | passed |
/panels/0/critical_value | tolerance | 2.1788128296672284 | 2.178812829667218 | 1.06E-14 | 14 | passed |
/panels/0/critical_df | exact | 12 | 12 | 0.00E+2 | passed | |
/panels/0/groups/0/label | exact | high | high | passed | ||
/panels/0/groups/0/size | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/panels/0/groups/0/rows | exact | 8 | 8 | 0.00E+2 | passed | |
/panels/0/groups/0/statistic | tolerance | 12.2125 | 12.212499999999999 | 1.42E-15 | 15 | passed |
/panels/0/groups/0/standard_error | tolerance | 0.26217738111184707 | 0.2621773811118473 | 2.26E-16 | 15 | passed |
/panels/0/groups/0/lower | tolerance | 10.772514558384954 | 10.772514558384954 | 4.69E-16 | 16 | passed |
/panels/0/groups/0/upper | tolerance | 11.914985441615046 | 11.914985441615043 | 3.08E-15 | 15 | passed |
/panels/0/groups/0/decision | exact | above | above | passed | ||
/panels/0/groups/1/label | exact | low | low | passed | ||
/panels/0/groups/1/size | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/panels/0/groups/1/rows | exact | 8 | 8 | 0.00E+2 | passed | |
/panels/0/groups/1/statistic | tolerance | 10.475000000000001 | 10.475000000000001 | 4.21E-16 | 16 | passed |
/panels/0/groups/1/standard_error | tolerance | 0.26217738111184707 | 0.2621773811118473 | 2.26E-16 | 15 | passed |
/panels/0/groups/1/lower | tolerance | 10.772514558384954 | 10.772514558384954 | 4.69E-16 | 16 | passed |
/panels/0/groups/1/upper | tolerance | 11.914985441615046 | 11.914985441615043 | 3.08E-15 | 15 | passed |
/panels/0/groups/1/decision | exact | below | below | passed | ||
/panels/0/signals | exact | 2 | 2 | 0.00E+2 | passed | |
/panels/1/center | tolerance | 11.34375 | 11.343749999999998 | 1.78E-15 | 15 | passed |
/panels/1/critical_value | tolerance | 2.1788128296672284 | 2.178812829667218 | 1.06E-14 | 14 | passed |
/panels/1/critical_df | exact | 12 | 12 | 0.00E+2 | passed | |
/panels/1/groups/0/label | exact | cold | cold | passed | ||
/panels/1/groups/0/size | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/panels/1/groups/0/rows | exact | 8 | 8 | 0.00E+2 | passed | |
/panels/1/groups/0/statistic | tolerance | 11.0875 | 11.0875 | 3.55E-16 | 16 | passed |
/panels/1/groups/0/standard_error | tolerance | 0.26217738111184707 | 0.2621773811118473 | 2.26E-16 | 15 | passed |
/panels/1/groups/0/lower | tolerance | 10.772514558384954 | 10.772514558384954 | 4.69E-16 | 16 | passed |
/panels/1/groups/0/upper | tolerance | 11.914985441615046 | 11.914985441615043 | 3.08E-15 | 15 | passed |
/panels/1/groups/0/decision | exact | within | within | passed | ||
/panels/1/groups/1/label | exact | warm | warm | passed | ||
/panels/1/groups/1/size | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/panels/1/groups/1/rows | exact | 8 | 8 | 0.00E+2 | passed | |
/panels/1/groups/1/statistic | tolerance | 11.600000000000001 | 11.6 | 1.36E-15 | 15 | passed |
/panels/1/groups/1/standard_error | tolerance | 0.26217738111184707 | 0.2621773811118473 | 2.26E-16 | 15 | passed |
/panels/1/groups/1/lower | tolerance | 10.772514558384954 | 10.772514558384954 | 4.69E-16 | 16 | passed |
/panels/1/groups/1/upper | tolerance | 11.914985441615046 | 11.914985441615043 | 3.08E-15 | 15 | passed |
/panels/1/groups/1/decision | exact | within | within | passed | ||
/panels/1/signals | exact | 0 | 0 | 0.00E+2 | passed | |
/panels/2/center | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/panels/2/critical_value | tolerance | 2.1788128296672284 | 2.1788128296672293 | 9.34E-16 | 15 | passed |
/panels/2/critical_df | exact | 12 | 12 | 0.00E+2 | passed | |
/panels/2/groups/0/label | exact | high / cold | high / cold | passed | ||
/panels/2/groups/0/size | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/panels/2/groups/0/rows | exact | 4 | 4 | 0.00E+2 | passed | |
/panels/2/groups/0/statistic | tolerance | 0.16874999999999929 | 0.1687499999999993 | 5.43E-19 | 17 | passed |
/panels/2/groups/0/standard_error | tolerance | 0.26217738111184707 | 0.2621773811118473 | 2.26E-16 | 15 | passed |
/panels/2/groups/0/lower | tolerance | -0.57123544161504691 | -0.5712354416150476 | 6.69E-16 | 14 | passed |
/panels/2/groups/0/upper | tolerance | 0.57123544161504691 | 0.5712354416150476 | 6.69E-16 | 14 | passed |
/panels/2/groups/0/decision | exact | within | within | passed | ||
/panels/2/groups/1/label | exact | high / warm | high / warm | passed | ||
/panels/2/groups/1/size | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/panels/2/groups/1/rows | exact | 4 | 4 | 0.00E+2 | passed | |
/panels/2/groups/1/statistic | tolerance | -0.16875000000000107 | -0.16875000000000107 | 4.19E-18 | 16 | passed |
/panels/2/groups/1/standard_error | tolerance | 0.26217738111184707 | 0.2621773811118473 | 2.26E-16 | 15 | passed |
/panels/2/groups/1/lower | tolerance | -0.57123544161504691 | -0.5712354416150476 | 6.69E-16 | 14 | passed |
/panels/2/groups/1/upper | tolerance | 0.57123544161504691 | 0.5712354416150476 | 6.69E-16 | 14 | passed |
/panels/2/groups/1/decision | exact | within | within | passed | ||
/panels/2/groups/2/label | exact | low / cold | low / cold | passed | ||
/panels/2/groups/2/size | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/panels/2/groups/2/rows | exact | 4 | 4 | 0.00E+2 | passed | |
/panels/2/groups/2/statistic | tolerance | -0.16875000000000107 | -0.16875000000000284 | 1.77E-15 | 13 | passed |
/panels/2/groups/2/standard_error | tolerance | 0.26217738111184707 | 0.2621773811118473 | 2.26E-16 | 15 | passed |
/panels/2/groups/2/lower | tolerance | -0.57123544161504691 | -0.5712354416150476 | 6.69E-16 | 14 | passed |
/panels/2/groups/2/upper | tolerance | 0.57123544161504691 | 0.5712354416150476 | 6.69E-16 | 14 | passed |
/panels/2/groups/2/decision | exact | within | within | passed | ||
/panels/2/groups/3/label | exact | low / warm | low / warm | passed | ||
/panels/2/groups/3/size | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/panels/2/groups/3/rows | exact | 4 | 4 | 0.00E+2 | passed | |
/panels/2/groups/3/statistic | tolerance | 0.16874999999999751 | 0.1687499999999975 | 3.10E-18 | 16 | passed |
/panels/2/groups/3/standard_error | tolerance | 0.26217738111184707 | 0.2621773811118473 | 2.26E-16 | 15 | passed |
/panels/2/groups/3/lower | tolerance | -0.57123544161504691 | -0.5712354416150476 | 6.69E-16 | 14 | passed |
/panels/2/groups/3/upper | tolerance | 0.57123544161504691 | 0.5712354416150476 | 6.69E-16 | 14 | passed |
/panels/2/groups/3/decision | exact | within | within | passed | ||
/panels/2/signals | exact | 0 | 0 | 0.00E+2 | passed | |
/pooled_sd | tolerance | 1.0487095244473883 | 1.0487095244473892 | 8.85E-16 | 15 | passed |
/residual_df | exact | 12 | 12 | 0.00E+2 | passed |
Convention
- Balanced 2 x 2 x 4: main-effect panels use the residual mean square on ab(r - 1) = 12 df with SE = s sqrt((a - 1)/(abr)); the interaction panel shows d_ij = m_ij - m_i. - m_.j + m with SE = s sqrt((a-1)(b-1)/(abr)) centred at zero, cells in row-major order 'fa / fb'. Every panel has two levels or a 2 x 2 contrast set, so h = qt(0.975, 12) exactly.
- Panel order: factor A (fa), factor B (fb), interaction; levels sorted ('high' before 'low', 'cold' before 'warm').
- Groups in sorted label order; centre is the weighted grand mean (pooled proportion or rate); limits are centre +/- h SE_i; a group is 'above', 'below' or 'within'.
- docs/manual/chapters/99-analysis-of-means.tex:10-19: limits ybar +/- h s_p sqrt((N - n_i)/(N n_i)) with pooled SD s_p and the joint critical value depending on the group sizes and residual df.
- docs/manual/chapters/99-analysis-of-means.tex:53-60: two-factor ANOM with alpha per chart; binomial ANOM pools successes and trials; Poisson ANOM pools counts and exposure.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
172 df <- a * b * (r - 1)
173 root <- sqrt(cell_ss / df)
174 grand <- mean(cell_mean)
175 row_means <- rowMeans(cell_mean); col_means <- colMeans(cell_mean)
176 h <- stats::qt(0.975, df)
177 outputs <- panel_outputs(0, grand, h, df,
178 data.frame(label = levels_a, size = b * r, statistic = row_means, se = root * sqrt((a - 1) / (a * b * r)), rows = b * r), "1e-9", "0")
179 outputs <- c(outputs, panel_outputs(1, grand, h, df,
180 data.frame(label = levels_b, size = a * r, statistic = col_means, se = root * sqrt((b - 1) / (a * b * r)), rows = a * r), "1e-9", "0"))
181 contrast <- cell_mean - row_means - rep(col_means, each = a) + grand
182 inter <- data.frame(label = as.vector(t(outer(levels_a, levels_b, paste, sep = " / "))), size = r,
183 statistic = as.vector(t(contrast)), se = root * sqrt((a - 1) * (b - 1) / (a * b * r)), rows = r)
184 outputs <- c(outputs, panel_outputs(2, 0, h, df, inter, "1e-9", "0"))
185 outputs[["/pooled_sd"]] <- tol(root, "root residual mean square")
186 outputs[["/residual_df"]] <- exact(df, "ab(r - 1)")
187 emit("STAT-HYP-ANALYSIS-OF-MEANS-004", "ANOM normal two-way 2 x 2", "axis_coverage",
188 list(analysis = "normal_two_way", response = "y", factor_a = "fa", factor_b = "fb", alpha = "0.05"),
189 outputs, c("Balanced 2 x 2 x 4: main-effect panels use the residual mean square on ab(r - 1) = 12 df with SE = s sqrt((a - 1)/(abr)); the interaction panel shows d_ij = m_ij - m_i. - m_.j + m with SE = s sqrt((a-1)(b-1)/(abr)) centred at zero, cells in row-major order 'fa / fb'. Every panel has two levels or a 2 x 2 contrast set, so h = qt(0.975, 12) exactly.",
190 "Panel order: factor A (fa), factor B (fb), interaction; levels sorted ('high' before 'low', 'cold' before 'warm')."),
191 "R 4.6.1 stats::qt", "Nelson PR, Wludyka PS, Copeland KAF (2005), The Analysis of Means, SIAM, ch. 6 (two-way ANOM; a 2 x 2 interaction reduces to a t quantile); R Core Team, stats package help: qt.")
ANOM binomial three groups
Case STAT-HYP-ANALYSIS-OF-MEANS-005 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::integrate, uniroot
- Citation
- Nelson PR, Wludyka PS, Copeland KAF (2005), The Analysis of Means, SIAM, ch. 2; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_analysis_of_means.R · sha256 d1cae03fb86acee1
- Dataset
- reference_data/datasets/HYP_ANOM.json
Settings compared
alpha= "0.05"analysis= "binomial"events= "events"group= "g3"trials= "trials"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/panels/0/center | tolerance | 0.31562499999999999 | 0.315625 | 1.10E-18 | 17 | passed |
/panels/0/critical_value | tolerance | 2.3434273444850295 | 2.3434273444849496 | 7.99E-14 | 13 | passed |
/panels/0/critical_df | absent | None | passed | |||
/panels/0/groups/0/label | exact | A | A | passed | ||
/panels/0/groups/0/size | tolerance | 200 | 200.0 | 0.00E+2 | passed | |
/panels/0/groups/0/rows | exact | 5 | 5 | 0.00E+2 | passed | |
/panels/0/groups/0/statistic | tolerance | 0.27000000000000002 | 0.27 | 2.24E-18 | 17 | passed |
/panels/0/groups/0/standard_error | tolerance | 0.027249222770595907 | 0.027249222770595907 | 4.44E-19 | 16 | passed |
/panels/0/groups/0/lower | tolerance | 0.25176842624342144 | 0.2517684262434236 | 2.16E-15 | 14 | passed |
/panels/0/groups/0/upper | tolerance | 0.37948157375657854 | 0.3794815737565764 | 2.17E-15 | 14 | passed |
/panels/0/groups/0/decision | exact | within | within | passed | ||
/panels/0/groups/1/label | exact | B | B | passed | ||
/panels/0/groups/1/size | tolerance | 200 | 200.0 | 0.00E+2 | passed | |
/panels/0/groups/1/rows | exact | 5 | 5 | 0.00E+2 | passed | |
/panels/0/groups/1/statistic | tolerance | 0.33000000000000002 | 0.33 | 4.46E-18 | 16 | passed |
/panels/0/groups/1/standard_error | tolerance | 0.027249222770595907 | 0.027249222770595907 | 4.44E-19 | 16 | passed |
/panels/0/groups/1/lower | tolerance | 0.25176842624342144 | 0.2517684262434236 | 2.16E-15 | 14 | passed |
/panels/0/groups/1/upper | tolerance | 0.37948157375657854 | 0.3794815737565764 | 2.17E-15 | 14 | passed |
/panels/0/groups/1/decision | exact | within | within | passed | ||
/panels/0/groups/2/label | exact | C | C | passed | ||
/panels/0/groups/2/size | tolerance | 240 | 240.0 | 0.00E+2 | passed | |
/panels/0/groups/2/rows | exact | 6 | 6 | 0.00E+2 | passed | |
/panels/0/groups/2/statistic | tolerance | 0.34166666666666667 | 0.3416666666666667 | 4.07E-18 | 16 | passed |
/panels/0/groups/2/standard_error | tolerance | 0.023717404132599807 | 0.023717404132599807 | 9.28E-20 | 17 | passed |
/panels/0/groups/2/lower | tolerance | 0.26004498661546338 | 0.26004498661546527 | 1.89E-15 | 14 | passed |
/panels/0/groups/2/upper | tolerance | 0.3712050133845366 | 0.3712050133845347 | 1.89E-15 | 14 | passed |
/panels/0/groups/2/decision | exact | within | within | passed | ||
/panels/0/signals | exact | 0 | 0 | 0.00E+2 | passed | |
/panels/0/groups/0/events | tolerance | 54 | 54.0 | 0.00E+2 | passed | |
/panels/0/groups/1/events | tolerance | 66 | 66.0 | 0.00E+2 | passed | |
/panels/0/groups/2/events | tolerance | 82 | 82.0 | 0.00E+2 | passed | |
/observations | exact | 16 | 16 | 0.00E+2 | passed |
Convention
- Binomial: p_bar = sum x / sum n; SE_i = sqrt(p_bar (1 - p_bar) / n_i) sqrt((N - n_i)/N); h solves P(max |Z_i| <= h) = 0.95 over the deviation correlation with weights n_i (infinite df) by the same deterministic quadrature as the three-group normal case; 1e-6 relative tolerance on h and the limits.
- Groups in sorted label order; centre is the weighted grand mean (pooled proportion or rate); limits are centre +/- h SE_i; a group is 'above', 'below' or 'within'.
- docs/manual/chapters/99-analysis-of-means.tex:10-19: limits ybar +/- h s_p sqrt((N - n_i)/(N n_i)) with pooled SD s_p and the joint critical value depending on the group sizes and residual df.
- docs/manual/chapters/99-analysis-of-means.tex:53-60: two-factor ANOM with alpha per chart; binomial ANOM pools successes and trials; Poisson ANOM pools counts and exposure.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
194 labels <- sort(unique(d$g3))
195 x <- as.vector(tapply(d$events, factor(d$g3, levels = labels), sum))
196 n <- as.vector(tapply(d$trials, factor(d$g3, levels = labels), sum))
197 rows <- as.vector(table(factor(d$g3, levels = labels)))
198 N <- sum(n); p_bar <- sum(x) / N
199 h <- anom_h(n, 0.05, NULL)
200 groups <- data.frame(label = labels, size = n, statistic = x / n,
201 se = sqrt(p_bar * (1 - p_bar)) / sqrt(n) * sqrt((N - n) / N), rows = rows)
202 outputs <- panel_outputs(0, p_bar, h, NULL, groups, "1e-6", "0")
203 for (g in seq_along(labels)) outputs[[paste0("/panels/0/groups/", g - 1, "/events")]] <- tol(x[g], "pooled successes of the group")
204 outputs[["/observations"]] <- exact(nrow(d), "analysed rows")
205 emit("STAT-HYP-ANALYSIS-OF-MEANS-005", "ANOM binomial three groups", "axis_coverage",
206 list(analysis = "binomial", group = "g3", events = "events", trials = "trials", alpha = "0.05"),
207 outputs, "Binomial: p_bar = sum x / sum n; SE_i = sqrt(p_bar (1 - p_bar) / n_i) sqrt((N - n_i)/N); h solves P(max |Z_i| <= h) = 0.95 over the deviation correlation with weights n_i (infinite df) by the same deterministic quadrature as the three-group normal case; 1e-6 relative tolerance on h and the limits.",
208 "R 4.6.1 stats::integrate, uniroot", "Nelson PR, Wludyka PS, Copeland KAF (2005), The Analysis of Means, SIAM, ch. 2; R Core Team, stats package help: integrate, uniroot.")
ANOM Poisson rates two groups with exposure
Case STAT-HYP-ANALYSIS-OF-MEANS-006 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::qnorm
- Citation
- Nelson PR, Wludyka PS, Copeland KAF (2005), The Analysis of Means, SIAM, ch. 2; R Core Team, stats package help: qnorm.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_analysis_of_means.R · sha256 d1cae03fb86acee1
- Dataset
- reference_data/datasets/HYP_ANOM.json
Settings compared
alpha= "0.05"analysis= "poisson"events= "counts"exposure= "exposure"exposure_unit= "hour"group= "g2"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/panels/0/center | tolerance | 4.4444444444444446 | 4.444444444444445 | 4.18E-17 | 17 | passed |
/panels/0/critical_value | tolerance | 1.9599639845400536 | 1.9599639845400527 | 8.83E-16 | 15 | passed |
/panels/0/critical_df | absent | None | passed | |||
/panels/0/groups/0/label | exact | A | A | passed | ||
/panels/0/groups/0/size | tolerance | 11.699999999999999 | 11.7 | 2.89E-16 | 16 | passed |
/panels/0/groups/0/rows | exact | 7 | 7 | 0.00E+2 | passed | |
/panels/0/groups/0/statistic | tolerance | 4.3589743589743595 | 4.3589743589743595 | 2.46E-17 | 17 | passed |
/panels/0/groups/0/standard_error | tolerance | 0.49638719403329334 | 0.49638719403329334 | 4.12E-18 | 17 | passed |
/panels/0/groups/0/lower | tolerance | 3.471543421752294 | 3.471543421752295 | 9.11E-16 | 15 | passed |
/panels/0/groups/0/upper | tolerance | 5.4173454671365953 | 5.417345467136594 | 9.28E-16 | 15 | passed |
/panels/0/groups/0/decision | exact | within | within | passed | ||
/panels/0/groups/1/label | exact | B | B | passed | ||
/panels/0/groups/1/size | tolerance | 21.600000000000001 | 21.6 | 4.21E-16 | 16 | passed |
/panels/0/groups/1/rows | exact | 9 | 9 | 0.00E+2 | passed | |
/panels/0/groups/1/statistic | tolerance | 4.4907407407407405 | 4.4907407407407405 | 2.24E-17 | 17 | passed |
/panels/0/groups/1/standard_error | tolerance | 0.26887639676803382 | 0.2688763967680338 | 7.17E-19 | 17 | passed |
/panels/0/groups/1/lower | tolerance | 3.9174563904861968 | 3.9174563904861968 | 4.00E-17 | 16 | passed |
/panels/0/groups/1/upper | tolerance | 4.9714324984026925 | 4.9714324984026925 | 2.36E-17 | 17 | passed |
/panels/0/groups/1/decision | exact | within | within | passed | ||
/panels/0/signals | exact | 0 | 0 | 0.00E+2 | passed | |
/panels/0/groups/0/events | tolerance | 51 | 51.0 | 0.00E+2 | passed | |
/panels/0/groups/1/events | tolerance | 97 | 97.0 | 0.00E+2 | passed |
Convention
- Poisson: lambda_hat = sum c / sum e; rate_i = c_i / e_i; SE_i = sqrt(lambda_hat (1/e_i - 1/E)); two groups give h = qnorm(0.975) exactly.
- Groups in sorted label order; centre is the weighted grand mean (pooled proportion or rate); limits are centre +/- h SE_i; a group is 'above', 'below' or 'within'.
- docs/manual/chapters/99-analysis-of-means.tex:10-19: limits ybar +/- h s_p sqrt((N - n_i)/(N n_i)) with pooled SD s_p and the joint critical value depending on the group sizes and residual df.
- docs/manual/chapters/99-analysis-of-means.tex:53-60: two-factor ANOM with alpha per chart; binomial ANOM pools successes and trials; Poisson ANOM pools counts and exposure.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
211 labels <- sort(unique(d$g2))
212 c_ <- as.vector(tapply(d$counts, factor(d$g2, levels = labels), sum))
213 e <- as.vector(tapply(d$exposure, factor(d$g2, levels = labels), sum))
214 rows <- as.vector(table(factor(d$g2, levels = labels)))
215 E <- sum(e); rate <- sum(c_) / E
216 h <- stats::qnorm(0.975)
217 groups <- data.frame(label = labels, size = e, statistic = c_ / e, se = sqrt(rate * (1 / e - 1 / E)), rows = rows)
218 outputs <- panel_outputs(0, rate, h, NULL, groups, "1e-9", "0")
219 for (g in seq_along(labels)) outputs[[paste0("/panels/0/groups/", g - 1, "/events")]] <- tol(c_[g], "pooled counts of the group")
220 emit("STAT-HYP-ANALYSIS-OF-MEANS-006", "ANOM Poisson rates two groups with exposure", "axis_coverage",
221 list(analysis = "poisson", group = "g2", events = "counts", exposure = "exposure", exposure_unit = "hour", alpha = "0.05"),
222 outputs, "Poisson: lambda_hat = sum c / sum e; rate_i = c_i / e_i; SE_i = sqrt(lambda_hat (1/e_i - 1/E)); two groups give h = qnorm(0.975) exactly.",
223 "R 4.6.1 stats::qnorm", "Nelson PR, Wludyka PS, Copeland KAF (2005), The Analysis of Means, SIAM, ch. 2; R Core Team, stats package help: qnorm.")
One-way ANOVA Tukey-Kramer
Case STAT-HYP-ANOVA-POST-HOC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::aov, TukeyHSD, qtukey
- Citation
- R Core Team, stats package help: aov, TukeyHSD, ptukey, qtukey.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.05group= "group"procedure= "tukey"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/comparisons/critical_value | tolerance | 3.6733776249744512 | 3.673377658897096 | 3.39E-8 | 8 | passed |
/comparisons/rows/0/difference | tolerance | -2.7666666666666657 | -2.7666666666666657 | 1.93E-17 | 17 | passed |
/comparisons/rows/0/standard_error | tolerance | 0.8351535676038756 | 0.835153567603876 | 4.46E-16 | 15 | passed |
/comparisons/rows/0/statistic | tolerance | -3.3127639921415417 | -3.31276399214154 | 1.76E-15 | 15 | passed |
/comparisons/rows/0/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/0/p_adjusted | tail_probability | 0.012375643255528423 | 0.012375643255054247 | 4.74E-13 | 10 | passed |
/comparisons/rows/0/lower | tolerance | -4.9359531947252275 | -4.935953214758003 | 2.00E-8 | 8 | passed |
/comparisons/rows/0/upper | tolerance | -0.59738013860810035 | -0.5973801185753289 | 2.00E-8 | 7 | passed |
/comparisons/rows/0/significant | exact | True | True | passed | ||
/comparisons/rows/1/difference | tolerance | -0.19999999999999929 | -0.20000000000000462 | 5.33E-15 | 13 | passed |
/comparisons/rows/1/standard_error | tolerance | 0.80758310791551102 | 0.8075831079155115 | 4.47E-16 | 15 | passed |
/comparisons/rows/1/statistic | tolerance | -0.24765253017268807 | -0.2476525301726945 | 6.44E-15 | 13 | passed |
/comparisons/rows/1/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/1/p_adjusted | tail_probability | 0.96682955098428414 | 0.9668295509842715 | 1.27E-14 | 13 | passed |
/comparisons/rows/1/lower | tolerance | -2.2976730798325713 | -2.29767309920402 | 1.94E-8 | 8 | passed |
/comparisons/rows/1/upper | tolerance | 1.8976730798325763 | 1.897673099204011 | 1.94E-8 | 7 | passed |
/comparisons/rows/1/significant | exact | False | False | passed | ||
/comparisons/rows/2/difference | tolerance | 2.5666666666666664 | 2.566666666666661 | 5.30E-15 | 14 | passed |
/comparisons/rows/2/standard_error | tolerance | 0.76732201114204235 | 0.7673220111420427 | 3.31E-16 | 15 | passed |
/comparisons/rows/2/statistic | tolerance | 3.3449668188803456 | 3.344966818880337 | 8.40E-15 | 14 | passed |
/comparisons/rows/2/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/2/p_adjusted | tail_probability | 0.01160577129889151 | 0.011605771298418444 | 4.73E-13 | 10 | passed |
/comparisons/rows/2/lower | tolerance | 0.57357058706906439 | 0.573570568663357 | 1.84E-8 | 7 | passed |
/comparisons/rows/2/upper | tolerance | 4.5597627462642683 | 4.559762764669966 | 1.84E-8 | 8 | passed |
/comparisons/rows/2/significant | exact | True | True | passed |
Convention
- TukeyHSD: adjusted p = ptukey(|diff| / (s sqrt((1/n_i + 1/n_j)/2)), k, df, lower = FALSE); interval half-width qtukey(0.95, k, df) s sqrt((1/n_i + 1/n_j)/2). TukeyHSD labels rows second-first, so the interval is negated. R documents qtukey as 'accurate to the 4th decimal place' (secant inversion of ptukey), so ptukey/qtukey-derived values are compared at 1e-6 relative rather than 1e-9.
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
44 emit <- function(id, title, kind, config, outputs, notes, source_ref, citation) {
45 write_expected("hypothesis", id, list(
46 schema_version = "2.0.0", case_id = id, outputs = outputs, expected_error = NULL,
47 deferred_outputs = list(), generator_run = run))
48 write_case("hypothesis", id, list(
49 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "hypothesis",
50 entry_point = entry, menu_items = list(menu), title = title, case_kind = kind,
51 dataset = list(path = "reference_data/datasets/HYP_POSTHOC.json", sha256 = ""),
52 excluded_rows = list(), configuration = config, "repeat" = 1L,
53 expected = list(path = paste0("reference_data/expected/hypothesis/", id, ".json"), sha256 = ""),
54 oracle = list(oracle_class = "independent_implementation", source = source_ref,
55 citation = citation,
56 generator = list(path = "generators/r/hypothesis_anova_post_hoc.R", sha256 = ""),
57 independent = TRUE,
58 convention_notes = c(notes, notes_common, "Expected computed from the exported CSV.")),
59 supported = TRUE, unsupported_reason = NULL,
60 requirement_ids = list("REQ-STAT-HYP-ANOVA-POST-HOC-001"),
61 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
One-way ANOVA Bonferroni
Case STAT-HYP-ANOVA-POST-HOC-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::pairwise.t.test
- Citation
- R Core Team, stats package help: pairwise.t.test, p.adjust, qt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.05group= "group"procedure= "bonferroni"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/comparisons/critical_value | tolerance | 2.6937393191964865 | 2.6937393191964882 | 1.74E-15 | 15 | passed |
/comparisons/rows/0/difference | tolerance | -2.7666666666666657 | -2.7666666666666657 | 1.93E-17 | 17 | passed |
/comparisons/rows/0/standard_error | tolerance | 0.8351535676038756 | 0.835153567603876 | 4.46E-16 | 15 | passed |
/comparisons/rows/0/statistic | tolerance | -3.3127639921415417 | -3.31276399214154 | 1.76E-15 | 15 | passed |
/comparisons/rows/0/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/0/p_adjusted | tail_probability | 0.014200148444110633 | 0.014200148444110685 | 5.20E-17 | 14 | passed |
/comparisons/rows/0/significant | exact | True | True | passed | ||
/comparisons/rows/0/lower | tolerance | -5.0163526692884464 | -5.016352669288449 | 2.63E-15 | 15 | passed |
/comparisons/rows/0/upper | tolerance | -0.51698066404488507 | -0.5169806640448824 | 2.66E-15 | 14 | passed |
/comparisons/rows/1/difference | tolerance | -0.19999999999999929 | -0.20000000000000462 | 5.33E-15 | 13 | passed |
/comparisons/rows/1/standard_error | tolerance | 0.80758310791551102 | 0.8075831079155115 | 4.47E-16 | 15 | passed |
/comparisons/rows/1/statistic | tolerance | -0.24765253017268807 | -0.2476525301726945 | 6.44E-15 | 13 | passed |
/comparisons/rows/1/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/1/p_adjusted | tail_probability | 1 | 1.0 | 0.00E+2 | passed | |
/comparisons/rows/1/significant | exact | False | False | passed | ||
/comparisons/rows/1/lower | tolerance | -2.3754183713109107 | -2.3754183713109187 | 8.01E-15 | 14 | passed |
/comparisons/rows/1/upper | tolerance | 1.9754183713109121 | 1.9754183713109095 | 2.63E-15 | 14 | passed |
/comparisons/rows/2/difference | tolerance | 2.5666666666666664 | 2.566666666666661 | 5.30E-15 | 14 | passed |
/comparisons/rows/2/standard_error | tolerance | 0.76732201114204235 | 0.7673220111420427 | 3.31E-16 | 15 | passed |
/comparisons/rows/2/statistic | tolerance | 3.3449668188803456 | 3.344966818880337 | 8.40E-15 | 14 | passed |
/comparisons/rows/2/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/2/p_adjusted | tail_probability | 0.013292559608100883 | 0.013292559608101101 | 2.18E-16 | 13 | passed |
/comparisons/rows/2/significant | exact | True | True | passed | ||
/comparisons/rows/2/lower | tolerance | 0.49970119476842267 | 0.4997011947684147 | 7.99E-15 | 13 | passed |
/comparisons/rows/2/upper | tolerance | 4.6336321385649102 | 4.6336321385649075 | 2.68E-15 | 15 | passed |
Convention
- pairwise.t.test(pool.sd = TRUE, p.adjust.method = 'bonferroni'); Bonferroni interval uses qt(1 - alpha/(2c), df) with c = 3 pairs
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
162 simple_case("STAT-HYP-ANOVA-POST-HOC-002", "One-way ANOVA Bonferroni", "bonferroni", "bonferroni")
One-way ANOVA Holm
Case STAT-HYP-ANOVA-POST-HOC-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::pairwise.t.test
- Citation
- R Core Team, stats package help: pairwise.t.test, p.adjust, qt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.05group= "group"procedure= "holm"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/comparisons/rows/0/difference | tolerance | -2.7666666666666657 | -2.7666666666666657 | 1.93E-17 | 17 | passed |
/comparisons/rows/0/standard_error | tolerance | 0.8351535676038756 | 0.835153567603876 | 4.46E-16 | 15 | passed |
/comparisons/rows/0/statistic | tolerance | -3.3127639921415417 | -3.31276399214154 | 1.76E-15 | 15 | passed |
/comparisons/rows/0/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/0/p_adjusted | tail_probability | 0.013292559608100883 | 0.013292559608101101 | 2.18E-16 | 13 | passed |
/comparisons/rows/0/significant | exact | True | True | passed | ||
/comparisons/rows/0/lower | absent | None | passed | |||
/comparisons/rows/1/difference | tolerance | -0.19999999999999929 | -0.20000000000000462 | 5.33E-15 | 13 | passed |
/comparisons/rows/1/standard_error | tolerance | 0.80758310791551102 | 0.8075831079155115 | 4.47E-16 | 15 | passed |
/comparisons/rows/1/statistic | tolerance | -0.24765253017268807 | -0.2476525301726945 | 6.44E-15 | 13 | passed |
/comparisons/rows/1/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/1/p_adjusted | tail_probability | 0.80776123862973748 | 0.8077612386297325 | 5.00E-15 | 14 | passed |
/comparisons/rows/1/significant | exact | False | False | passed | ||
/comparisons/rows/1/lower | absent | None | passed | |||
/comparisons/rows/2/difference | tolerance | 2.5666666666666664 | 2.566666666666661 | 5.30E-15 | 14 | passed |
/comparisons/rows/2/standard_error | tolerance | 0.76732201114204235 | 0.7673220111420427 | 3.31E-16 | 15 | passed |
/comparisons/rows/2/statistic | tolerance | 3.3449668188803456 | 3.344966818880337 | 8.40E-15 | 14 | passed |
/comparisons/rows/2/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/2/p_adjusted | tail_probability | 0.013292559608100883 | 0.013292559608101101 | 2.18E-16 | 13 | passed |
/comparisons/rows/2/significant | exact | True | True | passed | ||
/comparisons/rows/2/lower | absent | None | passed |
Convention
- pairwise.t.test(pool.sd = TRUE, p.adjust.method = 'holm').
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
163 simple_case("STAT-HYP-ANOVA-POST-HOC-003", "One-way ANOVA Holm", "holm", "holm")
One-way ANOVA Scheffe
Case STAT-HYP-ANOVA-POST-HOC-004 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::pf, qf
- Citation
- Scheffe H (1959), The Analysis of Variance, Wiley, section 3.5; R Core Team, stats package help: pf, qf.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.05group= "group"procedure= "scheffe"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/comparisons/critical_value | tolerance | 2.7137871484968161 | 2.7137871484968166 | 4.70E-16 | 15 | passed |
/comparisons/rows/0/difference | tolerance | -2.7666666666666657 | -2.7666666666666657 | 1.93E-17 | 17 | passed |
/comparisons/rows/0/standard_error | tolerance | 0.8351535676038756 | 0.835153567603876 | 4.46E-16 | 15 | passed |
/comparisons/rows/0/statistic | tolerance | -3.3127639921415417 | -3.31276399214154 | 1.76E-15 | 15 | passed |
/comparisons/rows/0/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/0/p_adjusted | tail_probability | 0.016277674141345212 | 0.01627767414134524 | 2.80E-17 | 14 | passed |
/comparisons/rows/0/lower | tolerance | -5.0330956854513307 | -5.0330956854513325 | 1.76E-15 | 15 | passed |
/comparisons/rows/0/upper | tolerance | -0.5002376478820012 | -0.5002376478819994 | 1.77E-15 | 14 | passed |
/comparisons/rows/0/significant | exact | True | True | passed | ||
/comparisons/rows/1/difference | tolerance | -0.19999999999999929 | -0.20000000000000462 | 5.33E-15 | 13 | passed |
/comparisons/rows/1/standard_error | tolerance | 0.80758310791551102 | 0.8075831079155115 | 4.47E-16 | 15 | passed |
/comparisons/rows/1/statistic | tolerance | -0.24765253017268807 | -0.2476525301726945 | 6.44E-15 | 13 | passed |
/comparisons/rows/1/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/1/p_adjusted | tail_probability | 0.96986017718321982 | 0.9698601771832182 | 1.67E-15 | 14 | passed |
/comparisons/rows/1/lower | tolerance | -2.3916086596042305 | -2.391608659604237 | 6.69E-15 | 14 | passed |
/comparisons/rows/1/upper | tolerance | 1.9916086596042319 | 1.991608659604228 | 3.95E-15 | 14 | passed |
/comparisons/rows/1/significant | exact | False | False | passed | ||
/comparisons/rows/2/difference | tolerance | 2.5666666666666664 | 2.566666666666661 | 5.30E-15 | 14 | passed |
/comparisons/rows/2/standard_error | tolerance | 0.76732201114204235 | 0.7673220111420427 | 3.31E-16 | 15 | passed |
/comparisons/rows/2/statistic | tolerance | 3.3449668188803456 | 3.344966818880337 | 8.40E-15 | 14 | passed |
/comparisons/rows/2/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/2/p_adjusted | tail_probability | 0.015304427018066656 | 0.015304427018066875 | 2.19E-16 | 13 | passed |
/comparisons/rows/2/lower | tolerance | 0.48431805407066131 | 0.48431805407065465 | 6.66E-15 | 13 | passed |
/comparisons/rows/2/upper | tolerance | 4.649015279262672 | 4.6490152792626676 | 4.45E-15 | 15 | passed |
/comparisons/rows/2/significant | exact | True | True | passed |
Convention
- Scheffe (1959): a pairwise contrast is significant when t^2/(k-1) exceeds F_{k-1, N-k}(alpha); p = pf(t^2/(k-1), k-1, df, lower.tail = FALSE); interval half-width sqrt((k-1) F) SE.
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
182 emit("STAT-HYP-ANOVA-POST-HOC-004", "One-way ANOVA Scheffe", "axis_coverage",
183 list(response = "y", group = "group", procedure = "scheffe", alpha = 0.05),
184 outputs, "Scheffe (1959): a pairwise contrast is significant when t^2/(k-1) exceeds F_{k-1, N-k}(alpha); p = pf(t^2/(k-1), k-1, df, lower.tail = FALSE); interval half-width sqrt((k-1) F) SE.",
185 "R 4.6.1 stats::pf, qf", "Scheffe H (1959), The Analysis of Variance, Wiley, section 3.5; R Core Team, stats package help: pf, qf.")
One-way ANOVA LSD alpha 0.10
Case STAT-HYP-ANOVA-POST-HOC-005 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::pairwise.t.test
- Citation
- R Core Team, stats package help: pairwise.t.test, p.adjust, qt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.1group= "group"procedure= "lsd"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/comparisons/critical_value | tolerance | 1.7530503556925727 | 1.753050355692572 | 6.40E-16 | 15 | passed |
/comparisons/rows/0/difference | tolerance | -2.7666666666666657 | -2.7666666666666657 | 1.93E-17 | 17 | passed |
/comparisons/rows/0/standard_error | tolerance | 0.8351535676038756 | 0.835153567603876 | 4.46E-16 | 15 | passed |
/comparisons/rows/0/statistic | tolerance | -3.3127639921415417 | -3.31276399214154 | 1.76E-15 | 15 | passed |
/comparisons/rows/0/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/0/p_adjusted | tail_probability | 0.0047333828147035446 | 0.004733382814703562 | 1.73E-17 | 14 | passed |
/comparisons/rows/0/significant | exact | True | True | passed | ||
/comparisons/rows/0/lower | tolerance | -4.2307329254125605 | -4.230732925412561 | 9.07E-16 | 15 | passed |
/comparisons/rows/0/upper | tolerance | -1.3026004079207705 | -1.3026004079207703 | 2.46E-16 | 15 | passed |
/comparisons/rows/1/difference | tolerance | -0.19999999999999929 | -0.20000000000000462 | 5.33E-15 | 13 | passed |
/comparisons/rows/1/standard_error | tolerance | 0.80758310791551102 | 0.8075831079155115 | 4.47E-16 | 15 | passed |
/comparisons/rows/1/statistic | tolerance | -0.24765253017268807 | -0.2476525301726945 | 6.44E-15 | 13 | passed |
/comparisons/rows/1/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/1/p_adjusted | tail_probability | 0.80776123862973748 | 0.8077612386297325 | 5.00E-15 | 14 | passed |
/comparisons/rows/1/significant | exact | False | False | passed | ||
/comparisons/rows/1/lower | tolerance | -1.6157338545825992 | -1.6157338545826048 | 5.57E-15 | 14 | passed |
/comparisons/rows/1/upper | tolerance | 1.2157338545826006 | 1.2157338545825955 | 5.07E-15 | 14 | passed |
/comparisons/rows/2/difference | tolerance | 2.5666666666666664 | 2.566666666666661 | 5.30E-15 | 14 | passed |
/comparisons/rows/2/standard_error | tolerance | 0.76732201114204235 | 0.7673220111420427 | 3.31E-16 | 15 | passed |
/comparisons/rows/2/statistic | tolerance | 3.3449668188803456 | 3.344966818880337 | 8.40E-15 | 14 | passed |
/comparisons/rows/2/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/2/p_adjusted | tail_probability | 0.0044308532027002943 | 0.004430853202700367 | 7.28E-17 | 13 | passed |
/comparisons/rows/2/significant | exact | True | True | passed | ||
/comparisons/rows/2/lower | tolerance | 1.2215125421033688 | 1.2215125421033635 | 5.34E-15 | 14 | passed |
/comparisons/rows/2/upper | tolerance | 3.9118207912299638 | 3.9118207912299585 | 5.28E-15 | 14 | passed |
Convention
- pairwise.t.test(pool.sd = TRUE, p.adjust.method = 'none'); LSD interval uses qt(1 - alpha/2, df)
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
164 simple_case("STAT-HYP-ANOVA-POST-HOC-005", "One-way ANOVA LSD alpha 0.10", "lsd", "none", alpha = 0.10)
One-way ANOVA Dunnett against control A
Case STAT-HYP-ANOVA-POST-HOC-006 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::integrate, uniroot
- Citation
- Dunnett CW (1955), A multiple comparison procedure for comparing several treatments with a control, JASA 50, 1096-1121; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.05control= "A"group= "group"procedure= "dunnett"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/comparisons/critical_value | tolerance | 2.4281518529165855 | 2.428132951773583 | 1.89E-5 | 5 | passed |
/comparisons/rows/0/difference | tolerance | 2.7666666666666657 | 2.7666666666666657 | 1.93E-17 | 17 | passed |
/comparisons/rows/0/standard_error | tolerance | 0.8351535676038756 | 0.8351535676038759 | 3.35E-16 | 15 | passed |
/comparisons/rows/0/statistic | tolerance | 3.3127639921415417 | 3.3127639921415404 | 1.32E-15 | 15 | passed |
/comparisons/rows/0/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/0/p_adjusted | tolerance | 0.0087001438186928848 | 0.00869932653252488 | 8.17E-7 | 4 | passed |
/comparisons/rows/0/lower | tolerance | 0.73878698401941811 | 0.7388027693764281 | 1.58E-5 | 4 | passed |
/comparisons/rows/0/upper | tolerance | 4.7945463493139133 | 4.794530563956903 | 1.58E-5 | 5 | passed |
/comparisons/rows/0/significant | exact | True | True | passed | ||
/comparisons/rows/1/difference | tolerance | 0.19999999999999929 | 0.20000000000000462 | 5.33E-15 | 13 | passed |
/comparisons/rows/1/standard_error | tolerance | 0.80758310791551102 | 0.8075831079155114 | 3.36E-16 | 15 | passed |
/comparisons/rows/1/statistic | tolerance | 0.24765253017268807 | 0.24765253017269456 | 6.49E-15 | 13 | passed |
/comparisons/rows/1/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/comparisons/rows/1/p_adjusted | tolerance | 0.95427025348792449 | 0.9542543816712122 | 1.59E-5 | 4 | passed |
/comparisons/rows/1/lower | tolerance | -1.7609344198691836 | -1.7609191556253698 | 1.53E-5 | 5 | passed |
/comparisons/rows/1/upper | tolerance | 2.1609344198691822 | 2.160919155625379 | 1.53E-5 | 5 | passed |
/comparisons/rows/1/significant | exact | False | False | passed |
Convention
- Dunnett (1955): rows are (B, A) and (C, A); critical value and adjusted p from the bivariate t with correlation sqrt(n_i n_j / ((n_i + n_0)(n_j + n_0))) on N - k df, computed by deterministic quadrature (product-correlation integral over W, then over the chi scale; rel.tol 1e-11; uniroot to 1e-12).
- The window calibrates the maximum multivariate t by replicated quasi-Monte Carlo with a stated target half-width of 1e-4 on the probability (docs/manual/chapters/83-repeated-anova-and-contrasts.tex:149-153), so the comparison allows 1e-4 absolute and relative; the reference itself is accurate to about 1e-10.
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
221 emit("STAT-HYP-ANOVA-POST-HOC-006", "One-way ANOVA Dunnett against control A", "axis_coverage",
222 list(response = "y", group = "group", procedure = "dunnett", alpha = 0.05, control = "A"),
223 outputs, c("Dunnett (1955): rows are (B, A) and (C, A); critical value and adjusted p from the bivariate t with correlation sqrt(n_i n_j / ((n_i + n_0)(n_j + n_0))) on N - k df, computed by deterministic quadrature (product-correlation integral over W, then over the chi scale; rel.tol 1e-11; uniroot to 1e-12).",
224 "The window calibrates the maximum multivariate t by replicated quasi-Monte Carlo with a stated target half-width of 1e-4 on the probability (docs/manual/chapters/83-repeated-anova-and-contrasts.tex:149-153), so the comparison allows 1e-4 absolute and relative; the reference itself is accurate to about 1e-10."),
225 "R 4.6.1 stats::integrate, uniroot", "Dunnett CW (1955), A multiple comparison procedure for comparing several treatments with a control, JASA 50, 1096-1121; R Core Team, stats package help: integrate, uniroot.")
One-way ANOVA Games-Howell
Case STAT-HYP-ANOVA-POST-HOC-007 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::ptukey, qtukey
- Citation
- Games PA, Howell JF (1976), Journal of Educational Statistics 1(2), 113-125; R Core Team, stats package help: ptukey, qtukey.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.05group= "group"procedure= "games_howell"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/comparisons/rows/0/difference | tolerance | -2.7666666666666657 | -2.7666666666666657 | 1.93E-17 | 17 | passed |
/comparisons/rows/0/standard_error | tolerance | 0.63254336698056612 | 0.6325433669805663 | 2.26E-16 | 15 | passed |
/comparisons/rows/0/statistic | tolerance | -4.3738766558778366 | -4.373876655877835 | 1.79E-15 | 15 | passed |
/comparisons/rows/0/df | tolerance | 8.9981805110286395 | 8.998180511028638 | 1.80E-15 | 15 | passed |
/comparisons/rows/0/p_adjusted | tail_probability | 0.0045655903292147748 | 0.0045655904875342435 | 1.58E-10 | 7 | passed |
/comparisons/rows/0/lower | tolerance | -4.5327970806466436 | -4.532797081179188 | 5.33E-10 | 9 | passed |
/comparisons/rows/0/upper | tolerance | -1.0005362526866879 | -1.0005362521541428 | 5.33E-10 | 9 | passed |
/comparisons/rows/1/difference | tolerance | -0.19999999999999929 | -0.20000000000000462 | 5.33E-15 | 13 | passed |
/comparisons/rows/1/standard_error | tolerance | 0.78117737757701045 | 0.7811773775770106 | 1.07E-16 | 15 | passed |
/comparisons/rows/1/statistic | tolerance | -0.25602379912785272 | -0.2560237991278595 | 6.78E-15 | 13 | passed |
/comparisons/rows/1/df | tolerance | 9.4929092469595098 | 9.492909246959512 | 1.75E-15 | 15 | passed |
/comparisons/rows/1/p_adjusted | tail_probability | 0.96464437953892135 | 0.9646443795390811 | 1.60E-13 | 12 | passed |
/comparisons/rows/1/lower | tolerance | -2.3603428415803225 | -2.36034284201028 | 4.30E-10 | 9 | passed |
/comparisons/rows/1/upper | tolerance | 1.9603428415803239 | 1.9603428420102706 | 4.30E-10 | 9 | passed |
/comparisons/rows/2/difference | tolerance | 2.5666666666666664 | 2.566666666666661 | 5.30E-15 | 14 | passed |
/comparisons/rows/2/standard_error | tolerance | 0.812618733693241 | 0.8126187336932411 | 1.13E-16 | 15 | passed |
/comparisons/rows/2/statistic | tolerance | 3.1585127935723527 | 3.1585127935723456 | 7.10E-15 | 14 | passed |
/comparisons/rows/2/df | tolerance | 10.455336053646997 | 10.455336053646997 | 2.99E-17 | 17 | passed |
/comparisons/rows/2/p_adjusted | tail_probability | 0.024047052762121157 | 0.024047052752322662 | 9.80E-12 | 9 | passed |
/comparisons/rows/2/lower | tolerance | 0.35487583674239254 | 0.354875835967595 | 7.75E-10 | 8 | passed |
/comparisons/rows/2/upper | tolerance | 4.7784574965909403 | 4.778457497365727 | 7.75E-10 | 9 | passed |
Convention
- Games and Howell (1976): SE = sqrt(s_i^2/n_i + s_j^2/n_j), Welch-Satterthwaite df per pair, p = ptukey(|t| sqrt(2), k, df_ij, lower = FALSE), half-width qtukey(0.95, k, df_ij) SE / sqrt(2). R documents qtukey as accurate to the 4th decimal place, so ptukey/qtukey-derived values are compared at 1e-6 relative.
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
246 emit("STAT-HYP-ANOVA-POST-HOC-007", "One-way ANOVA Games-Howell", "axis_coverage",
247 list(response = "y", group = "group", procedure = "games_howell", alpha = 0.05),
248 outputs, "Games and Howell (1976): SE = sqrt(s_i^2/n_i + s_j^2/n_j), Welch-Satterthwaite df per pair, p = ptukey(|t| sqrt(2), k, df_ij, lower = FALSE), half-width qtukey(0.95, k, df_ij) SE / sqrt(2). R documents qtukey as accurate to the 4th decimal place, so ptukey/qtukey-derived values are compared at 1e-6 relative.",
249 "R 4.6.1 stats::ptukey, qtukey", "Games PA, Howell JF (1976), Journal of Educational Statistics 1(2), 113-125; R Core Team, stats package help: ptukey, qtukey.")
One-way ANOVA Helmert contrasts pooled
Case STAT-HYP-ANOVA-POST-HOC-008 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::pt, qt
- Citation
- R Core Team, stats package help: pt, qt; contrast definition as in the SPSS ONEWAY Helmert family.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.05contrast_adjustment= "none"contrast_family= "helmert"contrast_variance= "pooled"group= "group"procedure= "none"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/contrasts/rows/0/estimate | tolerance | -1.4833333333333325 | -1.4833333333333352 | 2.67E-15 | 14 | passed |
/contrasts/rows/0/standard_error | tolerance | 0.72638847157716602 | 0.7263884715771665 | 4.41E-16 | 15 | passed |
/contrasts/rows/0/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/contrasts/rows/0/t_value | tolerance | -2.0420661827309226 | -2.0420661827309248 | 2.17E-15 | 14 | passed |
/contrasts/rows/0/p_value | tail_probability | 0.059136757743176449 | 0.059136757743176206 | 2.43E-16 | 14 | passed |
/contrasts/rows/0/lower | tolerance | -3.0315937109763427 | -3.0315937109763462 | 3.52E-15 | 14 | passed |
/contrasts/rows/0/upper | tolerance | 0.064927044309677662 | 0.06492704430967611 | 1.55E-15 | 13 | passed |
/contrasts/rows/1/estimate | tolerance | 2.5666666666666664 | 2.566666666666661 | 5.30E-15 | 14 | passed |
/contrasts/rows/1/standard_error | tolerance | 0.76732201114204235 | 0.7673220111420427 | 3.31E-16 | 15 | passed |
/contrasts/rows/1/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/contrasts/rows/1/t_value | tolerance | 3.3449668188803456 | 3.344966818880337 | 8.40E-15 | 14 | passed |
/contrasts/rows/1/p_value | tail_probability | 0.0044308532027002943 | 0.004430853202700367 | 7.28E-17 | 13 | passed |
/contrasts/rows/1/lower | tolerance | 0.93115851471994771 | 0.9311585147199413 | 6.44E-15 | 14 | passed |
/contrasts/rows/1/upper | tolerance | 4.2021748186133854 | 4.202174818613381 | 4.46E-15 | 14 | passed |
/comparisons | absent | None | passed |
Convention
- Helmert: each level against the mean of the later levels, rows (1, -1/2, -1/2) and (0, 1, -1); estimate = c'means, SE = sqrt(MSE sum(c_i^2 / n_i)), df = N - k, individual t intervals.
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
277 helmert <- rbind(c(1, -1/2, -1/2), c(0, 1, -1))
278 outputs <- c(anova_outputs(), contrast_rows(helmert, c("A vs later", "B vs later"), "pooled"))
279 outputs[["/comparisons"]] <- list(comparison = "absent", rationale = "procedure none: no pairwise table")
280 emit("STAT-HYP-ANOVA-POST-HOC-008", "One-way ANOVA Helmert contrasts pooled", "axis_coverage",
281 list(response = "y", group = "group", procedure = "none", alpha = 0.05,
282 contrast_family = "helmert", contrast_variance = "pooled", contrast_adjustment = "none"),
283 outputs, "Helmert: each level against the mean of the later levels, rows (1, -1/2, -1/2) and (0, 1, -1); estimate = c'means, SE = sqrt(MSE sum(c_i^2 / n_i)), df = N - k, individual t intervals.",
284 "R 4.6.1 stats::pt, qt", "R Core Team, stats package help: pt, qt; contrast definition as in the SPSS ONEWAY Helmert family.")
One-way ANOVA custom contrasts Welch Bonferroni
Case STAT-HYP-ANOVA-POST-HOC-009 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::pt, qt
- Citation
- Welch BL (1947), Biometrika 34, 28-35 (Satterthwaite df); R Core Team, stats package help: pt, qt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_anova_post_hoc.R · sha256 057b84f90d3c52ae
- Dataset
- reference_data/datasets/HYP_POSTHOC.json
Settings compared
alpha= 0.05coefficients= [1, -0.5, -0.5, 1, 0, -1]contrast_adjustment= "bonferroni"contrast_family= "custom"contrast_variance= "welch"group= "group"procedure= "none"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/between_ss | tolerance | 28.206666666666642 | 28.206666666666596 | 4.61E-14 | 14 | passed |
/anova/within_ss | tolerance | 28.533333333333317 | 28.533333333333346 | 2.86E-14 | 14 | passed |
/anova/between_df | exact | 2 | 2 | 0.00E+2 | passed | |
/anova/within_df | exact | 15 | 15 | 0.00E+2 | passed | |
/anova/mse | tolerance | 1.9022222222222211 | 1.9022222222222231 | 2.05E-15 | 14 | passed |
/anova/f_value | tolerance | 7.4141355140186898 | 7.414135514018669 | 2.05E-14 | 14 | passed |
/anova/p_value | tail_probability | 0.0057673172086628302 | 0.0057673172086628866 | 5.64E-17 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/groups/0/n | exact | 5 | 5 | 0.00E+2 | passed | |
/groups/0/mean | tolerance | 10.9 | 10.899999999999999 | 1.42E-15 | 15 | passed |
/groups/0/variance | tolerance | 0.87499999999999967 | 0.8750000000000003 | 6.63E-16 | 15 | passed |
/groups/1/n | exact | 6 | 6 | 0.00E+2 | passed | |
/groups/1/mean | tolerance | 13.666666666666666 | 13.666666666666664 | 1.70E-15 | 15 | passed |
/groups/1/variance | tolerance | 1.3506666666666673 | 1.3506666666666685 | 1.16E-15 | 15 | passed |
/groups/2/n | exact | 7 | 7 | 0.00E+2 | passed | |
/groups/2/mean | tolerance | 11.1 | 11.100000000000003 | 3.20E-15 | 15 | passed |
/groups/2/variance | tolerance | 3.0466666666666664 | 3.046666666666667 | 4.56E-16 | 15 | passed |
/contrasts/rows/0/estimate | tolerance | -1.4833333333333325 | -1.4833333333333352 | 2.67E-15 | 14 | passed |
/contrasts/rows/0/standard_error | tolerance | 0.58317004517319093 | 0.583170045173191 | 1.13E-16 | 15 | passed |
/contrasts/rows/0/df | tolerance | 11.269614331829457 | 11.269614331829453 | 3.51E-15 | 15 | passed |
/contrasts/rows/0/t_value | tolerance | -2.5435691452444362 | -2.54356914524444 | 4.02E-15 | 14 | passed |
/contrasts/rows/0/p_value | tail_probability | 0.026861948752526284 | 0.026861948752526146 | 1.38E-16 | 14 | passed |
/contrasts/rows/0/lower | tolerance | -2.9899676416378771 | -2.9899676416378798 | 2.66E-15 | 15 | passed |
/contrasts/rows/0/upper | tolerance | 0.023300974971211863 | 0.02330097497120942 | 2.44E-15 | 12 | passed |
/contrasts/rows/1/estimate | tolerance | -0.19999999999999929 | -0.20000000000000462 | 5.33E-15 | 13 | passed |
/contrasts/rows/1/standard_error | tolerance | 0.78117737757701045 | 0.7811773775770106 | 1.07E-16 | 15 | passed |
/contrasts/rows/1/df | tolerance | 9.4929092469595098 | 9.492909246959512 | 1.75E-15 | 15 | passed |
/contrasts/rows/1/t_value | tolerance | -0.25602379912785272 | -0.2560237991278595 | 6.78E-15 | 13 | passed |
/contrasts/rows/1/p_value | tail_probability | 0.80339454691214018 | 0.8033945469121351 | 5.10E-15 | 14 | passed |
/contrasts/rows/1/lower | tolerance | -2.276517475567617 | -2.276517475567623 | 6.18E-15 | 14 | passed |
/contrasts/rows/1/upper | tolerance | 1.8765174755676184 | 1.876517475567614 | 4.45E-15 | 14 | passed |
/contrasts/rows/0/p_adjusted | tail_probability | 0.053723897505052569 | 0.05372389750505229 | 2.78E-16 | 14 | passed |
/contrasts/rows/1/p_adjusted | tail_probability | 1 | 1.0 | 0.00E+2 | passed |
Convention
- Custom rows (1, -0.5, -0.5) and (1, 0, -1): SE = sqrt(sum c_i^2 s_i^2 / n_i), Welch-Satterthwaite df, Bonferroni over m = 2 contrasts (p times 2, qt(1 - alpha/(2m))).
- Groups in sorted label order A, B, C (n = 5, 6, 7); one row with a missing response is dropped and counted.
- Pairwise rows are the combinations (A,B), (A,C), (B,C); difference = first mean minus second mean; SE = s sqrt(1/n_i + 1/n_j) with s^2 the ANOVA MSE on N - k df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:127-129: 'offers independent-group procedures and planned contrast families. Choose a method whose variance and comparison assumptions match the design.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:133-143: the procedure table (LSD individual; Bonferroni, Sidak, Holm declared family; Tukey/Tukey-Kramer pooled; Dunnett against one control; Scheffe over the contrast space; Games-Howell without equal variances).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
300 emit("STAT-HYP-ANOVA-POST-HOC-009", "One-way ANOVA custom contrasts Welch Bonferroni", "axis_coverage",
301 list(response = "y", group = "group", procedure = "none", alpha = 0.05,
302 contrast_family = "custom", coefficients = list(1, -0.5, -0.5, 1, 0, -1),
303 contrast_variance = "welch", contrast_adjustment = "bonferroni"),
304 outputs, "Custom rows (1, -0.5, -0.5) and (1, 0, -1): SE = sqrt(sum c_i^2 s_i^2 / n_i), Welch-Satterthwaite df, Bonferroni over m = 2 contrasts (p times 2, qt(1 - alpha/(2m))).",
305 "R 4.6.1 stats::pt, qt", "Welch BL (1947), Biometrika 34, 28-35 (Satterthwaite df); R Core Team, stats package help: pt, qt.")
Configuration axis: STAT-HYP-AXIS-BASIC-POISSON-001
Case STAT-HYP-AXIS-BASIC-POISSON-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_RATES.json
Settings compared
count_column= "count"exposure_column= "exposure"exposure_unit= "hours"input_kind= "raw"method= "one_poisson_rate"null_rate= 0.15
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.14999999999999999 | 0.15 | 4.45E-18 | 16 | passed |
/p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed |
Convention
- Hours are display units; exact Poisson test uses total count and total exposure.
- Data-based values computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
74 one_rate <- stats::poisson.test(sum(r$count), T = sum(r$exposure), r = 0.15)
75 emit("STAT-HYP-AXIS-BASIC-POISSON-001", "tabelz.executor.additional_basic_tests",
76 "additionalBasicTestsMenuItem", "HYP_RATES",
77 list(method = "one_poisson_rate", input_kind = "raw", count_column = "count",
78 exposure_column = "exposure", null_rate = 0.15, exposure_unit = "hours"),
79 list("/estimate" = tol(sum(r$count) / sum(r$exposure), "events per exposure"),
80 "/p_value" = prob(one_rate$p.value, "exact one-rate Poisson tail")),
81 list("Hours are display units; exact Poisson test uses total count and total exposure."))
Configuration axis: STAT-HYP-AXIS-BASIC-SD-001
Case STAT-HYP-AXIS-BASIC-SD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
input_kind= "raw"method= "one_variance_chi_square"null_variance= 4response_column= "x"variance_display= "sd"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 13.909375000000001 | 13.909375000000004 | 3.26E-15 | 15 | passed |
/p_value | tail_probability | 0.93517363103879991 | 0.9351736310388007 | 7.80E-16 | 15 | passed |
Convention
- Null variance 4; sd display is a presentation axis only.
- Data-based values computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
107 variance <- stats::var(d$x)
108 chi <- (nrow(d) - 1) * variance / 4
109 emit("STAT-HYP-AXIS-BASIC-SD-001", "tabelz.executor.additional_basic_tests",
110 "additionalBasicTestsMenuItem", "HYP_CORE",
111 list(method = "one_variance_chi_square", input_kind = "raw", response_column = "x",
112 null_variance = 4, variance_display = "sd"),
113 list("/statistic" = tol(chi, "variance chi-square"),
114 "/p_value" = prob(min(1, 2 * min(stats::pchisq(chi, nrow(d) - 1),
115 stats::pchisq(chi, nrow(d) - 1, lower.tail = FALSE))),
116 "two-sided variance tail")),
117 list("Null variance 4; sd display is a presentation axis only."))
Configuration axis: STAT-HYP-AXIS-BASIC-SUMMARY-001
Case STAT-HYP-AXIS-BASIC-SUMMARY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- None
Settings compared
input_kind= "summary"known_sigma= 2method= "known_sigma_z"null_mean= 6sample_size= 16summary_mean= 6.8125
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.625 | 1.625 | 0.00E-1 | passed | |
/p_value | tail_probability | 0.10416255883043912 | 0.10416255883043905 | 6.68E-17 | 15 | passed |
Convention
- Summary mean and sample size are derived from the exported CSV.
- docs/manual/chapters/31-additional-basic-tests.tex:6-8: 'Summary mode is source independent: it does not claim a table population'.
- Data-based values computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
97 z_summary <- (mean(d$x) - 6) / (2 / sqrt(nrow(d)))
98 emit("STAT-HYP-AXIS-BASIC-SUMMARY-001", "tabelz.executor.additional_basic_tests",
99 "additionalBasicTestsMenuItem", NULL,
100 list(method = "known_sigma_z", input_kind = "summary", summary_mean = mean(d$x),
101 sample_size = nrow(d), known_sigma = 2, null_mean = 6),
102 list("/statistic" = tol(z_summary, "summary known-sigma z"),
103 "/p_value" = prob(2 * stats::pnorm(-abs(z_summary)), "normal tail")),
104 list("Summary mean and sample size are derived from the exported CSV.",
105 "docs/manual/chapters/31-additional-basic-tests.tex:6-8: 'Summary mode is source independent: it does not claim a table population'."))
Additional configuration coverage: STAT-HYP-AXIS-BASIC-SUMMARY-TWORATE-001
Case STAT-HYP-AXIS-BASIC-SUMMARY-TWORATE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats/multcomp
- Citation
- R stats::pnorm, pt, qt, binom.test, power.t.test; multcomp::glht and mvtnorm documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_completion.R · sha256 733ecb7b7daec34d
- Dataset
- None
Settings compared
alternative= "greater"input_kind= "summary"method= "two_poisson_rate"null_ratio= 1summary_count= 4summary_count_2= 8summary_exposure= 38summary_exposure_2= 42
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/p_value | tail_probability | 0.89967425784400523 | 0.8996742578440053 | 1.13E-16 | 15 | passed |
/estimate | tolerance | 0.55263157894736847 | 0.5526315789473685 | 3.64E-18 | 17 | passed |
Convention
- Summary two-rate mode is source independent; totals derived from the R CSV.
- Data-derived values use the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
119 count_a <- sum(r$count[r$g == "A"])
120 count_b <- sum(r$count[r$g == "B"])
121 exposure_a <- sum(r$exposure[r$g == "A"])
122 exposure_b <- sum(r$exposure[r$g == "B"])
123 null_probability <- exposure_a / (exposure_a + exposure_b)
124 conditional <- stats::binom.test(count_a, count_a + count_b,
125 p = null_probability, alternative = "greater")
126 emit("STAT-HYP-AXIS-BASIC-SUMMARY-TWORATE-001", "tabelz.executor.additional_basic_tests",
127 "additionalBasicTestsMenuItem", NULL,
128 list(method = "two_poisson_rate", input_kind = "summary", summary_count = count_a,
129 summary_exposure = exposure_a, summary_count_2 = count_b,
130 summary_exposure_2 = exposure_b, null_ratio = 1, alternative = "greater"),
131 list("/p_value" = prob(conditional$p.value, "conditional binomial right tail"),
132 "/estimate" = tol((count_a / exposure_a) / (count_b / exposure_b), "A/B rate ratio")),
133 "axis_coverage", list("Summary two-rate mode is source independent; totals derived from the R CSV."))
Configuration axis: STAT-HYP-AXIS-BASIC-TWORATE-001
Case STAT-HYP-AXIS-BASIC-TWORATE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_RATES.json
Settings compared
count_column= "count"exposure_column= "exposure"exposure_unit= "days"group_1= "A"group_2= "B"group_column= "g"input_kind= "raw"method= "two_poisson_rate"null_ratio= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.55263157894736847 | 0.5526315789473685 | 3.64E-18 | 17 | passed |
/p_value | tail_probability | 0.39491312585886024 | 0.3949131258588603 | 5.22E-17 | 15 | passed |
Convention
- Days are display units; conditional Poisson test compares A/B rate ratio.
- Data-based values computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
83 count_a <- sum(r$count[r$g == "A"])
84 count_b <- sum(r$count[r$g == "B"])
85 exposure_a <- sum(r$exposure[r$g == "A"])
86 exposure_b <- sum(r$exposure[r$g == "B"])
87 two_rate <- stats::poisson.test(c(count_a, count_b), T = c(exposure_a, exposure_b), r = 1)
88 emit("STAT-HYP-AXIS-BASIC-TWORATE-001", "tabelz.executor.additional_basic_tests",
89 "additionalBasicTestsMenuItem", "HYP_RATES",
90 list(method = "two_poisson_rate", input_kind = "raw", count_column = "count",
91 exposure_column = "exposure", group_column = "g", group_1 = "A", group_2 = "B",
92 null_ratio = 1, exposure_unit = "days"),
93 list("/estimate" = tol((count_a / exposure_a) / (count_b / exposure_b), "A/B rate ratio"),
94 "/p_value" = prob(two_rate$p.value, "conditional exact two-rate tail")),
95 list("Days are display units; conditional Poisson test compares A/B rate ratio."))
Configuration axis: STAT-HYP-AXIS-EQUIV-PAIRED-001
Case STAT-HYP-AXIS-EQUIV-PAIRED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
first_column= "x"lower_bound= -2mode= "paired_difference"second_column= "y"upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.56250000000000022 | 0.5625000000000002 | 2.04E-18 | 17 | passed |
/p_lower | tail_probability | 6.7332568764626561e-20 | 6.733256876462766e-20 | 1.09E-33 | 13 | passed |
Convention
- Paired difference is x minus y; Student t tails.
- Data-based values computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
48 paired <- d$x - d$y
49 paired_effect <- mean(paired)
50 paired_se <- sd(paired) / sqrt(length(paired))
51 emit("STAT-HYP-AXIS-EQUIV-PAIRED-001", "tabelz.executor.equivalence_extensions",
52 "equivalenceMenuItem", "HYP_CORE",
53 list(mode = "paired_difference", first_column = "x", second_column = "y",
54 lower_bound = -2, upper_bound = 2),
55 list("/estimate" = tol(paired_effect, "paired difference mean"),
56 "/p_lower" = prob(stats::pt((paired_effect + 2) / paired_se, length(paired) - 1,
57 lower.tail = FALSE), "lower paired TOST")),
58 list("Paired difference is x minus y; Student t tails."))
Configuration axis: STAT-HYP-AXIS-EQUIV-RATIO-001
Case STAT-HYP-AXIS-EQUIV-RATIO-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
first_column= "x"lower_bound= 0.8mode= "paired_log_ratio"second_column= "y"upper_bound= 1.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 1.1001438287236327 | 1.1001438287236327 | 3.93E-19 | 18 | passed |
/p_lower | tail_probability | 4.0254058583697218e-14 | 4.02540585836975e-14 | 2.84E-28 | 14 | passed |
/transformed_estimate | tolerance | 0.095440924641966768 | 0.0954409246419668 | 2.76E-17 | 15 | passed |
Convention
- TOST on log(x/y); display estimate is exp(mean log ratio).
- Data-based values computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
60 log_ratio <- log(d$x / d$y)
61 log_effect <- mean(log_ratio)
62 log_se <- sd(log_ratio) / sqrt(length(log_ratio))
63 emit("STAT-HYP-AXIS-EQUIV-RATIO-001", "tabelz.executor.equivalence_extensions",
64 "equivalenceMenuItem", "HYP_CORE",
65 list(mode = "paired_log_ratio", first_column = "x", second_column = "y",
66 lower_bound = 0.8, upper_bound = 1.25),
67 list("/estimate" = tol(exp(log_effect), "geometric mean ratio"),
68 "/p_lower" = prob(stats::pt((log_effect - log(0.8)) / log_se,
69 length(log_ratio) - 1, lower.tail = FALSE), "log-ratio lower TOST"),
70 "/transformed_estimate" = tol(log_effect, "mean log ratio")),
71 list("TOST on log(x/y); display estimate is exp(mean log ratio)."))
Configuration axis: STAT-HYP-AXIS-PERM-GREATER-001
Case STAT-HYP-AXIS-PERM-GREATER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "greater"group_a= "A"group_b= "B"group_column= "g"inference= "exact"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -1.5749999999999993 | -1.5750000000000002 | 8.78E-16 | 15 | passed |
/p_value | tail_probability | 0.94996114996115 | 0.94996114996115 | 2.38E-18 | 17 | passed |
Convention
- Every choose(16,8) assignment enumerated; one-sided tail inclusive of observed.
- Data-based values computed from the exported CSV.
Reference code
Configuration axis: STAT-HYP-AXIS-PERM-LESS-001
Case STAT-HYP-AXIS-PERM-LESS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "less"group_a= "A"group_b= "B"group_column= "g"inference= "exact"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -1.5749999999999993 | -1.5750000000000002 | 8.78E-16 | 15 | passed |
/p_value | tail_probability | 0.0533022533022533 | 0.0533022533022533 | 3.95E-19 | 17 | passed |
Convention
- Every choose(16,8) assignment enumerated; one-sided tail inclusive of observed.
- Data-based values computed from the exported CSV.
Reference code
Configuration axis: STAT-HYP-AXIS-PERM-MC-001
Case STAT-HYP-AXIS-PERM-MC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"inference= "monte_carlo"mode= "independent"resamples= 100response_column= "x"seed= 77
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -1.5749999999999993 | -1.5750000000000002 | 8.78E-16 | 15 | passed |
Convention
- Monte Carlo p and histogram are deferred to V27; compare only the observed statistic.
- Data-based values computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
158 emit("STAT-HYP-AXIS-PERM-MC-001", "tabelz.executor.permutation_tests",
159 "permutationTestsMenuItem", "HYP_CORE",
160 list(mode = "independent", response_column = "x", group_column = "g",
161 group_a = "A", group_b = "B", inference = "monte_carlo", seed = 77L,
162 resamples = 100L),
163 list("/statistic" = tol(observed, "observed A-B mean")),
164 list("Monte Carlo p and histogram are deferred to V27; compare only the observed statistic."),
165 deferred = list(list(path = "/p_value", reason = "Seeded random permutation p-values are V27 simulation evidence.")),
166 repetitions = 2L)
Configuration axis: STAT-HYP-AXIS-PERM-PAIRED-001
Case STAT-HYP-AXIS-PERM-PAIRED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_PAIRS.json
Settings compared
inference= "exact"mode= "paired"response_column= "x"second_response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.56000000000000016 | 0.5600000000000002 | 4.31E-18 | 17 | passed |
/p_value | tail_probability | 0.0625 | 0.0625 | 0.00E-2 | passed | |
/assignment_count | exact | 32 | 32 | 0.00E+2 | passed |
Convention
- Five pairs give 2^5 exact sign patterns; paired difference x-y.
- Data-based values computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
120 pair_df <- data.frame(x = d$x[1:5], y = d$y[1:5])
121 export_dataset(pair_df, "HYP_PAIRS", "First five pairs from exported HYP_CORE",
122 "Constructed by hypothesis_axes.R; exact sign-flip enumeration.",
123 "Constructed test data; no third-party dataset license.",
124 c(x = "Float64", y = "Float64"))
125 pairs <- read_dataset("HYP_PAIRS")
126 differences <- pairs$x - pairs$y
127 observed_pair <- mean(differences)
128 signs <- as.matrix(expand.grid(rep(list(c(-1, 1)), length(differences))))
129 null_pair <- as.vector(signs %*% differences) / length(differences)
130 emit("STAT-HYP-AXIS-PERM-PAIRED-001", "tabelz.executor.permutation_tests",
131 "permutationTestsMenuItem", "HYP_PAIRS",
132 list(mode = "paired", response_column = "x", second_response_column = "y",
133 inference = "exact"),
134 list("/statistic" = tol(observed_pair, "mean paired difference"),
135 "/p_value" = prob(mean(abs(null_pair) >= abs(observed_pair) - 1e-12),
136 "all paired sign flips"),
137 "/assignment_count" = exact(nrow(signs), "Every sign pattern enumerated.")),
138 list("Five pairs give 2^5 exact sign patterns; paired difference x-y."))
Additional configuration coverage: STAT-HYP-AXIS-PERM-PAIRED-MC-001
Case STAT-HYP-AXIS-PERM-PAIRED-MC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats/multcomp
- Citation
- R stats::pnorm, pt, qt, binom.test, power.t.test; multcomp::glht and mvtnorm documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_completion.R · sha256 733ecb7b7daec34d
- Dataset
- reference_data/datasets/HYP_PAIRS.json
Settings compared
histogram_bins= 5inference= "monte_carlo"max_cells= 1000max_rows= 100mode= "paired"resamples= 100response_column= "x"second_response_column= "y"seed= 42
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.56000000000000016 | 0.5600000000000002 | 4.31E-18 | 17 | passed |
Convention
- Mode and inference axes interact; random p-value belongs to V27.
- Data-derived values use the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
107 paired <- pairs$x - pairs$y
108 emit("STAT-HYP-AXIS-PERM-PAIRED-MC-001", "tabelz.executor.permutation_tests",
109 "permutationTestsMenuItem", "HYP_PAIRS",
110 list(mode = "paired", response_column = "x", second_response_column = "y",
111 inference = "monte_carlo", resamples = 100L, seed = 42L,
112 histogram_bins = 5L, max_rows = 100L, max_cells = 1000L),
113 list("/statistic" = tol(mean(paired), "paired mean difference")), "axis_coverage",
114 list("Mode and inference axes interact; random p-value belongs to V27."),
115 deferred = list(list(path = "/p_value", reason = "Seeded Monte Carlo p-value is V27 simulation evidence.")),
116 repetitions = 2L)
Configuration axis: STAT-HYP-AXIS-RANK-GREATER-001
Case STAT-HYP-AXIS-RANK-GREATER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "greater"inference= "exact"method= "runs"reference_mode= "fixed"reference_value= 6response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 4 | 4 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.99800199800199796 | 0.998001998001998 | 1.37E-18 | 17 | passed |
Convention
- Fixed reference 6; exact run-count distribution over all fixed-count label allocations.
- Data-based values computed from the exported CSV.
Reference code
Configuration axis: STAT-HYP-AXIS-RANK-LESS-001
Case STAT-HYP-AXIS-RANK-LESS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats help: t.test, poisson.test, binom.test, pnorm, pt, ptukey, power.t.test; exact enumeration by combn.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_axes.R · sha256 583517bdbb860353
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "less"inference= "exact"method= "runs"reference_mode= "fixed"reference_value= 6response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 4 | 4 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.013236763236763236 | 0.013236763236763236 | 1.01E-19 | 17 | passed |
Convention
- Fixed reference 6; exact run-count distribution over all fixed-count label allocations.
- Data-based values computed from the exported CSV.
Reference code
Known-sigma one-sample Z
Case STAT-HYP-BASIC-Z-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 independent implementation
- Citation
- R stats::Normal documentation (pnorm and qnorm); closed-form Z statistic.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_secondary.R · sha256 13b3dbafe11fd4e1
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
input_kind= "raw"known_sigma= 2method= "known_sigma_z"null_mean= 6response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.625 | 1.625 | 0.00E-1 | passed | |
/p_value | tail_probability | 0.10416255883043912 | 0.10416255883043905 | 6.68E-17 | 15 | passed |
/estimate | tolerance | 6.8125 | 6.8125 | 0.00E-2 | passed |
Convention
- Z uses known sigma 2 and n=16; normal two-sided tail.
- Expected values calculated after re-reading the exported CSV where data are present.
Reference code
The lines of the reference script that produce this case's expected values.
105 sigma <- 2
106 null_mean <- 6
107 z <- (mean(d$x) - null_mean) / (sigma / sqrt(length(d$x)))
108 emit("STAT-HYP-BASIC-Z-001", "tabelz.executor.additional_basic_tests", "additionalBasicTestsMenuItem",
109 "Known-sigma one-sample Z", "nominal", "HYP_CORE",
110 list(method = "known_sigma_z", input_kind = "raw", response_column = "x",
111 known_sigma = sigma, null_mean = null_mean),
112 list("/statistic" = tol(z, "known-sigma Z"),
113 "/p_value" = prob(2 * stats::pnorm(-abs(z)), "two-sided normal tail"),
114 "/estimate" = tol(mean(d$x), "sample mean")),
115 list("Z uses known sigma 2 and n=16; normal two-sided tail."),
116 "R stats::Normal documentation (pnorm and qnorm); closed-form Z statistic.")
Three-level factor, scale 0.5
Case STAT-HYP-BAYES-ANOVA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, pt, contr.helmert, determinant, solve
- Citation
- Rouder, Morey, Speckman and Province (2012), Default Bayes factors for ANOVA designs, Journal of Mathematical Psychology 56(5), 356-374, eqs. 7-10; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.95factor= "g3"prior_scale= 0.5response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.51974050787901704 | 0.519740507879017 | 4.07E-18 | 17 | passed |
/bayes_factors/0/bf01 | tolerance | 1.9240370624195713 | 1.9240370624195713 | 1.32E-17 | 17 | passed |
/bayes_factors/0/log_bf10 | tolerance | -0.65442561526981691 | -0.6544256152698169 | 2.88E-18 | 17 | passed |
/posteriors/0/mean | tolerance | 0.70919275131772619 | 0.7091927513177272 | 9.98E-16 | 14 | passed |
/posteriors/0/sd | tolerance | 0.70286899978810091 | 0.7028689997881006 | 3.31E-16 | 15 | passed |
/posteriors/0/median | tolerance | 0.66811651560998053 | 0.6681165156099814 | 8.91E-16 | 14 | passed |
/posteriors/0/lower | tolerance | -0.57828476358183456 | -0.5782847635818359 | 1.33E-15 | 14 | passed |
/posteriors/0/upper | tolerance | 2.200166827399741 | 2.2001668273997574 | 1.64E-14 | 14 | passed |
/posteriors/1/mean | tolerance | -0.58157145568226587 | -0.5815714556822666 | 7.77E-16 | 14 | passed |
/posteriors/1/sd | tolerance | 0.7064792769389624 | 0.7064792769389626 | 2.19E-16 | 15 | passed |
/posteriors/1/median | tolerance | -0.54354830948573329 | -0.5435483094857396 | 6.33E-15 | 13 | passed |
/posteriors/1/lower | tolerance | -2.0777456794515672 | -2.0777456794515894 | 2.22E-14 | 13 | passed |
/posteriors/1/upper | tolerance | 0.72902930595955773 | 0.7290293059595588 | 1.11E-15 | 14 | passed |
/posteriors/2/mean | tolerance | -0.12762129563546043 | -0.1276212956354603 | 1.39E-16 | 14 | passed |
/posteriors/2/sd | tolerance | 0.65840471503977804 | 0.6584047150397783 | 2.26E-16 | 15 | passed |
/posteriors/2/median | tolerance | -0.12013040778427868 | -0.12013040778427829 | 3.90E-16 | 14 | passed |
/posteriors/2/lower | tolerance | -1.4652511847112863 | -1.4652511847112861 | 1.75E-16 | 15 | passed |
/posteriors/2/upper | tolerance | 1.1751537529573899 | 1.1751537529573908 | 8.74E-16 | 15 | passed |
Convention
- 3 levels (high, low, mid, in code-point order), n = 20; level effects coded by normalized Helmert contrasts Q (any orthonormal basis of the sum-to-zero space gives the same Bayes factor and level effects Q theta).
- BF10(g) = |I + g X'PX|^(-1/2) ((y'Py - y'PX (X'PX + I/g)^-1 X'Py)/y'Py)^(-(n-1)/2) with P the centring matrix, averaged over g ~ Inverse-Gamma(1/2, r^2/2), r = 0.5 (Rouder, Morey, Speckman and Province 2012, eqs. 7-10), by R integrate on u = log g.
- Posterior of each level effect: given g, Student-t on n - 1 df with centre Q (X'X + I/g)^-1 X'y and scale from s^2 Q (X'X + I/g)^-1 Q', s^2 = residual/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot on the mixture CDF; SD by the law of total variance.
- Tolerance 1e-6: both sides integrate numerically.
- docs/manual/chapters/79-bayesian-analysis.tex:31-32: 'One-way ANOVA & Shared scale for fixed level effects, default 0.5; at most ten levels.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
484 emit("hypothesis", "bayesAnovaMenuItem", "tabelz.analysis.bayesian.linear:compute_bayes_anova",
485 id, title, kind,
486 list(response = "y", factor = factor, prior_scale = r, confidence_level = level),
487 outputs,
488 c(sprintf("%d levels (%s, in code-point order), n = %d; level effects coded by normalized Helmert contrasts Q (any orthonormal basis of the sum-to-zero space gives the same Bayes factor and level effects Q theta).", a, paste(levels, collapse = ", "), n),
489 sprintf("BF10(g) = |I + g X'PX|^(-1/2) ((y'Py - y'PX (X'PX + I/g)^-1 X'Py)/y'Py)^(-(n-1)/2) with P the centring matrix, averaged over g ~ Inverse-Gamma(1/2, r^2/2), r = %g (Rouder, Morey, Speckman and Province 2012, eqs. 7-10), by R integrate on u = log g.", r),
490 "Posterior of each level effect: given g, Student-t on n - 1 df with centre Q (X'X + I/g)^-1 X'y and scale from s^2 Q (X'X + I/g)^-1 Q', s^2 = residual/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot on the mixture CDF; SD by the law of total variance.",
491 "Tolerance 1e-6: both sides integrate numerically.",
492 paste0(manual, ":31-32: 'One-way ANOVA & Shared scale for fixed level effects, default 0.5; at most ten levels.'")),
493 "R stats: integrate, uniroot, pt, contr.helmert, determinant, solve",
494 "Rouder, Morey, Speckman and Province (2012), Default Bayes factors for ANOVA designs, Journal of Mathematical Psychology 56(5), 356-374, eqs. 7-10; R Core Team, stats package help: integrate, uniroot.",
495 "REQ-STAT-HYP-BAYES-ANOVA-001")
Three-level factor, scale 1
Case STAT-HYP-BAYES-ANOVA-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, pt, contr.helmert, determinant, solve
- Citation
- Rouder, Morey, Speckman and Province (2012), Default Bayes factors for ANOVA designs, Journal of Mathematical Psychology 56(5), 356-374, eqs. 7-10; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.95factor= "g3"prior_scale= 1response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.27391669251096151 | 0.2739166925109615 | 2.50E-18 | 17 | passed |
/bayes_factors/0/bf01 | tolerance | 3.6507450160598824 | 3.6507450160598824 | 4.18E-17 | 16 | passed |
/bayes_factors/0/log_bf10 | tolerance | -1.294931260754983 | -1.294931260754983 | 6.57E-18 | 17 | passed |
/posteriors/0/mean | tolerance | 0.94393805529168351 | 0.9439380552916841 | 5.54E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.76764521037269207 | 0.7676452103726925 | 4.40E-16 | 15 | passed |
/posteriors/0/median | tolerance | 0.93159669482692564 | 0.9315966948269541 | 2.84E-14 | 13 | passed |
/posteriors/0/lower | tolerance | -0.54266377923398423 | -0.5426637792339821 | 2.11E-15 | 14 | passed |
/posteriors/0/upper | tolerance | 2.4950588915396814 | 2.4950588915396823 | 9.00E-16 | 15 | passed |
/posteriors/1/mean | tolerance | -0.7810869148387144 | -0.7810869148387155 | 1.11E-15 | 14 | passed |
/posteriors/1/sd | tolerance | 0.78670562856158777 | 0.7867056285615879 | 1.07E-16 | 15 | passed |
/posteriors/1/median | tolerance | -0.76919754303930776 | -0.7691975430393319 | 2.41E-14 | 13 | passed |
/posteriors/1/lower | tolerance | -2.3701548522339544 | -2.370154852233955 | 4.34E-16 | 15 | passed |
/posteriors/1/upper | tolerance | 0.7467791719253386 | 0.7467791719253403 | 1.67E-15 | 14 | passed |
/posteriors/2/mean | tolerance | -0.16285114045296889 | -0.16285114045296875 | 1.39E-16 | 15 | passed |
/posteriors/2/sd | tolerance | 0.75052145176577656 | 0.7505214517657766 | 6.16E-19 | 18 | passed |
/posteriors/2/median | tolerance | -0.16086418268917485 | -0.16086418268917432 | 5.27E-16 | 14 | passed |
/posteriors/2/lower | tolerance | -1.6578006305300588 | -1.6578006305300583 | 4.72E-16 | 15 | passed |
/posteriors/2/upper | tolerance | 1.3221710826924693 | 1.322171082692469 | 2.20E-16 | 15 | passed |
Convention
- 3 levels (high, low, mid, in code-point order), n = 20; level effects coded by normalized Helmert contrasts Q (any orthonormal basis of the sum-to-zero space gives the same Bayes factor and level effects Q theta).
- BF10(g) = |I + g X'PX|^(-1/2) ((y'Py - y'PX (X'PX + I/g)^-1 X'Py)/y'Py)^(-(n-1)/2) with P the centring matrix, averaged over g ~ Inverse-Gamma(1/2, r^2/2), r = 1 (Rouder, Morey, Speckman and Province 2012, eqs. 7-10), by R integrate on u = log g.
- Posterior of each level effect: given g, Student-t on n - 1 df with centre Q (X'X + I/g)^-1 X'y and scale from s^2 Q (X'X + I/g)^-1 Q', s^2 = residual/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot on the mixture CDF; SD by the law of total variance.
- Tolerance 1e-6: both sides integrate numerically.
- docs/manual/chapters/79-bayesian-analysis.tex:31-32: 'One-way ANOVA & Shared scale for fixed level effects, default 0.5; at most ten levels.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
498 anova_case("STAT-HYP-BAYES-ANOVA-002", "Three-level factor, scale 1", "axis_coverage", "g3", 1, 0.95)
Two-level factor, 90% interval
Case STAT-HYP-BAYES-ANOVA-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, pt, contr.helmert, determinant, solve
- Citation
- Rouder, Morey, Speckman and Province (2012), Default Bayes factors for ANOVA designs, Journal of Mathematical Psychology 56(5), 356-374, eqs. 7-10; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.9factor= "g"prior_scale= 0.5response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.76043569975333625 | 0.7604356997533361 | 1.14E-16 | 15 | passed |
/bayes_factors/0/bf01 | tolerance | 1.3150355780565952 | 1.3150355780565952 | 1.13E-17 | 17 | passed |
/bayes_factors/0/log_bf10 | tolerance | -0.27386372082007909 | -0.27386372082007915 | 5.84E-17 | 15 | passed |
/posteriors/0/mean | tolerance | -0.57715857206188637 | -0.5771585720618857 | 6.70E-16 | 14 | passed |
/posteriors/0/sd | tolerance | 0.54330882690860582 | 0.5433088269086066 | 7.81E-16 | 14 | passed |
/posteriors/0/median | tolerance | -0.55639619102158921 | -0.5563961910216128 | 2.35E-14 | 13 | passed |
/posteriors/0/lower | tolerance | -1.4985352915013004 | -1.4985352915013166 | 1.62E-14 | 13 | passed |
/posteriors/0/upper | tolerance | 0.27392802645955994 | 0.273928026459558 | 1.95E-15 | 14 | passed |
/posteriors/1/mean | tolerance | 0.57715857206188637 | 0.5771585720618861 | 2.26E-16 | 15 | passed |
/posteriors/1/sd | tolerance | 0.54330882690860582 | 0.5433088269086065 | 6.70E-16 | 14 | passed |
/posteriors/1/median | tolerance | 0.55639619102158921 | 0.5563961910216128 | 2.35E-14 | 13 | passed |
/posteriors/1/lower | tolerance | -0.27392802645955938 | -0.2739280264595593 | 5.38E-17 | 15 | passed |
/posteriors/1/upper | tolerance | 1.4985352915012995 | 1.4985352915013166 | 1.71E-14 | 13 | passed |
Convention
- 2 levels (A, B, in code-point order), n = 20; level effects coded by normalized Helmert contrasts Q (any orthonormal basis of the sum-to-zero space gives the same Bayes factor and level effects Q theta).
- BF10(g) = |I + g X'PX|^(-1/2) ((y'Py - y'PX (X'PX + I/g)^-1 X'Py)/y'Py)^(-(n-1)/2) with P the centring matrix, averaged over g ~ Inverse-Gamma(1/2, r^2/2), r = 0.5 (Rouder, Morey, Speckman and Province 2012, eqs. 7-10), by R integrate on u = log g.
- Posterior of each level effect: given g, Student-t on n - 1 df with centre Q (X'X + I/g)^-1 X'y and scale from s^2 Q (X'X + I/g)^-1 Q', s^2 = residual/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot on the mixture CDF; SD by the law of total variance.
- Tolerance 1e-6: both sides integrate numerically.
- docs/manual/chapters/79-bayesian-analysis.tex:31-32: 'One-way ANOVA & Shared scale for fixed level effects, default 0.5; at most ten levels.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
499 anova_case("STAT-HYP-BAYES-ANOVA-003", "Two-level factor, 90% interval", "axis_coverage", "g", 0.5, 0.9)
Beta(1, 1) prior against p = 0.5
Case STAT-HYP-BAYES-BINOMIAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lbeta, qbeta, pbeta, dbeta, uniroot
- Citation
- R Core Team, stats package help: Beta (qbeta, pbeta, dbeta), Special (lbeta), uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "outcome"confidence_level= 0.95event_value= "pass"null_proportion= 0.5prior_a= 1prior_b= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.29728620193016497 | 0.297286201930165 | 2.75E-18 | 17 | passed |
/bayes_factors/0/bf01 | tolerance | 3.363761901855467 | 3.363761901855467 | 2.64E-17 | 17 | passed |
/bayes_factors/0/log_bf10 | tolerance | -1.2130599613226458 | -1.2130599613226458 | 1.89E-17 | 16 | passed |
/posteriors/0/mean | tolerance | 0.54545454545454541 | 0.5454545454545454 | 4.17E-18 | 17 | passed |
/posteriors/0/sd | tolerance | 0.1038254983127565 | 0.1038254983127565 | 3.43E-18 | 16 | passed |
/posteriors/0/median | tolerance | 0.54685650153544374 | 0.5468565015354439 | 1.11E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 0.34020630928027468 | 0.3402063092802746 | 5.86E-17 | 15 | passed |
/posteriors/0/upper | tolerance | 0.74286937359359317 | 0.7428693735935925 | 6.62E-16 | 15 | passed |
/posteriors/0/hdi_lower | tolerance | 0.34310117869230511 | 0.34310117869202084 | 2.84E-13 | 12 | passed |
/posteriors/0/hdi_upper | tolerance | 0.74560984692617449 | 0.7456098469264277 | 2.53E-13 | 12 | passed |
Convention
- x = 11 events (pass) in n = 20 trials; prior Beta(1, 1) gives posterior Beta(12, 10).
- log BF10 = lbeta(a + x, b + n - x) - lbeta(a, b) - x log p0 - (n - x) log(1 - p0): the beta-binomial marginal likelihood against the point null.
- Equal-tailed interval: qbeta at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.
- docs/manual/chapters/79-bayesian-analysis.tex:25-26: 'Binomial proportion & Beta(a,b), default Beta(1,1); name the event and point-null proportion.'
- docs/manual/chapters/79-bayesian-analysis.tex:62-64: 'Posterior mean is 7/12; SD is sqrt(7*5/(12^2*13)) ... BF10 = B(7,5)/0.5^10 ... equal-tailed limits are the 0.025 and 0.975 quantiles'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
122 binomial_case <- function(id, title, kind, event, p0, a, b, level, excluded = list()) {
123 v <- dat$outcome[rows_kept(excluded)]
124 n <- length(v)
125 x <- sum(v == event)
126 A <- a + x
127 B <- b + n - x
128 log_bf <- lbeta(A, B) - lbeta(a, b) - x * log(p0) - (n - x) * log1p(-p0)
129 tail <- (1 - level) / 2
130 hdi <- hdi_closed(function(p) stats::dbeta(p, A, B), function(p) stats::pbeta(p, A, B),
131 function(q) stats::qbeta(q, A, B), level, stats::qbeta(1e-12, A, B))
132 outputs <- c(
133 list("/n" = count_of(n, "Number of analysed trials.")),
134 bf_outputs(log_bf, "beta-binomial"),
135 posterior_outputs("/posteriors/0", A / (A + B), sqrt(A * B / ((A + B)^2 * (A + B + 1))),
136 stats::qbeta(0.5, A, B), stats::qbeta(tail, A, B), stats::qbeta(1 - tail, A, B),
137 hdi, sprintf("Beta(%g, %g)", A, B)))
138 emit("hypothesis", "bayesBinomialMenuItem",
139 "tabelz.analysis.bayesian.conjugate:compute_bayes_binomial", id, title, kind,
140 list(column = "outcome", event_value = event, null_proportion = p0, prior_a = a,
141 prior_b = b, confidence_level = level),
142 outputs,
143 c(sprintf("x = %d events (%s) in n = %d trials; prior Beta(%g, %g) gives posterior Beta(%g, %g).", x, event, n, a, b, A, B),
144 "log BF10 = lbeta(a + x, b + n - x) - lbeta(a, b) - x log p0 - (n - x) log(1 - p0): the beta-binomial marginal likelihood against the point null.",
145 "Equal-tailed interval: qbeta at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.",
146 paste0(manual, ":25-26: 'Binomial proportion & Beta(a,b), default Beta(1,1); name the event and point-null proportion.'"),
147 paste0(manual, ":62-64: 'Posterior mean is 7/12; SD is sqrt(7*5/(12^2*13)) ... BF10 = B(7,5)/0.5^10 ... equal-tailed limits are the 0.025 and 0.975 quantiles'")),
148 "R stats: lbeta, qbeta, pbeta, dbeta, uniroot",
149 "R Core Team, stats package help: Beta (qbeta, pbeta, dbeta), Special (lbeta), uniroot.",
150 "REQ-STAT-HYP-BAYES-BINOMIAL-001", excluded)
Informative Beta(2, 5) prior against p = 0.3
Case STAT-HYP-BAYES-BINOMIAL-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lbeta, qbeta, pbeta, dbeta, uniroot
- Citation
- R Core Team, stats package help: Beta (qbeta, pbeta, dbeta), Special (lbeta), uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "outcome"confidence_level= 0.95event_value= "pass"null_proportion= 0.3prior_a= 2prior_b= 5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 3.1038687351072145 | 3.103868735107217 | 2.67E-15 | 15 | passed |
/bayes_factors/0/bf01 | tolerance | 0.32217857304634301 | 0.32217857304634273 | 2.79E-16 | 15 | passed |
/bayes_factors/0/log_bf10 | tolerance | 1.1326493124793515 | 1.1326493124793524 | 9.10E-16 | 15 | passed |
/posteriors/0/mean | tolerance | 0.48148148148148145 | 0.48148148148148145 | 4.75E-18 | 17 | passed |
/posteriors/0/sd | tolerance | 0.094426287288755267 | 0.09442628728875527 | 3.35E-19 | 17 | passed |
/posteriors/0/median | tolerance | 0.48101754314588091 | 0.48101754314588074 | 1.66E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 0.29927217944159645 | 0.2992721794415965 | 5.86E-17 | 15 | passed |
/posteriors/0/upper | tolerance | 0.6662917815247078 | 0.6662917815247077 | 1.06E-16 | 15 | passed |
/posteriors/0/hdi_lower | tolerance | 0.2983496142960454 | 0.2983496142958298 | 2.16E-13 | 12 | passed |
/posteriors/0/hdi_upper | tolerance | 0.66535077002912435 | 0.6653507700293513 | 2.27E-13 | 12 | passed |
Convention
- x = 11 events (pass) in n = 20 trials; prior Beta(2, 5) gives posterior Beta(13, 14).
- log BF10 = lbeta(a + x, b + n - x) - lbeta(a, b) - x log p0 - (n - x) log(1 - p0): the beta-binomial marginal likelihood against the point null.
- Equal-tailed interval: qbeta at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.
- docs/manual/chapters/79-bayesian-analysis.tex:25-26: 'Binomial proportion & Beta(a,b), default Beta(1,1); name the event and point-null proportion.'
- docs/manual/chapters/79-bayesian-analysis.tex:62-64: 'Posterior mean is 7/12; SD is sqrt(7*5/(12^2*13)) ... BF10 = B(7,5)/0.5^10 ... equal-tailed limits are the 0.025 and 0.975 quantiles'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
154 binomial_case("STAT-HYP-BAYES-BINOMIAL-002", "Informative Beta(2, 5) prior against p = 0.3",
155 "axis_coverage", "pass", 0.3, 2, 5, 0.95)
90% credible interval, event 'fail'
Case STAT-HYP-BAYES-BINOMIAL-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lbeta, qbeta, pbeta, dbeta, uniroot
- Citation
- R Core Team, stats package help: Beta (qbeta, pbeta, dbeta), Special (lbeta), uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "outcome"confidence_level= 0.9event_value= "fail"null_proportion= 0.5prior_a= 1prior_b= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.29728620193016519 | 0.2972862019301652 | 4.80E-18 | 16 | passed |
/bayes_factors/0/bf01 | tolerance | 3.3637619018554639 | 3.363761901855464 | 3.50E-17 | 16 | passed |
/bayes_factors/0/log_bf10 | tolerance | -1.2130599613226449 | -1.213059961322645 | 3.07E-17 | 16 | passed |
/posteriors/0/mean | tolerance | 0.45454545454545453 | 0.45454545454545453 | 3.15E-19 | 18 | passed |
/posteriors/0/sd | tolerance | 0.1038254983127565 | 0.1038254983127565 | 3.43E-18 | 16 | passed |
/posteriors/0/median | tolerance | 0.45314349846455626 | 0.45314349846455626 | 2.52E-19 | 18 | passed |
/posteriors/0/lower | tolerance | 0.28580047808717579 | 0.2858004780871762 | 3.90E-16 | 14 | passed |
/posteriors/0/upper | tolerance | 0.62809886291875483 | 0.6280988629187549 | 1.11E-16 | 15 | passed |
/posteriors/0/hdi_lower | tolerance | 0.28295610302502788 | 0.28295610302493224 | 9.56E-14 | 12 | passed |
/posteriors/0/hdi_upper | tolerance | 0.62512165736120107 | 0.6251216573612979 | 9.68E-14 | 12 | passed |
Convention
- x = 9 events (fail) in n = 20 trials; prior Beta(1, 1) gives posterior Beta(10, 12).
- log BF10 = lbeta(a + x, b + n - x) - lbeta(a, b) - x log p0 - (n - x) log(1 - p0): the beta-binomial marginal likelihood against the point null.
- Equal-tailed interval: qbeta at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.
- docs/manual/chapters/79-bayesian-analysis.tex:25-26: 'Binomial proportion & Beta(a,b), default Beta(1,1); name the event and point-null proportion.'
- docs/manual/chapters/79-bayesian-analysis.tex:62-64: 'Posterior mean is 7/12; SD is sqrt(7*5/(12^2*13)) ... BF10 = B(7,5)/0.5^10 ... equal-tailed limits are the 0.025 and 0.975 quantiles'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
156 binomial_case("STAT-HYP-BAYES-BINOMIAL-003", "90% credible interval, event 'fail'",
157 "axis_coverage", "fail", 0.5, 1, 1, 0.9)
Three excluded rows
Case STAT-HYP-BAYES-BINOMIAL-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lbeta, qbeta, pbeta, dbeta, uniroot
- Citation
- R Core Team, stats package help: Beta (qbeta, pbeta, dbeta), Special (lbeta), uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "outcome"confidence_level= 0.95event_value= "pass"null_proportion= 0.5prior_a= 1prior_b= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 17 | 17 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.37442296265825803 | 0.3744229626582567 | 1.33E-15 | 14 | passed |
/bayes_factors/0/bf01 | tolerance | 2.6707763671874907 | 2.6707763671875004 | 9.74E-15 | 14 | passed |
/bayes_factors/0/log_bf10 | tolerance | -0.98236920437305031 | -0.9823692043730539 | 3.55E-15 | 14 | passed |
/posteriors/0/mean | tolerance | 0.57894736842105265 | 0.5789473684210527 | 4.95E-18 | 17 | passed |
/posteriors/0/sd | tolerance | 0.11040093138633174 | 0.11040093138633174 | 1.81E-18 | 16 | passed |
/posteriors/0/median | tolerance | 0.5817737444400044 | 0.5817737444400044 | 3.34E-18 | 17 | passed |
/posteriors/0/lower | tolerance | 0.35745120589306256 | 0.3574512058930627 | 1.13E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 0.78469849261270019 | 0.7846984926127001 | 1.07E-16 | 15 | passed |
/posteriors/0/hdi_lower | tolerance | 0.36342571631635884 | 0.3634257163161219 | 2.37E-13 | 12 | passed |
/posteriors/0/hdi_upper | tolerance | 0.79007857821907235 | 0.7900785782192628 | 1.90E-13 | 12 | passed |
Convention
- x = 10 events (pass) in n = 17 trials; prior Beta(1, 1) gives posterior Beta(11, 8).
- log BF10 = lbeta(a + x, b + n - x) - lbeta(a, b) - x log p0 - (n - x) log(1 - p0): the beta-binomial marginal likelihood against the point null.
- Equal-tailed interval: qbeta at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.
- docs/manual/chapters/79-bayesian-analysis.tex:25-26: 'Binomial proportion & Beta(a,b), default Beta(1,1); name the event and point-null proportion.'
- docs/manual/chapters/79-bayesian-analysis.tex:62-64: 'Posterior mean is 7/12; SD is sqrt(7*5/(12^2*13)) ... BF10 = B(7,5)/0.5^10 ... equal-tailed limits are the 0.025 and 0.975 quantiles'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
158 binomial_case("STAT-HYP-BAYES-BINOMIAL-004", "Three excluded rows", "missing_excluded",
159 "pass", 0.5, 1, 1, 0.95, excluded = list(0L, 7L, 12L))
Uniform prior (width 1) on x1 and y
Case STAT-HYP-BAYES-CORRELATION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, dbeta, cor
- Citation
- Ly, Verhagen and Wagenmakers (2016), Harold Jeffreys's default Bayes factor hypothesis tests: explanation, extension, and application in psychology, Journal of Mathematical Psychology 72, 19-32, eqs. 7 and 9; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.95first= "x1"prior_width= 1second= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 251.74340431116534 | 251.74340431116423 | 1.11E-12 | 14 | passed |
/bayes_factors/0/bf01 | tolerance | 0.0039722987092204341 | 0.003972298709220452 | 1.82E-17 | 14 | passed |
/bayes_factors/0/log_bf10 | tolerance | 5.5284103318956426 | 5.528410331895638 | 4.47E-15 | 15 | passed |
/posteriors/0/mean | tolerance | 0.6885279748461971 | 0.6885279748461969 | 2.23E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.12132050830333783 | 0.12132050830333851 | 6.85E-16 | 14 | passed |
/posteriors/0/median | tolerance | 0.70723986196305133 | 0.7072398619630511 | 2.21E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 0.4007413616778539 | 0.40074136167785357 | 3.31E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 0.87008633662916779 | 0.8700863366291678 | 8.30E-19 | 18 | passed |
Convention
- r = 0.75258494458730696 from n = 20 pairs.
- Likelihood of rho (Ly, Verhagen and Wagenmakers 2016, eq. 7): L(rho) proportional to (1 - rho^2)^((n-1)/2) integral_0^inf (cosh w - rho r)^-(n-1) dw, by R integrate.
- Prior: stretched Beta(1/width, 1/width) on (-1, 1), width 1, density dbeta((rho + 1)/2, 1/width, 1/width)/2; BF10 = integral prior(rho) L(rho)/L(0) drho by R integrate.
- Posterior moments and quantiles of rho by R integrate and uniroot on the normalized prior times likelihood.
- Tolerance 1e-6: both sides integrate numerically (nested R integrate rel.tol 1e-11/1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).
- docs/manual/chapters/79-bayesian-analysis.tex:23-24: 'Pearson correlation & Stretched beta prior on correlation in (-1,1); default width 1 is uniform.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
375 log_prior <- function(rho) stats::dbeta((rho + 1) / 2, alpha, alpha, log = TRUE) - log(2)
376 log_l0 <- log_lik(0)
377 bf <- stats::integrate(function(rho) vapply(rho, function(v) exp(log_prior(v) + log_lik(v) - log_l0), 0),
378 -1, 1, rel.tol = 1e-11, abs.tol = 0, subdivisions = 2000L)$value
379 log_bf <- log(bf)
380 s <- numeric_posterior(function(rho) log_prior(rho) + log_lik(rho), -1, 1, level)
381 outputs <- c(
382 list("/n" = count_of(n, "Number of complete pairs.")),
383 bf_outputs(log_bf, "correlation", kind = quad),
384 numeric_outputs("/posteriors/0", s, "posterior of rho"))
385 emit("hypothesis", "bayesCorrelationMenuItem",
386 "tabelz.analysis.bayesian.jzs:compute_bayes_correlation", id, title, kind,
387 list(first = first, second = second, prior_width = width, confidence_level = level),
388 outputs,
389 c(sprintf("r = %s from n = %d pairs.", format(r, digits = 17), n),
390 "Likelihood of rho (Ly, Verhagen and Wagenmakers 2016, eq. 7): L(rho) proportional to (1 - rho^2)^((n-1)/2) integral_0^inf (cosh w - rho r)^-(n-1) dw, by R integrate.",
391 sprintf("Prior: stretched Beta(1/width, 1/width) on (-1, 1), width %g, density dbeta((rho + 1)/2, 1/width, 1/width)/2; BF10 = integral prior(rho) L(rho)/L(0) drho by R integrate.", width),
392 "Posterior moments and quantiles of rho by R integrate and uniroot on the normalized prior times likelihood.",
393 "Tolerance 1e-6: both sides integrate numerically (nested R integrate rel.tol 1e-11/1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).",
394 paste0(manual, ":23-24: 'Pearson correlation & Stretched beta prior on correlation in (-1,1); default width 1 is uniform.'")),
395 "R stats: integrate, uniroot, dbeta, cor",
396 "Ly, Verhagen and Wagenmakers (2016), Harold Jeffreys's default Bayes factor hypothesis tests: explanation, extension, and application in psychology, Journal of Mathematical Psychology 72, 19-32, eqs. 7 and 9; R Core Team, stats package help: integrate, uniroot.",
397 "REQ-STAT-HYP-BAYES-CORRELATION-001")
Stretched Beta(2, 2) prior (width 0.5)
Case STAT-HYP-BAYES-CORRELATION-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, dbeta, cor
- Citation
- Ly, Verhagen and Wagenmakers (2016), Harold Jeffreys's default Bayes factor hypothesis tests: explanation, extension, and application in psychology, Journal of Mathematical Psychology 72, 19-32, eqs. 7 and 9; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.95first= "x1"prior_width= 0.5second= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 193.04083084157321 | 193.04083084157253 | 6.81E-13 | 14 | passed |
/bayes_factors/0/bf01 | tolerance | 0.0051802512227099281 | 0.005180251222709946 | 1.82E-17 | 14 | passed |
/bayes_factors/0/log_bf10 | tolerance | 5.2629017252941139 | 5.26290172529411 | 3.52E-15 | 15 | passed |
/posteriors/0/mean | tolerance | 0.65221979985706635 | 0.652219799857066 | 3.32E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.12862310449386624 | 0.1286231044938669 | 6.68E-16 | 14 | passed |
/posteriors/0/median | tolerance | 0.67082010902381761 | 0.6708201090238171 | 5.53E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 0.35062158248306119 | 0.350621582483061 | 1.67E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 0.84865035029164104 | 0.8486503502916408 | 2.20E-16 | 15 | passed |
Convention
- r = 0.75258494458730696 from n = 20 pairs.
- Likelihood of rho (Ly, Verhagen and Wagenmakers 2016, eq. 7): L(rho) proportional to (1 - rho^2)^((n-1)/2) integral_0^inf (cosh w - rho r)^-(n-1) dw, by R integrate.
- Prior: stretched Beta(1/width, 1/width) on (-1, 1), width 0.5, density dbeta((rho + 1)/2, 1/width, 1/width)/2; BF10 = integral prior(rho) L(rho)/L(0) drho by R integrate.
- Posterior moments and quantiles of rho by R integrate and uniroot on the normalized prior times likelihood.
- Tolerance 1e-6: both sides integrate numerically (nested R integrate rel.tol 1e-11/1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).
- docs/manual/chapters/79-bayesian-analysis.tex:23-24: 'Pearson correlation & Stretched beta prior on correlation in (-1,1); default width 1 is uniform.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
401 correlation_case("STAT-HYP-BAYES-CORRELATION-002", "Stretched Beta(2, 2) prior (width 0.5)",
402 "axis_coverage", "x1", "y", 0.5, 0.95)
Weak correlation x2 and d, 90% interval
Case STAT-HYP-BAYES-CORRELATION-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, dbeta, cor
- Citation
- Ly, Verhagen and Wagenmakers (2016), Harold Jeffreys's default Bayes factor hypothesis tests: explanation, extension, and application in psychology, Journal of Mathematical Psychology 72, 19-32, eqs. 7 and 9; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.9first= "x2"prior_width= 1second= "d"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.34229051988943493 | 0.3422905198894348 | 1.11E-16 | 15 | passed |
/bayes_factors/0/bf01 | tolerance | 2.921494876115807 | 2.9214948761158084 | 1.38E-15 | 15 | passed |
/bayes_factors/0/log_bf10 | tolerance | -1.0720954291569085 | -1.072095429156909 | 4.19E-16 | 15 | passed |
/posteriors/0/mean | tolerance | -0.13496237220944055 | -0.13496237220944046 | 8.79E-17 | 15 | passed |
/posteriors/0/sd | tolerance | 0.20987302617250256 | 0.20987302617250259 | 2.59E-17 | 15 | passed |
/posteriors/0/median | tolerance | -0.14129037598631206 | -0.14129037598629782 | 1.42E-14 | 12 | passed |
/posteriors/0/lower | tolerance | -0.46984475651198532 | -0.4698447565119852 | 1.13E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 0.22167014286530423 | 0.22167014286530476 | 5.29E-16 | 14 | passed |
Convention
- r = -0.15990692249686655 from n = 20 pairs.
- Likelihood of rho (Ly, Verhagen and Wagenmakers 2016, eq. 7): L(rho) proportional to (1 - rho^2)^((n-1)/2) integral_0^inf (cosh w - rho r)^-(n-1) dw, by R integrate.
- Prior: stretched Beta(1/width, 1/width) on (-1, 1), width 1, density dbeta((rho + 1)/2, 1/width, 1/width)/2; BF10 = integral prior(rho) L(rho)/L(0) drho by R integrate.
- Posterior moments and quantiles of rho by R integrate and uniroot on the normalized prior times likelihood.
- Tolerance 1e-6: both sides integrate numerically (nested R integrate rel.tol 1e-11/1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).
- docs/manual/chapters/79-bayesian-analysis.tex:23-24: 'Pearson correlation & Stretched beta prior on correlation in (-1,1); default width 1 is uniform.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
403 correlation_case("STAT-HYP-BAYES-CORRELATION-003", "Weak correlation x2 and d, 90% interval",
404 "axis_coverage", "x2", "d", 1, 0.9)
Normal(0, 1) prior, known SD 1, null 0
Case STAT-HYP-BAYES-NORMAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: dnorm, qnorm
- Citation
- R Core Team, stats package help: Normal (dnorm, qnorm).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "d"confidence_level= 0.95known_sd= 1null_value= 0prior_mean= 0prior_sd= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 22.0040052899997 | 22.004005289999682 | 1.77E-14 | 15 | passed |
/bayes_factors/0/bf01 | tolerance | 0.045446271568316529 | 0.04544627156831657 | 4.18E-17 | 15 | passed |
/bayes_factors/0/log_bf10 | tolerance | 3.0912244954240036 | 3.0912244954240027 | 9.17E-16 | 15 | passed |
/posteriors/0/mean | tolerance | 0.66285714285714292 | 0.6628571428571429 | 2.49E-18 | 17 | passed |
/posteriors/0/sd | tolerance | 0.21821789023599236 | 0.21821789023599236 | 2.24E-18 | 16 | passed |
/posteriors/0/median | tolerance | 0.66285714285714292 | 0.6628571428571429 | 2.49E-18 | 17 | passed |
/posteriors/0/lower | tolerance | 0.23515793721228329 | 0.23515793721228317 | 1.15E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 1.0905563485020027 | 1.0905563485020027 | 2.96E-17 | 16 | passed |
/posteriors/0/hdi_lower | tolerance | 0.23515793721228329 | 0.23515793721196954 | 3.14E-13 | 11 | passed |
/posteriors/0/hdi_upper | tolerance | 1.0905563485020027 | 1.0905563485023162 | 3.13E-13 | 12 | passed |
Convention
- ybar = 0.69600000000000006 from n = 20; posterior precision 1/tau^2 + n/sigma^2, mean (m0/tau^2 + n ybar/sigma^2)/precision.
- BF10 = N(ybar; m0, tau^2 + sigma^2/n) / N(ybar; mu0, sigma^2/n) (prior predictive against the point null).
- The posterior is symmetric: its HDI equals the equal-tailed interval from qnorm.
- docs/manual/chapters/79-bayesian-analysis.tex:29-30: 'Normal mean, known SD & Normal prior on the mean; supply the known observation SD, prior mean and prior SD.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
218 normal_case <- function(id, title, kind, sigma, m0, tau, mu0, level) {
219 v <- dat$d
220 n <- length(v)
221 ybar <- mean(v)
222 precision <- 1 / tau^2 + n / sigma^2
223 post_mean <- (m0 / tau^2 + n * ybar / sigma^2) / precision
224 post_sd <- sqrt(1 / precision)
225 log_bf <- stats::dnorm(ybar, m0, sqrt(tau^2 + sigma^2 / n), log = TRUE) -
226 stats::dnorm(ybar, mu0, sigma / sqrt(n), log = TRUE)
227 tail <- (1 - level) / 2
228 lower <- stats::qnorm(tail, post_mean, post_sd)
229 upper <- stats::qnorm(1 - tail, post_mean, post_sd)
230 outputs <- c(
231 list("/n" = count_of(n, "Number of observations.")),
232 bf_outputs(log_bf, "normal-normal"),
233 posterior_outputs("/posteriors/0", post_mean, post_sd, post_mean, lower, upper,
234 c(lower, upper), "Normal posterior"))
235 emit("hypothesis", "bayesNormalMenuItem",
236 "tabelz.analysis.bayesian.conjugate:compute_bayes_normal", id, title, kind,
237 list(column = "d", known_sd = sigma, prior_mean = m0, prior_sd = tau, null_value = mu0,
238 confidence_level = level),
239 outputs,
240 c(sprintf("ybar = %s from n = %d; posterior precision 1/tau^2 + n/sigma^2, mean (m0/tau^2 + n ybar/sigma^2)/precision.", format(ybar, digits = 17), n),
241 "BF10 = N(ybar; m0, tau^2 + sigma^2/n) / N(ybar; mu0, sigma^2/n) (prior predictive against the point null).",
242 "The posterior is symmetric: its HDI equals the equal-tailed interval from qnorm.",
243 paste0(manual, ":29-30: 'Normal mean, known SD & Normal prior on the mean; supply the known observation SD, prior mean and prior SD.'")),
244 "R stats: dnorm, qnorm",
245 "R Core Team, stats package help: Normal (dnorm, qnorm).",
246 "REQ-STAT-HYP-BAYES-NORMAL-001")
Informative Normal(1, 0.5) prior, known SD 1.2, null 0.5
Case STAT-HYP-BAYES-NORMAL-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: dnorm, qnorm
- Citation
- R Core Team, stats package help: Normal (dnorm, qnorm).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "d"confidence_level= 0.95known_sd= 1.2null_value= 0.5prior_mean= 1prior_sd= 0.5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.53490397130943779 | 0.5349039713094379 | 1.08E-16 | 15 | passed |
/bayes_factors/0/bf01 | tolerance | 1.8694944394449218 | 1.8694944394449216 | 2.48E-16 | 15 | passed |
/bayes_factors/0/log_bf10 | tolerance | -0.62566804107646079 | -0.6256680410764606 | 2.22E-16 | 15 | passed |
/posteriors/0/mean | tolerance | 0.7639751552795031 | 0.7639751552795031 | 4.21E-18 | 17 | passed |
/posteriors/0/sd | tolerance | 0.23643312187173018 | 0.23643312187173018 | 4.13E-18 | 16 | passed |
/posteriors/0/median | tolerance | 0.7639751552795031 | 0.7639751552795031 | 4.21E-18 | 17 | passed |
/posteriors/0/lower | tolerance | 0.30057475165854269 | 0.30057475165854264 | 5.18E-17 | 15 | passed |
/posteriors/0/upper | tolerance | 1.2273755589004636 | 1.2273755589004636 | 2.98E-17 | 16 | passed |
/posteriors/0/hdi_lower | tolerance | 0.30057475165854269 | 0.3005747516582028 | 3.40E-13 | 11 | passed |
/posteriors/0/hdi_upper | tolerance | 1.2273755589004636 | 1.2273755589008035 | 3.40E-13 | 12 | passed |
Convention
- ybar = 0.69600000000000006 from n = 20; posterior precision 1/tau^2 + n/sigma^2, mean (m0/tau^2 + n ybar/sigma^2)/precision.
- BF10 = N(ybar; m0, tau^2 + sigma^2/n) / N(ybar; mu0, sigma^2/n) (prior predictive against the point null).
- The posterior is symmetric: its HDI equals the equal-tailed interval from qnorm.
- docs/manual/chapters/79-bayesian-analysis.tex:29-30: 'Normal mean, known SD & Normal prior on the mean; supply the known observation SD, prior mean and prior SD.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
250 normal_case("STAT-HYP-BAYES-NORMAL-002", "Informative Normal(1, 0.5) prior, known SD 1.2, null 0.5",
251 "axis_coverage", 1.2, 1, 0.5, 0.5, 0.95)
90% credible interval
Case STAT-HYP-BAYES-NORMAL-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: dnorm, qnorm
- Citation
- R Core Team, stats package help: Normal (dnorm, qnorm).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "d"confidence_level= 0.9known_sd= 1null_value= 0prior_mean= 0prior_sd= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 22.0040052899997 | 22.004005289999682 | 1.77E-14 | 15 | passed |
/bayes_factors/0/bf01 | tolerance | 0.045446271568316529 | 0.04544627156831657 | 4.18E-17 | 15 | passed |
/bayes_factors/0/log_bf10 | tolerance | 3.0912244954240036 | 3.0912244954240027 | 9.17E-16 | 15 | passed |
/posteriors/0/mean | tolerance | 0.66285714285714292 | 0.6628571428571429 | 2.49E-18 | 17 | passed |
/posteriors/0/sd | tolerance | 0.21821789023599236 | 0.21821789023599236 | 2.24E-18 | 16 | passed |
/posteriors/0/median | tolerance | 0.66285714285714292 | 0.6628571428571429 | 2.49E-18 | 17 | passed |
/posteriors/0/lower | tolerance | 0.30392065463677254 | 0.3039206546367725 | 5.96E-17 | 15 | passed |
/posteriors/0/upper | tolerance | 1.0217936310775131 | 1.021793631077513 | 1.30E-17 | 16 | passed |
/posteriors/0/hdi_lower | tolerance | 0.30392065463677254 | 0.30392065463655005 | 2.22E-13 | 12 | passed |
/posteriors/0/hdi_upper | tolerance | 1.0217936310775131 | 1.0217936310777358 | 2.23E-13 | 12 | passed |
Convention
- ybar = 0.69600000000000006 from n = 20; posterior precision 1/tau^2 + n/sigma^2, mean (m0/tau^2 + n ybar/sigma^2)/precision.
- BF10 = N(ybar; m0, tau^2 + sigma^2/n) / N(ybar; mu0, sigma^2/n) (prior predictive against the point null).
- The posterior is symmetric: its HDI equals the equal-tailed interval from qnorm.
- docs/manual/chapters/79-bayesian-analysis.tex:29-30: 'Normal mean, known SD & Normal prior on the mean; supply the known observation SD, prior mean and prior SD.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
252 normal_case("STAT-HYP-BAYES-NORMAL-003", "90% credible interval", "axis_coverage",
253 1, 0, 1, 0, 0.9)
Gamma(1, 1) prior, unit exposure, rate 1
Case STAT-HYP-BAYES-POISSON-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lgamma, qgamma, pgamma, dgamma, uniroot
- Citation
- R Core Team, stats package help: GammaDist (qgamma, pgamma, dgamma), Special (lgamma), uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "count"confidence_level= 0.95null_rate= 1prior= "gamma"prior_rate= 1prior_shape= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 97960.949111648704 | 97960.9491116487 | 2.75E-13 | 17 | passed |
/bayes_factors/0/bf01 | tolerance | 1.0208149360213663e-05 | 1.0208149360213663e-05 | 2.67E-22 | 16 | passed |
/bayes_factors/0/log_bf10 | tolerance | 11.492324199786509 | 11.492324199786509 | 9.80E-17 | 17 | passed |
/posteriors/0/mean | tolerance | 2.3333333333333335 | 2.333333333333333 | 4.63E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.33333333333333331 | 0.3333333333333333 | 4.83E-18 | 16 | passed |
/posteriors/0/median | tolerance | 2.3174796571298648 | 2.3174796571298644 | 4.32E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 1.72621284518234 | 1.72621284518234 | 2.78E-17 | 16 | passed |
/posteriors/0/upper | tolerance | 3.0305255324822502 | 3.0305255324822507 | 4.50E-16 | 15 | passed |
/posteriors/0/hdi_lower | tolerance | 1.6976595239219689 | 1.6976595239219379 | 3.10E-14 | 13 | passed |
/posteriors/0/hdi_upper | tolerance | 2.9960342789569472 | 2.9960342789569894 | 4.22E-14 | 13 | passed |
Convention
- X = 48 events over total exposure T = 20 (one unit per row).
- Gamma(shape 1, rate 1) prior gives the posterior Gamma(shape 49, rate 21); BF10 = b^a Gamma(a + X) / (Gamma(a) (b + T)^(a + X)) divided by lambda0^X exp(-lambda0 T).
- Equal-tailed interval: qgamma at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.
- docs/manual/chapters/79-bayesian-analysis.tex:27-28: 'Poisson rate & Gamma shape and rate, both positive, per unit of exposure. The Jeffreys option supplies a posterior only.'
- docs/manual/chapters/79-bayesian-analysis.tex:86-88: 'An improper prior's arbitrary normalization prevents a point-null Bayes factor from being defined.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
181 tail <- (1 - level) / 2
182 hdi <- hdi_closed(function(v) stats::dgamma(v, shape, rate = rate),
183 function(v) stats::pgamma(v, shape, rate = rate),
184 function(q) stats::qgamma(q, shape, rate = rate), level,
185 stats::qgamma(1e-12, shape, rate = rate))
186 outputs <- c(
187 list("/n" = count_of(length(rows), "Number of count rows.")), bf,
188 posterior_outputs("/posteriors/0", shape / rate, sqrt(shape) / rate,
189 stats::qgamma(0.5, shape, rate = rate), stats::qgamma(tail, shape, rate = rate),
190 stats::qgamma(1 - tail, shape, rate = rate), hdi,
191 sprintf("Gamma(%g, rate %g)", shape, rate)))
192 configuration <- list(column = "count", null_rate = lambda0, prior = prior, prior_shape = a,
193 prior_rate = b, confidence_level = level)
194 if (with_exposure) configuration$exposure <- "exposure"
195 emit("hypothesis", "bayesPoissonMenuItem",
196 "tabelz.analysis.bayesian.conjugate:compute_bayes_poisson", id, title, kind,
197 configuration, outputs,
198 c(sprintf("X = %d events over total exposure T = %s (%s).", X, format(Tt, digits = 17),
199 if (with_exposure) "sum of the exposure column" else "one unit per row"),
200 prior_note,
201 "Equal-tailed interval: qgamma at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.",
202 paste0(manual, ":27-28: 'Poisson rate & Gamma shape and rate, both positive, per unit of exposure. The Jeffreys option supplies a posterior only.'"),
203 paste0(manual, ":86-88: 'An improper prior's arbitrary normalization prevents a point-null Bayes factor from being defined.'")),
204 "R stats: lgamma, qgamma, pgamma, dgamma, uniroot",
205 "R Core Team, stats package help: GammaDist (qgamma, pgamma, dgamma), Special (lgamma), uniroot.",
206 "REQ-STAT-HYP-BAYES-POISSON-001")
Gamma(2, 0.5) prior with an exposure column
Case STAT-HYP-BAYES-POISSON-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lgamma, qgamma, pgamma, dgamma, uniroot
- Citation
- R Core Team, stats package help: GammaDist (qgamma, pgamma, dgamma), Special (lgamma), uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "count"confidence_level= 0.95exposure= "exposure"null_rate= 1.5prior= "gamma"prior_rate= 0.5prior_shape= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.42301616950270005 | 0.42301616950269705 | 3.00E-15 | 14 | passed |
/bayes_factors/0/bf01 | tolerance | 2.3639758290459798 | 2.3639758290459967 | 1.69E-14 | 14 | passed |
/bayes_factors/0/log_bf10 | tolerance | -0.86034487489174083 | -0.8603448748917479 | 7.10E-15 | 14 | passed |
/posteriors/0/mean | tolerance | 1.9364833462432223 | 1.9364833462432225 | 1.92E-16 | 16 | passed |
/posteriors/0/sd | tolerance | 0.27386010115667991 | 0.2738601011566799 | 3.71E-18 | 16 | passed |
/posteriors/0/median | tolerance | 1.9235888697906367 | 1.9235888697906365 | 2.20E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 1.4372952648126207 | 1.437295264812621 | 2.32E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 2.5089310066970678 | 2.5089310066970683 | 4.56E-16 | 15 | passed |
/posteriors/0/hdi_lower | tolerance | 1.4140441352568855 | 1.41404413525666 | 2.26E-13 | 12 | passed |
/posteriors/0/hdi_upper | tolerance | 2.480899148350626 | 2.4808991483509537 | 3.28E-13 | 12 | passed |
Convention
- X = 48 events over total exposure T = 25.32 (sum of the exposure column).
- Gamma(shape 2, rate 0.5) prior gives the posterior Gamma(shape 50, rate 25.82); BF10 = b^a Gamma(a + X) / (Gamma(a) (b + T)^(a + X)) divided by lambda0^X exp(-lambda0 T).
- Equal-tailed interval: qgamma at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.
- docs/manual/chapters/79-bayesian-analysis.tex:27-28: 'Poisson rate & Gamma shape and rate, both positive, per unit of exposure. The Jeffreys option supplies a posterior only.'
- docs/manual/chapters/79-bayesian-analysis.tex:86-88: 'An improper prior's arbitrary normalization prevents a point-null Bayes factor from being defined.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
210 poisson_case("STAT-HYP-BAYES-POISSON-002", "Gamma(2, 0.5) prior with an exposure column",
211 "axis_coverage", TRUE, "gamma", 2, 0.5, 1.5, 0.95)
Jeffreys prior with an exposure column (posterior only)
Case STAT-HYP-BAYES-POISSON-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lgamma, qgamma, pgamma, dgamma, uniroot
- Citation
- R Core Team, stats package help: GammaDist (qgamma, pgamma, dgamma), Special (lgamma), uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "count"confidence_level= 0.95exposure= "exposure"null_rate= 1prior= "jeffreys"prior_rate= 1prior_shape= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | absent | None | passed | |||
/bayes_factors/0/bf01 | absent | None | passed | |||
/bayes_factors/0/log_bf10 | absent | None | passed | |||
/posteriors/0/mean | tolerance | 1.915481832543444 | 1.9154818325434444 | 3.96E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.27504716187172429 | 0.2750471618717244 | 1.09E-16 | 15 | passed |
/posteriors/0/median | tolerance | 1.902333215563133 | 1.9023332155631334 | 3.95E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 1.4147218851753474 | 1.414721885175348 | 6.26E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 2.490944657189889 | 2.4909446571898894 | 4.44E-16 | 15 | passed |
/posteriors/0/hdi_lower | tolerance | 1.3910548732560113 | 1.3910548732559833 | 2.80E-14 | 13 | passed |
/posteriors/0/hdi_upper | tolerance | 2.4623273982078695 | 2.4623273982079095 | 4.00E-14 | 13 | passed |
Convention
- X = 48 events over total exposure T = 25.32 (sum of the exposure column).
- Jeffreys prior rate^(-1/2) gives the posterior Gamma(shape X + 1/2 = 48.5, rate T = 25.32); no Bayes factor.
- Equal-tailed interval: qgamma at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.
- docs/manual/chapters/79-bayesian-analysis.tex:27-28: 'Poisson rate & Gamma shape and rate, both positive, per unit of exposure. The Jeffreys option supplies a posterior only.'
- docs/manual/chapters/79-bayesian-analysis.tex:86-88: 'An improper prior's arbitrary normalization prevents a point-null Bayes factor from being defined.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
212 poisson_case("STAT-HYP-BAYES-POISSON-003", "Jeffreys prior with an exposure column (posterior only)",
213 "axis_coverage", TRUE, "jeffreys", 1, 1, 1, 0.95)
99% credible interval
Case STAT-HYP-BAYES-POISSON-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: lgamma, qgamma, pgamma, dgamma, uniroot
- Citation
- R Core Team, stats package help: GammaDist (qgamma, pgamma, dgamma), Special (lgamma), uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "count"confidence_level= 0.99null_rate= 2prior= "gamma"prior_rate= 1prior_shape= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.16885068638672501 | 0.168850686386725 | 2.96E-18 | 16 | passed |
/bayes_factors/0/bf01 | tolerance | 5.9223922709420487 | 5.922392270942049 | 2.46E-17 | 17 | passed |
/bayes_factors/0/log_bf10 | tolerance | -1.7787404670908629 | -1.7787404670908629 | 3.54E-17 | 16 | passed |
/posteriors/0/mean | tolerance | 2.3333333333333335 | 2.333333333333333 | 4.63E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.33333333333333331 | 0.3333333333333333 | 4.83E-18 | 16 | passed |
/posteriors/0/median | tolerance | 2.3174796571298648 | 2.3174796571298644 | 4.32E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 1.5641326308474701 | 1.5641326308474701 | 1.79E-17 | 16 | passed |
/posteriors/0/upper | tolerance | 3.2810274022836432 | 3.2810274022836436 | 4.46E-16 | 15 | passed |
/posteriors/0/hdi_lower | tolerance | 1.5366746996223128 | 1.5366746996214453 | 8.67E-13 | 12 | passed |
/posteriors/0/hdi_upper | tolerance | 3.2457902490435528 | 3.245790249044987 | 1.43E-12 | 12 | passed |
Convention
- X = 48 events over total exposure T = 20 (one unit per row).
- Gamma(shape 1, rate 1) prior gives the posterior Gamma(shape 49, rate 21); BF10 = b^a Gamma(a + X) / (Gamma(a) (b + T)^(a + X)) divided by lambda0^X exp(-lambda0 T).
- Equal-tailed interval: qgamma at (1 - level)/2 and 1 - (1 - level)/2; HDI by equal densities at both ends.
- docs/manual/chapters/79-bayesian-analysis.tex:27-28: 'Poisson rate & Gamma shape and rate, both positive, per unit of exposure. The Jeffreys option supplies a posterior only.'
- docs/manual/chapters/79-bayesian-analysis.tex:86-88: 'An improper prior's arbitrary normalization prevents a point-null Bayes factor from being defined.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
214 poisson_case("STAT-HYP-BAYES-POISSON-004", "99% credible interval", "axis_coverage",
215 FALSE, "gamma", 1, 1, 2, 0.99)
One-sample JZS t, default scale
Case STAT-HYP-BAYES-TTEST-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, dnorm, dchisq, dcauchy
- Citation
- Rouder, Speckman, Sun, Morey and Iverson (2009), Bayesian t tests for accepting and rejecting the null hypothesis, Psychonomic Bulletin & Review 16(2), 225-237, eq. 1; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "d"confidence_level= 0.95design= "one_sample"null_value= 0prior_scale= 0.707106781186547
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 14.747893521917074 | 14.747893521917101 | 2.70E-14 | 14 | passed |
/bayes_factors/0/bf01 | tolerance | 0.067806293726889497 | 0.06780629372688937 | 1.25E-16 | 14 | passed |
/bayes_factors/0/log_bf10 | tolerance | 2.691100260513795 | 2.691100260513797 | 1.80E-15 | 15 | passed |
/posteriors/0/mean | tolerance | 0.68999646137616255 | 0.6899964613761628 | 2.23E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.25166272892437885 | 0.2516627289243786 | 2.74E-16 | 14 | passed |
/posteriors/0/median | tolerance | 0.68700076267332788 | 0.6870007626732958 | 3.21E-14 | 13 | passed |
/posteriors/0/lower | tolerance | 0.20605166948326906 | 0.20605166948326897 | 8.68E-17 | 15 | passed |
/posteriors/0/upper | tolerance | 1.1910338981265274 | 1.1910338981265285 | 1.09E-15 | 15 | passed |
Convention
- One-sample t against 0: t = 3.4213189214583015 on 19 df, effective N = 20.
- BF10 = integral over g of (1 + N g r^2)^(-1/2) (1 + t^2/((1 + N g r^2) nu))^(-(nu+1)/2) (2 pi)^(-1/2) g^(-3/2) exp(-1/(2g)) dg divided by (1 + t^2/nu)^(-(nu+1)/2) (Rouder et al. 2009, eq. 1), r = 0.70710678118654746, by R integrate on u = log g.
- Posterior of delta proportional to the noncentral t density of t with ncp delta sqrt(N) (written as an integral over the chi-square denominator) times the Cauchy(0, r) prior; moments and quantiles by R integrate and uniroot.
- Tolerance 1e-6: both sides integrate numerically (R integrate rel.tol 1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).
- docs/manual/chapters/79-bayesian-analysis.tex:21-22: 't tests & Cauchy prior on standardized effect, default scale 1/sqrt(2); declare the null mean or paired difference and the comparison direction.'
- docs/manual/chapters/79-bayesian-analysis.tex:38-40: 'For independent-group effects, verify which group is subtracted from which.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
327 stopifnot(abs(nct_density(t, nu, t) - stats::dt(t, nu, ncp = t)) < 1e-9)
328 s <- numeric_posterior(log_post, -limit, limit, level)
329 outputs <- c(
330 list("/n" = count_of(n, "Number of analysed observations.")),
331 bf_outputs(log_bf, "JZS", kind = quad),
332 numeric_outputs("/posteriors/0", s, "posterior of delta"))
333 configuration <- list(design = design, column = column, null_value = null_value,
334 prior_scale = r, confidence_level = level)
335 if (!is.null(second)) configuration$second <- second
336 if (!is.null(group)) configuration$group <- group
337 if (!is.null(first_group)) configuration$first_group <- first_group
338 emit("hypothesis", "bayesTTestMenuItem", "tabelz.analysis.bayesian.jzs:compute_bayes_ttest",
339 id, title, kind, configuration, outputs,
340 c(definition,
341 sprintf("BF10 = integral over g of (1 + N g r^2)^(-1/2) (1 + t^2/((1 + N g r^2) nu))^(-(nu+1)/2) (2 pi)^(-1/2) g^(-3/2) exp(-1/(2g)) dg divided by (1 + t^2/nu)^(-(nu+1)/2) (Rouder et al. 2009, eq. 1), r = %s, by R integrate on u = log g.", format(r, digits = 17)),
342 "Posterior of delta proportional to the noncentral t density of t with ncp delta sqrt(N) (written as an integral over the chi-square denominator) times the Cauchy(0, r) prior; moments and quantiles by R integrate and uniroot.",
343 "Tolerance 1e-6: both sides integrate numerically (R integrate rel.tol 1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).",
344 paste0(manual, ":21-22: 't tests & Cauchy prior on standardized effect, default scale 1/sqrt(2); declare the null mean or paired difference and the comparison direction.'"),
345 paste0(manual, ":38-40: 'For independent-group effects, verify which group is subtracted from which.'")),
346 "R stats: integrate, uniroot, dnorm, dchisq, dcauchy",
347 "Rouder, Speckman, Sun, Morey and Iverson (2009), Bayesian t tests for accepting and rejecting the null hypothesis, Psychonomic Bulletin & Review 16(2), 225-237, eq. 1; R Core Team, stats package help: integrate, uniroot.",
348 "REQ-STAT-HYP-BAYES-TTEST-001")
Paired JZS t
Case STAT-HYP-BAYES-TTEST-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, dnorm, dchisq, dcauchy
- Citation
- Rouder, Speckman, Sun, Morey and Iverson (2009), Bayesian t tests for accepting and rejecting the null hypothesis, Psychonomic Bulletin & Review 16(2), 225-237, eq. 1; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "d"confidence_level= 0.95design= "paired"null_value= 0prior_scale= 0.707106781186547second= "d2"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 10.492896823673206 | 10.492896823673224 | 1.78E-14 | 14 | passed |
/bayes_factors/0/bf01 | tolerance | 0.095302566755815485 | 0.09530256675581532 | 1.67E-16 | 14 | passed |
/bayes_factors/0/log_bf10 | tolerance | 2.3506985352553453 | 2.350698535255347 | 1.81E-15 | 15 | passed |
/posteriors/0/mean | tolerance | 0.65274773102656547 | 0.6527477310265657 | 2.22E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.24789204669164391 | 0.2478920466916438 | 1.07E-16 | 15 | passed |
/posteriors/0/median | tolerance | 0.64974630199988992 | 0.64974630199989 | 1.10E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 0.17613834684625365 | 0.1761383468462535 | 1.37E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 1.1464017654312706 | 1.14640176543127 | 6.74E-16 | 15 | passed |
Convention
- Paired-difference t against 0: t = 3.2444064938081936 on 19 df, effective N = 20.
- BF10 = integral over g of (1 + N g r^2)^(-1/2) (1 + t^2/((1 + N g r^2) nu))^(-(nu+1)/2) (2 pi)^(-1/2) g^(-3/2) exp(-1/(2g)) dg divided by (1 + t^2/nu)^(-(nu+1)/2) (Rouder et al. 2009, eq. 1), r = 0.70710678118654746, by R integrate on u = log g.
- Posterior of delta proportional to the noncentral t density of t with ncp delta sqrt(N) (written as an integral over the chi-square denominator) times the Cauchy(0, r) prior; moments and quantiles by R integrate and uniroot.
- Tolerance 1e-6: both sides integrate numerically (R integrate rel.tol 1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).
- docs/manual/chapters/79-bayesian-analysis.tex:21-22: 't tests & Cauchy prior on standardized effect, default scale 1/sqrt(2); declare the null mean or paired difference and the comparison direction.'
- docs/manual/chapters/79-bayesian-analysis.tex:38-40: 'For independent-group effects, verify which group is subtracted from which.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
352 ttest_case("STAT-HYP-BAYES-TTEST-002", "Paired JZS t", "axis_coverage", "paired", "d",
353 second = "d2")
Independent-samples JZS t, code-point group order
Case STAT-HYP-BAYES-TTEST-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, dnorm, dchisq, dcauchy
- Citation
- Rouder, Speckman, Sun, Morey and Iverson (2009), Bayesian t tests for accepting and rejecting the null hypothesis, Psychonomic Bulletin & Review 16(2), 225-237, eq. 1; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "y"confidence_level= 0.95design= "independent"group= "g"null_value= 0prior_scale= 0.707106781186547
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.76043569975333536 | 0.7604356997533371 | 1.78E-15 | 14 | passed |
/bayes_factors/0/bf01 | tolerance | 1.3150355780565968 | 1.3150355780565937 | 3.14E-15 | 14 | passed |
/bayes_factors/0/log_bf10 | tolerance | -0.27386372082008026 | -0.2738637208200779 | 2.33E-15 | 14 | passed |
/posteriors/0/mean | tolerance | -0.43918011588724809 | -0.4391801158872488 | 7.22E-16 | 14 | passed |
/posteriors/0/sd | tolerance | 0.40563806758154053 | 0.40563806758154036 | 1.68E-16 | 15 | passed |
/posteriors/0/median | tolerance | -0.42091394658236875 | -0.4209139465823695 | 7.75E-16 | 14 | passed |
/posteriors/0/lower | tolerance | -1.2812368009452408 | -1.2812368009452417 | 9.27E-16 | 15 | passed |
/posteriors/0/upper | tolerance | 0.31086328498064247 | 0.3108632849806383 | 4.16E-15 | 13 | passed |
Convention
- Pooled two-sample t: groups A minus B, t = -1.3716009662677922 on 18 df, effective N = n1 n2/(n1 + n2) = 4.9500000000000002.
- BF10 = integral over g of (1 + N g r^2)^(-1/2) (1 + t^2/((1 + N g r^2) nu))^(-(nu+1)/2) (2 pi)^(-1/2) g^(-3/2) exp(-1/(2g)) dg divided by (1 + t^2/nu)^(-(nu+1)/2) (Rouder et al. 2009, eq. 1), r = 0.70710678118654746, by R integrate on u = log g.
- Posterior of delta proportional to the noncentral t density of t with ncp delta sqrt(N) (written as an integral over the chi-square denominator) times the Cauchy(0, r) prior; moments and quantiles by R integrate and uniroot.
- Tolerance 1e-6: both sides integrate numerically (R integrate rel.tol 1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).
- docs/manual/chapters/79-bayesian-analysis.tex:21-22: 't tests & Cauchy prior on standardized effect, default scale 1/sqrt(2); declare the null mean or paired difference and the comparison direction.'
- docs/manual/chapters/79-bayesian-analysis.tex:38-40: 'For independent-group effects, verify which group is subtracted from which.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
354 ttest_case("STAT-HYP-BAYES-TTEST-003", "Independent-samples JZS t, code-point group order",
355 "axis_coverage", "independent", "y", group = "g")
Independent-samples JZS t, group B first
Case STAT-HYP-BAYES-TTEST-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, dnorm, dchisq, dcauchy
- Citation
- Rouder, Speckman, Sun, Morey and Iverson (2009), Bayesian t tests for accepting and rejecting the null hypothesis, Psychonomic Bulletin & Review 16(2), 225-237, eq. 1; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "y"confidence_level= 0.95design= "independent"first_group= "B"group= "g"null_value= 0prior_scale= 0.707106781186547
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.76043569975333536 | 0.7604356997533371 | 1.78E-15 | 14 | passed |
/bayes_factors/0/bf01 | tolerance | 1.3150355780565968 | 1.3150355780565937 | 3.14E-15 | 14 | passed |
/bayes_factors/0/log_bf10 | tolerance | -0.27386372082008026 | -0.2738637208200779 | 2.33E-15 | 14 | passed |
/posteriors/0/mean | tolerance | 0.43918011588724809 | 0.4391801158872488 | 7.22E-16 | 14 | passed |
/posteriors/0/sd | tolerance | 0.40563806758154053 | 0.40563806758154036 | 1.68E-16 | 15 | passed |
/posteriors/0/median | tolerance | 0.42091394658236869 | 0.42091394658236936 | 6.68E-16 | 14 | passed |
/posteriors/0/lower | tolerance | -0.31086328498064203 | -0.3108632849806403 | 1.72E-15 | 14 | passed |
/posteriors/0/upper | tolerance | 1.2812368009452402 | 1.2812368009452415 | 1.31E-15 | 14 | passed |
Convention
- Pooled two-sample t: groups B minus A, t = 1.3716009662677922 on 18 df, effective N = n1 n2/(n1 + n2) = 4.9500000000000002.
- BF10 = integral over g of (1 + N g r^2)^(-1/2) (1 + t^2/((1 + N g r^2) nu))^(-(nu+1)/2) (2 pi)^(-1/2) g^(-3/2) exp(-1/(2g)) dg divided by (1 + t^2/nu)^(-(nu+1)/2) (Rouder et al. 2009, eq. 1), r = 0.70710678118654746, by R integrate on u = log g.
- Posterior of delta proportional to the noncentral t density of t with ncp delta sqrt(N) (written as an integral over the chi-square denominator) times the Cauchy(0, r) prior; moments and quantiles by R integrate and uniroot.
- Tolerance 1e-6: both sides integrate numerically (R integrate rel.tol 1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).
- docs/manual/chapters/79-bayesian-analysis.tex:21-22: 't tests & Cauchy prior on standardized effect, default scale 1/sqrt(2); declare the null mean or paired difference and the comparison direction.'
- docs/manual/chapters/79-bayesian-analysis.tex:38-40: 'For independent-group effects, verify which group is subtracted from which.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
356 ttest_case("STAT-HYP-BAYES-TTEST-004", "Independent-samples JZS t, group B first",
357 "axis_coverage", "independent", "y", group = "g", first_group = "B")
One-sample JZS t, scale 1, null 0.3, 90% interval
Case STAT-HYP-BAYES-TTEST-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, dnorm, dchisq, dcauchy
- Citation
- Rouder, Speckman, Sun, Morey and Iverson (2009), Bayesian t tests for accepting and rejecting the null hypothesis, Psychonomic Bulletin & Review 16(2), 225-237, eq. 1; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
column= "d"confidence_level= 0.9design= "one_sample"null_value= 0.3prior_scale= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/0/bf10 | tolerance | 0.90374006408258556 | 0.9037400640825858 | 2.21E-16 | 15 | passed |
/bayes_factors/0/bf01 | tolerance | 1.1065128566753659 | 1.1065128566753657 | 2.03E-16 | 15 | passed |
/bayes_factors/0/log_bf10 | tolerance | -0.10121349966908855 | -0.10121349966908832 | 2.25E-16 | 14 | passed |
/posteriors/0/mean | tolerance | 0.40633661459450965 | 0.40633661459450976 | 1.10E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.22696219371450063 | 0.22696219371450038 | 2.48E-16 | 14 | passed |
/posteriors/0/median | tolerance | 0.40510922397889676 | 0.4051092239788795 | 1.73E-14 | 13 | passed |
/posteriors/0/lower | tolerance | 0.035166311767063543 | 0.035166311767062954 | 5.89E-16 | 13 | passed |
/posteriors/0/upper | tolerance | 0.78171994465982686 | 0.781719944659828 | 1.11E-15 | 14 | passed |
Convention
- One-sample t against 0.3: t = 1.9466124897952408 on 19 df, effective N = 20.
- BF10 = integral over g of (1 + N g r^2)^(-1/2) (1 + t^2/((1 + N g r^2) nu))^(-(nu+1)/2) (2 pi)^(-1/2) g^(-3/2) exp(-1/(2g)) dg divided by (1 + t^2/nu)^(-(nu+1)/2) (Rouder et al. 2009, eq. 1), r = 1, by R integrate on u = log g.
- Posterior of delta proportional to the noncentral t density of t with ncp delta sqrt(N) (written as an integral over the chi-square denominator) times the Cauchy(0, r) prior; moments and quantiles by R integrate and uniroot.
- Tolerance 1e-6: both sides integrate numerically (R integrate rel.tol 1e-12; HypoNum adaptive quadrature with estimated error below 1e-6).
- docs/manual/chapters/79-bayesian-analysis.tex:21-22: 't tests & Cauchy prior on standardized effect, default scale 1/sqrt(2); declare the null mean or paired difference and the comparison direction.'
- docs/manual/chapters/79-bayesian-analysis.tex:38-40: 'For independent-group effects, verify which group is subtracted from which.'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
358 ttest_case("STAT-HYP-BAYES-TTEST-005", "One-sample JZS t, scale 1, null 0.3, 90% interval",
359 "axis_coverage", "one_sample", "d", null_value = 0.3, r = 1, level = 0.9)
Bootstrap estimate mean
Case STAT-HYP-BOOTSTRAP-ESTIMATE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95intervals= "percentile"resamples= 200scheme= "rows"seed= 20260928statistic= "mean"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Mean: one row of v is missing, so 19 rows are used.
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
44 emit <- function(id, title, kind, config, outputs, notes, extra_deferred = list()) {
45 write_expected("hypothesis", id, list(
46 schema_version = "2.0.0", case_id = id, outputs = outputs, expected_error = NULL,
47 deferred_outputs = c(deferred(), extra_deferred), generator_run = run))
48 write_case("hypothesis", id, list(
49 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "hypothesis",
50 entry_point = entry, menu_items = list(menu), title = title, case_kind = kind,
51 dataset = list(path = "reference_data/datasets/HYP_BOOT.json", sha256 = ""),
52 excluded_rows = list(), configuration = c(config, list(resamples = resamples, seed = 20260928L,
53 confidence_level = 0.95, intervals = "percentile", scheme = "rows")),
54 "repeat" = 1L,
55 expected = list(path = paste0("reference_data/expected/hypothesis/", id, ".json"), sha256 = ""),
56 oracle = list(oracle_class = "independent_implementation", source = "R 4.6.1 base and stats",
57 citation = "R Core Team, base and stats package help: mean, median, sd, quantile, cor.",
58 generator = list(path = "generators/r/hypothesis_bootstrap_estimate.R", sha256 = ""),
59 independent = TRUE,
60 convention_notes = c(notes, notes_common, "Expected computed from the exported CSV.")),
61 supported = TRUE, unsupported_reason = NULL,
62 requirement_ids = list("REQ-STAT-HYP-BOOTSTRAP-ESTIMATE-001"),
63 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
Bootstrap estimate median
Case STAT-HYP-BOOTSTRAP-ESTIMATE-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95intervals= "percentile"resamples= 200scheme= "rows"seed= 20260928statistic= "median"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | 12.4 | 12.4 | 3.55E-16 | 16 | passed |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Median of an odd count of values is the middle order statistic.
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
87 emit("STAT-HYP-BOOTSTRAP-ESTIMATE-002", "Bootstrap estimate median", "axis_coverage",
88 list(statistic = "median", column = "v"),
89 counts(length(v), stats::median(v), "median of the 19 finite values"),
90 "Median of an odd count of values is the middle order statistic.")
Bootstrap estimate standard deviation
Case STAT-HYP-BOOTSTRAP-ESTIMATE-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95intervals= "percentile"resamples= 200scheme= "rows"seed= 20260928statistic= "sd"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | 2.1758778560490115 | 2.1758778560490115 | 1.61E-17 | 17 | passed |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Standard deviation with the n - 1 divisor.
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
92 emit("STAT-HYP-BOOTSTRAP-ESTIMATE-003", "Bootstrap estimate standard deviation", "axis_coverage",
93 list(statistic = "sd", column = "v"),
94 counts(length(v), stats::sd(v), "sample SD (n - 1) of the 19 finite values"),
95 "Standard deviation with the n - 1 divisor.")
Bootstrap estimate 10 percent trimmed mean
Case STAT-HYP-BOOTSTRAP-ESTIMATE-004 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95intervals= "percentile"resamples= 200scheme= "rows"seed= 20260928statistic= "trimmed_mean"trim= 0.1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | 12.494117647058824 | 12.494117647058825 | 1.33E-15 | 15 | passed |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Trimmed mean: R's mean(trim = 0.1) and SciPy's trim_mean both drop floor(0.1 n) = 1 value from each end of the 19 sorted values.
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
97 emit("STAT-HYP-BOOTSTRAP-ESTIMATE-004", "Bootstrap estimate 10 percent trimmed mean", "axis_coverage",
98 list(statistic = "trimmed_mean", column = "v", trim = 0.1),
99 counts(length(v), mean(v, trim = 0.1), "mean(trim = 0.1): floor(0.1 n) values cut from each end"),
100 "Trimmed mean: R's mean(trim = 0.1) and SciPy's trim_mean both drop floor(0.1 n) = 1 value from each end of the 19 sorted values.")
Bootstrap estimate first quartile
Case STAT-HYP-BOOTSTRAP-ESTIMATE-005 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95intervals= "percentile"probability= 0.25resamples= 200scheme= "rows"seed= 20260928statistic= "quantile"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | 11.050000000000001 | 11.050000000000002 | 1.49E-15 | 15 | passed |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Quantile with R's type 7 linear interpolation (NumPy's default 'linear' method).
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
102 emit("STAT-HYP-BOOTSTRAP-ESTIMATE-005", "Bootstrap estimate first quartile", "axis_coverage",
103 list(statistic = "quantile", column = "v", probability = 0.25),
104 counts(length(v), stats::quantile(v, 0.25, type = 7, names = FALSE), "quantile(0.25, type = 7)"),
105 "Quantile with R's type 7 linear interpolation (NumPy's default 'linear' method).")
Bootstrap estimate Pearson correlation
Case STAT-HYP-BOOTSTRAP-ESTIMATE-006 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95intervals= "percentile"resamples= 200scheme= "rows"second= "w"seed= 20260928statistic= "pearson"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | 0.9933856368684717 | 0.9933856368684718 | 1.11E-16 | 15 | passed |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Pearson correlation of v and w on the 19 rows complete on both.
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
107 complete <- is.finite(d$v) & is.finite(d$w)
108 emit("STAT-HYP-BOOTSTRAP-ESTIMATE-006", "Bootstrap estimate Pearson correlation", "axis_coverage",
109 list(statistic = "pearson", column = "v", second = "w"),
110 counts(sum(complete), stats::cor(d$v[complete], d$w[complete]), "Pearson r on the complete pairs"),
111 "Pearson correlation of v and w on the 19 rows complete on both.")
Bootstrap estimate mean difference B minus A
Case STAT-HYP-BOOTSTRAP-ESTIMATE-007 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95first_group= "B"group= "g"intervals= "percentile"resamples= 200scheme= "rows"seed= 20260928statistic= "mean_difference"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | -0.86555555555555586 | -0.8655555555555559 | 4.44E-18 | 17 | passed |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed | |
/components/0/name | exact | Mean of v: B minus A | Mean of v: B minus A | passed |
Convention
- Difference of two group means with the declared first group B: mean(B) - mean(A) on the finite rows.
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
113 a <- d$v[is.finite(d$v) & d$g == "A"]
114 b <- d$v[is.finite(d$v) & d$g == "B"]
115 emit("STAT-HYP-BOOTSTRAP-ESTIMATE-007", "Bootstrap estimate mean difference B minus A", "axis_coverage",
116 list(statistic = "mean_difference", column = "v", group = "g", first_group = "B"),
117 counts(length(a) + length(b), mean(b) - mean(a), "mean of group B minus mean of group A", "Mean of v: B minus A"),
118 "Difference of two group means with the declared first group B: mean(B) - mean(A) on the finite rows.")
Bootstrap estimate mean minus target
Case STAT-HYP-BOOTSTRAP-ESTIMATE-008 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95intervals= "percentile"resamples= 200scheme= "rows"seed= 20260928statistic= "mean_minus_target"target= 12
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Mean minus target: the target 12 is fixed in every replicate.
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
120 emit("STAT-HYP-BOOTSTRAP-ESTIMATE-008", "Bootstrap estimate mean minus target", "axis_coverage",
121 list(statistic = "mean_minus_target", column = "v", target = 12),
122 counts(length(v), mean(v) - 12, "mean of v minus the fixed target 12"),
123 "Mean minus target: the target 12 is fixed in every replicate.")
Bootstrap estimate mean of paired differences
Case STAT-HYP-BOOTSTRAP-ESTIMATE-009 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 base and stats
- Citation
- R Core Team, base and stats package help: mean, median, sd, quantile, cor.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bootstrap_estimate.R · sha256 8eb6eded9e3eb420
- Dataset
- reference_data/datasets/HYP_BOOT.json
Settings compared
column= "v"confidence_level= 0.95intervals= "percentile"resamples= 200scheme= "rows"second= "w"seed= 20260928statistic= "paired_mean_difference"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_used | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/units | exact | 19 | 19 | 0.00E+2 | passed | |
/components/0/estimate | tolerance | -8.594736842105263 | -8.594736842105263 | 8.31E-18 | 18 | passed |
/components/0/attempted | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/successful | exact | 200 | 200 | 0.00E+2 | passed | |
/components/0/failed | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Mean of paired differences v - w; each complete row is one pair.
- Rows with a missing or non-finite value in any required column are dropped and counted; the estimate is the statistic on the remaining rows; attempted = resamples and successful = resamples when every replicate is defined.
- docs/manual/chapters/77-bootstrap-estimates.tex:11-17: 'Available statistics include means, medians, trimmed means, standard deviations, quantiles, correlations ... two-group mean differences, means minus a fixed target, means or medians of paired differences'
- docs/manual/chapters/77-bootstrap-estimates.tex:27-31: 'The defaults are 5,000 replicates, seed 20260928, row resampling and a 95% percentile interval'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
125 emit("STAT-HYP-BOOTSTRAP-ESTIMATE-009", "Bootstrap estimate mean of paired differences", "axis_coverage",
126 list(statistic = "paired_mean_difference", column = "v", second = "w"),
127 counts(sum(complete), mean(d$v[complete] - d$w[complete]), "mean of v minus w over the complete pairs"),
128 "Mean of paired differences v - w; each complete row is one pair.")
Boundary: STAT-HYP-BOUNDARY-BASIC-MIN-001
Case STAT-HYP-BOUNDARY-BASIC-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
alpha= 0.1known_sigma= 1max_rows= 100method= "known_sigma_z"null_mean= 0response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.045500263896358424 | 0.04550026389635839 | 3.46E-17 | 15 | passed |
Convention
- One finite response is sufficient when population sigma is supplied.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
143 z_min <- (tiny$x[[2]] - 0) / 1
144 emit("STAT-HYP-BOUNDARY-BASIC-MIN-001", "tabelz.executor.additional_basic_tests",
145 "additionalBasicTestsMenuItem", "HYP_TINY",
146 list(method = "known_sigma_z", response_column = "x", known_sigma = 1,
147 null_mean = 0, alpha = 0.1, max_rows = 100L),
148 list("/statistic" = tol(z_min, "one-observation known-sigma z"),
149 "/p_value" = prob(2 * stats::pnorm(-abs(z_min)), "normal tail")),
150 notes = list("One finite response is sufficient when population sigma is supplied."),
151 excluded = list(0L))
Boundary: STAT-HYP-BOUNDARY-BASIC-ZEROEVENT-001
Case STAT-HYP-BOUNDARY-BASIC-ZEROEVENT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_ZERO_RATE.json
Settings compared
count_column= "count"exposure_column= "exposure"method= "one_poisson_rate"null_rate= 0.1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0 | 0.0 | 0.00E+2 | 15 | passed |
/p_value | tail_probability | 0.044741543712331182 | 0.044741543712331175 | 7.11E-18 | 15 | passed |
/upper | tolerance | 0.097075775108261458 | 0.09707577510826146 | 3.90E-19 | 17 | passed |
Convention
- Zero observed events; manual chapter 31 specifies doubled minimum-tail p-value.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
152 count <- sum(z$count)
153 exposure <- sum(z$exposure)
154 rate_test <- stats::poisson.test(count, T = exposure, r = 0.1)
155 expected_count <- 0.1 * exposure
156 p_zero <- min(1, 2 * min(stats::ppois(count, expected_count),
157 stats::ppois(count - 1, expected_count, lower.tail = FALSE)))
158 emit("STAT-HYP-BOUNDARY-BASIC-ZEROEVENT-001", "tabelz.executor.additional_basic_tests",
159 "additionalBasicTestsMenuItem", "HYP_ZERO_RATE",
160 list(method = "one_poisson_rate", count_column = "count", exposure_column = "exposure",
161 null_rate = 0.1),
162 list("/estimate" = tol(0, "zero event rate"),
163 "/p_value" = prob(p_zero, "doubled minimum Poisson tail"),
164 "/upper" = tol(rate_test$conf.int[[2]], "positive exact upper rate bound")),
165 notes = list("Zero observed events; manual chapter 31 specifies doubled minimum-tail p-value."))
Boundary: STAT-HYP-BOUNDARY-EQUIV-MIN-001
Case STAT-HYP-BOUNDARY-EQUIV-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_EDGE.json
Settings compared
alpha= 0.1group_a= "A"group_b= "B"group_column= "g"lower_bound= -3max_rows= 100response_column= "x"upper_bound= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/difference_a_minus_b | tolerance | -0.25 | -0.25 | 0.00E+0 | passed | |
/p_lower | tail_probability | 0.03341271022140762 | 0.03341271022140761 | 7.29E-18 | 15 | passed |
Convention
- Two finite observations per selected group; Welch-Satterthwaite df.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
103 a <- e$x[e$g == "A"]
104 b <- e$x[e$g == "B"]
105 delta <- mean(a) - mean(b)
106 va <- var(a) / length(a)
107 vb <- var(b) / length(b)
108 se <- sqrt(va + vb)
109 df <- (va + vb)^2 / (va^2 / (length(a) - 1) + vb^2 / (length(b) - 1))
110 emit("STAT-HYP-BOUNDARY-EQUIV-MIN-001", "tabelz.executor.equivalence", "equivalenceMenuItem",
111 "HYP_EDGE",
112 list(response_column = "x", group_column = "g", group_a = "A", group_b = "B",
113 lower_bound = -3, upper_bound = 3, alpha = 0.1, max_rows = 100L),
114 list("/difference_a_minus_b" = tol(delta, "n=2/group A-B mean"),
115 "/p_lower" = prob(stats::pt((delta + 3) / se, df, lower.tail = FALSE), "Welch lower TOST")),
116 notes = list("Two finite observations per selected group; Welch-Satterthwaite df."))
Boundary: STAT-HYP-BOUNDARY-EQUIV-ZEROSE-001
Case STAT-HYP-BOUNDARY-EQUIV-ZEROSE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_CONSTANT.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"lower_bound= -1response_column= "x"upper_bound= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Both groups are constant at the same value; Welch standard error is zero.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
117 emit("STAT-HYP-BOUNDARY-EQUIV-ZEROSE-001", "tabelz.executor.equivalence", "equivalenceMenuItem",
118 "HYP_CONSTANT",
119 list(response_column = "x", group_column = "g", group_a = "A", group_b = "B",
120 lower_bound = -1, upper_bound = 1),
121 error = list(error_class = "EquivalenceExecutionError", message_contains = "zero standard error"),
122 notes = list("Both groups are constant at the same value; Welch standard error is zero."))
Boundary: STAT-HYP-BOUNDARY-EQUIVEXT-MIN-001
Case STAT-HYP-BOUNDARY-EQUIVEXT-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
alpha= 0.1lower_bound= -3max_rows= 100mode= "one_sample_difference"response_column= "x"target= 1.5upper_bound= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0 | 0.0 | 0.00E+2 | 15 | passed |
/p_lower | tail_probability | 0.052568456711253424 | 0.05256845671125344 | 1.36E-17 | 15 | passed |
Convention
- Two finite nonconstant responses are the one-sample TOST minimum.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
125 mini_effect <- mean(tiny$x - 1.5)
126 mini_se <- sd(tiny$x - 1.5) / sqrt(nrow(tiny))
127 emit("STAT-HYP-BOUNDARY-EQUIVEXT-MIN-001", "tabelz.executor.equivalence_extensions",
128 "equivalenceMenuItem", "HYP_TINY",
129 list(mode = "one_sample_difference", response_column = "x", target = 1.5,
130 lower_bound = -3, upper_bound = 3, alpha = 0.1, max_rows = 100L),
131 list("/estimate" = tol(mini_effect, "n=2 mean-target effect"),
132 "/p_lower" = prob(stats::pt((mini_effect + 3) / mini_se, 1,
133 lower.tail = FALSE), "n=2 lower TOST")),
134 notes = list("Two finite nonconstant responses are the one-sample TOST minimum."))
Boundary: STAT-HYP-BOUNDARY-EQUIVEXT-ZEROSE-001
Case STAT-HYP-BOUNDARY-EQUIVEXT-ZEROSE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_CONSTANT.json
Settings compared
lower_bound= -1mode= "one_sample_difference"response_column= "x"target= 1upper_bound= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Four identical responses make the one-sample standard error zero.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
135 emit("STAT-HYP-BOUNDARY-EQUIVEXT-ZEROSE-001", "tabelz.executor.equivalence_extensions",
136 "equivalenceMenuItem", "HYP_CONSTANT",
137 list(mode = "one_sample_difference", response_column = "x", target = 1,
138 lower_bound = -1, upper_bound = 1),
139 error = list(error_class = "EquivalenceExtensionsExecutionError", message_contains = "zero standard error"),
140 notes = list("Four identical responses make the one-sample standard error zero."))
Boundary: STAT-HYP-BOUNDARY-PERM-LIMIT-001
Case STAT-HYP-BOUNDARY-PERM-LIMIT-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_PERM_LIMIT.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"inference= "exact"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- choose(22,11) exact assignments exceed the documented 20,000 budget.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
180 emit("STAT-HYP-BOUNDARY-PERM-LIMIT-001", "tabelz.executor.permutation_tests",
181 "permutationTestsMenuItem", "HYP_PERM_LIMIT",
182 list(mode = "independent", response_column = "x", group_column = "g",
183 group_a = "A", group_b = "B", inference = "exact"),
184 error = list(error_class = "PermutationTestsExecutionError", message_contains = "above the bounded budget"),
185 notes = list("choose(22,11) exact assignments exceed the documented 20,000 budget."))
Boundary: STAT-HYP-BOUNDARY-PERM-MIN-001
Case STAT-HYP-BOUNDARY-PERM-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_EDGE.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"inference= "exact"max_cells= 1000max_rows= 100mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -0.25 | -0.2499999999999999 | 1.11E-16 | 15 | passed |
/p_value | tail_probability | 0.66666666666666663 | 0.6666666666666666 | 3.41E-19 | 18 | passed |
Convention
- Two complete responses per group; exactly choose(4,2)=6 label assignments.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
168 idx <- utils::combn(seq_len(nrow(e)), 2)
169 sa <- colSums(matrix(e$x[idx], nrow = 2))
170 null <- sa / 2 - (sum(e$x) - sa) / 2
171 p_perm <- mean(abs(null) >= abs(delta) - 1e-12)
172 emit("STAT-HYP-BOUNDARY-PERM-MIN-001", "tabelz.executor.permutation_tests",
173 "permutationTestsMenuItem", "HYP_EDGE",
174 list(mode = "independent", response_column = "x", group_column = "g",
175 group_a = "A", group_b = "B", inference = "exact", max_rows = 100L,
176 max_cells = 1000L),
177 list("/statistic" = tol(delta, "n=2/group A-B mean"),
178 "/p_value" = prob(p_perm, "all six assignments")),
179 notes = list("Two complete responses per group; exactly choose(4,2)=6 label assignments."))
Boundary: STAT-HYP-BOUNDARY-POWER-MIN-001
Case STAT-HYP-BOUNDARY-POWER-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- None
Settings compared
alpha= 0.1analysis= "one_sample_t"effect_size= 0.5sample_size= 2solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.12356674265882894 | 0.12356674265872954 | 9.94E-14 | 12 | passed |
Convention
- Sample size two is the smallest accepted planned t sample.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
85 p_min <- stats::power.t.test(n = 2, delta = 0.5, sd = 1, sig.level = 0.1,
86 type = "one.sample", alternative = "two.sided", strict = TRUE)
87 emit("STAT-HYP-BOUNDARY-POWER-MIN-001", "tabelz.analysis.hypothesis_tests:run_power_analysis",
88 "hypothesisTestsMenuItem", NULL,
89 list(analysis = "one_sample_t", solve_for = "power", sample_size = 2L,
90 effect_size = 0.5, alpha = 0.1),
91 list("/value" = tol(p_min$power, "n=2 noncentral t power")),
92 notes = list("Sample size two is the smallest accepted planned t sample."))
Boundary: STAT-HYP-BOUNDARY-POWER-NEARNULL-001
Case STAT-HYP-BOUNDARY-POWER-NEARNULL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- None
Settings compared
analysis= "one_sample_t"effect_size= 1e-08sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.050000000000000377 | 0.050000000000000315 | 6.20E-17 | 14 | passed |
Convention
- Effect size is positive but near zero, testing the no-effect boundary.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
93 p_near <- stats::power.t.test(n = 30, delta = 1e-8, sd = 1, sig.level = 0.05,
94 type = "one.sample", alternative = "two.sided", strict = TRUE)
95 emit("STAT-HYP-BOUNDARY-POWER-NEARNULL-001", "tabelz.analysis.hypothesis_tests:run_power_analysis",
96 "hypothesisTestsMenuItem", NULL,
97 list(analysis = "one_sample_t", solve_for = "power", sample_size = 30L,
98 effect_size = 1e-8),
99 list("/value" = tol(p_near$power, "tiny-positive-effect noncentral t power")),
100 notes = list("Effect size is positive but near zero, testing the no-effect boundary."))
Boundary: STAT-HYP-BOUNDARY-RANK-MIN-001
Case STAT-HYP-BOUNDARY-RANK-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_EDGE_BLOCKS.json
Settings compared
block_column= "block"max_blocks= 10max_rows= 100method= "friedman"response_column= "x"treatment_column= "treatment"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/friedman_statistic | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.1353352832366127 | 0.1353352832366127 | 2.32E-18 | 16 | passed |
Convention
- Two complete blocks with three treatments each are the minimum design.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
188 friedman <- stats::friedman.test(x ~ treatment | block, data = bl)
189 emit("STAT-HYP-BOUNDARY-RANK-MIN-001", "tabelz.executor.blocked_rank_tests",
190 "blockedRankTestsMenuItem", "HYP_EDGE_BLOCKS",
191 list(method = "friedman", response_column = "x", treatment_column = "treatment",
192 block_column = "block", max_rows = 100L, max_blocks = 10L),
193 list("/friedman_statistic" = tol(friedman$statistic, "two-block Friedman chi-square"),
194 "/p_value" = prob(friedman$p.value, "Friedman chi-square tail")),
195 notes = list("Two complete blocks with three treatments each are the minimum design."))
Boundary: STAT-HYP-BOUNDARY-RANK-TIES-001
Case STAT-HYP-BOUNDARY-RANK-TIES-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_CONSTANT.json
Settings compared
method= "runs"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- All numeric values equal the median and are omitted; no runs sequence remains.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
196 emit("STAT-HYP-BOUNDARY-RANK-TIES-001", "tabelz.executor.blocked_rank_tests",
197 "blockedRankTestsMenuItem", "HYP_CONSTANT",
198 list(method = "runs", response_column = "x"),
199 error = list(error_class = "BlockedRankTestsExecutionError", message_contains = "at least one observation in each category"),
200 notes = list("All numeric values equal the median and are omitted; no runs sequence remains."))
Boundary: STAT-HYP-BOUNDARY-TEST-CONSTANT-001
Case STAT-HYP-BOUNDARY-TEST-CONSTANT-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_CONSTANT.json
Settings compared
response= "x"target= 0test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Zero sample variance makes a finite t statistic undefined.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
78 emit("STAT-HYP-BOUNDARY-TEST-CONSTANT-001", "tabelz.analysis.hypothesis_tests:run_hypothesis_test",
79 "hypothesisTestsMenuItem", "HYP_CONSTANT",
80 list(test = "one_sample_t", response = "x", target = 0),
81 error = list(error_class = "ValueError", message_contains = "no sample variation"),
82 notes = list("Zero sample variance makes a finite t statistic undefined."))
Boundary: STAT-HYP-BOUNDARY-TEST-MIN-001
Case STAT-HYP-BOUNDARY-TEST-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and manual-defined design boundaries
- Citation
- R stats help: t.test, poisson.test, friedman.test, ptukey, power.t.test; Tabelz manual chapters 07, 16, 31-34, 62.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_boundaries.R · sha256 39e5c59beef75737
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
alpha= 0.1response= "x"target= 0test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.20483276469913345 | 0.20483276469913345 | 3.92E-18 | 16 | passed |
Convention
- Two nonconstant finite observations are the minimum for a Student t statistic.
- R numerical values use the exported CSV; invalid designs have no estimator.
Reference code
The lines of the reference script that produce this case's expected values.
71 t_min <- stats::t.test(tiny$x, mu = 0)
72 emit("STAT-HYP-BOUNDARY-TEST-MIN-001", "tabelz.analysis.hypothesis_tests:run_hypothesis_test",
73 "hypothesisTestsMenuItem", "HYP_TINY",
74 list(test = "one_sample_t", response = "x", target = 0, alpha = 0.1),
75 list("/statistic" = tol(t_min$statistic, "n=2 Student t"),
76 "/p_value" = prob(t_min$p.value, "n=2 Student t tail")),
77 notes = list("Two nonconstant finite observations are the minimum for a Student t statistic."))
Two-way categorical association
Case STAT-HYP-CHI-ASSOC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"second_group= "h"test= "chi_square_association"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed |
Convention
- Yates continuity correction disabled, as the manual's Pearson test specifies.
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
62 association <- stats::chisq.test(table(d$g, d$h), correct = FALSE)
63 emit("STAT-HYP-CHI-ASSOC-001", "Two-way categorical association",
64 list(test = "chi_square_association", group = "g", second_group = "h"),
65 list("/statistic" = tol(association$statistic, "Pearson association chi-square"),
66 "/p_value" = prob(association$p.value, "association chi-square tail")),
67 list("Yates continuity correction disabled, as the manual's Pearson test specifies."))
Two-category chi-square goodness of fit
Case STAT-HYP-CHI-GOF-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
response= "outcome"test= "chi_square_gof"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed |
Convention
- Blank expected proportions means equal category probabilities.
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
54 observed <- as.integer(table(d$outcome))
55 gof <- stats::chisq.test(observed, p = rep(0.5, 2))
56 emit("STAT-HYP-CHI-GOF-001", "Two-category chi-square goodness of fit",
57 list(test = "chi_square_gof", response = "outcome"),
58 list("/statistic" = tol(gof$statistic, "Pearson GOF chi-square"),
59 "/p_value" = prob(gof$p.value, "GOF chi-square tail")),
60 list("Blank expected proportions means equal category probabilities."))
One-sample difference TOST
Case STAT-HYP-EQUIV-ONE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 independent implementation
- Citation
- R stats::t.test documentation; analytic one-sample TOST.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_secondary.R · sha256 13b3dbafe11fd4e1
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
lower_bound= -2mode= "one_sample_difference"response_column= "x"target= 6upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.81250000000000011 | 0.8125000000000002 | 1.12E-16 | 15 | passed |
/standard_error | tolerance | 0.48147992343052753 | 0.48147992343052765 | 1.15E-16 | 15 | passed |
/p_lower | tail_probability | 1.6227244268166216e-05 | 1.6227244268166257e-05 | 4.08E-20 | 14 | passed |
/p_upper | tail_probability | 0.013092877229204013 | 0.013092877229204046 | 3.27E-17 | 14 | passed |
Convention
- Student one-sample TOST on x-target.
- Expected values calculated after re-reading the exported CSV where data are present.
Reference code
The lines of the reference script that produce this case's expected values.
86 target <- 6
87 delta <- d$x - target
88 effect <- mean(delta)
89 se1 <- sd(delta) / sqrt(length(delta))
90 df1 <- length(delta) - 1
91 lo1 <- -2
92 hi1 <- 2
93 emit("STAT-HYP-EQUIV-ONE-001", "tabelz.executor.equivalence_extensions", "equivalenceMenuItem",
94 "One-sample difference TOST", "nominal", "HYP_CORE",
95 list(mode = "one_sample_difference", response_column = "x", target = target,
96 lower_bound = lo1, upper_bound = hi1),
97 list("/estimate" = tol(effect, "mean(x-target)"),
98 "/standard_error" = tol(se1, "one-sample SE"),
99 "/p_lower" = prob(stats::pt((effect - lo1) / se1, df1, lower.tail = FALSE), "lower TOST"),
100 "/p_upper" = prob(stats::pt((effect - hi1) / se1, df1), "upper TOST")),
101 list("Student one-sample TOST on x-target."),
102 "R stats::t.test documentation; analytic one-sample TOST.")
Welch two-group TOST
Case STAT-HYP-EQUIV-WELCH-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 independent implementation
- Citation
- R stats::t.test documentation (Welch variance and Student t quantiles); analytic TOST from the two one-sided tests.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_secondary.R · sha256 13b3dbafe11fd4e1
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"lower_bound= -3response_column= "x"upper_bound= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/difference_a_minus_b | tolerance | -1.5749999999999993 | -1.5750000000000002 | 8.78E-16 | 15 | passed |
/standard_error | tolerance | 0.90351496153317001 | 0.9035149615331702 | 2.26E-16 | 15 | passed |
/degrees_of_freedom | tolerance | 13.99945589410847 | 13.999455894108472 | 1.91E-15 | 15 | passed |
/p_lower | tail_probability | 0.068539258692386876 | 0.06853925869238707 | 1.94E-16 | 14 | passed |
/p_upper | tail_probability | 8.6476893043807419e-05 | 8.647689304380732e-05 | 9.51E-20 | 14 | passed |
/interval_lower | tolerance | -3.1663744299504435 | -3.166374429950445 | 1.32E-15 | 15 | passed |
/interval_upper | tolerance | 0.016374429950444913 | 0.01637442995044447 | 4.44E-16 | 13 | passed |
Convention
- Two one-sided Welch t tails; strict equivalence requires both p-values below alpha.
- Expected values calculated after re-reading the exported CSV where data are present.
Reference code
The lines of the reference script that produce this case's expected values.
59 a <- d$x[d$g == "A"]
60 bb <- d$x[d$g == "B"]
61 diff <- mean(a) - mean(bb)
62 term_a <- var(a) / length(a)
63 term_b <- var(bb) / length(bb)
64 se <- sqrt(term_a + term_b)
65 df <- (term_a + term_b)^2 / (term_a^2 / (length(a) - 1) + term_b^2 / (length(bb) - 1))
66 lower <- -3
67 upper <- 3
68 p_lower <- stats::pt((diff - lower) / se, df, lower.tail = FALSE)
69 p_upper <- stats::pt((diff - upper) / se, df)
70 crit <- stats::qt(0.95, df)
71 emit("STAT-HYP-EQUIV-WELCH-001", "tabelz.executor.equivalence", "equivalenceMenuItem",
72 "Welch two-group TOST", "nominal", "HYP_CORE",
73 list(response_column = "x", group_column = "g", group_a = "A", group_b = "B",
74 lower_bound = lower, upper_bound = upper),
75 list("/difference_a_minus_b" = tol(diff, "A minus B"),
76 "/standard_error" = tol(se, "Welch standard error"),
77 "/degrees_of_freedom" = tol(df, "Welch-Satterthwaite df"),
78 "/p_lower" = prob(p_lower, "lower TOST"),
79 "/p_upper" = prob(p_upper, "upper TOST"),
80 "/interval_lower" = tol(diff - crit * se, "90% interval lower"),
81 "/interval_upper" = tol(diff + crit * se, "90% interval upper")),
82 list("Two one-sided Welch t tails; strict equivalence requires both p-values below alpha."),
83 "R stats::t.test documentation (Welch variance and Student t quantiles); analytic TOST from the two one-sided tests.")
Complete-block Friedman
Case STAT-HYP-FRIEDMAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 independent implementation
- Citation
- R stats::friedman.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_secondary.R · sha256 13b3dbafe11fd4e1
- Dataset
- reference_data/datasets/HYP_BLOCKS.json
Settings compared
block_column= "block"method= "friedman"response_column= "x"treatment_column= "treatment"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/friedman_statistic | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.018315638888734179 | 0.018315638888734182 | 3.14E-18 | 15 | passed |
/block_count | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- No within-block ties; R friedman.test chi-square approximation.
- Expected values calculated after re-reading the exported CSV where data are present.
Reference code
The lines of the reference script that produce this case's expected values.
137 friedman <- stats::friedman.test(x ~ treatment | block, data = b)
138 emit("STAT-HYP-FRIEDMAN-001", "tabelz.executor.blocked_rank_tests", "blockedRankTestsMenuItem",
139 "Complete-block Friedman", "nominal", "HYP_BLOCKS",
140 list(method = "friedman", response_column = "x", treatment_column = "treatment",
141 block_column = "block"),
142 list("/friedman_statistic" = tol(friedman$statistic, "Friedman chi-square"),
143 "/p_value" = prob(friedman$p.value, "Friedman chi-square tail"),
144 "/block_count" = exact(length(unique(b$block)), "Four complete blocks.")),
145 list("No within-block ties; R friedman.test chi-square approximation."),
146 "R stats::friedman.test documentation.")
Large-offset numerical case: STAT-HYP-HARD-BASIC-001
Case STAT-HYP-HARD-BASIC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, power.t.test; analytic TOST and runs formulae.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_hard.R · sha256 892a9672937f8cfa
- Dataset
- reference_data/datasets/HYP_HARD.json
Settings compared
known_sigma= 2method= "known_sigma_z"null_mean= 1000000006response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.625 | 1.625 | 0.00E-1 | passed | |
/p_value | tail_probability | 0.10416255883043912 | 0.10416255883043905 | 6.68E-17 | 15 | passed |
Convention
- Known sigma 2 and large mean offset.
- All data-based expected values use the exported large-offset CSV.
Reference code
The lines of the reference script that produce this case's expected values.
76 z <- (mean(d$x) - center) / (2 / sqrt(nrow(d)))
77 emit("STAT-HYP-HARD-BASIC-001", "tabelz.executor.additional_basic_tests",
78 "additionalBasicTestsMenuItem",
79 list(method = "known_sigma_z", response_column = "x", known_sigma = 2, null_mean = center),
80 list("/statistic" = tol(z, "known-sigma z"),
81 "/p_value" = prob(2 * stats::pnorm(-abs(z)), "normal tail")),
82 list("Known sigma 2 and large mean offset."))
Large-offset numerical case: STAT-HYP-HARD-EQUIV-001
Case STAT-HYP-HARD-EQUIV-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, power.t.test; analytic TOST and runs formulae.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_hard.R · sha256 892a9672937f8cfa
- Dataset
- reference_data/datasets/HYP_HARD.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"lower_bound= -3response_column= "x"upper_bound= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/difference_a_minus_b | tolerance | -1.5750000476837158 | -1.5750000476837158 | 2.03E-17 | 16 | passed |
/standard_error | tolerance | 0.90351495430005979 | 0.9035149543000598 | 1.59E-18 | 17 | passed |
/p_lower | tail_probability | 0.068539263305043049 | 0.0685392633050431 | 5.59E-17 | 15 | passed |
Convention
- Welch TOST on differences of means near one billion.
- All data-based expected values use the exported large-offset CSV.
Reference code
The lines of the reference script that produce this case's expected values.
51 a <- d$x[d$g == "A"]
52 b <- d$x[d$g == "B"]
53 delta <- mean(a) - mean(b)
54 va <- var(a) / length(a)
55 vb <- var(b) / length(b)
56 se <- sqrt(va + vb)
57 df <- (va + vb)^2 / (va^2 / (length(a) - 1) + vb^2 / (length(b) - 1))
58 emit("STAT-HYP-HARD-EQUIV-001", "tabelz.executor.equivalence", "equivalenceMenuItem",
59 list(response_column = "x", group_column = "g", group_a = "A", group_b = "B",
60 lower_bound = -3, upper_bound = 3),
61 list("/difference_a_minus_b" = tol(delta, "small A-B difference"),
62 "/standard_error" = tol(se, "Welch SE"),
63 "/p_lower" = prob(stats::pt((delta + 3) / se, df, lower.tail = FALSE), "lower TOST")),
64 list("Welch TOST on differences of means near one billion."))
Large-offset numerical case: STAT-HYP-HARD-EQUIVEXT-001
Case STAT-HYP-HARD-EQUIVEXT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, power.t.test; analytic TOST and runs formulae.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_hard.R · sha256 892a9672937f8cfa
- Dataset
- reference_data/datasets/HYP_HARD.json
Settings compared
lower_bound= -2mode= "one_sample_difference"response_column= "x"target= 1000000006upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.8125000074505806 | 0.8125000074505806 | 3.08E-18 | 17 | passed |
/standard_error | tolerance | 0.48147992042592802 | 0.481479920425928 | 7.55E-19 | 17 | passed |
Convention
- Subtract the large target from each observed response before computing the t standard error.
- All data-based expected values use the exported large-offset CSV.
Reference code
The lines of the reference script that produce this case's expected values.
66 one_effect <- mean(d$x - center)
67 one_se <- sd(d$x - center) / sqrt(nrow(d))
68 emit("STAT-HYP-HARD-EQUIVEXT-001", "tabelz.executor.equivalence_extensions",
69 "equivalenceMenuItem",
70 list(mode = "one_sample_difference", response_column = "x", target = center,
71 lower_bound = -2, upper_bound = 2),
72 list("/estimate" = tol(one_effect, "small mean-target effect"),
73 "/standard_error" = tol(one_se, "one-sample SE")),
74 list("Subtract the large target from each observed response before computing the t standard error."))
Large-offset numerical case: STAT-HYP-HARD-PERM-001
Case STAT-HYP-HARD-PERM-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, power.t.test; analytic TOST and runs formulae.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_hard.R · sha256 892a9672937f8cfa
- Dataset
- reference_data/datasets/HYP_HARD.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"inference= "exact"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -1.5750000029802322 | -1.5750000029802322 | 3.88E-17 | 16 | passed |
/p_value | tail_probability | 0.10318570318570319 | 0.10318570318570319 | 2.55E-18 | 16 | passed |
Convention
- All choose(16,8) assignments enumerated with no Monte Carlo; the pooled responses are measured from their median so the exact tail is decided on the low-order bits; two-sided tail uses the absolute mean difference with no tie tolerance.
- All data-based expected values use the exported large-offset CSV.
Reference code
The lines of the reference script that produce this case's expected values.
88 centred <- d$x - stats::median(d$x)
89 perm_delta <- mean(centred[d$g == "A"]) - mean(centred[d$g == "B"])
90 sum_a <- colSums(matrix(centred[assign], nrow = length(a)))
91 null <- sum_a / length(a) - (sum(centred) - sum_a) / length(b)
92 p_exact <- mean(abs(null) >= abs(perm_delta))
93 emit("STAT-HYP-HARD-PERM-001", "tabelz.executor.permutation_tests",
94 "permutationTestsMenuItem",
95 list(mode = "independent", response_column = "x", group_column = "g",
96 group_a = "A", group_b = "B", inference = "exact"),
97 list("/statistic" = tol(perm_delta, "centred large-offset mean difference"),
98 "/p_value" = prob(p_exact, "all exact assignments, centred enumeration")),
99 list("All choose(16,8) assignments enumerated with no Monte Carlo; the pooled responses are measured from their median so the exact tail is decided on the low-order bits; two-sided tail uses the absolute mean difference with no tie tolerance."),
100 version = "2.0.0")
Large-offset numerical case: STAT-HYP-HARD-POWER-001
Case STAT-HYP-HARD-POWER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, power.t.test; analytic TOST and runs formulae.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_hard.R · sha256 892a9672937f8cfa
- Dataset
- None
Settings compared
analysis= "one_sample_t"effect_size= 0.0001sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.050000032156781504 | 0.05000003215677629 | 5.21E-15 | 12 | passed |
Convention
- Strict two-sided power includes both rejection tails for a tiny effect.
- All data-based expected values use the exported large-offset CSV.
Reference code
The lines of the reference script that produce this case's expected values.
131 power <- stats::power.t.test(n = 30, delta = 1e-4, sd = 1, sig.level = 0.05,
132 type = "one.sample", alternative = "two.sided", strict = TRUE)
133 emit("STAT-HYP-HARD-POWER-001", "tabelz.analysis.hypothesis_tests:run_power_analysis",
134 "hypothesisTestsMenuItem",
135 list(analysis = "one_sample_t", solve_for = "power", effect_size = 1e-4,
136 sample_size = 30L),
137 list("/value" = tol(power$power, "near-null noncentral-t power")),
138 list("Strict two-sided power includes both rejection tails for a tiny effect."), dataset = NULL)
Large-offset numerical case: STAT-HYP-HARD-RANK-001
Case STAT-HYP-HARD-RANK-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, power.t.test; analytic TOST and runs formulae.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_hard.R · sha256 892a9672937f8cfa
- Dataset
- reference_data/datasets/HYP_HARD.json
Settings compared
inference= "asymptotic"method= "runs"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/expected_runs | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.0096606229974849512 | 0.00966062299748495 | 1.74E-18 | 15 | passed |
Convention
- Numeric median reference, source row order, no continuity correction.
- All data-based expected values use the exported large-offset CSV.
Reference code
The lines of the reference script that produce this case's expected values.
102 sequence <- d$x > stats::median(d$x)
103 n1 <- sum(sequence)
104 n2 <- length(sequence) - n1
105 runs <- 1L + sum(sequence[-1] != sequence[-length(sequence)])
106 expected_runs <- 1 + 2 * n1 * n2 / length(sequence)
107 runs_var <- 2 * n1 * n2 * (2 * n1 * n2 - length(sequence)) /
108 (length(sequence)^2 * (length(sequence) - 1))
109 runs_p <- 2 * stats::pnorm(-abs((runs - expected_runs) / sqrt(runs_var)))
110 emit("STAT-HYP-HARD-RANK-001", "tabelz.executor.blocked_rank_tests",
111 "blockedRankTestsMenuItem",
112 list(method = "runs", response_column = "x", inference = "asymptotic"),
113 list("/expected_runs" = tol(expected_runs, "runs null expectation"),
114 "/p_value" = prob(runs_p, "asymptotic no-correction runs tail")),
115 list("Numeric median reference, source row order, no continuity correction."))
Large-offset numerical case: STAT-HYP-HARD-TEST-001
Case STAT-HYP-HARD-TEST-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, power.t.test; analytic TOST and runs formulae.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_hard.R · sha256 892a9672937f8cfa
- Dataset
- reference_data/datasets/HYP_HARD.json
Settings compared
response= "x"target= 1000000006test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.6875054712172506 | 1.6875054606866398 | 1.05E-8 | 8 | passed |
/p_value | tail_probability | 0.11218389262537118 | 0.11218389468238715 | 2.06E-9 | 7 | passed |
Convention
- Large common offset, small sample spread; null mean uses the same offset.
- All data-based expected values use the exported large-offset CSV.
Reference code
The lines of the reference script that produce this case's expected values.
43 center <- 1e9 + 6
44 t <- stats::t.test(d$x, mu = center)
45 emit("STAT-HYP-HARD-TEST-001", "tabelz.analysis.hypothesis_tests:run_hypothesis_test",
46 "hypothesisTestsMenuItem", list(test = "one_sample_t", response = "x", target = center),
47 list("/statistic" = tol(t$statistic, "one-sample t statistic"),
48 "/p_value" = prob(t$p.value, "Student t tail")),
49 list("Large common offset, small sample spread; null mean uses the same offset."))
Interacting axes: STAT-HYP-INTERACT-BASIC-ONERATE-GREATER-001
Case STAT-HYP-INTERACT-BASIC-ONERATE-GREATER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- reference_data/datasets/HYP_RATES.json
Settings compared
alternative= "greater"count_column= "count"exposure_column= "exposure"method= "one_poisson_rate"null_rate= 0.15
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.14999999999999999 | 0.15 | 4.45E-18 | 16 | passed |
/p_value | tail_probability | 0.53840266693638195 | 0.5384026669363817 | 2.26E-16 | 15 | passed |
Convention
- One-sided exact Poisson count tail at null rate times exposure.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
Interacting axes: STAT-HYP-INTERACT-BASIC-ONERATE-LESS-001
Case STAT-HYP-INTERACT-BASIC-ONERATE-LESS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- reference_data/datasets/HYP_RATES.json
Settings compared
alternative= "less"count_column= "count"exposure_column= "exposure"method= "one_poisson_rate"null_rate= 0.15
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.14999999999999999 | 0.15 | 4.45E-18 | 16 | passed |
/p_value | tail_probability | 0.57596524857306464 | 0.5759652485730645 | 1.15E-16 | 15 | passed |
Convention
- One-sided exact Poisson count tail at null rate times exposure.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
Interacting axes: STAT-HYP-INTERACT-BASIC-SUMMARY-ONERATE-001
Case STAT-HYP-INTERACT-BASIC-SUMMARY-ONERATE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- None
Settings compared
input_kind= "summary"method= "one_poisson_rate"null_rate= 0.15summary_count= 12summary_exposure= 80
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.14999999999999999 | 0.15 | 4.45E-18 | 16 | passed |
/p_value | tail_probability | 1 | 1.0 | 0.00E+2 | passed |
Convention
- Summary count/exposure totals are from exported HYP_RATES; no table source is claimed.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
50 count <- sum(r$count)
51 exposure <- sum(r$exposure)
52 expected <- 0.15 * exposure
53 p_rate <- min(1, 2 * min(stats::ppois(count, expected),
54 stats::ppois(count - 1, expected, lower.tail = FALSE)))
55 emit("STAT-HYP-INTERACT-BASIC-SUMMARY-ONERATE-001", basic, menu, NULL,
56 list(method = "one_poisson_rate", input_kind = "summary",
57 summary_count = count, summary_exposure = exposure, null_rate = 0.15),
58 list("/estimate" = tol(count / exposure, "summary event rate"),
59 "/p_value" = prob(p_rate, "doubled minimum Poisson tail")),
60 list("Summary count/exposure totals are from exported HYP_RATES; no table source is claimed."))
Interacting axes: STAT-HYP-INTERACT-BASIC-SUMMARY-VARIANCE-001
Case STAT-HYP-INTERACT-BASIC-SUMMARY-VARIANCE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- None
Settings compared
input_kind= "summary"method= "one_variance_chi_square"null_variance= 4sample_size= 16summary_variance= 3.70916666666667
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 13.909375000000001 | 13.909375000000013 | 1.21E-14 | 15 | passed |
/p_value | tail_probability | 0.93517363103879991 | 0.9351736310388017 | 1.78E-15 | 14 | passed |
Convention
- Summary variance and n come from the R CSV; no source table is passed.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
38 n <- nrow(d)
39 sample_var <- stats::var(d$x)
40 chi <- (n - 1) * sample_var / 4
41 two_tail_chi <- min(1, 2 * min(stats::pchisq(chi, n - 1),
42 stats::pchisq(chi, n - 1, lower.tail = FALSE)))
43 emit("STAT-HYP-INTERACT-BASIC-SUMMARY-VARIANCE-001", basic, menu, NULL,
44 list(method = "one_variance_chi_square", input_kind = "summary",
45 summary_variance = sample_var, sample_size = n, null_variance = 4),
46 list("/statistic" = tol(chi, "summary variance chi-square"),
47 "/p_value" = prob(two_tail_chi, "two-sided variance chi-square tail")),
48 list("Summary variance and n come from the R CSV; no source table is passed."))
Interacting axes: STAT-HYP-INTERACT-BASIC-TWORATE-GREATER-001
Case STAT-HYP-INTERACT-BASIC-TWORATE-GREATER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- reference_data/datasets/HYP_RATES.json
Settings compared
alternative= "greater"count_column= "count"exposure_column= "exposure"group_1= "A"group_2= "B"group_column= "g"method= "two_poisson_rate"null_ratio= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.55263157894736847 | 0.5526315789473685 | 3.64E-18 | 17 | passed |
/p_value | tail_probability | 0.89967425784400523 | 0.8996742578440053 | 1.13E-16 | 15 | passed |
Convention
- Condition on total event count; null group-A probability follows exposure ratio.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
Interacting axes: STAT-HYP-INTERACT-BASIC-TWORATE-LESS-001
Case STAT-HYP-INTERACT-BASIC-TWORATE-LESS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- reference_data/datasets/HYP_RATES.json
Settings compared
alternative= "less"count_column= "count"exposure_column= "exposure"group_1= "A"group_2= "B"group_column= "g"method= "two_poisson_rate"null_ratio= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.55263157894736847 | 0.5526315789473685 | 3.64E-18 | 17 | passed |
/p_value | tail_probability | 0.24575576243579059 | 0.2457557624357906 | 3.23E-18 | 16 | passed |
Convention
- Condition on total event count; null group-A probability follows exposure ratio.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
Interacting axes: STAT-HYP-INTERACT-BASIC-VARIANCE-GREATER-001
Case STAT-HYP-INTERACT-BASIC-VARIANCE-GREATER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "greater"method= "one_variance_chi_square"null_variance= 4response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 13.909375000000001 | 13.909375000000004 | 3.26E-15 | 15 | passed |
/p_value | tail_probability | 0.53241318448060004 | 0.5324131844805997 | 3.30E-16 | 15 | passed |
Convention
- One-sided variance chi-square tail.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
Interacting axes: STAT-HYP-INTERACT-BASIC-VARIANCE-LESS-001
Case STAT-HYP-INTERACT-BASIC-VARIANCE-LESS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "less"method= "one_variance_chi_square"null_variance= 4response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 13.909375000000001 | 13.909375000000004 | 3.26E-15 | 15 | passed |
/p_value | tail_probability | 0.46758681551939996 | 0.46758681551940035 | 3.85E-16 | 15 | passed |
Convention
- One-sided variance chi-square tail.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
Interacting axes: STAT-HYP-INTERACT-POWER-ANOVA-001
Case STAT-HYP-INTERACT-POWER-ANOVA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- None
Settings compared
analysis= "one_way_anova"effect_size= 0.5groups= 3solve_for= "sample_size"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | exact | 42 | 42 | 0.00E+2 | passed |
Convention
- R noncentral F ANOVA with three equal-size groups; total is a multiple of three.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
142 anova <- pwr::pwr.anova.test(k = 3, f = 0.5, sig.level = 0.05, power = 0.8)
143 emit("STAT-HYP-INTERACT-POWER-ANOVA-001", power_entry, power_menu, NULL,
144 list(analysis = "one_way_anova", solve_for = "sample_size", effect_size = 0.5,
145 target_power = 0.8, groups = 3L),
146 list("/value" = exact(3 * ceiling(anova$n), "Three equal groups rounded upward.")),
147 list("R noncentral F ANOVA with three equal-size groups; total is a multiple of three."))
Interacting axes: STAT-HYP-INTERACT-POWER-ONE-PROP-001
Case STAT-HYP-INTERACT-POWER-ONE-PROP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- None
Settings compared
analysis= "one_proportion"effect_size= 0.5solve_for= "sample_size"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | exact | 32 | 32 | 0.00E+2 | passed |
Convention
- Cohen h=0.5 enters the one-degree chi-square approximation as w=0.5.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
127 one_prop <- pwr::pwr.chisq.test(w = 0.5, df = 1, sig.level = 0.05, power = 0.8)
128 emit("STAT-HYP-INTERACT-POWER-ONE-PROP-001", power_entry, power_menu, NULL,
129 list(analysis = "one_proportion", solve_for = "sample_size", effect_size = 0.5,
130 target_power = 0.8),
131 list("/value" = exact(ceiling(one_prop$N), "Required one-proportion chi-square n.")),
132 list("Cohen h=0.5 enters the one-degree chi-square approximation as w=0.5."))
Interacting axes: STAT-HYP-INTERACT-POWER-PAIRED-001
Case STAT-HYP-INTERACT-POWER-PAIRED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- None
Settings compared
analysis= "paired_t"effect_size= 0.5solve_for= "sample_size"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | exact | 34 | 34 | 0.00E+2 | passed |
Convention
- R noncentral t power for paired differences, strict two-sided.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
107 power_entry <- "tabelz.analysis.hypothesis_tests:run_power_analysis"
108 power_menu <- "hypothesisTestsMenuItem"
109 paired <- stats::power.t.test(power = 0.8, delta = 0.5, sd = 1,
110 sig.level = 0.05, type = "paired",
111 alternative = "two.sided", strict = TRUE)
112 emit("STAT-HYP-INTERACT-POWER-PAIRED-001", power_entry, power_menu, NULL,
113 list(analysis = "paired_t", solve_for = "sample_size", effect_size = 0.5,
114 target_power = 0.8),
115 list("/value" = exact(ceiling(paired$n), "Round required pairs upward.")),
116 list("R noncentral t power for paired differences, strict two-sided."))
Interacting axes: STAT-HYP-INTERACT-POWER-TWO-PROP-001
Case STAT-HYP-INTERACT-POWER-TWO-PROP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- None
Settings compared
analysis= "two_proportion"effect_size= 0.5ratio= 1solve_for= "sample_size"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | exact | 126 | 126 | 0.00E+2 | passed |
Convention
- Cohen h=0.5; normal two-group approximation, round each group upward.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
134 two_prop <- pwr::pwr.2p.test(h = 0.5, sig.level = 0.05, power = 0.8,
135 alternative = "two.sided")
136 emit("STAT-HYP-INTERACT-POWER-TWO-PROP-001", power_entry, power_menu, NULL,
137 list(analysis = "two_proportion", solve_for = "sample_size", effect_size = 0.5,
138 target_power = 0.8, ratio = 1),
139 list("/value" = exact(2 * ceiling(two_prop$n), "Required total across equal groups.")),
140 list("Cohen h=0.5; normal two-group approximation, round each group upward."))
Interacting axes: STAT-HYP-INTERACT-POWER-TWO-T-001
Case STAT-HYP-INTERACT-POWER-TWO-T-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test, pchisq, ppois, pbinom; pwr::pwr.chisq.test, pwr.2p.test, pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_interactions.R · sha256 ab0cee41d6980e30
- Dataset
- None
Settings compared
analysis= "two_sample_t"effect_size= 0.5ratio= 1solve_for= "sample_size"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | exact | 128 | 128 | 0.00E+2 | passed |
Convention
- R two-sample noncentral t with equal group sizes; round each group upward.
- Entered summary values, when used, were computed from an exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
118 two_t <- stats::power.t.test(power = 0.8, delta = 0.5, sd = 1,
119 sig.level = 0.05, type = "two.sample",
120 alternative = "two.sided", strict = TRUE)
121 emit("STAT-HYP-INTERACT-POWER-TWO-T-001", power_entry, power_menu, NULL,
122 list(analysis = "two_sample_t", solve_for = "sample_size", effect_size = 0.5,
123 target_power = 0.8, ratio = 1),
124 list("/value" = exact(2 * ceiling(two_t$n), "Required total across equal groups.")),
125 list("R two-sample noncentral t with equal group sizes; round each group upward."))
Invalid request: Known sigma must be positive.
Case STAT-HYP-INVALID-BASIC-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
known_sigma= 0method= "known_sigma_z"null_mean= 6response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Known sigma must be positive.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Alpha must be strictly positive.
Case STAT-HYP-INVALID-BASIC-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0known_sigma= 2method= "known_sigma_z"null_mean= 6response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Alpha must be strictly positive.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Lower bound must precede upper bound.
Case STAT-HYP-INVALID-EQUIV-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"lower_bound= 2response_column= "x"upper_bound= -2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Lower bound must precede upper bound.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Compared groups must differ.
Case STAT-HYP-INVALID-EQUIV-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group_a= "A"group_b= "A"group_column= "g"lower_bound= -2response_column= "x"upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Compared groups must differ.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Lower bound must precede upper bound.
Case STAT-HYP-INVALID-EQUIVEXT-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
lower_bound= 2mode= "one_sample_difference"response_column= "x"target= 6upper_bound= -2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Lower bound must precede upper bound.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Paired mode needs both columns.
Case STAT-HYP-INVALID-EQUIVEXT-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
lower_bound= -2mode= "paired_difference"upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Paired mode needs both columns.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Independent labels must differ.
Case STAT-HYP-INVALID-PERM-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group_a= "A"group_b= "A"group_column= "g"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Independent labels must differ.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Inference is exact or Monte Carlo.
Case STAT-HYP-INVALID-PERM-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"inference= "unsupported"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Inference is exact or Monte Carlo.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Planning analysis must be listed.
Case STAT-HYP-INVALID-POWER-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- None
Settings compared
analysis= "unsupported"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Planning analysis must be listed.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Standardized effect size is positive.
Case STAT-HYP-INVALID-POWER-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- None
Settings compared
analysis= "one_sample_t"effect_size= -1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Standardized effect size is positive.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Friedman needs treatment and block columns.
Case STAT-HYP-INVALID-RANK-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
method= "friedman"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Friedman needs treatment and block columns.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Friedman is two-sided.
Case STAT-HYP-INVALID-RANK-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "less"block_column= "h"method= "friedman"response_column= "x"treatment_column= "g"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Friedman is two-sided.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Alpha must be strictly positive.
Case STAT-HYP-INVALID-TEST-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0response= "x"test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Alpha must be strictly positive.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Invalid request: Only listed hypothesis tests are accepted.
Case STAT-HYP-INVALID-TEST-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz user manual: hypothesis and feature setup rules
- Citation
- docs/manual/chapters/07-models-and-tests.tex and feature chapters 16, 31-34, 62
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_invalid.R · sha256 65212f2bd73aed4f
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
response= "x"test= "unsupported"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Invalid condition: Only listed hypothesis tests are accepted.
- No test statistic exists for an invalid request; rejection is the only valid result.
Reference code
Kruskal-Wallis rank test
Case STAT-HYP-KRUSKAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"response= "x"test= "kruskal_wallis"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 2.161764705882355 | 2.161764705882355 | 3.10E-17 | 16 | passed |
/p_value | tail_probability | 0.14148212148279338 | 0.141482121482789 | 4.39E-15 | 13 | passed |
Convention
- R kruskal.test tie-corrected chi-square.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
The lines of the reference script that produce this case's expected values.
155 kruskal <- stats::kruskal.test(x ~ g, data = d)
156 emit("STAT-HYP-KRUSKAL-001", "Kruskal-Wallis rank test", "nominal",
157 list(test = "kruskal_wallis", response = "x", group = "g"),
158 list("/statistic" = tol(kruskal$statistic, "Kruskal-Wallis H"),
159 "/p_value" = prob(kruskal$p.value, "Kruskal-Wallis chi-square tail")),
160 list("R kruskal.test tie-corrected chi-square."))
Two-sample exact rank test
Case STAT-HYP-MANN-WHITNEY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"response= "x"test= "mann_whitney"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.1605283605283605 | 0.1605283605283605 | 3.07E-18 | 16 | passed |
Convention
- No ties and n=8/group: R wilcox.test exact p. R W equals U for the first group.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
The lines of the reference script that produce this case's expected values.
148 mann <- stats::wilcox.test(x ~ g, data = d, exact = TRUE, correct = FALSE)
149 emit("STAT-HYP-MANN-WHITNEY-001", "Two-sample exact rank test", "nominal",
150 list(test = "mann_whitney", response = "x", group = "g"),
151 list("/statistic" = tol(mann$statistic, "Mann-Whitney U"),
152 "/p_value" = prob(mann$p.value, "exact rank tail")),
153 list("No ties and n=8/group: R wilcox.test exact p. R W equals U for the first group."))
Common-effect meta-analysis of generic effects
Case STAT-HYP-META-001 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) inverse-variance pooling written from the manual formulas
- Citation
- DerSimonian and Laird (1986) Controlled Clinical Trials 7:177-188; Hartung and Knapp (2001) Statistics in Medicine 20:3875-3889; Viechtbauer (2007) Statistics in Medicine 26:37-52 (Q-profile interval); Egger et al. (1997) BMJ 315:629-634; Begg and Mazumdar (1994) Biometrics 50:1088-1101; R stats: lm, cor.test (exact Kendall), uniroot, pt, pnorm, pchisq.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_meta_analysis.R · sha256 cb731b4b15b1a99e
- Dataset
- reference_data/datasets/HYP_META_STUDIES.json
Settings compared
data= "generic"effect= "effect"measure= "hedges_g"model= "fixed"standard_error= "se"study= "study"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pooled/0/estimate | tolerance | 0.33870168009517793 | 0.33870168009517787 | 5.94E-17 | 15 | passed |
/pooled/0/standard_error | tolerance | 0.048784802893275914 | 0.048784802893275914 | 3.18E-19 | 17 | passed |
/pooled/0/statistic | tolerance | 6.9427702892669005 | 6.942770289266899 | 1.74E-15 | 15 | passed |
/pooled/0/p_value | tail_probability | 3.8448435076081302e-12 | 3.844843507608176e-12 | 4.60E-26 | 13 | passed |
/pooled/0/lower | tolerance | 0.24308522343147174 | 0.24308522343147165 | 8.69E-17 | 15 | passed |
/pooled/0/upper | tolerance | 0.43431813675888409 | 0.4343181367588841 | 2.01E-18 | 17 | passed |
/heterogeneity/q | tolerance | 12.211539628178901 | 12.211539628178901 | 4.02E-17 | 17 | passed |
/heterogeneity/df | exact | 7 | 7 | 0.00E+2 | passed | |
/heterogeneity/p_value | tail_probability | 0.09381338651981122 | 0.09381338651981116 | 5.51E-17 | 15 | passed |
/k | exact | 8 | 8 | 0.00E+2 | passed | |
/heterogeneity/i2 | tolerance | 42.677170830719362 | 42.67717083071936 | 1.58E-17 | 18 | passed |
/heterogeneity/h2 | tolerance | 1.7445056611684144 | 1.7445056611684144 | 3.43E-17 | 16 | passed |
/studies/0/weight_percent | tolerance | 19.669066060626299 | 19.6690660606263 | 4.75E-16 | 16 | passed |
/studies/4/weight_percent | tolerance | 29.382185102910892 | 29.382185102910896 | 3.58E-15 | 15 | passed |
/studies/0/lower | tolerance | 0.094403961700594091 | 0.09440396170059406 | 2.76E-17 | 15 | passed |
/bias/0/statistic | tolerance | -0.71722519962852016 | -0.7172251996285203 | 1.11E-16 | 15 | passed |
/bias/0/p_value | tail_probability | 0.50019110680776269 | 0.5001911068077626 | 1.15E-16 | 15 | passed |
/bias/1/statistic | tolerance | -0.21428571428571427 | -0.21428571428571427 | 3.82E-18 | 16 | passed |
/bias/1/p_value | tail_probability | 0.54841269841269846 | 0.5484126984126985 | 2.75E-18 | 17 | passed |
/cumulative/7/estimate | tolerance | 0.33870168009517793 | 0.33870168009517787 | 5.94E-17 | 15 | passed |
/leave_one_out/0/estimate | tolerance | 0.3457292996454383 | 0.34572929964543825 | 5.17E-17 | 15 | passed |
Convention
- Common effect: mu = sum(w y)/sum(w), w = 1/se^2, normal z inference; Q = sum w (y - mu)^2 on k - 1 df; I^2 = max(0, 100 (Q - df)/Q), H^2 = Q/df.
- Egger: lm(y/se ~ 1/se), intercept t on k - 2 df. Begg: Kendall tau between (y - mu)/sqrt(v - 1/sum w) and v, exact p (no ties).
- Expected computed from the exported CSV.
- docs/manual/chapters/78-meta-analysis.tex:25-31: common effect w=1/v; random effects w=1/(v+tau^2); REML default, DL/PM/SJ alternatives.
- docs/manual/chapters/78-meta-analysis.tex:33-37: modified Hartung-Knapp scales 1/sum(w) by q=max(1, sum w (y-mu)^2/(k-1)) on t(k-1); ordinary HK removes the floor.
- docs/manual/chapters/78-meta-analysis.tex:70-79: Q, tau^2 with Q-profile interval, I^2 and H^2 relative to the typical within-study variance; prediction interval mu +- t(k-2) sqrt(tau^2 + Var(mu)).
Reference code
The lines of the reference script that produce this case's expected values.
212 y <- d$effect; v <- d$se^2; k <- length(y)
213 cp <- common_pool(y, v)
214 eg <- egger(y, v); bg <- begg(y, v)
215 outputs <- common_outputs(cp, 0.95)
216 outputs[["/k"]] <- exact(k, "eight studies")
217 outputs[["/heterogeneity/i2"]] <- tol(max(0, 100 * (cp$q - cp$df) / cp$q), "common-effect I^2 from Q")
218 outputs[["/heterogeneity/h2"]] <- tol(cp$q / cp$df, "common-effect H^2 = Q/df")
219 outputs[["/studies/0/weight_percent"]] <- tol(cp$weights[1], "inverse-variance weight of study 1 (%)")
220 outputs[["/studies/4/weight_percent"]] <- tol(cp$weights[5], "inverse-variance weight of study 5 (%)")
221 outputs[["/studies/0/lower"]] <- tol(y[1] - stats::qnorm(0.975) * sqrt(v[1]), "study 1 normal CI lower")
222 outputs[["/bias/0/statistic"]] <- tol(eg$t, "Egger intercept t (lm of y/SE on 1/SE)")
223 outputs[["/bias/0/p_value"]] <- prob(eg$p, "Egger intercept p on k - 2 df")
224 outputs[["/bias/1/statistic"]] <- tol(bg$tau, "Begg Kendall tau (cor.test)")
225 outputs[["/bias/1/p_value"]] <- prob(bg$p, "Begg exact Kendall p (cor.test exact=TRUE)")
226 outputs[["/cumulative/7/estimate"]] <- tol(cp$mu, "cumulative estimate after all studies = pooled")
227 loo <- common_pool(y[-1], v[-1])
228 outputs[["/leave_one_out/0/estimate"]] <- tol(loo$mu, "common-effect estimate without study 1")
229 emit("STAT-HYP-META-001", "Common-effect meta-analysis of generic effects", "nominal",
230 list(data = "generic", study = "study", effect = "effect", standard_error = "se",
231 model = "fixed", measure = "hedges_g"),
232 outputs,
233 list("Common effect: mu = sum(w y)/sum(w), w = 1/se^2, normal z inference; Q = sum w (y - mu)^2 on k - 1 df; I^2 = max(0, 100 (Q - df)/Q), H^2 = Q/df.",
234 "Egger: lm(y/se ~ 1/se), intercept t on k - 2 df. Begg: Kendall tau between (y - mu)/sqrt(v - 1/sum w) and v, exact p (no ties)."))
Random effects, DerSimonian-Laird, normal inference
Case STAT-HYP-META-002 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) inverse-variance pooling written from the manual formulas
- Citation
- DerSimonian and Laird (1986) Controlled Clinical Trials 7:177-188; Hartung and Knapp (2001) Statistics in Medicine 20:3875-3889; Viechtbauer (2007) Statistics in Medicine 26:37-52 (Q-profile interval); Egger et al. (1997) BMJ 315:629-634; Begg and Mazumdar (1994) Biometrics 50:1088-1101; R stats: lm, cor.test (exact Kendall), uniroot, pt, pnorm, pchisq.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_meta_analysis.R · sha256 cb731b4b15b1a99e
- Dataset
- reference_data/datasets/HYP_META_STUDIES.json
Settings compared
data= "generic"effect= "effect"inference= "normal"measure= "hedges_g"model= "random"standard_error= "se"study= "study"tau2= "dl"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pooled/0/estimate | tolerance | 0.33870168009517793 | 0.33870168009517787 | 5.94E-17 | 15 | passed |
/pooled/0/standard_error | tolerance | 0.048784802893275914 | 0.048784802893275914 | 3.18E-19 | 17 | passed |
/pooled/0/statistic | tolerance | 6.9427702892669005 | 6.942770289266899 | 1.74E-15 | 15 | passed |
/pooled/0/p_value | tail_probability | 3.8448435076081302e-12 | 3.844843507608176e-12 | 4.60E-26 | 13 | passed |
/pooled/0/lower | tolerance | 0.24308522343147174 | 0.24308522343147165 | 8.69E-17 | 15 | passed |
/pooled/0/upper | tolerance | 0.43431813675888409 | 0.4343181367588841 | 2.01E-18 | 17 | passed |
/heterogeneity/q | tolerance | 12.211539628178901 | 12.211539628178901 | 4.02E-17 | 17 | passed |
/heterogeneity/df | exact | 7 | 7 | 0.00E+2 | passed | |
/heterogeneity/p_value | tail_probability | 0.09381338651981122 | 0.09381338651981116 | 5.51E-17 | 15 | passed |
/pooled/1/estimate | tolerance | 0.32556727267988272 | 0.3255672726798827 | 4.34E-18 | 16 | passed |
/pooled/1/standard_error | tolerance | 0.068336509456068714 | 0.06833650945606871 | 1.86E-19 | 17 | passed |
/pooled/1/statistic | tolerance | 4.7641776741491189 | 4.764177674149119 | 4.26E-17 | 17 | passed |
/pooled/1/p_value | tail_probability | 1.8962536666438452e-06 | 1.8962536666438446e-06 | 6.20E-22 | 15 | passed |
/pooled/1/lower | tolerance | 0.19163017531680723 | 0.1916301753168072 | 2.47E-17 | 15 | passed |
/pooled/1/upper | tolerance | 0.45950437004295819 | 0.45950437004295824 | 5.34E-17 | 15 | passed |
/pooled/1/prediction_lower | tolerance | -0.018013793646925069 | -0.0180137936469264 | 1.33E-15 | 13 | passed |
/pooled/1/prediction_upper | tolerance | 0.66914833900669057 | 0.6691483390066919 | 1.34E-15 | 14 | passed |
/heterogeneity/tau2 | tolerance | 0.015046257132957555 | 0.01504625713295755 | 5.13E-18 | 15 | passed |
/heterogeneity/i2 | tolerance | 42.677170830719362 | 42.677170830719355 | 7.09E-15 | 15 | passed |
/heterogeneity/h2 | tolerance | 1.7445056611684142 | 1.7445056611684144 | 2.34E-16 | 15 | passed |
/heterogeneity/tau2_upper | tolerance | 0.203344963643254 | 0.20334496364325397 | 3.24E-17 | 15 | passed |
/studies/0/weight_percent | tolerance | 17.202660763755134 | 17.202660763755134 | 3.56E-16 | 16 | passed |
/leave_one_out/0/estimate | tolerance | 0.32517051778416539 | 0.3251705177841654 | 1.54E-18 | 17 | passed |
/leave_one_out/0/tau2 | tolerance | 0.023042835246738978 | 0.023042835246738985 | 6.51E-18 | 15 | passed |
/cumulative/2/estimate | tolerance | 0.3385161346130019 | 0.3385161346130019 | 4.44E-18 | 16 | passed |
Convention
- DL tau^2 = max(0, (Q - (k - 1)) / (sum w - sum w^2 / sum w)); random-effects weights 1/(v + tau^2); normal interval.
- Typical within-study variance s^2 = (k - 1)/(sum w - sum w^2/sum w); I^2 = 100 tau^2/(tau^2 + s^2); H^2 = (tau^2 + s^2)/s^2.
- Q-profile limits: tau^2 where the generalized Q equals chi-square(k - 1) quantiles 0.975 (lower) and 0.025 (upper), by uniroot to 1e-14; 0 when Q(0) is below the quantile.
- Prediction interval: mu +- t(k - 2, 0.975) sqrt(tau^2 + 1/sum w*); relative tolerance 1e-8 because the Q-profile limits come from a root search.
- Expected computed from the exported CSV.
- docs/manual/chapters/78-meta-analysis.tex:25-31: common effect w=1/v; random effects w=1/(v+tau^2); REML default, DL/PM/SJ alternatives.
- docs/manual/chapters/78-meta-analysis.tex:33-37: modified Hartung-Knapp scales 1/sum(w) by q=max(1, sum w (y-mu)^2/(k-1)) on t(k-1); ordinary HK removes the floor.
- docs/manual/chapters/78-meta-analysis.tex:70-79: Q, tau^2 with Q-profile interval, I^2 and H^2 relative to the typical within-study variance; prediction interval mu +- t(k-2) sqrt(tau^2 + Var(mu)).
Reference code
The lines of the reference script that produce this case's expected values.
237 t_dl <- tau2_dl(y, v)
238 stopifnot(t_dl > 0)
239 rp <- random_pool(y, v, t_dl, "normal", 0.95)
240 prof <- qprofile(y, v, 0.95)
241 outputs <- c(common_outputs(cp, 0.95), random_outputs(rp, t_dl, prof, cp, 0.95))
242 loo <- random_pool(y[-1], v[-1], tau2_dl(y[-1], v[-1]), "normal", 0.95)
243 outputs[["/leave_one_out/0/estimate"]] <- tol(loo$mu, "DL random-effects estimate without study 1", "1e-8")
244 outputs[["/leave_one_out/0/tau2"]] <- tol(tau2_dl(y[-1], v[-1]), "DL tau^2 without study 1", "1e-8")
245 cum3 <- random_pool(y[1:3], v[1:3], tau2_dl(y[1:3], v[1:3]), "normal", 0.95)
246 outputs[["/cumulative/2/estimate"]] <- tol(cum3$mu, "DL cumulative estimate after three studies", "1e-8")
247 emit("STAT-HYP-META-002", "Random effects, DerSimonian-Laird, normal inference", "axis_coverage",
248 list(data = "generic", study = "study", effect = "effect", standard_error = "se",
249 model = "random", measure = "hedges_g", tau2 = "dl", inference = "normal"),
250 outputs,
251 list("DL tau^2 = max(0, (Q - (k - 1)) / (sum w - sum w^2 / sum w)); random-effects weights 1/(v + tau^2); normal interval.",
252 "Typical within-study variance s^2 = (k - 1)/(sum w - sum w^2/sum w); I^2 = 100 tau^2/(tau^2 + s^2); H^2 = (tau^2 + s^2)/s^2.",
253 "Q-profile limits: tau^2 where the generalized Q equals chi-square(k - 1) quantiles 0.975 (lower) and 0.025 (upper), by uniroot to 1e-14; 0 when Q(0) is below the quantile.",
254 "Prediction interval: mu +- t(k - 2, 0.975) sqrt(tau^2 + 1/sum w*); relative tolerance 1e-8 because the Q-profile limits come from a root search."))
Hedges' g from two arms, DL, modified Hartung-Knapp, 90%
Case STAT-HYP-META-003 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) inverse-variance pooling written from the manual formulas
- Citation
- DerSimonian and Laird (1986) Controlled Clinical Trials 7:177-188; Hartung and Knapp (2001) Statistics in Medicine 20:3875-3889; Viechtbauer (2007) Statistics in Medicine 26:37-52 (Q-profile interval); Egger et al. (1997) BMJ 315:629-634; Begg and Mazumdar (1994) Biometrics 50:1088-1101; R stats: lm, cor.test (exact Kendall), uniroot, pt, pnorm, pchisq.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_meta_analysis.R · sha256 cb731b4b15b1a99e
- Dataset
- reference_data/datasets/HYP_META_STUDIES.json
Settings compared
confidence_level= 0.9data= "continuous"inference= "modified_hk"mean1= "mean1"mean2= "mean2"measure= "hedges_g"model= "random"n1= "n1"n2= "n2"sd1= "sd1"sd2= "sd2"study= "study"tau2= "dl"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pooled/0/estimate | tolerance | 0.41606215163317017 | 0.4160621516331702 | 4.14E-18 | 17 | passed |
/pooled/0/standard_error | tolerance | 0.10345067594260225 | 0.10345067594260225 | 2.08E-18 | 16 | passed |
/pooled/0/statistic | tolerance | 4.0218408226159372 | 4.021840822615937 | 2.76E-17 | 17 | passed |
/pooled/0/p_value | tail_probability | 5.7745077414981249e-05 | 5.774507741498131e-05 | 6.07E-20 | 14 | passed |
/pooled/0/lower | tolerance | 0.24590093209839953 | 0.24590093209839944 | 8.60E-17 | 15 | passed |
/pooled/0/upper | tolerance | 0.58622337116794077 | 0.5862233711679409 | 1.07E-16 | 15 | passed |
/heterogeneity/q | tolerance | 15.495053660249621 | 15.495053660249619 | 2.06E-15 | 15 | passed |
/heterogeneity/df | exact | 7 | 7 | 0.00E+2 | passed | |
/heterogeneity/p_value | tail_probability | 0.030151986884212174 | 0.030151986884212206 | 3.16E-17 | 14 | passed |
/pooled/1/estimate | tolerance | 0.40906552360352344 | 0.4090655236035235 | 5.54E-17 | 15 | passed |
/pooled/1/standard_error | tolerance | 0.16115837807219863 | 0.16115837807219865 | 2.47E-17 | 15 | passed |
/pooled/1/statistic | tolerance | 2.5382827036163329 | 2.5382827036163325 | 4.41E-16 | 15 | passed |
/pooled/1/p_value | tail_probability | 0.038761105776692804 | 0.03876110577669285 | 4.90E-17 | 14 | passed |
/pooled/1/lower | tolerance | 0.1037383084769295 | 0.10373830847692955 | 5.27E-17 | 15 | passed |
/pooled/1/upper | tolerance | 0.71439273873011744 | 0.7143927387301174 | 1.90E-18 | 17 | passed |
/pooled/1/prediction_lower | tolerance | -0.29483029557110885 | -0.29483029557110935 | 4.96E-16 | 14 | passed |
/pooled/1/prediction_upper | tolerance | 1.1129613427781557 | 1.1129613427781564 | 6.93E-16 | 15 | passed |
/heterogeneity/tau2 | tolerance | 0.1052451215777212 | 0.1052451215777212 | 1.24E-18 | 16 | passed |
/heterogeneity/i2 | tolerance | 54.824293264904824 | 54.82429326490482 | 6.86E-15 | 15 | passed |
/heterogeneity/h2 | tolerance | 2.213579094321374 | 2.213579094321374 | 7.85E-18 | 17 | passed |
/heterogeneity/tau2_upper | tolerance | 0.61417350149896466 | 0.6141735014989645 | 1.13E-16 | 15 | passed |
/studies/0/weight_percent | tolerance | 12.9251981169734 | 12.9251981169734 | 1.80E-16 | 16 | passed |
/heterogeneity/tau2_lower | tolerance | 0.0096843147481845606 | 0.009684314748184552 | 8.67E-18 | 15 | passed |
/heterogeneity/hk_scale | tolerance | 1.0664699829510926 | 1.0664699829510929 | 2.54E-16 | 15 | passed |
/studies/0/effect | tolerance | 0.38406277875396999 | 0.38406277875397 | 1.11E-18 | 17 | passed |
/studies/0/standard_error | tolerance | 0.28839523530832906 | 0.28839523530832906 | 3.49E-18 | 16 | passed |
/studies/3/effect | tolerance | -0.29410290839615849 | -0.2941029083961585 | 1.12E-18 | 17 | passed |
/pooled/1/distribution | exact | t(7) | t(7) | passed |
Convention
- Hedges' g = J d with d = (m1 - m2)/s_pooled, J = Gamma(m/2)/(sqrt(m/2) Gamma((m - 1)/2)), m = n1 + n2 - 2; variance 1/n1 + 1/n2 + g^2/(2 (n1 + n2)) (metafor escalc SMD convention).
- Modified Hartung-Knapp: Var(mu) = max(1, sum w (y - mu)^2/(k - 1)) / sum w with t(k - 1); the same scaled variance enters the prediction interval.
- tau^2 = 0 would make the modified HK scale floor at 1; this data set has tau^2 > 0 (asserted in the generator).
- Expected computed from the exported CSV.
- docs/manual/chapters/78-meta-analysis.tex:25-31: common effect w=1/v; random effects w=1/(v+tau^2); REML default, DL/PM/SJ alternatives.
- docs/manual/chapters/78-meta-analysis.tex:33-37: modified Hartung-Knapp scales 1/sum(w) by q=max(1, sum w (y-mu)^2/(k-1)) on t(k-1); ordinary HK removes the floor.
- docs/manual/chapters/78-meta-analysis.tex:70-79: Q, tau^2 with Q-profile interval, I^2 and H^2 relative to the typical within-study variance; prediction interval mu +- t(k-2) sqrt(tau^2 + Var(mu)).
Reference code
The lines of the reference script that produce this case's expected values.
257 m <- d$n1 + d$n2 - 2
258 sp <- sqrt(((d$n1 - 1) * d$sd1^2 + (d$n2 - 1) * d$sd2^2) / m)
259 dd <- (d$mean1 - d$mean2) / sp
260 J <- exp(lgamma(m / 2) - 0.5 * log(m / 2) - lgamma((m - 1) / 2))
261 g <- J * dd
262 vg <- 1 / d$n1 + 1 / d$n2 + g^2 / (2 * (d$n1 + d$n2))
263 cpg <- common_pool(g, vg)
264 t_g <- tau2_dl(g, vg)
265 rpg <- random_pool(g, vg, t_g, "modified_hk", 0.90)
266 profg <- qprofile(g, vg, 0.90)
267 outputs <- c(common_outputs(cpg, 0.90), random_outputs(rpg, t_g, profg, cpg, 0.90))
268 outputs[["/studies/0/effect"]] <- tol(g[1], "Hedges' g of study 1 (exact J)")
269 outputs[["/studies/0/standard_error"]] <- tol(sqrt(vg[1]), "SE of Hedges' g of study 1")
270 outputs[["/studies/3/effect"]] <- tol(g[4], "Hedges' g of study 4")
271 outputs[["/pooled/1/distribution"]] <- list(comparison = "exact", value = "t(7)",
272 rationale = "Hartung-Knapp uses t on k - 1 = 7 df")
273 emit("STAT-HYP-META-003", "Hedges' g from two arms, DL, modified Hartung-Knapp, 90%", "axis_coverage",
274 list(data = "continuous", study = "study", n1 = "n1", mean1 = "mean1", sd1 = "sd1",
275 n2 = "n2", mean2 = "mean2", sd2 = "sd2", measure = "hedges_g", model = "random",
276 tau2 = "dl", inference = "modified_hk", confidence_level = 0.90),
277 outputs,
278 list("Hedges' g = J d with d = (m1 - m2)/s_pooled, J = Gamma(m/2)/(sqrt(m/2) Gamma((m - 1)/2)), m = n1 + n2 - 2; variance 1/n1 + 1/n2 + g^2/(2 (n1 + n2)) (metafor escalc SMD convention).",
279 "Modified Hartung-Knapp: Var(mu) = max(1, sum w (y - mu)^2/(k - 1)) / sum w with t(k - 1); the same scaled variance enters the prediction interval.",
280 "tau^2 = 0 would make the modified HK scale floor at 1; this data set has tau^2 > 0 (asserted in the generator)."))
Log odds ratio from events, REML, ordinary Hartung-Knapp
Case STAT-HYP-META-004 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) inverse-variance pooling written from the manual formulas
- Citation
- DerSimonian and Laird (1986) Controlled Clinical Trials 7:177-188; Hartung and Knapp (2001) Statistics in Medicine 20:3875-3889; Viechtbauer (2007) Statistics in Medicine 26:37-52 (Q-profile interval); Egger et al. (1997) BMJ 315:629-634; Begg and Mazumdar (1994) Biometrics 50:1088-1101; R stats: lm, cor.test (exact Kendall), uniroot, pt, pnorm, pchisq.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_meta_analysis.R · sha256 cb731b4b15b1a99e
- Dataset
- reference_data/datasets/HYP_META_STUDIES.json
Settings compared
correction= 0.5data= "binary"events1= "events1"events2= "events2"inference= "hk"measure= "log_or"model= "random"study= "study"tau2= "reml"total1= "total1"total2= "total2"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pooled/0/estimate | tolerance | -0.93203759368255279 | -0.9320375936825529 | 1.11E-16 | 15 | passed |
/pooled/0/standard_error | tolerance | 0.23303218382838639 | 0.2330321838283864 | 1.11E-18 | 17 | passed |
/pooled/0/statistic | tolerance | -3.9996088882252425 | -3.999608888225243 | 4.64E-16 | 15 | passed |
/pooled/0/p_value | tail_probability | 6.3447250747710346e-05 | 6.344725074771012e-05 | 2.30E-19 | 14 | passed |
/pooled/0/lower | tolerance | -1.3887722812249073 | -1.3887722812249075 | 1.79E-16 | 15 | passed |
/pooled/0/upper | tolerance | -0.47530290614019838 | -0.4753029061401984 | 2.08E-18 | 17 | passed |
/heterogeneity/q | tolerance | 12.972288383802946 | 12.972288383802944 | 2.09E-15 | 15 | passed |
/heterogeneity/df | exact | 7 | 7 | 0.00E+2 | passed | |
/heterogeneity/p_value | tail_probability | 0.072786464796518083 | 0.07278646479651808 | 2.35E-19 | 17 | passed |
/pooled/1/estimate | tolerance | -1.0001121575329686 | -1.0001121575329688 | 1.82E-16 | 15 | passed |
/pooled/1/standard_error | tolerance | 0.32410388444953431 | 0.32410388444953436 | 5.29E-17 | 15 | passed |
/pooled/1/statistic | tolerance | -3.08577652264669 | -3.08577652264669 | 1.04E-18 | 18 | passed |
/pooled/1/p_value | tail_probability | 0.01767144683702367 | 0.01767144683702368 | 9.91E-18 | 15 | passed |
/pooled/1/lower | tolerance | -1.7664960627377626 | -1.766496062737763 | 4.51E-16 | 15 | passed |
/pooled/1/upper | tolerance | -0.23372825232817451 | -0.2337282523281744 | 1.08E-16 | 15 | passed |
/pooled/1/prediction_lower | tolerance | -2.6741891205495505 | -2.674189120549558 | 7.54E-15 | 14 | passed |
/pooled/1/prediction_upper | tolerance | 0.67396480548361337 | 0.6739648054836205 | 7.11E-15 | 13 | passed |
/heterogeneity/tau2 | tolerance | 0.36303032000333696 | 0.3630303200033372 | 2.21E-16 | 15 | passed |
/heterogeneity/i2 | tolerance | 44.83255110838904 | 44.832551108389055 | 1.47E-14 | 15 | passed |
/heterogeneity/h2 | tolerance | 1.8126631194506169 | 1.8126631194506175 | 6.33E-16 | 15 | passed |
/heterogeneity/tau2_upper | tolerance | 3.5097076003384222 | 3.509707600338426 | 4.01E-15 | 14 | passed |
/studies/0/weight_percent | tolerance | 13.580004061633923 | 13.580004061633923 | 4.84E-16 | 16 | passed |
/heterogeneity/hk_scale | tolerance | 0.99423539580305975 | 0.9942353958030594 | 3.31E-16 | 15 | passed |
/studies/3/effect | tolerance | -2.95441412422326 | -2.95441412422326 | 3.57E-18 | 17 | passed |
/studies/3/standard_error | tolerance | 1.5210523916409018 | 1.5210523916409018 | 2.03E-17 | 16 | passed |
/studies/0/effect | tolerance | -1.5761631235492282 | -1.5761631235492282 | 3.78E-17 | 16 | passed |
Convention
- Log OR = log(a d/(b c)) with variance 1/a + 1/b + 1/c + 1/d; the one study with a zero cell gets 0.5 added to all four cells (manual chapter 78 lines 17-20).
- REML tau^2: the root of the restricted score -tr(P)/2 + y'PPy/2 (one sign change on a 4000-point log grid, asserted), found by uniroot to 1e-15 and compared with the boundary 0 by the restricted likelihood.
- Ordinary Hartung-Knapp: Var(mu) = (sum w (y - mu)^2/(k - 1)) / sum w without the floor at 1, t(k - 1).
- Relative tolerance 1e-8: tau^2 is an iterative root in both implementations.
- Expected computed from the exported CSV.
- docs/manual/chapters/78-meta-analysis.tex:25-31: common effect w=1/v; random effects w=1/(v+tau^2); REML default, DL/PM/SJ alternatives.
- docs/manual/chapters/78-meta-analysis.tex:33-37: modified Hartung-Knapp scales 1/sum(w) by q=max(1, sum w (y-mu)^2/(k-1)) on t(k-1); ordinary HK removes the floor.
- docs/manual/chapters/78-meta-analysis.tex:70-79: Q, tau^2 with Q-profile interval, I^2 and H^2 relative to the typical within-study variance; prediction interval mu +- t(k-2) sqrt(tau^2 + Var(mu)).
Reference code
The lines of the reference script that produce this case's expected values.
284 a <- d$events1; b <- d$total1 - d$events1; cc <- d$events2; dd2 <- d$total2 - d$events2
285 zero <- (a == 0 | b == 0 | cc == 0 | dd2 == 0)
286 stopifnot(sum(zero) == 1L, !any((a == 0 & cc == 0) | (b == 0 & dd2 == 0)))
287 a[zero] <- a[zero] + 0.5; b[zero] <- b[zero] + 0.5; cc[zero] <- cc[zero] + 0.5; dd2[zero] <- dd2[zero] + 0.5
288 lor <- log(a * dd2 / (b * cc))
289 vlor <- 1 / a + 1 / b + 1 / cc + 1 / dd2
290 cpl <- common_pool(lor, vlor)
291 t_reml <- tau2_reml(lor, vlor)
292 stopifnot(t_reml > 0)
293 rpl <- random_pool(lor, vlor, t_reml, "hk", 0.95)
294 profl <- qprofile(lor, vlor, 0.95)
295 outputs <- c(common_outputs(cpl, 0.95), random_outputs(rpl, t_reml, profl, cpl, 0.95))
296 outputs[[paste0("/studies/", which(zero) - 1, "/effect")]] <- tol(lor[zero], "log OR of the zero-cell study after adding 0.5 to each cell")
297 outputs[[paste0("/studies/", which(zero) - 1, "/standard_error")]] <- tol(sqrt(vlor[zero]), "SE of the corrected log OR")
298 outputs[["/studies/0/effect"]] <- tol(lor[1], "log OR of study 1")
299 emit("STAT-HYP-META-004", "Log odds ratio from events, REML, ordinary Hartung-Knapp", "axis_coverage",
300 list(data = "binary", study = "study", events1 = "events1", total1 = "total1",
301 events2 = "events2", total2 = "total2", measure = "log_or", correction = 0.5,
302 model = "random", tau2 = "reml", inference = "hk"),
303 outputs,
304 list("Log OR = log(a d/(b c)) with variance 1/a + 1/b + 1/c + 1/d; the one study with a zero cell gets 0.5 added to all four cells (manual chapter 78 lines 17-20).",
305 "REML tau^2: the root of the restricted score -tr(P)/2 + y'PPy/2 (one sign change on a 4000-point log grid, asserted), found by uniroot to 1e-15 and compared with the boundary 0 by the restricted likelihood.",
306 "Ordinary Hartung-Knapp: Var(mu) = (sum w (y - mu)^2/(k - 1)) / sum w without the floor at 1, t(k - 1).",
307 "Relative tolerance 1e-8: tau^2 is an iterative root in both implementations."))
Paule-Mandel tau^2 with normal inference, 99%
Case STAT-HYP-META-005 · status: passed
Reference
- Evidence type
- R
- Source
- Base R (stats) inverse-variance pooling written from the manual formulas
- Citation
- DerSimonian and Laird (1986) Controlled Clinical Trials 7:177-188; Hartung and Knapp (2001) Statistics in Medicine 20:3875-3889; Viechtbauer (2007) Statistics in Medicine 26:37-52 (Q-profile interval); Egger et al. (1997) BMJ 315:629-634; Begg and Mazumdar (1994) Biometrics 50:1088-1101; R stats: lm, cor.test (exact Kendall), uniroot, pt, pnorm, pchisq.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_meta_analysis.R · sha256 cb731b4b15b1a99e
- Dataset
- reference_data/datasets/HYP_META_STUDIES.json
Settings compared
confidence_level= 0.99data= "generic"effect= "effect"inference= "normal"measure= "hedges_g"model= "random"standard_error= "se"study= "study"tau2= "pm"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pooled/0/estimate | tolerance | 0.33870168009517793 | 0.33870168009517787 | 5.94E-17 | 15 | passed |
/pooled/0/standard_error | tolerance | 0.048784802893275914 | 0.048784802893275914 | 3.18E-19 | 17 | passed |
/pooled/0/statistic | tolerance | 6.9427702892669005 | 6.942770289266899 | 1.74E-15 | 15 | passed |
/pooled/0/p_value | tail_probability | 3.8448435076081302e-12 | 3.844843507608176e-12 | 4.60E-26 | 13 | passed |
/pooled/0/lower | tolerance | 0.21304035523482068 | 0.2130403552348206 | 8.58E-17 | 15 | passed |
/pooled/0/upper | tolerance | 0.46436300495553517 | 0.4643630049555352 | 4.64E-18 | 16 | passed |
/heterogeneity/q | tolerance | 12.211539628178901 | 12.211539628178901 | 4.02E-17 | 17 | passed |
/heterogeneity/df | exact | 7 | 7 | 0.00E+2 | passed | |
/heterogeneity/p_value | tail_probability | 0.09381338651981122 | 0.09381338651981116 | 5.51E-17 | 15 | passed |
/pooled/1/estimate | tolerance | 0.32307915192569081 | 0.32307915192562336 | 6.74E-14 | 12 | passed |
/pooled/1/standard_error | tolerance | 0.074784336208212066 | 0.07478433620840802 | 1.96E-13 | 11 | passed |
/pooled/1/statistic | tolerance | 4.3201446761014841 | 4.320144676089263 | 1.22E-11 | 11 | passed |
/pooled/1/p_value | tail_probability | 1.5592693918690127e-05 | 1.5592693919553694e-05 | 8.64E-16 | 10 | passed |
/pooled/1/lower | tolerance | 0.13044746727412515 | 0.13044746727355291 | 5.72E-13 | 11 | passed |
/pooled/1/upper | tolerance | 0.51571083657725647 | 0.5157108365776938 | 4.37E-13 | 12 | passed |
/pooled/1/prediction_lower | tolerance | -0.28972670441955839 | -0.2897267044223734 | 2.82E-12 | 11 | passed |
/pooled/1/prediction_upper | tolerance | 0.93588500827094001 | 0.9358850082736201 | 2.68E-12 | 11 | passed |
/heterogeneity/tau2 | tolerance | 0.021728540011937983 | 0.021728540012153255 | 2.15E-13 | 11 | passed |
/heterogeneity/i2 | tolerance | 51.810770650519196 | 51.81077065076656 | 2.47E-10 | 11 | passed |
/heterogeneity/h2 | tolerance | 2.0751525050291635 | 2.075152505039816 | 1.07E-11 | 11 | passed |
/heterogeneity/tau2_upper | tolerance | 0.37517629475721259 | 0.3751762947572126 | 1.69E-18 | 17 | passed |
/studies/0/weight_percent | tolerance | 16.532480976504612 | 16.532480976486045 | 1.86E-11 | 11 | passed |
Convention
- Paule-Mandel tau^2: the root of the generalized Q(tau^2) = sum (y - mu*)^2/(v + tau^2) = k - 1, by uniroot to 1e-14 (0 when Q(0) <= k - 1).
- Relative tolerance 1e-8: tau^2 and the Q-profile limits are iterative roots in both implementations.
- Expected computed from the exported CSV.
- docs/manual/chapters/78-meta-analysis.tex:25-31: common effect w=1/v; random effects w=1/(v+tau^2); REML default, DL/PM/SJ alternatives.
- docs/manual/chapters/78-meta-analysis.tex:33-37: modified Hartung-Knapp scales 1/sum(w) by q=max(1, sum w (y-mu)^2/(k-1)) on t(k-1); ordinary HK removes the floor.
- docs/manual/chapters/78-meta-analysis.tex:70-79: Q, tau^2 with Q-profile interval, I^2 and H^2 relative to the typical within-study variance; prediction interval mu +- t(k-2) sqrt(tau^2 + Var(mu)).
Reference code
The lines of the reference script that produce this case's expected values.
310 t_pm <- tau2_pm(y, v)
311 stopifnot(t_pm > 0)
312 rpp <- random_pool(y, v, t_pm, "normal", 0.99)
313 profp <- qprofile(y, v, 0.99)
314 outputs <- c(common_outputs(cp, 0.99), random_outputs(rpp, t_pm, profp, cp, 0.99))
315 emit("STAT-HYP-META-005", "Paule-Mandel tau^2 with normal inference, 99%", "axis_coverage",
316 list(data = "generic", study = "study", effect = "effect", standard_error = "se",
317 model = "random", measure = "hedges_g", tau2 = "pm", inference = "normal",
318 confidence_level = 0.99),
319 outputs,
320 list("Paule-Mandel tau^2: the root of the generalized Q(tau^2) = sum (y - mu*)^2/(v + tau^2) = k - 1, by uniroot to 1e-14 (0 when Q(0) <= k - 1).",
321 "Relative tolerance 1e-8: tau^2 and the Q-profile limits are iterative roots in both implementations."))
Below minimum: One retained response is below the sample-variance minimum.
Case STAT-HYP-MINIMUM-BASIC-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz manual sample/design requirements
- Citation
- docs/manual/chapters/07-models-and-tests.tex; 16, 31-34 and 62 feature chapters.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_minimum.R · sha256 26fd44b917263966
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
method= "one_variance_chi_square"null_variance= 1response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One retained response is below the sample-variance minimum.
- No estimator is defined below the minimum; the request must fail explicitly.
Reference code
Below minimum: One response in each group is below the Welch TOST minimum.
Case STAT-HYP-MINIMUM-EQUIV-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz manual sample/design requirements
- Citation
- docs/manual/chapters/07-models-and-tests.tex; 16, 31-34 and 62 feature chapters.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_minimum.R · sha256 26fd44b917263966
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"lower_bound= -2response_column= "x"upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One response in each group is below the Welch TOST minimum.
- No estimator is defined below the minimum; the request must fail explicitly.
Reference code
Below minimum: One retained response is below the one-sample TOST minimum.
Case STAT-HYP-MINIMUM-EQUIVEXT-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz manual sample/design requirements
- Citation
- docs/manual/chapters/07-models-and-tests.tex; 16, 31-34 and 62 feature chapters.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_minimum.R · sha256 26fd44b917263966
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
lower_bound= -2mode= "one_sample_difference"response_column= "x"target= 0upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One retained response is below the one-sample TOST minimum.
- No estimator is defined below the minimum; the request must fail explicitly.
Reference code
Below minimum: One response per group is below the independent permutation minimum.
Case STAT-HYP-MINIMUM-PERM-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz manual sample/design requirements
- Citation
- docs/manual/chapters/07-models-and-tests.tex; 16, 31-34 and 62 feature chapters.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_minimum.R · sha256 26fd44b917263966
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"inference= "exact"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One response per group is below the independent permutation minimum.
- No estimator is defined below the minimum; the request must fail explicitly.
Reference code
Below minimum: Prospective t power needs at least two planned observations.
Case STAT-HYP-MINIMUM-POWER-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz manual sample/design requirements
- Citation
- docs/manual/chapters/07-models-and-tests.tex; 16, 31-34 and 62 feature chapters.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_minimum.R · sha256 26fd44b917263966
- Dataset
- None
Settings compared
analysis= "one_sample_t"sample_size= 1solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Prospective t power needs at least two planned observations.
- No estimator is defined below the minimum; the request must fail explicitly.
Reference code
Below minimum: One retained response cannot populate both runs categories.
Case STAT-HYP-MINIMUM-RANK-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz manual sample/design requirements
- Citation
- docs/manual/chapters/07-models-and-tests.tex; 16, 31-34 and 62 feature chapters.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_minimum.R · sha256 26fd44b917263966
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
method= "runs"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One retained response cannot populate both runs categories.
- No estimator is defined below the minimum; the request must fail explicitly.
Reference code
Below minimum: One remaining response is below the one-sample t minimum.
Case STAT-HYP-MINIMUM-TEST-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Tabelz manual sample/design requirements
- Citation
- docs/manual/chapters/07-models-and-tests.tex; 16, 31-34 and 62 feature chapters.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0, stats 4.6.1
- Reference script
- generators/r/hypothesis_minimum.R · sha256 26fd44b917263966
- Dataset
- reference_data/datasets/HYP_TINY.json
Settings compared
response= "x"test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One remaining response is below the one-sample t minimum.
- No estimator is defined below the minimum; the request must fail explicitly.
Reference code
Missing and excluded population: STAT-HYP-MISSING-BASIC-001
Case STAT-HYP-MISSING-BASIC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, binom.test; complete-case population calculated in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_population.R · sha256 4ad84083bcd91622
- Dataset
- reference_data/datasets/HYP_MISSING.json
Settings compared
known_sigma= 2method= "known_sigma_z"null_mean= 6response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 2.3652619909249557 | 2.3652619909249557 | 3.97E-18 | 17 | passed |
/p_value | tail_probability | 0.01801732010292318 | 0.01801732010292318 | 2.58E-19 | 16 | passed |
/sample_size | exact | 14 | 14 | 0.00E+2 | passed |
Convention
- Known sigma 2; incomplete response removed.
- Exclude source row 0, then drop missing cells only in selected roles.
Reference code
The lines of the reference script that produce this case's expected values.
83 z <- (mean(x) - 6) / (2 / sqrt(length(x)))
84 emit("STAT-HYP-MISSING-BASIC-001", "tabelz.executor.additional_basic_tests",
85 "additionalBasicTestsMenuItem",
86 list(method = "known_sigma_z", response_column = "x", known_sigma = 2, null_mean = 6),
87 list("/statistic" = tol(z, "known-sigma Z"),
88 "/p_value" = prob(2 * stats::pnorm(-abs(z)), "normal tail"),
89 "/sample_size" = exact(length(x), "Finite responses.")),
90 list("Known sigma 2; incomplete response removed."))
Missing and excluded population: STAT-HYP-MISSING-EQUIV-001
Case STAT-HYP-MISSING-EQUIV-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, binom.test; complete-case population calculated in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_population.R · sha256 4ad84083bcd91622
- Dataset
- reference_data/datasets/HYP_MISSING.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"lower_bound= -3response_column= "x"upper_bound= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/difference_a_minus_b | tolerance | -0.85999999999999943 | -0.8600000000000003 | 8.90E-16 | 14 | passed |
/p_lower | tail_probability | 0.01614109743074028 | 0.01614109743074031 | 3.16E-17 | 14 | passed |
/analyzed_count | exact | 13 | 13 | 0.00E+2 | passed |
Convention
- Welch two-sample TOST, complete x/group rows.
- Exclude source row 0, then drop missing cells only in selected roles.
Reference code
The lines of the reference script that produce this case's expected values.
55 grouped <- included[is.finite(included$x) & !is.na(included$g), , drop = FALSE]
56 a <- grouped$x[grouped$g == "A"]
57 b <- grouped$x[grouped$g == "B"]
58 delta <- mean(a) - mean(b)
59 va <- var(a) / length(a)
60 vb <- var(b) / length(b)
61 se <- sqrt(va + vb)
62 df <- (va + vb)^2 / (va^2 / (length(a) - 1) + vb^2 / (length(b) - 1))
63 emit("STAT-HYP-MISSING-EQUIV-001", "tabelz.executor.equivalence", "equivalenceMenuItem",
64 list(response_column = "x", group_column = "g", group_a = "A", group_b = "B",
65 lower_bound = -3, upper_bound = 3),
66 list("/difference_a_minus_b" = tol(delta, "A-B mean"),
67 "/p_lower" = prob(stats::pt((delta + 3) / se, df, lower.tail = FALSE), "lower TOST"),
68 "/analyzed_count" = exact(nrow(grouped), "Complete x/group rows.")),
69 list("Welch two-sample TOST, complete x/group rows."))
Missing and excluded population: STAT-HYP-MISSING-EQUIVEXT-001
Case STAT-HYP-MISSING-EQUIVEXT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, binom.test; complete-case population calculated in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_population.R · sha256 4ad84083bcd91622
- Dataset
- reference_data/datasets/HYP_MISSING.json
Settings compared
lower_bound= -2mode= "one_sample_difference"response_column= "x"target= 6upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 1.2642857142857145 | 1.2642857142857145 | 4.30E-17 | 16 | passed |
/p_lower | tail_probability | 1.5495157642539877e-06 | 1.5495157642539961e-06 | 8.42E-21 | 14 | passed |
/analyzed_count | exact | 14 | 14 | 0.00E+2 | passed |
Convention
- One-sample difference TOST on finite x after exclusion.
- Exclude source row 0, then drop missing cells only in selected roles.
Reference code
The lines of the reference script that produce this case's expected values.
71 effect <- mean(x - 6)
72 se_one <- sd(x) / sqrt(length(x))
73 emit("STAT-HYP-MISSING-EQUIVEXT-001", "tabelz.executor.equivalence_extensions",
74 "equivalenceMenuItem",
75 list(mode = "one_sample_difference", response_column = "x", target = 6,
76 lower_bound = -2, upper_bound = 2),
77 list("/estimate" = tol(effect, "mean(x-6)"),
78 "/p_lower" = prob(stats::pt((effect + 2) / se_one, length(x) - 1,
79 lower.tail = FALSE), "lower one-sample TOST"),
80 "/analyzed_count" = exact(length(x), "Complete response count.")),
81 list("One-sample difference TOST on finite x after exclusion."))
Missing and excluded population: STAT-HYP-MISSING-PERM-001
Case STAT-HYP-MISSING-PERM-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, binom.test; complete-case population calculated in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_population.R · sha256 4ad84083bcd91622
- Dataset
- reference_data/datasets/HYP_MISSING.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"inference= "exact"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -0.85999999999999943 | -0.8600000000000003 | 8.90E-16 | 14 | passed |
/p_value | tail_probability | 0.38383838383838381 | 0.3838383838383838 | 2.03E-18 | 17 | passed |
/analyzed_count | exact | 13 | 13 | 0.00E+2 | passed |
Convention
- All choose(n,nA) complete-case assignments enumerated.
- Exclude source row 0, then drop missing cells only in selected roles.
Reference code
The lines of the reference script that produce this case's expected values.
92 assignments <- utils::combn(seq_len(nrow(grouped)), length(a))
93 pooled <- grouped$x
94 sum_a <- colSums(matrix(pooled[assignments], nrow = length(a)))
95 null <- sum_a / length(a) - (sum(pooled) - sum_a) / length(b)
96 p_perm <- mean(abs(null) >= abs(delta) - 1e-12)
97 emit("STAT-HYP-MISSING-PERM-001", "tabelz.executor.permutation_tests",
98 "permutationTestsMenuItem",
99 list(mode = "independent", response_column = "x", group_column = "g",
100 group_a = "A", group_b = "B", inference = "exact"),
101 list("/statistic" = tol(delta, "included A-B mean"),
102 "/p_value" = prob(p_perm, "all complete-case label assignments"),
103 "/analyzed_count" = exact(nrow(grouped), "Complete x/group rows.")),
104 list("All choose(n,nA) complete-case assignments enumerated."))
Missing and excluded population: STAT-HYP-MISSING-RANK-001
Case STAT-HYP-MISSING-RANK-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, binom.test; complete-case population calculated in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_population.R · sha256 4ad84083bcd91622
- Dataset
- reference_data/datasets/HYP_MISSING.json
Settings compared
inference= "asymptotic"method= "runs"reference_mode= "median"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Chapter 32 and the issue #12 ruling: a missing value in the retained runs sequence is refused, not dropped.
- Until 2026-09-25 this case expected the missing value to be dropped and the neighbours joined.
- Exclude source row 0, then drop missing cells only in selected roles.
Reference code
The lines of the reference script that produce this case's expected values.
109 stopifnot(any(!is.finite(included$x)))
110 emit("STAT-HYP-MISSING-RANK-001", "tabelz.executor.blocked_rank_tests",
111 "blockedRankTestsMenuItem",
112 list(method = "runs", response_column = "x", reference_mode = "median",
113 inference = "asymptotic"),
114 structure(list(), names = character()),
115 list("Chapter 32 and the issue #12 ruling: a missing value in the retained runs sequence is refused, not dropped.",
116 "Until 2026-09-25 this case expected the missing value to be dropped and the neighbours joined."),
117 error = list(error_class = "BlockedRankTestsExecutionError",
118 message_contains = "missing or non-finite required values"))
Missing and excluded population: STAT-HYP-MISSING-TEST-001
Case STAT-HYP-MISSING-TEST-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R stats package help: t.test, pnorm, ptukey, binom.test; complete-case population calculated in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_population.R · sha256 4ad84083bcd91622
- Dataset
- reference_data/datasets/HYP_MISSING.json
Settings compared
response= "x"target= 6test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 3.0070519456860207 | 3.007051945686018 | 2.62E-15 | 15 | passed |
/p_value | tail_probability | 0.010100976986853593 | 0.01010097698685366 | 6.76E-17 | 14 | passed |
/sample_count | exact | 14 | 14 | 0.00E+2 | passed | |
/dropped_rows | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- One-sample response x; R t.test removes the single missing response in included rows.
- Exclude source row 0, then drop missing cells only in selected roles.
Reference code
The lines of the reference script that produce this case's expected values.
45 x <- included$x[is.finite(included$x)]
46 t <- stats::t.test(x, mu = 6)
47 emit("STAT-HYP-MISSING-TEST-001", "tabelz.analysis.hypothesis_tests:run_hypothesis_test",
48 "hypothesisTestsMenuItem", list(test = "one_sample_t", response = "x", target = 6),
49 list("/statistic" = tol(t$statistic, "one-sample t"),
50 "/p_value" = prob(t$p.value, "Student t tail"),
51 "/sample_count" = exact(length(x), "Finite selected responses after exclusion."),
52 "/dropped_rows" = exact(nrow(included) - length(x), "Missing selected response.")),
53 list("One-sample response x; R t.test removes the single missing response in included rows."))
Mood median with ties below
Case STAT-HYP-MOOD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"response= "x"test= "moods_median"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.31731050786291415 | 0.31731050786291115 | 3.00E-15 | 14 | passed |
/estimate | tolerance | 6.75 | 6.75 | 0.00E+0 | passed |
Convention
- Values equal to the pooled median count in the below cell; no Yates correction.
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
97 grand_median <- stats::median(d$x)
98 below <- d$x <= grand_median
99 mood <- stats::chisq.test(table(d$g, below), correct = FALSE)
100 emit("STAT-HYP-MOOD-001", "Mood median with ties below",
101 list(test = "moods_median", response = "x", group = "g"),
102 list("/statistic" = tol(mood$statistic, "median contingency chi-square"),
103 "/p_value" = prob(mood$p.value, "median chi-square tail"),
104 "/estimate" = tol(grand_median, "grand median")),
105 list("Values equal to the pooled median count in the below cell; no Yates correction."))
Additional configuration coverage: STAT-HYP-NOMINAL-BASIC-GREATER-001
Case STAT-HYP-NOMINAL-BASIC-GREATER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats/multcomp
- Citation
- R stats::pnorm, pt, qt, binom.test, power.t.test; multcomp::glht and mvtnorm documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_completion.R · sha256 733ecb7b7daec34d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1alternative= "greater"confidence_level= 0.9known_sigma= 2max_rows= 100method= "known_sigma_z"null_mean= 6response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.625 | 1.625 | 0.00E-1 | passed | |
/p_value | tail_probability | 0.052081279415219561 | 0.05208127941521953 | 3.44E-17 | 15 | passed |
Convention
- Directional known-sigma normal tail; confidence level equals 1-alpha.
- Data-derived values use the exported CSV.
Reference code
Additional configuration coverage: STAT-HYP-NOMINAL-BASIC-LESS-001
Case STAT-HYP-NOMINAL-BASIC-LESS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats/multcomp
- Citation
- R stats::pnorm, pt, qt, binom.test, power.t.test; multcomp::glht and mvtnorm documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_completion.R · sha256 733ecb7b7daec34d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1alternative= "less"confidence_level= 0.9known_sigma= 2max_rows= 100method= "known_sigma_z"null_mean= 6response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.625 | 1.625 | 0.00E-1 | passed | |
/p_value | tail_probability | 0.94791872058478044 | 0.9479187205847804 | 1.28E-18 | 17 | passed |
Convention
- Directional known-sigma normal tail; confidence level equals 1-alpha.
- Data-derived values use the exported CSV.
Reference code
Additional configuration coverage: STAT-HYP-NOMINAL-RANK-RUNS-001
Case STAT-HYP-NOMINAL-RANK-RUNS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats/multcomp
- Citation
- R stats::pnorm, pt, qt, binom.test, power.t.test; multcomp::glht and mvtnorm documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_completion.R · sha256 733ecb7b7daec34d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "two-sided"inference= "asymptotic"max_exact_n= 20method= "runs"reference_mode= "median"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/runs | exact | 4 | 4 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.0096606229974849512 | 0.00966062299748495 | 1.74E-18 | 15 | passed |
Convention
- Observed median, asymptotic normal runs test without continuity correction.
- Data-derived values use the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
58 reference <- stats::median(d$x)
59 sequence <- d$x > reference
60 sequence <- sequence[d$x != reference]
61 runs <- 1L + sum(sequence[-1] != sequence[-length(sequence)])
62 n1 <- sum(sequence)
63 n2 <- length(sequence) - n1
64 expected <- 1 + 2 * n1 * n2 / length(sequence)
65 variance <- 2 * n1 * n2 * (2 * n1 * n2 - length(sequence)) /
66 (length(sequence)^2 * (length(sequence) - 1))
67 p_runs <- 2 * stats::pnorm(-abs((runs - expected) / sqrt(variance)))
68 emit("STAT-HYP-NOMINAL-RANK-RUNS-001", "tabelz.executor.blocked_rank_tests",
69 "blockedRankTestsMenuItem", "HYP_CORE",
70 list(method = "runs", response_column = "x", reference_mode = "median",
71 inference = "asymptotic", alternative = "two-sided", max_exact_n = 20L),
72 list("/runs" = exact(as.integer(runs), "Observed runs in row order."),
73 "/p_value" = prob(p_runs, "no-continuity-correction normal tail")),
74 "nominal", list("Observed median, asymptotic normal runs test without continuity correction."))
Additional configuration coverage: STAT-HYP-NUMERIC-EQUIV-001
Case STAT-HYP-NUMERIC-EQUIV-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats/multcomp
- Citation
- R stats::pnorm, pt, qt, binom.test, power.t.test; multcomp::glht and mvtnorm documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_completion.R · sha256 733ecb7b7daec34d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1group_a= "A"group_b= "B"group_column= "g"lower_bound= -3max_cells= 1000max_rows= 100response_column= "x"upper_bound= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/difference_a_minus_b | tolerance | -1.5749999999999993 | -1.5750000000000002 | 8.78E-16 | 15 | passed |
/p_lower | tail_probability | 0.068539258692386876 | 0.06853925869238707 | 1.94E-16 | 14 | passed |
Convention
- Non-default alpha and bounded source/cell limits do not alter Welch estimators.
- Data-derived values use the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
77 a <- d$x[d$g == "A"]
78 bb <- d$x[d$g == "B"]
79 effect <- mean(a) - mean(bb)
80 va <- var(a) / length(a)
81 vb <- var(bb) / length(bb)
82 se <- sqrt(va + vb)
83 df <- (va + vb)^2 / (va^2 / (length(a) - 1) + vb^2 / (length(bb) - 1))
84 emit("STAT-HYP-NUMERIC-EQUIV-001", "tabelz.executor.equivalence", "equivalenceMenuItem",
85 "HYP_CORE",
86 list(response_column = "x", group_column = "g", group_a = "A", group_b = "B",
87 lower_bound = -3, upper_bound = 3, max_rows = 100L, max_cells = 1000L,
88 alpha = 0.1),
89 list("/difference_a_minus_b" = tol(effect, "A-B mean"),
90 "/p_lower" = prob(stats::pt((effect + 3) / se, df, lower.tail = FALSE), "Welch lower TOST")),
91 "axis_coverage", list("Non-default alpha and bounded source/cell limits do not alter Welch estimators."))
Additional configuration coverage: STAT-HYP-NUMERIC-EQUIVEXT-001
Case STAT-HYP-NUMERIC-EQUIVEXT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats/multcomp
- Citation
- R stats::pnorm, pt, qt, binom.test, power.t.test; multcomp::glht and mvtnorm documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_completion.R · sha256 733ecb7b7daec34d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1lower_bound= -2max_cells= 1000max_rows= 100mode= "one_sample_difference"response_column= "x"target= 6upper_bound= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/estimate | tolerance | 0.81250000000000011 | 0.8125000000000002 | 1.12E-16 | 15 | passed |
/p_lower | tail_probability | 1.6227244268166216e-05 | 1.6227244268166257e-05 | 4.08E-20 | 14 | passed |
Convention
- Non-default alpha and bounded source/cell limits do not alter one-sample estimators.
- Data-derived values use the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
93 delta <- d$x - 6
94 one_effect <- mean(delta)
95 one_se <- sd(delta) / sqrt(length(delta))
96 emit("STAT-HYP-NUMERIC-EQUIVEXT-001", "tabelz.executor.equivalence_extensions",
97 "equivalenceMenuItem", "HYP_CORE",
98 list(mode = "one_sample_difference", response_column = "x", target = 6,
99 lower_bound = -2, upper_bound = 2, max_rows = 100L, max_cells = 1000L,
100 alpha = 0.1),
101 list("/estimate" = tol(one_effect, "mean-target effect"),
102 "/p_lower" = prob(stats::pt((one_effect + 2) / one_se, length(delta) - 1,
103 lower.tail = FALSE), "one-sample lower TOST")),
104 "axis_coverage", list("Non-default alpha and bounded source/cell limits do not alter one-sample estimators."))
Additional configuration coverage: STAT-HYP-NUMERIC-POWER-TARGET-001
Case STAT-HYP-NUMERIC-POWER-TARGET-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats/multcomp
- Citation
- R stats::pnorm, pt, qt, binom.test, power.t.test; multcomp::glht and mvtnorm documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_completion.R · sha256 733ecb7b7daec34d
- Dataset
- None
Settings compared
analysis= "one_sample_t"effect_size= 0.5solve_for= "sample_size"target_power= 0.85
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | exact | 38 | 38 | 0.00E+2 | passed |
Convention
- Target power 0.85 is non-default; strict two-sided noncentral t solution.
- Data-derived values use the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
153 target <- 0.85
154 required <- stats::power.t.test(power = target, delta = 0.5, sd = 1,
155 sig.level = 0.05, type = "one.sample",
156 alternative = "two.sided", strict = TRUE)
157 emit("STAT-HYP-NUMERIC-POWER-TARGET-001",
158 "tabelz.analysis.hypothesis_tests:run_power_analysis", "hypothesisTestsMenuItem",
159 NULL,
160 list(analysis = "one_sample_t", solve_for = "sample_size", effect_size = 0.5,
161 target_power = target),
162 list("/value" = exact(as.integer(ceiling(required$n)), "Round R solved n upward.")),
163 "axis_coverage", list("Target power 0.85 is non-default; strict two-sided noncentral t solution."))
One-way classic ANOVA
Case STAT-HYP-ONE-ANOVA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "classic"posthoc= falseresponse= "x"test= "one_way_anova"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 3.0387181450289869 | 3.0387181450289837 | 3.16E-15 | 14 | passed |
/p_value | tail_probability | 0.10320961287583313 | 0.10320961287583322 | 8.76E-17 | 15 | passed |
Convention
- Classic fixed-effects one-way ANOVA; posthoc disabled.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
The lines of the reference script that produce this case's expected values.
124 anova <- stats::aov(x ~ g, data = d)
125 anova_row <- summary(anova)[[1]][1, ]
126 emit("STAT-HYP-ONE-ANOVA-001", "One-way classic ANOVA", "nominal",
127 list(test = "one_way_anova", response = "x", group = "g", method = "classic", posthoc = FALSE),
128 list("/statistic" = tol(anova_row[["F value"]], "one-way ANOVA F"),
129 "/p_value" = prob(anova_row[["Pr(>F)"]], "one-way ANOVA F tail")),
130 list("Classic fixed-effects one-way ANOVA; posthoc disabled."))
Welch one-way ANOVA
Case STAT-HYP-ONE-ANOVA-WELCH-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "welch"posthoc= falseresponse= "x"test= "one_way_anova"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 3.0387181450289811 | 3.0387181450289837 | 2.64E-15 | 15 | passed |
/p_value | tail_probability | 0.10321046049139604 | 0.1032104604913958 | 2.37E-16 | 14 | passed |
/df2 | tolerance | 13.999455894108474 | 13.999455894108475 | 1.46E-15 | 15 | passed |
Convention
- R oneway.test uses unequal-variance Welch correction.
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
37 welch_aov <- stats::oneway.test(x ~ g, data = d, var.equal = FALSE)
38 emit("STAT-HYP-ONE-ANOVA-WELCH-001", "Welch one-way ANOVA",
39 list(test = "one_way_anova", response = "x", group = "g", method = "welch", posthoc = FALSE),
40 list("/statistic" = tol(welch_aov$statistic, "Welch ANOVA F"),
41 "/p_value" = prob(welch_aov$p.value, "Welch ANOVA F tail"),
42 "/df2" = tol(welch_aov$parameter[[2]], "Welch denominator df")),
43 list("R oneway.test uses unequal-variance Welch correction."))
Exact one-proportion test
Case STAT-HYP-ONE-PROP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
response= "outcome"success_value= "yes"target= 0.4test= "one_proportion"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.4505040316334078 | 0.4505040316334081 | 2.75E-16 | 15 | passed |
/estimate | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/ci_lower | tolerance | 0.24651011149057533 | 0.2465101114905753 | 2.34E-17 | 16 | passed |
/ci_upper | tolerance | 0.75348988850942467 | 0.7534898885094247 | 4.34E-18 | 17 | passed |
Convention
- binom.test exact two-sided p and Clopper-Pearson interval.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
The lines of the reference script that produce this case's expected values.
104 binomial <- stats::binom.test(sum(d$outcome == "yes"), length(d$outcome), p = 0.4)
105 emit("STAT-HYP-ONE-PROP-001", "Exact one-proportion test", "nominal",
106 list(test = "one_proportion", response = "outcome", success_value = "yes", target = 0.4),
107 list("/statistic" = tol(sum(d$outcome == "yes"), "success count"),
108 "/p_value" = prob(binomial$p.value, "binomial exact"),
109 "/estimate" = tol(unname(binomial$estimate), "success proportion"),
110 "/ci_lower" = tol(binomial$conf.int[[1]], "Clopper-Pearson lower"),
111 "/ci_upper" = tol(binomial$conf.int[[2]], "Clopper-Pearson upper")),
112 list("binom.test exact two-sided p and Clopper-Pearson interval."))
One-sample t two-sided
Case STAT-HYP-ONE-T-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "two-sided"response= "x"target= 6.2test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.2721195011330044 | 1.272119501133006 | 1.58E-15 | 14 | passed |
/p_value | tail_probability | 0.2226990019491252 | 0.2226990019491247 | 4.97E-16 | 14 | passed |
/estimate | tolerance | 0.61249999999999982 | 0.6125000000000007 | 8.91E-16 | 14 | passed |
/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/ci_lower | tolerance | -0.41375016399215347 | -0.41375016399215303 | 4.39E-16 | 14 | passed |
/ci_upper | tolerance | 1.6387501639921531 | 1.6387501639921545 | 1.35E-15 | 15 | passed |
Convention
- t.test one-sample; response minus target; directional CI follows the alternative.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reproduce it yourself
- Data: data.csv, the rows as analysed.
- R: run the script below; it prints every compared value with its output path.
- HypoNum: follow the steps below and read the same values from the result window.
R script
# One-sample t test against a target mean. Base R only; tested with R 4.6.1.
report <- function(path, x) cat(path, "=", if (is.numeric(x)) sprintf("%.17g", x) else as.character(x), "\n")
d <- read.csv("data.csv") # column x (thickness)
target <- 6.2
fit <- t.test(d$x, mu = target) # two-sided, 95 % interval
report("/estimate", mean(d$x) - target) # mean difference from target
report("/statistic", fit$statistic)
report("/df", fit$parameter)
report("/p_value", fit$p.value)
report("/ci_lower", fit$conf.int[1] - target) # interval for the difference
report("/ci_upper", fit$conf.int[2] - target)
HypoNum
- File > Import data, select
data.csv, click Import. - Statistics > Compare means & ANOVA > Hypothesis tests.
- Test: One-sample t-test. Response: x. Target: 6.2. Click Run test.
Read the mean difference from target, its 95 % interval, t, the degrees of freedom and the p-value from the result window.
Reference code
One-sample t less
Case STAT-HYP-ONE-T-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "less"response= "x"target= 6.2test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.2721195011330044 | 1.272119501133006 | 1.58E-15 | 14 | passed |
/p_value | tail_probability | 0.88865049902543736 | 0.8886504990254377 | 3.30E-16 | 15 | passed |
/estimate | tolerance | 0.61249999999999982 | 0.6125000000000007 | 8.91E-16 | 14 | passed |
/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/ci_upper | tolerance | 1.4565585510287189 | 1.4565585510287196 | 6.61E-16 | 15 | passed |
Convention
- t.test one-sample; response minus target; directional CI follows the alternative.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
One-sample t greater
Case STAT-HYP-ONE-T-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alternative= "greater"response= "x"target= 6.2test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.2721195011330044 | 1.272119501133006 | 1.58E-15 | 14 | passed |
/p_value | tail_probability | 0.1113495009745626 | 0.11134950097456235 | 2.48E-16 | 14 | passed |
/estimate | tolerance | 0.61249999999999982 | 0.6125000000000007 | 8.91E-16 | 14 | passed |
/df | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/ci_lower | tolerance | -0.23155855102871925 | -0.23155855102871814 | 1.11E-15 | 14 | passed |
Convention
- t.test one-sample; response minus target; directional CI follows the alternative.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
R sleep group 1 one-sample t-test against zero
Case STAT-HYP-ONESAMPLE-T-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::t.test
- Citation
- Cushny AR, Peebles AR (1905). The Action of Optical Isomers: II. Hyoscines. The Journal of Physiology 32(5-6), 501-510. doi:10.1113/jphysiol.1905.sp001097
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/smoke.R · sha256 3c019e985f24b0aa
- Dataset
- reference_data/datasets/SLEEP.json
Settings compared
response= "extra"target= 0test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1.3257101407138212 | 1.3257101407138212 | 5.69E-18 | 17 | passed |
/df | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.2175977800684489 | 0.21759778006844888 | 2.39E-17 | 15 | passed |
/ci_lower | tolerance | -0.52978041352623217 | -0.5297804135262318 | 3.29E-16 | 15 | passed |
/ci_upper | tolerance | 2.0297804135262321 | 2.0297804135262316 | 4.81E-16 | 15 | passed |
Convention
- Use only group 1's extra; exclude zero-based dataset rows 10 through 19.
- Two-sided Student one-sample t-test, mu=0, 95% confidence interval.
- Expected values computed from the exported CSV, not R's in-memory sleep object.
Reference code
The lines of the reference script that produce this case's expected values.
3 data("sleep", package = "datasets")
4 citation <- paste(
5 "Cushny AR, Peebles AR (1905). The Action of Optical Isomers: II. Hyoscines.",
6 "The Journal of Physiology 32(5-6), 501-510. doi:10.1113/jphysiol.1905.sp001097"
7 )
8 dataset <- data.frame(extra = as.double(sleep$extra), group = as.character(sleep$group))
9 export_dataset(
10 dataset, "SLEEP", "R 4.6.1 datasets::sleep", citation,
11 "Published data distributed with R; retain the citation.",
12 c(extra = "Float64", group = "String")
13 )
14 reloaded <- read_dataset("SLEEP")
15 group_one <- reloaded$extra[reloaded$group == "1"]
16 reference <- stats::t.test(group_one, mu = 0, alternative = "two.sided", conf.level = 0.95)
17 case_id <- "STAT-HYP-ONESAMPLE-T-001"
Paired differences
Case STAT-HYP-PAIRED-T-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
response= "x"second_response= "y"test= "paired_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 13.821640128763882 | 13.821640128763867 | 1.45E-14 | 14 | passed |
/p_value | tail_probability | 6.1259435838448321e-10 | 6.125943583844918e-10 | 8.58E-24 | 13 | passed |
/estimate | tolerance | 0.56250000000000022 | 0.5625000000000002 | 2.04E-18 | 17 | passed |
Convention
- Pair rows by exported CSV order; difference is x minus y.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reproduce it yourself
- Data: data.csv, the rows as analysed.
- R: run the script below; it prints every compared value with its output path.
- HypoNum: follow the steps below and read the same values from the result window.
R script
# Paired t test. Base R only; tested with R 4.6.1.
report <- function(path, x) cat(path, "=", if (is.numeric(x)) sprintf("%.17g", x) else as.character(x), "\n")
d <- read.csv("data.csv") # columns x and y, one pair per row
fit <- t.test(d$x, d$y, paired = TRUE) # two-sided
report("/estimate", mean(d$x - d$y)) # mean of the x - y differences
report("/statistic", fit$statistic)
report("/p_value", fit$p.value)
HypoNum
- File > Import data, select
data.csv, click Import. - Statistics > Compare means & ANOVA > Hypothesis tests.
- Test: Paired t-test. Response: x. Paired response: y. Click Run test.
Read the mean difference, t and the p-value from the result window.
Reference code
The lines of the reference script that produce this case's expected values.
96 paired <- stats::t.test(d$x, d$y, paired = TRUE)
97 emit("STAT-HYP-PAIRED-T-001", "Paired differences", "nominal",
98 list(test = "paired_t", response = "x", second_response = "y"),
99 list("/statistic" = tol(paired$statistic, "paired t"),
100 "/p_value" = prob(paired$p.value, "paired t"),
101 "/estimate" = tol(mean(d$x - d$y), "paired mean difference")),
102 list("Pair rows by exported CSV order; difference is x minus y."))
Exact independent mean permutation
Case STAT-HYP-PERM-EXACT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 independent implementation
- Citation
- R utils::combn documentation; exact finite-label randomization enumeration.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_secondary.R · sha256 13b3dbafe11fd4e1
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group_a= "A"group_b= "B"group_column= "g"inference= "exact"mode= "independent"response_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -1.5749999999999993 | -1.5750000000000002 | 8.78E-16 | 15 | passed |
/p_value | tail_probability | 0.1066045066045066 | 0.1066045066045066 | 7.90E-19 | 17 | passed |
/assignment_count | exact | 12870 | 12870 | 0.00E+2 | passed |
Convention
- combn enumerates every allocation of 8 labels to 16 values; two-sided absolute statistic.
- Expected values calculated after re-reading the exported CSV where data are present.
Reference code
The lines of the reference script that produce this case's expected values.
119 pooled <- d$x
120 n_a <- length(a)
121 observed <- diff
122 all_a <- utils::combn(seq_along(pooled), n_a)
123 total_sum <- sum(pooled)
124 assigned_a <- colSums(matrix(pooled[all_a], nrow = n_a))
125 null <- assigned_a / n_a - (total_sum - assigned_a) / (length(pooled) - n_a)
126 p_exact <- mean(abs(null) >= abs(observed) - 1e-12)
127 emit("STAT-HYP-PERM-EXACT-001", "tabelz.executor.permutation_tests", "permutationTestsMenuItem",
128 "Exact independent mean permutation", "nominal", "HYP_CORE",
129 list(mode = "independent", response_column = "x", group_column = "g",
130 group_a = "A", group_b = "B", inference = "exact"),
131 list("/statistic" = tol(observed, "observed A-B mean"),
132 "/p_value" = prob(p_exact, "all choose(16,8) assignments"),
133 "/assignment_count" = exact(ncol(all_a), "All independent assignments enumerated.")),
134 list("combn enumerates every allocation of 8 labels to 16 values; two-sided absolute statistic."),
135 "R utils::combn documentation; exact finite-label randomization enumeration.")
Prospective power axis: STAT-HYP-POWER-ALT-GREATER-001
Case STAT-HYP-POWER-ALT-GREATER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test and pwr::pwr.chisq.test / pwr.2p2n.test / pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_power_axes.R · sha256 3116c4f725f974d6
- Dataset
- None
Settings compared
alternative= "greater"analysis= "one_sample_t"effect_size= 0.5sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.848254190929147 | 0.8482541909289824 | 1.65E-13 | 12 | passed |
Convention
- Positive standardized effect magnitude; one-sided noncentral t power.
- The manual names less and greater alternatives but gives a positive effect-size input.
Reference code
Prospective power axis: STAT-HYP-POWER-ALT-LESS-001
Case STAT-HYP-POWER-ALT-LESS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test and pwr::pwr.chisq.test / pwr.2p2n.test / pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_power_axes.R · sha256 3116c4f725f974d6
- Dataset
- None
Settings compared
alternative= "less"analysis= "one_sample_t"effect_size= 0.5sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.848254190929147 | 0.8482541909289824 | 1.65E-13 | 12 | passed |
Convention
- Positive standardized effect magnitude; one-sided noncentral t power.
- The manual names less and greater alternatives but gives a positive effect-size input.
Reference code
Prospective power axis: STAT-HYP-POWER-ANOVA-001
Case STAT-HYP-POWER-ANOVA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test and pwr::pwr.chisq.test / pwr.2p2n.test / pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_power_axes.R · sha256 3116c4f725f974d6
- Dataset
- None
Settings compared
analysis= "one_way_anova"effect_size= 0.5groups= 3sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.63523984359137786 | 0.6352398434241289 | 1.67E-10 | 9 | passed |
Convention
- Cohen f=0.5, three groups with ten observations each; N=30.
Reference code
The lines of the reference script that produce this case's expected values.
85 anova <- pwr::pwr.anova.test(k = 3, n = 10, f = 0.5, sig.level = 0.05)
86 emit("STAT-HYP-POWER-ANOVA-001",
87 list(analysis = "one_way_anova", solve_for = "power", effect_size = 0.5,
88 sample_size = 30L, groups = 3L),
89 tol(anova$power, "three-group ANOVA noncentral F power"),
90 list("Cohen f=0.5, three groups with ten observations each; N=30."))
Prospective power axis: STAT-HYP-POWER-ONE-PROP-001
Case STAT-HYP-POWER-ONE-PROP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test and pwr::pwr.chisq.test / pwr.2p2n.test / pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_power_axes.R · sha256 3116c4f725f974d6
- Dataset
- None
Settings compared
analysis= "one_proportion"effect_size= 0.5sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.7819079987319798 | 0.7819079987319797 | 1.08E-16 | 15 | passed |
Convention
- Cohen h=0.5 enters the one-degree chi-square approximation as w=0.5.
Reference code
The lines of the reference script that produce this case's expected values.
70 one_prop <- pwr::pwr.chisq.test(w = 0.5, N = 30, df = 1, sig.level = 0.05)
71 emit("STAT-HYP-POWER-ONE-PROP-001",
72 list(analysis = "one_proportion", solve_for = "power", effect_size = 0.5,
73 sample_size = 30L),
74 tol(one_prop$power, "one-degree chi-square power"),
75 list("Cohen h=0.5 enters the one-degree chi-square approximation as w=0.5."))
One-sample t achieved power
Case STAT-HYP-POWER-ONE-T-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 independent implementation
- Citation
- R stats::power.t.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_secondary.R · sha256 13b3dbafe11fd4e1
- Dataset
- None
Settings compared
alpha= 0.05analysis= "one_sample_t"effect_size= 0.5sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.75396471574385193 | 0.7539647157437899 | 6.21E-14 | 13 | passed |
/achieved_power | tolerance | 0.75396471574385193 | 0.7539647157437899 | 6.21E-14 | 13 | passed |
Convention
- R power.t.test uses standardized delta/sd = 0.5 and n=30.
- strict=TRUE counts both rejection tails. docs/manual/chapters/07-models-and-tests.tex:864-866: 'two-sided alternatives.'
- Expected values calculated after re-reading the exported CSV where data are present.
Reference code
The lines of the reference script that produce this case's expected values.
177 power <- stats::power.t.test(n = 30, delta = 0.5, sd = 1, sig.level = 0.05,
178 type = "one.sample", alternative = "two.sided", strict = TRUE)
179 emit("STAT-HYP-POWER-ONE-T-001", "tabelz.analysis.hypothesis_tests:run_power_analysis",
180 "hypothesisTestsMenuItem", "One-sample t achieved power", "nominal", NULL,
181 list(analysis = "one_sample_t", solve_for = "power", effect_size = 0.5,
182 sample_size = 30L, alpha = 0.05),
183 list("/value" = tol(power$power, "R noncentral-t achieved power"),
184 "/achieved_power" = tol(power$power, "R noncentral-t achieved power")),
185 list("R power.t.test uses standardized delta/sd = 0.5 and n=30.",
186 "strict=TRUE counts both rejection tails. docs/manual/chapters/07-models-and-tests.tex:864-866: 'two-sided alternatives.'"),
187 "R stats::power.t.test documentation.")
Prospective power axis: STAT-HYP-POWER-PAIRED-001
Case STAT-HYP-POWER-PAIRED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test and pwr::pwr.chisq.test / pwr.2p2n.test / pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_power_axes.R · sha256 3116c4f725f974d6
- Dataset
- None
Settings compared
analysis= "paired_t"effect_size= 0.5sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.75396471574385193 | 0.7539647157437899 | 6.21E-14 | 13 | passed |
Convention
- Cohen dz = 0.5, n is number of pairs; strict two-sided t rejection.
Reference code
The lines of the reference script that produce this case's expected values.
49 pair <- stats::power.t.test(n = 30, delta = 0.5, sd = 1, sig.level = 0.05,
50 type = "paired", alternative = "two.sided", strict = TRUE)
51 emit("STAT-HYP-POWER-PAIRED-001",
52 list(analysis = "paired_t", solve_for = "power", effect_size = 0.5, sample_size = 30L),
53 tol(pair$power, "paired t power for 30 pairs"),
54 list("Cohen dz = 0.5, n is number of pairs; strict two-sided t rejection."))
Prospective power axis: STAT-HYP-POWER-SAMPLE-SIZE-001
Case STAT-HYP-POWER-SAMPLE-SIZE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test and pwr::pwr.chisq.test / pwr.2p2n.test / pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_power_axes.R · sha256 3116c4f725f974d6
- Dataset
- None
Settings compared
alpha= 0.05analysis= "one_sample_t"effect_size= 0.5solve_for= "sample_size"target_power= 0.8
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | exact | 34 | 34 | 0.00E+2 | passed |
Convention
- R power.t.test strict=TRUE includes both two-sided rejection tails; round solved n upward.
Reference code
The lines of the reference script that produce this case's expected values.
30 sample <- stats::power.t.test(power = 0.8, delta = 0.5, sd = 1, sig.level = 0.05,
31 type = "one.sample", alternative = "two.sided", strict = TRUE)
32 emit("STAT-HYP-POWER-SAMPLE-SIZE-001",
33 list(analysis = "one_sample_t", solve_for = "sample_size", effect_size = 0.5,
34 target_power = 0.8, alpha = 0.05),
35 exact(ceiling(sample$n), "Smallest integer n meeting target power from R noncentral t."),
36 list("R power.t.test strict=TRUE includes both two-sided rejection tails; round solved n upward."))
Prospective power axis: STAT-HYP-POWER-TWO-PROP-001
Case STAT-HYP-POWER-TWO-PROP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test and pwr::pwr.chisq.test / pwr.2p2n.test / pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_power_axes.R · sha256 3116c4f725f974d6
- Dataset
- None
Settings compared
analysis= "two_proportion"effect_size= 0.5ratio= 1sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.49068556766996918 | 0.4906855676699689 | 2.77E-16 | 15 | passed |
Convention
- Cohen h=0.5 and 30 observations per group; two-sided normal approximation.
Reference code
The lines of the reference script that produce this case's expected values.
77 two_prop <- pwr::pwr.2p2n.test(h = 0.5, n1 = 30, n2 = 30, sig.level = 0.05,
78 alternative = "two.sided")
79 emit("STAT-HYP-POWER-TWO-PROP-001",
80 list(analysis = "two_proportion", solve_for = "power", effect_size = 0.5,
81 sample_size = 30L, ratio = 1),
82 tol(two_prop$power, "two-independent-proportion normal power"),
83 list("Cohen h=0.5 and 30 observations per group; two-sided normal approximation."))
Prospective power axis: STAT-HYP-POWER-TWO-T-001
Case STAT-HYP-POWER-TWO-T-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and pwr
- Citation
- R stats::power.t.test and pwr::pwr.chisq.test / pwr.2p2n.test / pwr.anova.test documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, pwr 1.3.0, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_power_axes.R · sha256 3116c4f725f974d6
- Dataset
- None
Settings compared
analysis= "two_sample_t"effect_size= 0.5ratio= 1.5sample_size= 30solve_for= "power"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/value | tolerance | 0.55308658349486373 | 0.5530865834946614 | 2.02E-13 | 12 | passed |
Convention
- n1=30, n2=ceil(1.5*n1)=45; df=n1+n2-2; noncentrality d/sqrt(1/n1+1/n2).
Reference code
The lines of the reference script that produce this case's expected values.
57 n1 <- 30
58 n2 <- ceiling(1.5 * n1)
59 df <- n1 + n2 - 2
60 ncp <- 0.5 / sqrt(1 / n1 + 1 / n2)
61 critical <- stats::qt(0.975, df)
62 two_t_power <- stats::pt(-critical, df, ncp = ncp) +
63 stats::pt(critical, df, ncp = ncp, lower.tail = FALSE)
64 emit("STAT-HYP-POWER-TWO-T-001",
65 list(analysis = "two_sample_t", solve_for = "power", effect_size = 0.5,
66 sample_size = n1, ratio = 1.5),
67 tol(two_t_power, "unequal-allocation independent t noncentral tail"),
68 list("n1=30, n2=ceil(1.5*n1)=45; df=n1+n2-2; noncentrality d/sqrt(1/n1+1/n2)."))
Repeated measures one within factor three levels
Case STAT-HYP-REPEATED-MEASURES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R Core Team, stats package help: aov, anova.mlm, mauchly.test, SSD, t.test; Greenhouse SW, Geisser S (1959), Psychometrika 24, 95-112; Lecoutre B (1991), Journal of Educational Statistics 16, 371-372.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_repeated_measures.R · sha256 8faee62dc29c9cba
- Dataset
- reference_data/datasets/HYP_RM.json
Settings compared
cells= ["t1", "t2", "t3"]contrast_family= "none"factor1_levels= ["t1", "t2", "t3"]factor1_name= "Time"pairwise_procedure= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sphericity/0/dimensions | exact | 2 | 2 | 0.00E+2 | passed | |
/sphericity/0/greenhouse_geisser | tolerance | 0.648791503629081 | 0.6487915036290826 | 1.56E-15 | 14 | passed |
/sphericity/0/huynh_feldt | tolerance | 0.72199678681617363 | 0.7219967868161762 | 2.55E-15 | 14 | passed |
/sphericity/0/huynh_feldt_applied | tolerance | 0.72199678681617363 | 0.7219967868161762 | 2.55E-15 | 14 | passed |
/sphericity/0/lower_bound | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/sphericity/0/mauchly_w | tolerance | 0.45867278716444532 | 0.4586727871644492 | 3.88E-15 | 14 | passed |
/sphericity/0/chi_square | tolerance | 5.4559274359622236 | 5.455927435962165 | 5.86E-14 | 13 | passed |
/sphericity/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/sphericity/0/p_value | tail_probability | 0.065352229840869316 | 0.06535222984087123 | 1.92E-15 | 13 | passed |
/within_tests/0/sum_of_squares | tolerance | 17.027407407407416 | 17.027407407407345 | 7.06E-14 | 14 | passed |
/within_tests/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/within_tests/0/mean_square | tolerance | 8.5137037037037082 | 8.513703703703673 | 3.55E-14 | 14 | passed |
/within_tests/0/f_value | tolerance | 41.966225467822859 | 41.966225467822724 | 1.35E-13 | 14 | passed |
/within_tests/0/error_sum_of_squares | tolerance | 3.2459259259259317 | 3.2459259259259285 | 3.15E-15 | 15 | passed |
/within_tests/0/error_df | exact | 16 | 16 | 0.00E+2 | passed | |
/within_tests/0/partial_eta_squared | tolerance | 0.83989184844166742 | 0.839891848441667 | 4.43E-16 | 15 | passed |
/within_tests/0/tests/0/correction | exact | Sphericity assumed | Sphericity assumed | passed | ||
/within_tests/0/tests/0/epsilon | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/within_tests/0/tests/0/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/within_tests/0/tests/0/df2 | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/within_tests/0/tests/0/p_value | tail_probability | 4.3182476875850561e-07 | 4.3182476875851525e-07 | 9.64E-21 | 13 | passed |
/within_tests/0/tests/1/correction | exact | Greenhouse-Geisser | Greenhouse-Geisser | passed | ||
/within_tests/0/tests/1/epsilon | tolerance | 0.648791503629081 | 0.6487915036290826 | 1.56E-15 | 14 | passed |
/within_tests/0/tests/1/df1 | tolerance | 1.297583007258162 | 1.297583007258165 | 3.11E-15 | 14 | passed |
/within_tests/0/tests/1/df2 | tolerance | 10.380664058065296 | 10.38066405806532 | 2.49E-14 | 14 | passed |
/within_tests/0/tests/1/p_value | tail_probability | 3.0901261916248958e-05 | 3.090126191624883e-05 | 1.29E-19 | 14 | passed |
/within_tests/0/tests/2/correction | exact | Huynh-Feldt | Huynh-Feldt | passed | ||
/within_tests/0/tests/2/epsilon | tolerance | 0.72199678681617363 | 0.7219967868161762 | 2.55E-15 | 14 | passed |
/within_tests/0/tests/2/df1 | tolerance | 1.4439935736323473 | 1.4439935736323524 | 5.07E-15 | 14 | passed |
/within_tests/0/tests/2/df2 | tolerance | 11.551948589058778 | 11.551948589058819 | 4.09E-14 | 14 | passed |
/within_tests/0/tests/2/p_value | tail_probability | 1.2628833876660175e-05 | 1.2628833876659985e-05 | 1.90E-19 | 13 | passed |
/multivariate_tests/0/statistic | exact | Pillai's trace | Pillai's trace | passed | ||
/multivariate_tests/0/value | tolerance | 0.97425023342054551 | 0.9742502334213975 | 8.52E-13 | 12 | passed |
/multivariate_tests/0/f_value | tolerance | 132.42356222726377 | 132.4235622317611 | 4.50E-9 | 10 | passed |
/multivariate_tests/0/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/0/df2 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/multivariate_tests/0/p_value | tail_probability | 2.7397222569971624e-06 | 2.7397222566798884e-06 | 3.17E-16 | 9 | passed |
/multivariate_tests/1/statistic | exact | Wilks' lambda | Wilks' lambda | passed | ||
/multivariate_tests/1/value | tolerance | 0.02574976657945878 | 0.025749766578602666 | 8.56E-13 | 10 | passed |
/multivariate_tests/1/f_value | tolerance | 132.42356222724115 | 132.42356223176026 | 4.52E-9 | 10 | passed |
/multivariate_tests/1/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/1/df2 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/multivariate_tests/1/p_value | tail_probability | 2.7397222569987586e-06 | 2.739722256679948e-06 | 3.19E-16 | 9 | passed |
/multivariate_tests/2/statistic | exact | Hotelling-Lawley trace | Hotelling-Lawley trace | passed | ||
/multivariate_tests/2/value | tolerance | 37.835303493497307 | 37.83530349478865 | 1.29E-9 | 10 | passed |
/multivariate_tests/2/f_value | tolerance | 132.42356222724058 | 132.42356223176026 | 4.52E-9 | 10 | passed |
/multivariate_tests/2/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/2/df2 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/multivariate_tests/2/p_value | tail_probability | 2.7397222569987976e-06 | 2.739722256679948e-06 | 3.19E-16 | 9 | passed |
/multivariate_tests/3/statistic | exact | Roy's root | Roy's root | passed | ||
/multivariate_tests/3/value | tolerance | 37.8353034934973 | 37.83530349478865 | 1.29E-9 | 10 | passed |
/multivariate_tests/3/f_value | tolerance | 132.42356222724055 | 132.42356223176026 | 4.52E-9 | 10 | passed |
/multivariate_tests/3/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/3/df2 | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/multivariate_tests/3/p_value | tail_probability | 2.7397222569988022e-06 | 2.739722256679948e-06 | 3.19E-16 | 9 | passed |
/within_tests/0/effect | exact | Time | Time | passed | ||
/between_tests/0/effect | exact | (Intercept) | (Intercept) | passed | ||
/between_tests/0/sum_of_squares | tolerance | 4505.9792592592594 | 4505.979259259259 | 2.08E-14 | 17 | passed |
/between_tests/0/f_value | tolerance | 545.12698270454348 | 545.1269827045433 | 2.28E-13 | 15 | passed |
/between_tests/0/p_value | tail_probability | 1.2035017877443359e-08 | 1.2035017877443376e-08 | 1.69E-23 | 14 | passed |
/between_error_ss | tolerance | 66.127407407407389 | 66.12740740740743 | 4.31E-14 | 15 | passed |
/design/subjects | exact | 10 | 10 | 0.00E+2 | passed | |
/design/used | exact | 9 | 9 | 0.00E+2 | passed | |
/design/incomplete | exact | 1 | 1 | 0.00E+2 | passed | |
/design/residual_df | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Subject 10 lacks t2, so 9 subjects are used; nu = 8.
- Mauchly: W from the eigenvalues of the orthonormal-contrast residual covariance (equal to mauchly.test's W); the chi-square and p use the first-order factor nu - (2q^2 + q + 2)/(6q) rather than mauchly.test's second-order expansion, as the manual states.
- Between-subject intercept test on the normalized subject total Y 1 / sqrt(p): F = t^2 of the one-sample t test of that total.
- A subject missing any cell column is dropped and counted as incomplete; nu = N - rank(X).
- Within-subject effects use orthonormal contrasts: SS = tr(H) and error SS = tr(E_W) equal the classical univariate repeated-measures sums of squares (aov with Error(subject/factor)); F on (r q, nu q) df; the Greenhouse-Geisser and Huynh-Feldt (Lecoutre) epsilons multiply both df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:33-47: the univariate F, Greenhouse-Geisser epsilon (sum lambda)^2 / (q sum lambda^2), corrected tests multiplying both df, the Huynh-Feldt/Lecoutre and lower-bound corrections, Mauchly's first-order approximation.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:48-52: 'For a two-occasion design without between-subject factors, the test equals the paired t test squared.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:54-58: Pillai, Wilks, Hotelling-Lawley and Roy multivariate tests.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
46 emit <- function(id, title, kind, config, outputs, notes, excluded = list()) {
47 write_expected("hypothesis", id, list(
48 schema_version = "2.0.0", case_id = id, outputs = outputs, expected_error = NULL,
49 deferred_outputs = list(), generator_run = run))
50 write_case("hypothesis", id, list(
51 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "hypothesis",
52 entry_point = entry, menu_items = list(menu), title = title, case_kind = kind,
53 dataset = list(path = "reference_data/datasets/HYP_RM.json", sha256 = ""),
54 excluded_rows = excluded, configuration = config, "repeat" = 1L,
55 expected = list(path = paste0("reference_data/expected/hypothesis/", id, ".json"), sha256 = ""),
56 oracle = list(oracle_class = "independent_implementation", source = "R 4.6.1 stats",
57 citation = "R Core Team, stats package help: aov, anova.mlm, mauchly.test, SSD, t.test; Greenhouse SW, Geisser S (1959), Psychometrika 24, 95-112; Lecoutre B (1991), Journal of Educational Statistics 16, 371-372.",
58 generator = list(path = "generators/r/hypothesis_repeated_measures.R", sha256 = ""),
59 independent = TRUE,
60 convention_notes = c(notes, notes_common, "Expected computed from the exported CSV.")),
61 supported = TRUE, unsupported_reason = NULL,
62 requirement_ids = list("REQ-STAT-HYP-REPEATED-MEASURES-001"),
63 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
Repeated measures with a balanced between-subject factor
Case STAT-HYP-REPEATED-MEASURES-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R Core Team, stats package help: aov, anova.mlm, mauchly.test, SSD, t.test; Greenhouse SW, Geisser S (1959), Psychometrika 24, 95-112; Lecoutre B (1991), Journal of Educational Statistics 16, 371-372.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_repeated_measures.R · sha256 8faee62dc29c9cba
- Dataset
- reference_data/datasets/HYP_RM.json
Settings compared
between= ["grp"]cells= ["t1", "t2", "t3"]contrast_family= "none"factor1_levels= ["t1", "t2", "t3"]factor1_name= "Time"pairwise_procedure= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sphericity/0/dimensions | exact | 2 | 2 | 0.00E+2 | passed | |
/sphericity/0/greenhouse_geisser | tolerance | 0.58056007115909514 | 0.5805600711590949 | 2.25E-16 | 15 | passed |
/sphericity/0/huynh_feldt | tolerance | 0.63318796668399135 | 0.6331879666839908 | 5.51E-16 | 15 | passed |
/sphericity/0/huynh_feldt_applied | tolerance | 0.63318796668399135 | 0.6331879666839908 | 5.51E-16 | 15 | passed |
/sphericity/0/lower_bound | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/sphericity/0/mauchly_w | tolerance | 0.27752535925612681 | 0.27752535925612576 | 1.05E-15 | 14 | passed |
/sphericity/0/chi_square | tolerance | 6.4092148263210627 | 6.409214826321081 | 1.86E-14 | 14 | passed |
/sphericity/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/sphericity/0/p_value | tail_probability | 0.040574827654846102 | 0.04057482765484572 | 3.82E-16 | 14 | passed |
/within_tests/0/sum_of_squares | tolerance | 16.743333333333325 | 16.743333333333332 | 7.29E-15 | 15 | passed |
/within_tests/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/within_tests/0/mean_square | tolerance | 8.3716666666666626 | 8.371666666666666 | 3.55E-15 | 15 | passed |
/within_tests/0/f_value | tolerance | 41.398351648351571 | 41.39835164835159 | 2.18E-14 | 15 | passed |
/within_tests/0/error_sum_of_squares | tolerance | 2.4266666666666699 | 2.42666666666667 | 4.18E-17 | 16 | passed |
/within_tests/0/error_df | exact | 12 | 12 | 0.00E+2 | passed | |
/within_tests/0/partial_eta_squared | tolerance | 0.87341331942270894 | 0.873413319422709 | 4.73E-18 | 17 | passed |
/within_tests/0/tests/0/correction | exact | Sphericity assumed | Sphericity assumed | passed | ||
/within_tests/0/tests/0/epsilon | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/within_tests/0/tests/0/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/within_tests/0/tests/0/df2 | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/within_tests/0/tests/0/p_value | tail_probability | 4.1146042495770505e-06 | 4.114604249577034e-06 | 1.69E-20 | 14 | passed |
/within_tests/0/tests/1/correction | exact | Greenhouse-Geisser | Greenhouse-Geisser | passed | ||
/within_tests/0/tests/1/epsilon | tolerance | 0.58056007115909514 | 0.5805600711590949 | 2.25E-16 | 15 | passed |
/within_tests/0/tests/1/df1 | tolerance | 1.1611201423181903 | 1.1611201423181898 | 4.70E-16 | 15 | passed |
/within_tests/0/tests/1/df2 | tolerance | 6.9667208539091412 | 6.966720853909139 | 1.78E-15 | 15 | passed |
/within_tests/0/tests/1/p_value | tail_probability | 0.00029081711249609189 | 0.0002908171124960923 | 4.30E-19 | 14 | passed |
/within_tests/0/tests/2/correction | exact | Huynh-Feldt | Huynh-Feldt | passed | ||
/within_tests/0/tests/2/epsilon | tolerance | 0.63318796668399135 | 0.6331879666839908 | 5.51E-16 | 15 | passed |
/within_tests/0/tests/2/df1 | tolerance | 1.2663759333679827 | 1.2663759333679816 | 1.10E-15 | 15 | passed |
/within_tests/0/tests/2/df2 | tolerance | 7.5982556002078958 | 7.59825560020789 | 6.21E-15 | 15 | passed |
/within_tests/0/tests/2/p_value | tail_probability | 0.00016960057935868196 | 0.00016960057935868256 | 5.99E-19 | 14 | passed |
/within_tests/1/sum_of_squares | tolerance | 0.12333333333333237 | 0.12333333333333389 | 1.52E-15 | 13 | passed |
/within_tests/1/df | exact | 2 | 2 | 0.00E+2 | passed | |
/within_tests/1/mean_square | tolerance | 0.061666666666666183 | 0.061666666666666946 | 7.63E-16 | 13 | passed |
/within_tests/1/f_value | tolerance | 0.30494505494505214 | 0.3049450549450559 | 3.78E-15 | 13 | passed |
/within_tests/1/error_sum_of_squares | tolerance | 2.4266666666666699 | 2.42666666666667 | 4.18E-17 | 16 | passed |
/within_tests/1/error_df | exact | 12 | 12 | 0.00E+2 | passed | |
/within_tests/1/partial_eta_squared | tolerance | 0.048366013071895003 | 0.04836601307189557 | 5.69E-16 | 13 | passed |
/within_tests/1/tests/0/correction | exact | Sphericity assumed | Sphericity assumed | passed | ||
/within_tests/1/tests/0/epsilon | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/within_tests/1/tests/0/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/within_tests/1/tests/0/df2 | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/within_tests/1/tests/0/p_value | tail_probability | 0.74271067306767813 | 0.7427106730676754 | 2.78E-15 | 14 | passed |
/within_tests/1/tests/1/correction | exact | Greenhouse-Geisser | Greenhouse-Geisser | passed | ||
/within_tests/1/tests/1/epsilon | tolerance | 0.58056007115909514 | 0.5805600711590949 | 2.25E-16 | 15 | passed |
/within_tests/1/tests/1/df1 | tolerance | 1.1611201423181903 | 1.1611201423181898 | 4.70E-16 | 15 | passed |
/within_tests/1/tests/1/df2 | tolerance | 6.9667208539091412 | 6.966720853909139 | 1.78E-15 | 15 | passed |
/within_tests/1/tests/1/p_value | tail_probability | 0.63129626623221358 | 0.6312962662322112 | 2.33E-15 | 14 | passed |
/within_tests/1/tests/2/correction | exact | Huynh-Feldt | Huynh-Feldt | passed | ||
/within_tests/1/tests/2/epsilon | tolerance | 0.63318796668399135 | 0.6331879666839908 | 5.51E-16 | 15 | passed |
/within_tests/1/tests/2/df1 | tolerance | 1.2663759333679827 | 1.2663759333679816 | 1.10E-15 | 15 | passed |
/within_tests/1/tests/2/df2 | tolerance | 7.5982556002078958 | 7.59825560020789 | 6.21E-15 | 15 | passed |
/within_tests/1/tests/2/p_value | tail_probability | 0.64914014617527349 | 0.6491401461752708 | 2.66E-15 | 14 | passed |
/multivariate_tests/0/statistic | exact | Pillai's trace | Pillai's trace | passed | ||
/multivariate_tests/0/value | tolerance | 0.98899716872530719 | 0.9889971687256394 | 3.32E-13 | 12 | passed |
/multivariate_tests/0/f_value | tolerance | 224.71424491441152 | 224.7142449212712 | 6.86E-9 | 10 | passed |
/multivariate_tests/0/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/0/df2 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/multivariate_tests/0/p_value | tail_probability | 1.2698754670669953e-05 | 1.2698754669711511e-05 | 9.58E-16 | 10 | passed |
/multivariate_tests/1/statistic | exact | Wilks' lambda | Wilks' lambda | passed | ||
/multivariate_tests/1/value | tolerance | 0.011002831274661239 | 0.011002831274360626 | 3.01E-13 | 10 | passed |
/multivariate_tests/1/f_value | tolerance | 224.71424491506357 | 224.71424492127142 | 6.21E-9 | 10 | passed |
/multivariate_tests/1/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/1/df2 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/multivariate_tests/1/p_value | tail_probability | 1.2698754670578864e-05 | 1.269875466971148e-05 | 8.67E-16 | 10 | passed |
/multivariate_tests/2/statistic | exact | Hotelling-Lawley trace | Hotelling-Lawley trace | passed | ||
/multivariate_tests/2/value | tolerance | 89.885697966028317 | 89.88569796850857 | 2.48E-9 | 10 | passed |
/multivariate_tests/2/f_value | tolerance | 224.71424491507079 | 224.71424492127142 | 6.20E-9 | 10 | passed |
/multivariate_tests/2/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/2/df2 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/multivariate_tests/2/p_value | tail_probability | 1.2698754670577872e-05 | 1.269875466971148e-05 | 8.66E-16 | 10 | passed |
/multivariate_tests/3/statistic | exact | Roy's root | Roy's root | passed | ||
/multivariate_tests/3/value | tolerance | 89.885697966028346 | 89.88569796850857 | 2.48E-9 | 10 | passed |
/multivariate_tests/3/f_value | tolerance | 224.71424491507088 | 224.71424492127142 | 6.20E-9 | 10 | passed |
/multivariate_tests/3/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/3/df2 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/multivariate_tests/3/p_value | tail_probability | 1.2698754670577826e-05 | 1.269875466971148e-05 | 8.66E-16 | 10 | passed |
/multivariate_tests/4/statistic | exact | Pillai's trace | Pillai's trace | passed | ||
/multivariate_tests/4/value | tolerance | 0.10910015991505728 | 0.10910015990696476 | 8.09E-12 | 10 | passed |
/multivariate_tests/4/f_value | tolerance | 0.30615158687382621 | 0.3061515868483364 | 2.55E-11 | 10 | passed |
/multivariate_tests/4/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/4/df2 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/multivariate_tests/4/p_value | tail_probability | 0.74915589703855623 | 0.7491558970555687 | 1.70E-11 | 10 | passed |
/multivariate_tests/5/statistic | exact | Wilks' lambda | Wilks' lambda | passed | ||
/multivariate_tests/5/value | tolerance | 0.8908998400849425 | 0.8908998400930354 | 8.09E-12 | 11 | passed |
/multivariate_tests/5/f_value | tolerance | 0.30615158687382682 | 0.3061515868483361 | 2.55E-11 | 10 | passed |
/multivariate_tests/5/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/5/df2 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/multivariate_tests/5/p_value | tail_probability | 0.74915589703855634 | 0.749155897055569 | 1.70E-11 | 10 | passed |
/multivariate_tests/6/statistic | exact | Hotelling-Lawley trace | Hotelling-Lawley trace | passed | ||
/multivariate_tests/6/value | tolerance | 0.12246063474953066 | 0.12246063473933455 | 1.02E-11 | 10 | passed |
/multivariate_tests/6/f_value | tolerance | 0.30615158687382665 | 0.3061515868483364 | 2.55E-11 | 10 | passed |
/multivariate_tests/6/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/6/df2 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/multivariate_tests/6/p_value | tail_probability | 0.74915589703855601 | 0.7491558970555687 | 1.70E-11 | 10 | passed |
/multivariate_tests/7/statistic | exact | Roy's root | Roy's root | passed | ||
/multivariate_tests/7/value | tolerance | 0.12246063474953137 | 0.12246063473933454 | 1.02E-11 | 10 | passed |
/multivariate_tests/7/f_value | tolerance | 0.30615158687382843 | 0.3061515868483363 | 2.55E-11 | 10 | passed |
/multivariate_tests/7/df1 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/multivariate_tests/7/df2 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/multivariate_tests/7/p_value | tail_probability | 0.74915589703855479 | 0.7491558970555688 | 1.70E-11 | 10 | passed |
/within_tests/0/effect | exact | Time | Time | passed | ||
/within_tests/1/effect | exact | Time × grp | Time × grp | passed | ||
/between_tests/1/effect | exact | grp | grp | passed | ||
/between_tests/1/sum_of_squares | tolerance | 37.750416666666716 | 37.75041666666672 | 7.13E-15 | 15 | passed |
/between_tests/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/between_tests/1/f_value | tolerance | 9.6937479938656992 | 9.693747993865696 | 3.57E-15 | 15 | passed |
/between_tests/1/p_value | tail_probability | 0.020756621924184239 | 0.020756621924184263 | 2.42E-17 | 14 | passed |
/between_error_ss | tolerance | 23.365833333333335 | 23.365833333333345 | 1.02E-14 | 15 | passed |
/design/used | exact | 8 | 8 | 0.00E+2 | passed | |
/design/incomplete | exact | 1 | 1 | 0.00E+2 | passed | |
/design/excluded | exact | 1 | 1 | 0.00E+2 | passed | |
/design/residual_df | exact | 6 | 6 | 0.00E+2 | passed |
Convention
- Within effects: aov(y ~ grp * Time + Error(subject / Time)) rows Time and grp:Time with the subject:Time residual; sphericity from the residual SSD of lm(Y ~ grp) on nu = 6 df.
- Multivariate tests: anova.mlm rows (Intercept) (= Time) and grp (= Time x grp) with X = ~1, M = ~Time; balanced groups make the sequential tests the Type III tests.
- Between tests on the normalized subject total: anova(lm(total ~ grp)).
- A subject missing any cell column is dropped and counted as incomplete; nu = N - rank(X).
- Within-subject effects use orthonormal contrasts: SS = tr(H) and error SS = tr(E_W) equal the classical univariate repeated-measures sums of squares (aov with Error(subject/factor)); F on (r q, nu q) df; the Greenhouse-Geisser and Huynh-Feldt (Lecoutre) epsilons multiply both df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:33-47: the univariate F, Greenhouse-Geisser epsilon (sum lambda)^2 / (q sum lambda^2), corrected tests multiplying both df, the Huynh-Feldt/Lecoutre and lower-bound corrections, Mauchly's first-order approximation.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:48-52: 'For a two-occasion design without between-subject factors, the test equals the paired t test squared.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:54-58: Pillai, Wilks, Hotelling-Lawley and Roy multivariate tests.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
170 keep <- stats::complete.cases(d[c("t1", "t2", "t3")]) & seq_len(nrow(d)) != 5
171 cc <- d[keep, ]
172 Y <- as.matrix(cc[c("t1", "t2", "t3")])
173 n <- nrow(Y); p <- 3L
174 grp <- factor(cc$grp)
175 fit <- stats::lm(Y ~ grp, contrasts = list(grp = "contr.sum"))
176 nu <- n - 2L
177 long <- data.frame(y = as.vector(Y), subject = factor(rep(seq_len(n), p)), Time = factor(rep(1:p, each = n)), grp = rep(grp, p))
178 strata <- summary(stats::aov(y ~ grp * Time + Error(subject / Time), data = long))
179 within <- strata[["Error: subject:Time"]][[1]]
180 between <- strata[["Error: subject"]][[1]]
181 sph <- sphericity_outputs(0, fit, orthonormal(p), nu)
182 outputs <- c(sph$outputs,
183 univariate_outputs(0, within["Time", "Sum Sq"], within["Time", "Df"], within["Residuals", "Sum Sq"], within["Residuals", "Df"], sph$gg, sph$hf),
184 univariate_outputs(1, within["grp:Time", "Sum Sq"], within["grp:Time", "Df"], within["Residuals", "Sum Sq"], within["Residuals", "Df"], sph$gg, sph$hf),
185 multivariate_outputs(0, fit, ~1, ~Time, idata, "(Intercept)"),
186 multivariate_outputs(4, fit, ~1, ~Time, idata, "grp"))
187 rownames(within) <- trimws(rownames(within)); rownames(between) <- trimws(rownames(between))
188 outputs[["/within_tests/0/effect"]] <- word("Time", "effect name")
189 outputs[["/within_tests/1/effect"]] <- word("Time × grp", "interaction effect name")
190 total <- rowSums(Y) / sqrt(p)
191 bt <- stats::anova(stats::lm(total ~ grp))
192 outputs[["/between_tests/1/effect"]] <- word("grp", "between effect")
193 outputs[["/between_tests/1/sum_of_squares"]] <- tol(bt["grp", "Sum Sq"], "grp SS of the normalized subject total")
194 outputs[["/between_tests/1/df"]] <- exact(bt["grp", "Df"], "grp df")
195 outputs[["/between_tests/1/f_value"]] <- tol(bt["grp", "F value"], "grp F")
196 outputs[["/between_tests/1/p_value"]] <- prob(bt["grp", "Pr(>F)"], "grp F tail")
197 outputs[["/between_error_ss"]] <- tol(bt["Residuals", "Sum Sq"], "residual SS of the normalized subject total")
198 outputs[["/design/used"]] <- exact(n, "complete, non-excluded subjects")
199 outputs[["/design/incomplete"]] <- exact(1L, "subject 10 lacks t2")
200 outputs[["/design/excluded"]] <- exact(1L, "row 5 excluded")
201 outputs[["/design/residual_df"]] <- exact(nu, "N - rank(X) with the intercept and one sum-to-zero column")
202 emit("STAT-HYP-REPEATED-MEASURES-002", "Repeated measures with a balanced between-subject factor", "missing_excluded",
203 list(factor1_name = "Time", factor1_levels = list("t1", "t2", "t3"), cells = list("t1", "t2", "t3"),
204 between = list("grp"), contrast_family = "none", pairwise_procedure = "none"),
205 outputs, c("Within effects: aov(y ~ grp * Time + Error(subject / Time)) rows Time and grp:Time with the subject:Time residual; sphericity from the residual SSD of lm(Y ~ grp) on nu = 6 df.",
206 "Multivariate tests: anova.mlm rows (Intercept) (= Time) and grp (= Time x grp) with X = ~1, M = ~Time; balanced groups make the sequential tests the Type III tests.",
207 "Between tests on the normalized subject total: anova(lm(total ~ grp))."),
208 excluded = list(4L))
Repeated measures two occasions equals paired t squared
Case STAT-HYP-REPEATED-MEASURES-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R Core Team, stats package help: aov, anova.mlm, mauchly.test, SSD, t.test; Greenhouse SW, Geisser S (1959), Psychometrika 24, 95-112; Lecoutre B (1991), Journal of Educational Statistics 16, 371-372.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_repeated_measures.R · sha256 8faee62dc29c9cba
- Dataset
- reference_data/datasets/HYP_RM.json
Settings compared
cells= ["t1", "t2"]contrast_family= "none"factor1_levels= ["t1", "t2"]factor1_name= "Time"pairwise_procedure= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sphericity/0/dimensions | exact | 1 | 1 | 0.00E+2 | passed | |
/sphericity/0/greenhouse_geisser | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/sphericity/0/mauchly_w | absent | None | passed | |||
/within_tests/0/effect | exact | Time | Time | passed | ||
/within_tests/0/sum_of_squares | tolerance | 1.5605555555555546 | 1.5605555555555508 | 3.79E-15 | 14 | passed |
/within_tests/0/df | exact | 1 | 1 | 0.00E+2 | passed | |
/within_tests/0/error_sum_of_squares | tolerance | 2.1744444444444468 | 2.1744444444444446 | 2.18E-15 | 14 | passed |
/within_tests/0/error_df | exact | 8 | 8 | 0.00E+2 | passed | |
/within_tests/0/f_value | tolerance | 5.7414409810935005 | 5.7414409810934925 | 7.95E-15 | 14 | passed |
/within_tests/0/tests/0/p_value | tail_probability | 0.043438250091039007 | 0.04343825009103914 | 1.32E-16 | 14 | passed |
/within_tests/0/tests/1/epsilon | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/within_tests/0/tests/1/p_value | tail_probability | 0.043438250091039007 | 0.04343825009103914 | 1.32E-16 | 14 | passed |
/multivariate_tests/0/f_value | tolerance | 5.7414409810935005 | 5.741440981093491 | 9.73E-15 | 14 | passed |
/multivariate_tests/0/p_value | tail_probability | 0.043438250091039007 | 0.04343825009103914 | 1.32E-16 | 14 | passed |
/multivariate_tests/1/p_value | tail_probability | 0.043438250091039007 | 0.04343825009103914 | 1.32E-16 | 14 | passed |
/design/used | exact | 9 | 9 | 0.00E+2 | passed | |
/design/residual_df | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Two occasions: the orthonormal contrast score (t2 - t1)/sqrt(2) gives F = t^2 of the paired t test and the same p; with one contrast every epsilon is 1, there is no Mauchly test and the multivariate F is exact.
- A subject missing any cell column is dropped and counted as incomplete; nu = N - rank(X).
- Within-subject effects use orthonormal contrasts: SS = tr(H) and error SS = tr(E_W) equal the classical univariate repeated-measures sums of squares (aov with Error(subject/factor)); F on (r q, nu q) df; the Greenhouse-Geisser and Huynh-Feldt (Lecoutre) epsilons multiply both df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:33-47: the univariate F, Greenhouse-Geisser epsilon (sum lambda)^2 / (q sum lambda^2), corrected tests multiplying both df, the Huynh-Feldt/Lecoutre and lower-bound corrections, Mauchly's first-order approximation.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:48-52: 'For a two-occasion design without between-subject factors, the test equals the paired t test squared.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:54-58: Pillai, Wilks, Hotelling-Lawley and Roy multivariate tests.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
211 cc <- d[stats::complete.cases(d[c("t1", "t2")]), ]
212 n <- nrow(cc); nu <- n - 1L
213 tt <- stats::t.test(cc$t1, cc$t2, paired = TRUE)
214 score <- (cc$t2 - cc$t1) / sqrt(2) # orthonormal contrast score
215 outputs <- list(
216 "/sphericity/0/dimensions" = exact(1L, "one contrast"),
217 "/sphericity/0/greenhouse_geisser" = tol(1, "epsilon is 1 with one contrast"),
218 "/sphericity/0/mauchly_w" = absent("no Mauchly test with one contrast"),
219 "/within_tests/0/effect" = word("Time", "effect name"),
220 "/within_tests/0/sum_of_squares" = tol(n * mean(score)^2, "n times the squared mean contrast score"),
221 "/within_tests/0/df" = exact(1L, "one contrast"),
222 "/within_tests/0/error_sum_of_squares" = tol(sum((score - mean(score))^2), "contrast score SS about its mean"),
223 "/within_tests/0/error_df" = exact(nu, "n - 1"),
224 "/within_tests/0/f_value" = tol(unname(tt$statistic)^2, "squared paired t"),
225 "/within_tests/0/tests/0/p_value" = prob(tt$p.value, "paired t two-sided tail"),
226 "/within_tests/0/tests/1/epsilon" = tol(1, "Greenhouse-Geisser epsilon 1"),
227 "/within_tests/0/tests/1/p_value" = prob(tt$p.value, "unchanged by epsilon 1"),
228 "/multivariate_tests/0/f_value" = tol(unname(tt$statistic)^2, "Pillai exact F with one contrast"),
229 "/multivariate_tests/0/p_value" = prob(tt$p.value, "exact F tail with one contrast"),
230 "/multivariate_tests/1/p_value" = prob(tt$p.value, "Wilks exact F tail with one contrast"),
231 "/design/used" = exact(n, "complete subjects"),
232 "/design/residual_df" = exact(nu, "n - 1")
233 )
234 emit("STAT-HYP-REPEATED-MEASURES-003", "Repeated measures two occasions equals paired t squared", "axis_coverage",
235 list(factor1_name = "Time", factor1_levels = list("t1", "t2"), cells = list("t1", "t2"),
236 contrast_family = "none", pairwise_procedure = "none"),
237 outputs, "Two occasions: the orthonormal contrast score (t2 - t1)/sqrt(2) gives F = t^2 of the paired t test and the same p; with one contrast every epsilon is 1, there is no Mauchly test and the multivariate F is exact.")
Repeated measures two within factors 2 x 2
Case STAT-HYP-REPEATED-MEASURES-004 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats
- Citation
- R Core Team, stats package help: aov, anova.mlm, mauchly.test, SSD, t.test; Greenhouse SW, Geisser S (1959), Psychometrika 24, 95-112; Lecoutre B (1991), Journal of Educational Statistics 16, 371-372.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_repeated_measures.R · sha256 8faee62dc29c9cba
- Dataset
- reference_data/datasets/HYP_RM.json
Settings compared
cells= ["t1", "t2", "t3", "t4"]contrast_family= "none"factor1_levels= ["a1", "a2"]factor1_name= "A"factor2_levels= ["b1", "b2"]factor2_name= "B"pairwise_procedure= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/design/used | exact | 9 | 9 | 0.00E+2 | passed | |
/design/residual_df | exact | 8 | 8 | 0.00E+2 | passed | |
/within_tests/0/effect | exact | A | A | passed | ||
/within_tests/0/sum_of_squares | tolerance | 11.902500000000002 | 11.902499999999987 | 1.46E-14 | 14 | passed |
/within_tests/0/df | exact | 1 | 1 | 0.00E+2 | passed | |
/within_tests/0/error_sum_of_squares | tolerance | 1.4249999999999985 | 1.4249999999999985 | 9.90E-18 | 17 | passed |
/within_tests/0/error_df | exact | 8 | 8 | 0.00E+2 | passed | |
/within_tests/0/f_value | tolerance | 66.821052631579022 | 66.82105263157895 | 7.12E-14 | 14 | passed |
/within_tests/0/tests/0/p_value | tail_probability | 3.7376465619768127e-05 | 3.737646561976824e-05 | 1.15E-19 | 14 | passed |
/sphericity/0/greenhouse_geisser | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/multivariate_tests/0/p_value | tail_probability | 3.7376465619768127e-05 | 3.737646561976824e-05 | 1.15E-19 | 14 | passed |
/within_tests/1/effect | exact | B | B | passed | ||
/within_tests/1/sum_of_squares | tolerance | 0.23361111111111171 | 0.23361111111110944 | 2.27E-15 | 14 | passed |
/within_tests/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/within_tests/1/error_sum_of_squares | tolerance | 1.2038888888888928 | 1.2038888888888972 | 4.42E-15 | 14 | passed |
/within_tests/1/error_df | exact | 8 | 8 | 0.00E+2 | passed | |
/within_tests/1/f_value | tolerance | 1.552376557452698 | 1.5523765574526778 | 2.02E-14 | 13 | passed |
/within_tests/1/tests/0/p_value | tail_probability | 0.24803472724910058 | 0.24803472724910347 | 2.89E-15 | 13 | passed |
/sphericity/1/greenhouse_geisser | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/multivariate_tests/4/p_value | tail_probability | 0.24803472724910058 | 0.24803472724910366 | 3.08E-15 | 13 | passed |
/within_tests/2/effect | exact | A × B | A × B | passed | ||
/within_tests/2/sum_of_squares | tolerance | 5.0624999999999973 | 5.0624999999999885 | 8.85E-15 | 14 | passed |
/within_tests/2/df | exact | 1 | 1 | 0.00E+2 | passed | |
/within_tests/2/error_sum_of_squares | tolerance | 1.4049999999999998 | 1.4049999999999954 | 4.44E-15 | 14 | passed |
/within_tests/2/error_df | exact | 8 | 8 | 0.00E+2 | passed | |
/within_tests/2/f_value | tolerance | 28.825622775800696 | 28.825622775800742 | 4.59E-14 | 14 | passed |
/within_tests/2/tests/0/p_value | tail_probability | 0.00067044503588731795 | 0.0006704450358873147 | 3.26E-18 | 14 | passed |
/sphericity/2/greenhouse_geisser | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/multivariate_tests/8/p_value | tail_probability | 0.00067044503588731795 | 0.0006704450358873138 | 4.12E-18 | 14 | passed |
Convention
- Cells in first-factor-slowest order: t1 = a1 b1, t2 = a1 b2, t3 = a2 b1, t4 = a2 b2. Each effect is one orthonormal contrast (A: (t1 + t2 - t3 - t4)/2, B: (t1 - t2 + t3 - t4)/2, A x B: (t1 - t2 - t3 + t4)/2) whose one-sample t squared is the F; effects are ordered A, B, A x B with four multivariate rows each.
- A subject missing any cell column is dropped and counted as incomplete; nu = N - rank(X).
- Within-subject effects use orthonormal contrasts: SS = tr(H) and error SS = tr(E_W) equal the classical univariate repeated-measures sums of squares (aov with Error(subject/factor)); F on (r q, nu q) df; the Greenhouse-Geisser and Huynh-Feldt (Lecoutre) epsilons multiply both df.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:33-47: the univariate F, Greenhouse-Geisser epsilon (sum lambda)^2 / (q sum lambda^2), corrected tests multiplying both df, the Huynh-Feldt/Lecoutre and lower-bound corrections, Mauchly's first-order approximation.
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:48-52: 'For a two-occasion design without between-subject factors, the test equals the paired t test squared.'
- docs/manual/chapters/83-repeated-anova-and-contrasts.tex:54-58: Pillai, Wilks, Hotelling-Lawley and Roy multivariate tests.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
258 emit("STAT-HYP-REPEATED-MEASURES-004", "Repeated measures two within factors 2 x 2", "axis_coverage",
259 list(factor1_name = "A", factor1_levels = list("a1", "a2"), factor2_name = "B", factor2_levels = list("b1", "b2"),
260 cells = list("t1", "t2", "t3", "t4"), contrast_family = "none", pairwise_procedure = "none"),
261 outputs, "Cells in first-factor-slowest order: t1 = a1 b1, t2 = a1 b2, t3 = a2 b1, t4 = a2 b2. Each effect is one orthonormal contrast (A: (t1 + t2 - t3 - t4)/2, B: (t1 - t2 + t3 - t4)/2, A x B: (t1 - t2 - t3 + t4)/2) whose one-sample t squared is the F; effects are ordered A, B, A x B with four multivariate rows each.")
Exact paired sign test
Case STAT-HYP-SIGN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
response= "x"second_response= "y"test= "sign"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 3.051757812500002e-05 | 3.0517578125000014e-05 | 6.45E-21 | 15 | passed |
Convention
- Zero paired differences omitted; test positive among nonzero differences.
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
76 paired_diff <- d$x - d$y
77 positive <- sum(paired_diff > 0)
78 nonzero <- sum(paired_diff != 0)
79 sign <- stats::binom.test(positive, nonzero, p = 0.5)
80 emit("STAT-HYP-SIGN-001", "Exact paired sign test",
81 list(test = "sign", response = "x", second_response = "y"),
82 list("/statistic" = tol(positive, "positive paired differences"),
83 "/p_value" = prob(sign$p.value, "exact two-sided binomial tail")),
84 list("Zero paired differences omitted; test positive among nonzero differences."))
Decision threshold: STAT-HYP-THRESHOLD-EQUIV-ESTABLISHED-001
Case STAT-HYP-THRESHOLD-EQUIV-ESTABLISHED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R Student t tails
- Citation
- R stats::t.test, pt and qt documentation; TOST analytic one-sided t tests.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_thresholds.R · sha256 e175b2ee1750ea1d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1group_a= "A"group_b= "B"group_column= "g"lower_bound= -2.80240997929645response_column= "x"upper_bound= -0.347590020703553
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/p_lower | tail_probability | 0.097899531619999397 | 0.09789953161999881 | 5.83E-16 | 14 | passed |
/p_upper | tail_probability | 0.097899531619999355 | 0.09789953161999934 | 1.35E-17 | 15 | passed |
/equivalent | exact | True | True | passed |
Convention
- Bounds straddle the 1-alpha Welch interval endpoints by 1% of its half-width.
- All critical values and observed tails use the exported HYP_CORE CSV.
Reference code
Decision threshold: STAT-HYP-THRESHOLD-EQUIV-NOT-ESTABLISHED-001
Case STAT-HYP-THRESHOLD-EQUIV-NOT-ESTABLISHED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R Student t tails
- Citation
- R stats::t.test, pt and qt documentation; TOST analytic one-sided t tests.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_thresholds.R · sha256 e175b2ee1750ea1d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1group_a= "A"group_b= "B"group_column= "g"lower_bound= -2.77810483119157response_column= "x"upper_bound= -0.371895168808433
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/p_lower | tail_probability | 0.10213683397395916 | 0.10213683397395866 | 5.00E-16 | 14 | passed |
/p_upper | tail_probability | 0.10213683397395923 | 0.10213683397395912 | 1.12E-16 | 14 | passed |
/equivalent | exact | False | False | passed |
Convention
- Bounds straddle the 1-alpha Welch interval endpoints by 1% of its half-width.
- All critical values and observed tails use the exported HYP_CORE CSV.
Reference code
Decision threshold: STAT-HYP-THRESHOLD-EQUIVEXT-ESTABLISHED-001
Case STAT-HYP-THRESHOLD-EQUIVEXT-ESTABLISHED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R Student t tails
- Citation
- R stats::t.test, pt and qt documentation; TOST analytic one-sided t tests.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_thresholds.R · sha256 e175b2ee1750ea1d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1lower_bound= 0.160570567727443mode= "one_sample_difference"response_column= "x"target= 6upper_bound= 1.46442943227256
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/p_lower | tail_probability | 0.09789095181259852 | 0.09789095181259855 | 2.78E-17 | 15 | passed |
/p_upper | tail_probability | 0.09789095181259852 | 0.09789095181259769 | 8.33E-16 | 14 | passed |
/equivalent | exact | True | True | passed |
Convention
- Bounds straddle the 1-alpha one-sample t interval endpoints by 1%.
- All critical values and observed tails use the exported HYP_CORE CSV.
Reference code
Decision threshold: STAT-HYP-THRESHOLD-EQUIVEXT-NOT-ESTABLISHED-001
Case STAT-HYP-THRESHOLD-EQUIVEXT-NOT-ESTABLISHED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R Student t tails
- Citation
- R stats::t.test, pt and qt documentation; TOST analytic one-sided t tests.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_thresholds.R · sha256 e175b2ee1750ea1d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1lower_bound= 0.173480061435811mode= "one_sample_difference"response_column= "x"target= 6upper_bound= 1.45151993856419
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/p_lower | tail_probability | 0.10214546373369493 | 0.10214546373369517 | 2.36E-16 | 14 | passed |
/p_upper | tail_probability | 0.10214546373369493 | 0.102145463733695 | 6.94E-17 | 15 | passed |
/equivalent | exact | False | False | passed |
Convention
- Bounds straddle the 1-alpha one-sample t interval endpoints by 1%.
- All critical values and observed tails use the exported HYP_CORE CSV.
Reference code
Decision threshold: STAT-HYP-THRESHOLD-TEST-REJECT-001
Case STAT-HYP-THRESHOLD-TEST-REJECT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R Student t tails
- Citation
- R stats::t.test, pt and qt documentation; TOST analytic one-sided t tests.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_thresholds.R · sha256 e175b2ee1750ea1d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1response= "x"target= 5.96000086346099test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/p_value | tail_probability | 0.096944750730209223 | 0.09694475073020724 | 1.98E-15 | 13 | passed |
/conclusion | contains | ['provide evidence'] | The data provide evidence that the mean differs from 5.96 (p | passed |
Convention
- Null target is mean minus factor times the alpha=.1 critical standard error.
- factor 1.01 puts R p below alpha
- All critical values and observed tails use the exported HYP_CORE CSV.
Reference code
Decision threshold: STAT-HYP-THRESHOLD-TEST-RETAIN-001
Case STAT-HYP-THRESHOLD-TEST-RETAIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R Student t tails
- Citation
- R stats::t.test, pt and qt documentation; TOST analytic one-sided t tests.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_thresholds.R · sha256 e175b2ee1750ea1d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
alpha= 0.1response= "x"target= 5.97688203448157test= "one_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/p_value | tail_probability | 0.10313951140411243 | 0.10313951140411273 | 3.03E-16 | 14 | passed |
/conclusion | contains | ['do not provide sufficient evidence'] | The data do not provide sufficient evidence that the mean di | passed |
Convention
- Null target is mean minus factor times the alpha=.1 critical standard error.
- factor 0.99 puts R p above alpha
- All critical values and observed tails use the exported HYP_CORE CSV.
Reference code
Simultaneous comparisons: STAT-HYP-TUKEY-001
Case STAT-HYP-TUKEY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and multcomp
- Citation
- R stats::aov and TukeyHSD help; multcomp::glht and mvtnorm::pmvt documentation.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, multcomp 1.4.32, mvtnorm 1.4.2, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_simultaneous.R · sha256 3aa116cb96c8afa8
- Dataset
- reference_data/datasets/HYP_BLOCKS.json
Settings compared
group= "treatment"posthoc= trueresponse= "x"test= "one_way_anova"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 8.0528455284552898 | 8.052845528455283 | 7.12E-15 | 15 | passed |
/p_value | tail_probability | 0.0098881826855001104 | 0.009888182685500138 | 2.77E-17 | 14 | passed |
/intervals/0/estimate | tolerance | 1.0749999999999975 | 1.0750000000000002 | 2.68E-15 | 14 | passed |
/intervals/0/significant | exact | False | False | passed |
Convention
- R TukeyHSD is Tukey-Kramer for unequal group sizes; this balanced design uses the same convention.
- The first ordered interval is B minus A; its rejection flag is compared without reducing the numerical tier.
- All fitted data were re-read from exported HYP_BLOCKS CSV.
Reference code
The lines of the reference script that produce this case's expected values.
34 fit <- stats::aov(x ~ treatment, data = d)
35 anova_row <- summary(fit)[[1]][1, ]
36 tukey <- stats::TukeyHSD(fit, "treatment", conf.level = 0.95)$treatment
37 emit("STAT-HYP-TUKEY-001", "tabelz.analysis.hypothesis_tests:run_hypothesis_test",
38 "hypothesisTestsMenuItem",
39 list(test = "one_way_anova", response = "x", group = "treatment", posthoc = TRUE),
40 list("/statistic" = tol(anova_row[["F value"]], "one-way F"),
41 "/p_value" = prob(anova_row[["Pr(>F)"]], "one-way F tail"),
42 "/intervals/0/estimate" = tol(tukey["B-A", "diff"], "Tukey-Kramer B-A contrast"),
43 "/intervals/0/significant" = exact(tukey["B-A", "p adj"] < 0.05,
44 "R TukeyHSD adjusted p below alpha.")),
45 list(list(path = "/intervals/0/lower", reason = "Statsmodels rounds the displayed Tukey interval; full-tier numeric comparison is deferred."),
46 list(path = "/intervals/0/upper", reason = "Statsmodels rounds the displayed Tukey interval; full-tier numeric comparison is deferred.")),
47 list("R TukeyHSD is Tukey-Kramer for unequal group sizes; this balanced design uses the same convention.",
48 "The first ordered interval is B minus A; its rejection flag is compared without reducing the numerical tier."))
Type II two-way interaction ANOVA
Case STAT-HYP-TWO-ANOVA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"posthoc= falseresponse= "x"second_group= "h"test= "two_way_anova"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.0028027560434421609 | 0.002802756043442922 | 7.61E-16 | 12 | passed |
/p_value | tail_probability | 0.9586499938109283 | 0.9586499938109226 | 5.66E-15 | 14 | passed |
Convention
- Type II sums of squares, g:h interaction is the primary statistic.
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
45 two_way <- car::Anova(stats::lm(x ~ g * h, data = d), type = 2)
46 interaction <- two_way["g:h", ]
47 emit("STAT-HYP-TWO-ANOVA-001", "Type II two-way interaction ANOVA",
48 list(test = "two_way_anova", response = "x", group = "g", second_group = "h",
49 posthoc = FALSE),
50 list("/statistic" = tol(interaction[["F value"]], "type II interaction F"),
51 "/p_value" = prob(interaction[["Pr(>F)"]], "type II interaction F tail")),
52 list("Type II sums of squares, g:h interaction is the primary statistic."))
Sparse two-proportion Fisher test
Case STAT-HYP-TWO-PROP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "fisher"response= "outcome"success_value= "yes"test= "two_proportion"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/p_value | tail_probability | 0.61926961926961921 | 0.6192696192696194 | 2.21E-16 | 15 | passed |
/estimate | tolerance | 0.25 | 0.25 | 0.00E+0 | passed |
Convention
- Fisher p-value from 2x2 table; the reported estimate is A minus B proportion.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
The lines of the reference script that produce this case's expected values.
114 tab <- table(d$g, d$outcome == "yes")
115 fisher <- stats::fisher.test(tab)
116 emit("STAT-HYP-TWO-PROP-001", "Sparse two-proportion Fisher test", "nominal",
117 list(test = "two_proportion", response = "outcome", group = "g", success_value = "yes",
118 method = "fisher"),
119 list("/p_value" = prob(fisher$p.value, "Fisher exact two-sided"),
120 "/estimate" = tol(mean(d$outcome[d$g == "A"] == "yes") -
121 mean(d$outcome[d$g == "B"] == "yes"), "proportion difference")),
122 list("Fisher p-value from 2x2 table; the reported estimate is A minus B proportion."))
Pooled two-proportion Z
Case STAT-HYP-TWO-PROP-Z-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "z"response= "outcome"success_value= "yes"test= "two_proportion"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.31731050786291409 | 0.31731050786291415 | 5.84E-17 | 15 | passed |
Convention
- Manual method z uses no continuity correction; pooled null SE shown analytically.
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
108 g_a <- d$outcome[d$g == "A"]
109 g_b <- d$outcome[d$g == "B"]
110 p_a <- mean(g_a == "yes")
111 p_b <- mean(g_b == "yes")
112 pooled <- (sum(g_a == "yes") + sum(g_b == "yes")) / (length(g_a) + length(g_b))
113 z <- (p_a - p_b) / sqrt(pooled * (1 - pooled) * (1 / length(g_a) + 1 / length(g_b)))
114 emit("STAT-HYP-TWO-PROP-Z-001", "Pooled two-proportion Z",
115 list(test = "two_proportion", response = "outcome", group = "g",
116 success_value = "yes", method = "z"),
117 list("/statistic" = tol(z, "pooled two-proportion z"),
118 "/p_value" = prob(2 * stats::pnorm(-abs(z)), "uncorrected normal tail")),
119 list("Manual method z uses no continuity correction; pooled null SE shown analytically."))
Independent welch t
Case STAT-HYP-TWO-T-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "welch"response= "x"test= "two_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -1.7431919415339725 | -1.7431919415339734 | 8.88E-16 | 15 | passed |
/df | tolerance | 13.999455894108475 | 13.999455894108468 | 6.64E-15 | 15 | passed |
/p_value | tail_probability | 0.103210460491396 | 0.10321046049139593 | 7.22E-17 | 15 | passed |
/estimate | tolerance | -1.5749999999999993 | -1.5750000000000002 | 8.78E-16 | 15 | passed |
Convention
- R t.test uses var.equal=FALSE for Welch and TRUE for pooled; A minus B.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reproduce it yourself
- Data: data.csv, the rows as analysed.
- R: run the script below; it prints every compared value with its output path.
- HypoNum: follow the steps below and read the same values from the result window.
R script
# Welch two-sample t test. Base R only; tested with R 4.6.1.
report <- function(path, x) cat(path, "=", if (is.numeric(x)) sprintf("%.17g", x) else as.character(x), "\n")
d <- read.csv("data.csv") # columns x (thickness) and g (line A or B)
fit <- t.test(x ~ g, data = d) # Welch, two-sided, 95 % interval
report("/estimate", diff(rev(tapply(d$x, d$g, mean)))) # mean(A) - mean(B)
report("/statistic", fit$statistic)
report("/df", fit$parameter)
report("/p_value", fit$p.value)
HypoNum
- File > Import data, select
data.csv, click Import. - Statistics > Compare means & ANOVA > Hypothesis tests.
- Test: Two-sample t-test. Response: x. Group: g. Click Run test.
Welch is the default method. Read the A-minus-B difference, t, the degrees of freedom and the p-value from the result window.
Reference code
Independent pooled t
Case STAT-HYP-TWO-T-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "pooled"response= "x"test= "two_sample_t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -1.7431919415339725 | -1.7431919415339734 | 8.88E-16 | 15 | passed |
/df | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.10320961287583347 | 0.10320961287583322 | 2.52E-16 | 14 | passed |
/estimate | tolerance | -1.5749999999999993 | -1.5750000000000002 | 8.78E-16 | 15 | passed |
Convention
- R t.test uses var.equal=FALSE for Welch and TRUE for pooled; A minus B.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
Bartlett equal variances
Case STAT-HYP-VARIANCE-BARTLETT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "bartlett"response= "x"test= "equal_variance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.00025393088616851859 | 0.0002539308861685186 | 2.71E-21 | 16 | passed |
/p_value | tail_probability | 0.98728608083675551 | 0.9872860808367555 | 1.45E-18 | 17 | passed |
Convention
- Bartlett test uses sample variances and chi-square approximation.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
The lines of the reference script that produce this case's expected values.
141 bartlett <- stats::bartlett.test(x ~ g, data = d)
142 emit("STAT-HYP-VARIANCE-BARTLETT-001", "Bartlett equal variances", "axis_coverage",
143 list(test = "equal_variance", response = "x", group = "g", method = "bartlett"),
144 list("/statistic" = tol(bartlett$statistic, "Bartlett K2"),
145 "/p_value" = prob(bartlett$p.value, "Bartlett chi-square tail")),
146 list("Bartlett test uses sample variances and chi-square approximation."))
Two-group variance ratio
Case STAT-HYP-VARIANCE-F-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats package documentation
- Citation
- R Core Team, stats package help: t.test, var.test, aov, binom.test, chisq.test, fisher.test, wilcox.test, kruskal.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_tests.R · sha256 d4285bc8becb7ad3
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "f"response= "x"test= "equal_variance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.9876086956521738 | 0.9876086956521734 | 4.48E-16 | 15 | passed |
/p_value | tail_probability | 0.98730004532327642 | 0.9873000453232759 | 5.54E-16 | 15 | passed |
/ci_lower | tolerance | 0.19772305207929139 | 0.19772305207929144 | 5.48E-17 | 15 | passed |
/ci_upper | tolerance | 4.9330157787400672 | 4.933015778740061 | 6.17E-15 | 14 | passed |
Convention
- var.test compares A/B sample variances in sorted group order.
- Expected computed from the exported CSV.
- docs/manual/chapters/07-models-and-tests.tex:827-828: 'Tests a population mean against the declared target.'
- docs/manual/chapters/07-models-and-tests.tex:855: 'Results lead with the estimate, confidence interval'
Reference code
The lines of the reference script that produce this case's expected values.
132 variance <- stats::var.test(x ~ g, data = d)
133 emit("STAT-HYP-VARIANCE-F-001", "Two-group variance ratio", "axis_coverage",
134 list(test = "equal_variance", response = "x", group = "g", method = "f"),
135 list("/statistic" = tol(variance$statistic, "variance ratio F"),
136 "/p_value" = prob(variance$p.value, "variance ratio F tail"),
137 "/ci_lower" = tol(variance$conf.int[[1]], "variance ratio CI lower"),
138 "/ci_upper" = tol(variance$conf.int[[2]], "variance ratio CI upper")),
139 list("var.test compares A/B sample variances in sorted group order."))
Brown-Forsythe median-centred variance test
Case STAT-HYP-VARIANCE-LEVENE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
group= "g"method= "levene"response= "x"test= "equal_variance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 0.045307443365696039 | 0.04530744336569605 | 1.36E-17 | 15 | passed |
/p_value | tail_probability | 0.83450794270745887 | 0.8345079427074588 | 1.09E-16 | 15 | passed |
Convention
- Levene deviations centred on each group's median.
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
69 lev <- car::leveneTest(x ~ g, data = d, center = median)
70 emit("STAT-HYP-VARIANCE-LEVENE-001", "Brown-Forsythe median-centred variance test",
71 list(test = "equal_variance", response = "x", group = "g", method = "levene"),
72 list("/statistic" = tol(lev[["F value"]][[1]], "Brown-Forsythe F"),
73 "/p_value" = prob(lev[["Pr(>F)"]][[1]], "Brown-Forsythe F tail")),
74 list("Levene deviations centred on each group's median."))
Paired Wilcoxon signed ranks
Case STAT-HYP-WILCOXON-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats and car
- Citation
- R Core Team, stats help: oneway.test, chisq.test, binom.test, wilcox.test, aov and kruskal.test; car::Anova and car::leveneTest help.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_methods.R · sha256 e2faa3576983ee8d
- Dataset
- reference_data/datasets/HYP_CORE.json
Settings compared
response= "x"second_response= "y"test= "wilcoxon"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | 136 | 136.0 | 0.00E+2 | passed | |
/p_value | tail_probability | 3.0517578125e-05 | 3.0517578125e-05 | 0.00E-13 | passed |
Convention
- Issue #12 ruling: W+ and exact conditional inference for m <= 50, including ties.
- Until 2026-09-25 this case used R's explicit normal approximation (exact = FALSE, correct = TRUE).
- Every statistic was computed after re-reading the exported HYP_CORE CSV.
Reference code
The lines of the reference script that produce this case's expected values.
88 wilcox <- stats::wilcox.test(paired_diff, mu = 0, exact = TRUE)
89 stopifnot(sum(paired_diff != 0) <= 50L)
90 emit("STAT-HYP-WILCOXON-001", "Paired Wilcoxon signed ranks",
91 list(test = "wilcoxon", response = "x", second_response = "y"),
92 list("/statistic" = tol(wilcox$statistic, "W+, the positive signed-rank sum"),
93 "/p_value" = prob(wilcox$p.value, "exact conditional signed-rank distribution with tied ranks")),
94 list("Issue #12 ruling: W+ and exact conditional inference for m <= 50, including ties.",
95 "Until 2026-09-25 this case used R's explicit normal approximation (exact = FALSE, correct = TRUE)."))
Binomial single-sampling plan: AQL 0.01, LTPD 0.06
Case STAT-MSA-ACCEPT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::pbinom, stats::qt (noncentral) and survival::survreg
- Citation
- R stats::Binomial, stats::TDist and survival::survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/measurement_manufacturing.R · sha256 5a42bd20f26f6b22
- Dataset
- None
Settings compared
aql= 0.01consumer_risk= 0.1ltpd= 0.06producer_risk= 0.05
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sample_size | exact | 110 | 110 | 0.00E+2 | passed | |
/accept_number | exact | 3 | 3 | 0.00E+2 | passed | |
/probability_accept_aql | tolerance | 0.9749618536347715 | 0.9749618536347714 | 1.08E-16 | 15 | passed |
/probability_accept_ltpd | tolerance | 0.098030380753621096 | 0.09803038075362057 | 5.27E-16 | 14 | passed |
Convention
- Search over n = 1, 2, ... and, for each n, c = 0, 1, ...; the first plan meeting both risks.
Reference code
Binomial single-sampling plan: AQL 0.02, LTPD 0.08
Case STAT-MSA-ACCEPT-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::pbinom, stats::qt (noncentral) and survival::survreg
- Citation
- R stats::Binomial, stats::TDist and survival::survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/measurement_manufacturing.R · sha256 5a42bd20f26f6b22
- Dataset
- None
Settings compared
aql= 0.02consumer_risk= 0.05ltpd= 0.08producer_risk= 0.1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sample_size | exact | 112 | 112 | 0.00E+2 | passed | |
/accept_number | exact | 4 | 4 | 0.00E+2 | passed | |
/probability_accept_aql | tolerance | 0.92509790466795905 | 0.9250979046679594 | 3.31E-16 | 15 | passed |
/probability_accept_ltpd | tolerance | 0.049490241670264092 | 0.04949024167026439 | 2.98E-16 | 14 | passed |
Convention
- Search over n = 1, 2, ... and, for each n, c = 0, 1, ...; the first plan meeting both risks.
Reference code
An AQL at or above the LTPD is refused
Case STAT-MSA-ACCEPT-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::pbinom, stats::qt (noncentral) and survival::survreg
- Citation
- R stats::Binomial, stats::TDist and survival::survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/measurement_manufacturing.R · sha256 5a42bd20f26f6b22
- Dataset
- None
Settings compared
aql= 0.05ltpd= 0.05
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A plan needs AQL < LTPD.
Reference code
The lines of the reference script that produce this case's expected values.
74 emit("STAT-MSA-ACCEPT-003", acc, "An AQL at or above the LTPD is refused", NULL, list(aql = 0.05, ltpd = 0.05), list(),
75 c("A plan needs AQL < LTPD."), kind = "invalid_input", error = list(error_class = "ValueError", message_contains = "LTPD"))
Three appraisers, two trials and a known standard
Case STAT-MSA-AGREE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test
- Citation
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_AGREE.json
Settings compared
appraiser= "appraiser"part= "item"rating= "rating"standard= "standard"trial= "trial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/appraisers/[appraiser=Ann]/within/agreement_pct | tolerance | 83.333333333333329 | 83.33333333333334 | 1.38E-14 | 15 | passed |
/appraisers/[appraiser=Ann]/within/ci_lower | tolerance | 55.196913774702658 | 55.19691377470266 | 8.23E-17 | 17 | passed |
/appraisers/[appraiser=Ann]/within/ci_upper | tolerance | 95.303485781614626 | 95.30348578161463 | 3.06E-16 | 17 | passed |
/appraisers/[appraiser=Ann]/within/kappa | tolerance | 0.67567567567567588 | 0.6756756756756758 | 1.11E-16 | 15 | passed |
/appraisers/[appraiser=Ann]/versus_standard/agreement_pct | tolerance | 91.666666666666671 | 91.66666666666666 | 1.38E-14 | 15 | passed |
/appraisers/[appraiser=Bob]/within/agreement_pct | tolerance | 75 | 75.0 | 0.00E+2 | passed | |
/appraisers/[appraiser=Bob]/within/ci_lower | tolerance | 46.76946650664344 | 46.769466506643425 | 1.46E-14 | 15 | passed |
/appraisers/[appraiser=Bob]/within/ci_upper | tolerance | 91.105833160594514 | 91.10583316059453 | 1.44E-14 | 15 | passed |
/appraisers/[appraiser=Bob]/within/kappa | tolerance | 0.47058823529411764 | 0.47058823529411764 | 5.28E-19 | 17 | passed |
/appraisers/[appraiser=Bob]/versus_standard/agreement_pct | tolerance | 79.166666666666671 | 79.16666666666666 | 1.38E-14 | 15 | passed |
/appraisers/[appraiser=Cy]/within/agreement_pct | tolerance | 58.333333333333336 | 58.333333333333336 | 2.98E-16 | 17 | passed |
/appraisers/[appraiser=Cy]/within/ci_lower | tolerance | 31.951131254954984 | 31.951131254954973 | 1.11E-14 | 15 | passed |
/appraisers/[appraiser=Cy]/within/ci_upper | tolerance | 80.67396863412435 | 80.67396863412435 | 1.81E-16 | 17 | passed |
/appraisers/[appraiser=Cy]/within/kappa | tolerance | 0.16666666666666674 | 0.16666666666666663 | 1.10E-16 | 15 | passed |
/appraisers/[appraiser=Cy]/versus_standard/agreement_pct | tolerance | 54.166666666666664 | 54.166666666666664 | 2.98E-16 | 17 | passed |
/between/agreement_pct | tolerance | 41.666666666666664 | 41.66666666666667 | 7.40E-15 | 15 | passed |
/between/kappa | tolerance | 0.21249999999999983 | 0.21249999999999983 | 2.08E-18 | 17 | passed |
/n_trials | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Nominal scale (line 288); Fleiss kappa for more than two appraisers (line 302).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
85 ratings <- sapply(appr, function(ap) c(rating_of(ap, "T1"), rating_of(ap, "T2")))
86 between <- sum(apply(ratings, 1, function(v) length(unique(v)) == 1))
87 out[["/between/agreement_pct"]] <- tol(100 * between / 24, "Item-and-trial pairs where all appraisers agree.")
88 out[["/between/kappa"]] <- tol(irr::kappam.fleiss(ratings)$value, "Fleiss kappa over three appraisers.")
89 out[["/n_trials"]] <- exact(2L, "Two trials.")
90 emit("STAT-MSA-AGREE-001", agree_entry, "attributeAgreementMenuItem", "Three appraisers, two trials and a known standard", "MSA_AGREE",
91 list(rating = "rating", part = "item", appraiser = "appraiser", trial = "trial", standard = "standard"), out,
92 c("Nominal scale (line 288); Fleiss kappa for more than two appraisers (line 302)."))
Two appraisers use Cohen kappa between them
Case STAT-MSA-AGREE-002 · status: passed
Reference
- Evidence type
- R
- Source
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test
- Citation
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_AGREE_TWO.json
Settings compared
appraiser= "appraiser"part= "item"rating= "rating"trial= "trial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/between/kappa | tolerance | 0.58333333333333326 | 0.5833333333333333 | 6.82E-19 | 17 | passed |
/between/agreement_pct | tolerance | 79.166666666666657 | 79.16666666666666 | 1.93E-16 | 17 | passed |
/overall_standard | absent | None | passed |
Convention
- Two appraisers.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
93 two <- read_dataset("MSA_AGREE"); two <- two[two$appraiser != "Cy", ]
94 export_dataset(two, "MSA_AGREE_TWO", "MSA_AGREE with appraisers Ann and Bob only", "R stats::runif documentation",
95 "Constructed validation data; no third-party license.",
96 c(item = "String", appraiser = "String", trial = "String", rating = "String", standard = "String"))
97 a <- read_dataset("MSA_AGREE_TWO")
98 ratings2 <- sapply(c("Ann", "Bob"), function(ap) c(rating_of(ap, "T1"), rating_of(ap, "T2")))
99 emit("STAT-MSA-AGREE-002", agree_entry, "attributeAgreementMenuItem", "Two appraisers use Cohen kappa between them", "MSA_AGREE_TWO",
100 list(rating = "rating", part = "item", appraiser = "appraiser", trial = "trial"),
101 list("/between/kappa" = tol(irr::kappa2(ratings2)$value, "Cohen kappa for two appraisers (line 302)."),
102 "/between/agreement_pct" = tol(100 * mean(ratings2[, 1] == ratings2[, 2]), "Item-and-trial agreement."),
103 "/overall_standard" = absent("No standard was assigned.")),
104 c("Two appraisers."), kind = "axis_coverage")
Weighted Cohen kappa: ordinal_linear
Case STAT-MSA-AGREE-003 · status: passed
Reference
- Evidence type
- R
- Source
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test
- Citation
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_AGREE_ORDINAL.json
Settings compared
appraiser= "appraiser"part= "item"rating= "rating"scale= "ordinal_linear"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/between/kappa | tolerance | 0.38144329896907203 | 0.38144329896907214 | 1.12E-16 | 15 | passed |
Convention
- Numeric-looking categories are ordered numerically (line 309-310); one trial.
- All reference calculations re-read the exported CSV.
Reference code
Weighted Cohen kappa: ordinal_quadratic
Case STAT-MSA-AGREE-004 · status: passed
Reference
- Evidence type
- R
- Source
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test
- Citation
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_AGREE_ORDINAL.json
Settings compared
appraiser= "appraiser"part= "item"rating= "rating"scale= "ordinal_quadratic"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/between/kappa | tolerance | 0.44444444444444464 | 0.4444444444444441 | 5.53E-16 | 14 | passed |
Convention
- Numeric-looking categories are ordered numerically (line 309-310); one trial.
- All reference calculations re-read the exported CSV.
Reference code
Repeated columns are refused
Case STAT-MSA-AGREE-005 · status: passed
Reference
- Evidence type
- R
- Source
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test
- Citation
- R irr::kappa2, irr::kappam.fleiss and stats::prop.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_AGREE.json
Settings compared
appraiser= "item"part= "item"rating= "rating"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 293: all assigned columns must be distinct.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
121 emit("STAT-MSA-AGREE-005", agree_entry, "attributeAgreementMenuItem", "Repeated columns are refused", "MSA_AGREE",
122 list(rating = "rating", part = "item", appraiser = "item"), list(),
123 c("Line 293: all assigned columns must be distinct."), kind = "invalid_input",
124 error = list(error_class = "ValueError", message_contains = "must use a different column"))
AIAG MSA-4 ANOVA Gage R&R on the Figure III-B 15 data (interaction pooled)
Case STAT-MSA-AIAG-ANOVA-001 · status: imprecise_reference
Reference
- Evidence type
- Published example
- Source
- MSA-4 worked examples, as recorded in the approved AIAG MSA-4 specification (sections 6 and 7) with its documented printed discrepancies.
- Citation
- AIAG, Measurement Systems Analysis Reference Manual, 4th edition (2010), Chapter III Section B, Chapter IV Sections E and H, Appendices A and B
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MSA_AIAG_FIG_IIIB15.json
Settings compared
appraiser_column= "appraiser"max_rows= 1000000measurement_column= "y"method= "anova"part_column= "part"process_sd= nullreference_column= nullstandard= {"identifier": "aiag-msa-4", "name": "AIAG MSA, 4th ed.", "version": 1, "built_in": true, "external_label": true, "fingerprint": "5d1842e99ace9d1d24abfa59ab42370ee2d3a2c49d650dfbadd88259d31ba67d", "effective_fingerprint": "8fc9f2f1f400754051e434d7497668a5bf0dd29fea1e673cbb3ba179582a4eff", "lineage": [], "settings": {"spread_multiplier": 6.0, "percent_tolerance_basis": "fixed_six_sigma", "guideline_lower_pct": 10.0, "guideline_upper_pct": 30.0, "guidance_wording": "decision_phrases", "guidance_caution": true, "decision_basis": "intended_use", "ndc_constant": 1.41, "ndc_rounding": "truncate_minimum_one", "ndc_guidance_minimum": 5, "interaction_alpha": 0.25, "interaction_explanation": true, "interaction_row": "separate", "main_effect_f": "not_reported", "confidence_limits": "none", "confidence_level": 0.95, "zero_residual_ms": "withhold_model", "unbalanced_data": "refuse", "k_decimals": 4, "range_d2_star_decimals": 5, "control_factor_rule": "report_form", "constants_beyond_tables": "formula", "display_precision": "report_form", "report_layout": "report_form", "design_min_parts": 10, "design_min_ranges": 15, "show_assumptions": true, "appraiser_label": "Appraiser (or fixture)", "out_of_control_ranges": "flag_and_compute", "negative_pv_squared": "boundary_zero", "appendix_e_pv": false, "methods": ["anova", "average_range", "range", "chart_worksheet", "pooled_sd"], "default_method": "anova", "graphical_analysis": true, "gage_r_study": true, "gage_r_readings": 10, "gage_r_estimator": "sample_sd", "cp_impact_panel": true, "chart_worksheet_constants": "section_e_tables", "chart_worksheet_category_meanings": true, "pooled_sd_chart_limits": "pooled_c4", "pooled_sd_descriptive_h_index": true}, "study_choices": {}, "changes_from_base": [], "documentation": "User manual, Gage R&R chapter, section on measurement-system standards", "recorded_only": false}total_variation= {"option": "study", "process_spread": null, "target_pp": null, "tolerance": 8.0, "intended_use": "process"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/anova/table/[source=Parts]/ss | tolerance | 88.3619 | 88.36193444444444 | 3.44E-5 | 6 | passed |
/anova/table/[source=Appraiser]/ss | tolerance | 3.1673 | 3.167262222222222 | 3.78E-5 | 4 | passed |
/anova/table/[source=Appraiser by part]/ss | tolerance | 0.3590 | 0.35898222222222204 | 1.78E-5 | 4 | passed |
/anova/table/[source=Equipment]/ss | tolerance | 2.7589 | 2.7589333333333337 | 3.33E-5 | 4 | passed |
/anova/decision/f | tolerance | 0.434 | 0.43372103013510294 | imprecise_reference | ||
/anova/decision/decision | exact | pooled | pooled | passed | ||
/anova/part_variance | tolerance | 1.086447 | 1.0864466044106784 | 3.96E-7 | 6 | passed |
/summary/rows/[key=ev]/std_dev | tolerance | 0.199933 | 0.19993317972081662 | 1.80E-7 | 6 | passed |
/summary/rows/[key=av]/std_dev | tolerance | 0.226838 | 0.2268375214963223 | 4.79E-7 | 5 | passed |
/summary/rows/[key=int]/std_dev | tolerance | 0 | 0.0 | 0.00E+2 | 15 | passed |
/summary/rows/[key=grr]/variance | tolerance | 0.09143 | 0.09142853751187084 | 1.46E-6 | 4 | passed |
/summary/rows/[key=pv]/std_dev | tolerance | 1.042327 | 1.0423274938380347 | 4.94E-7 | 6 | passed |
/summary/rows/[key=tv]/std_dev | tolerance | 1.085 | 1.08529956321863 | imprecise_reference | ||
/summary/rows/[key=grr]/pct_total_variation | tolerance | 27.9 | 27.86065088114229 | imprecise_reference | ||
/summary/rows/[key=grr]/pct_contribution | tolerance | 7.8 | 7.762158675208948 | imprecise_reference | ||
/summary/rows/[key=pv]/pct_total_variation | tolerance | 96.0 | 96.04053379942818 | imprecise_reference | ||
/summary/rows/[key=grr]/pct_tolerance | tolerance | 22.68 | 22.67786417421785 | 2.14E-3 | 4 | passed |
/summary/ndc/value | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Table A 5 prints GRR SD 0.302373 and 6-sigma 1.814238; the raw data give 0.3023715 and 1.8142291. sqrt(0.09143) = 0.3023739 rounds to 0.302374, so the printed pair is consistent with the rounded variance and a truncated SD, not ordinary rounding (issue #17); the variance is compared instead.
- Main-effect F values are not reported under this profile (Q19, D4).
AIAG MSA-4 Average and Range on the Figure III-B 15 raw data
Case STAT-MSA-AIAG-AR-001 · status: imprecise_reference
Reference
- Evidence type
- Published example
- Source
- MSA-4 worked examples, as recorded in the approved AIAG MSA-4 specification (sections 6 and 7) with its documented printed discrepancies.
- Citation
- AIAG, Measurement Systems Analysis Reference Manual, 4th edition (2010), Chapter III Section B, Chapter IV Sections E and H, Appendices A and B
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MSA_AIAG_FIG_IIIB15.json
Settings compared
appraiser_column= "appraiser"max_rows= 1000000measurement_column= "y"method= "average_range"part_column= "part"process_sd= nullreference_column= nullstandard= {"identifier": "aiag-msa-4", "name": "AIAG MSA, 4th ed.", "version": 1, "built_in": true, "external_label": true, "fingerprint": "5d1842e99ace9d1d24abfa59ab42370ee2d3a2c49d650dfbadd88259d31ba67d", "effective_fingerprint": "8fc9f2f1f400754051e434d7497668a5bf0dd29fea1e673cbb3ba179582a4eff", "lineage": [], "settings": {"spread_multiplier": 6.0, "percent_tolerance_basis": "fixed_six_sigma", "guideline_lower_pct": 10.0, "guideline_upper_pct": 30.0, "guidance_wording": "decision_phrases", "guidance_caution": true, "decision_basis": "intended_use", "ndc_constant": 1.41, "ndc_rounding": "truncate_minimum_one", "ndc_guidance_minimum": 5, "interaction_alpha": 0.25, "interaction_explanation": true, "interaction_row": "separate", "main_effect_f": "not_reported", "confidence_limits": "none", "confidence_level": 0.95, "zero_residual_ms": "withhold_model", "unbalanced_data": "refuse", "k_decimals": 4, "range_d2_star_decimals": 5, "control_factor_rule": "report_form", "constants_beyond_tables": "formula", "display_precision": "report_form", "report_layout": "report_form", "design_min_parts": 10, "design_min_ranges": 15, "show_assumptions": true, "appraiser_label": "Appraiser (or fixture)", "out_of_control_ranges": "flag_and_compute", "negative_pv_squared": "boundary_zero", "appendix_e_pv": false, "methods": ["anova", "average_range", "range", "chart_worksheet", "pooled_sd"], "default_method": "anova", "graphical_analysis": true, "gage_r_study": true, "gage_r_readings": 10, "gage_r_estimator": "sample_sd", "cp_impact_panel": true, "chart_worksheet_constants": "section_e_tables", "chart_worksheet_category_meanings": true, "pooled_sd_chart_limits": "pooled_c4", "pooled_sd_descriptive_h_index": true}, "study_choices": {}, "changes_from_base": [], "documentation": "User manual, Gage R&R chapter, section on measurement-system standards", "recorded_only": false}total_variation= {"option": "study", "process_spread": null, "target_pp": null, "tolerance": null, "intended_use": "process"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/average_range/r_double_bar | tolerance | 0.3417 | 0.34166666666666673 | 3.33E-5 | 4 | passed |
/average_range/x_diff | tolerance | 0.4446 | 0.44466666666666665 | imprecise_reference | ||
/average_range/r_p | tolerance | 3.511 | 3.511111111111111 | 1.11E-4 | 4 | passed |
/average_range/ucl_r | tolerance | 0.8816 | 0.8815000000000002 | imprecise_reference | ||
/average_range/out_of_control/0/appraiser | exact | B | B | passed | ||
/average_range/out_of_control/0/part | exact | 4 | 4 | passed | ||
/summary/rows/[key=ev]/std_dev | tolerance | 0.20188 | 0.2018566666666667 | imprecise_reference | ||
/summary/rows/[key=av]/std_dev | tolerance | 0.22963 | 0.22966702910320377 | imprecise_reference | ||
/summary/rows/[key=grr]/std_dev | tolerance | 0.30575 | 0.30576634565443866 | 1.63E-5 | 4 | passed |
/summary/rows/[key=pv]/std_dev | tolerance | 1.10456 | 1.1045955555555556 | 3.56E-5 | 4 | passed |
/summary/rows/[key=tv]/std_dev | tolerance | 1.14610 | 1.1461345468521382 | 3.45E-5 | 4 | passed |
/summary/rows/[key=grr]/pct_total_variation | tolerance | 26.68 | 26.678049841026677 | 1.95E-3 | 4 | passed |
/summary/ndc/value | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- Printed results come from rounded intermediates; the raw data are compared at four significant digits (Q16). %EV prints 17.62 but computes to 17.61 (D16).
AIAG MSA-4 Appendix B impact of GRR on Cp (corrected tolerance formula)
Case STAT-MSA-AIAG-CP-001 · status: passed
Reference
- Evidence type
- Published example
- Source
- MSA-4 worked examples, as recorded in the approved AIAG MSA-4 specification (sections 6 and 7) with its documented printed discrepancies.
- Citation
- AIAG, Measurement Systems Analysis Reference Manual, 4th edition (2010), Chapter III Section B, Chapter IV Sections E and H, Appendices A and B
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- None
Settings compared
measurement_sd= 0.6observed_cp= 2.0observed_sd= 1.0tolerance= 12.0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/bases/[basis=process]/actual_cp | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/bases/[basis=tolerance]/actual_cp | tolerance | 2.5 | 2.5 | 0.00E+1 | passed |
Convention
- Observed Cp only; Cpk is refused (Q13).
AIAG MSA-4 Chapter IV Section H pooled standard deviation study
Case STAT-MSA-AIAG-POOLED-001 · status: imprecise_reference
Reference
- Evidence type
- Published example
- Source
- MSA-4 worked examples, as recorded in the approved AIAG MSA-4 specification (sections 6 and 7) with its documented printed discrepancies.
- Citation
- AIAG, Measurement Systems Analysis Reference Manual, 4th edition (2010), Chapter III Section B, Chapter IV Sections E and H, Appendices A and B
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MSA_AIAG_FIG_IIIB15.json
Settings compared
appraiser_column= "appraiser"max_rows= 1000000measurement_column= "y"method= "pooled_sd"part_column= "part"process_sd= nullreference_column= nullstandard= {"identifier": "aiag-msa-4", "name": "AIAG MSA, 4th ed.", "version": 1, "built_in": true, "external_label": true, "fingerprint": "5d1842e99ace9d1d24abfa59ab42370ee2d3a2c49d650dfbadd88259d31ba67d", "effective_fingerprint": "8fc9f2f1f400754051e434d7497668a5bf0dd29fea1e673cbb3ba179582a4eff", "lineage": [], "settings": {"spread_multiplier": 6.0, "percent_tolerance_basis": "fixed_six_sigma", "guideline_lower_pct": 10.0, "guideline_upper_pct": 30.0, "guidance_wording": "decision_phrases", "guidance_caution": true, "decision_basis": "intended_use", "ndc_constant": 1.41, "ndc_rounding": "truncate_minimum_one", "ndc_guidance_minimum": 5, "interaction_alpha": 0.25, "interaction_explanation": true, "interaction_row": "separate", "main_effect_f": "not_reported", "confidence_limits": "none", "confidence_level": 0.95, "zero_residual_ms": "withhold_model", "unbalanced_data": "refuse", "k_decimals": 4, "range_d2_star_decimals": 5, "control_factor_rule": "report_form", "constants_beyond_tables": "formula", "display_precision": "report_form", "report_layout": "report_form", "design_min_parts": 10, "design_min_ranges": 15, "show_assumptions": true, "appraiser_label": "Appraiser (or fixture)", "out_of_control_ranges": "flag_and_compute", "negative_pv_squared": "boundary_zero", "appendix_e_pv": false, "methods": ["anova", "average_range", "range", "chart_worksheet", "pooled_sd"], "default_method": "anova", "graphical_analysis": true, "gage_r_study": true, "gage_r_readings": 10, "gage_r_estimator": "sample_sd", "cp_impact_panel": true, "chart_worksheet_constants": "section_e_tables", "chart_worksheet_category_meanings": true, "pooled_sd_chart_limits": "pooled_c4", "pooled_sd_descriptive_h_index": true}, "study_choices": {}, "changes_from_base": [], "documentation": "User manual, Gage R&R chapter, section on measurement-system standards", "recorded_only": false}total_variation= {"option": "study", "process_spread": null, "target_pp": null, "tolerance": null, "intended_use": "process"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pooled_sd/pooled_repeatability | tolerance | 0.21443466 | 0.21443465723203942 | 2.77E-9 | 7 | passed |
/pooled_sd/pooled_reproducibility | tolerance | 0.20843064 | 0.20843064394021651 | 3.94E-9 | 7 | passed |
/pooled_sd/pooled_grr | tolerance | 0.29904106 | 0.2990410599826645 | 1.73E-11 | 10 | passed |
/pooled_sd/limits/sigma | tolerance | 0.2153 | 0.21532995744686606 | imprecise_reference | ||
/pooled_sd/limits/s_center | tolerance | 0.1908 | 0.1908312061460093 | imprecise_reference |
Convention
- Reproducibility divides by r (Q24, D10); no z for k (Q25, D11).
AIAG MSA-4 Range method on the Table III-B 6 data
Case STAT-MSA-AIAG-RANGE-001 · status: imprecise_reference
Reference
- Evidence type
- Published example
- Source
- MSA-4 worked examples, as recorded in the approved AIAG MSA-4 specification (sections 6 and 7) with its documented printed discrepancies.
- Citation
- AIAG, Measurement Systems Analysis Reference Manual, 4th edition (2010), Chapter III Section B, Chapter IV Sections E and H, Appendices A and B
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MSA_AIAG_TABLE_IIIB6.json
Settings compared
appraiser_column= "appraiser"max_rows= 1000000measurement_column= "y"method= "range"part_column= "part"process_sd= 0.0777reference_column= nullstandard= {"identifier": "aiag-msa-4", "name": "AIAG MSA, 4th ed.", "version": 1, "built_in": true, "external_label": true, "fingerprint": "5d1842e99ace9d1d24abfa59ab42370ee2d3a2c49d650dfbadd88259d31ba67d", "effective_fingerprint": "8fc9f2f1f400754051e434d7497668a5bf0dd29fea1e673cbb3ba179582a4eff", "lineage": [], "settings": {"spread_multiplier": 6.0, "percent_tolerance_basis": "fixed_six_sigma", "guideline_lower_pct": 10.0, "guideline_upper_pct": 30.0, "guidance_wording": "decision_phrases", "guidance_caution": true, "decision_basis": "intended_use", "ndc_constant": 1.41, "ndc_rounding": "truncate_minimum_one", "ndc_guidance_minimum": 5, "interaction_alpha": 0.25, "interaction_explanation": true, "interaction_row": "separate", "main_effect_f": "not_reported", "confidence_limits": "none", "confidence_level": 0.95, "zero_residual_ms": "withhold_model", "unbalanced_data": "refuse", "k_decimals": 4, "range_d2_star_decimals": 5, "control_factor_rule": "report_form", "constants_beyond_tables": "formula", "display_precision": "report_form", "report_layout": "report_form", "design_min_parts": 10, "design_min_ranges": 15, "show_assumptions": true, "appraiser_label": "Appraiser (or fixture)", "out_of_control_ranges": "flag_and_compute", "negative_pv_squared": "boundary_zero", "appendix_e_pv": false, "methods": ["anova", "average_range", "range", "chart_worksheet", "pooled_sd"], "default_method": "anova", "graphical_analysis": true, "gage_r_study": true, "gage_r_readings": 10, "gage_r_estimator": "sample_sd", "cp_impact_panel": true, "chart_worksheet_constants": "section_e_tables", "chart_worksheet_category_meanings": true, "pooled_sd_chart_limits": "pooled_c4", "pooled_sd_descriptive_h_index": true}, "study_choices": {}, "changes_from_base": [], "documentation": "User manual, Gage R&R chapter, section on measurement-system standards", "recorded_only": false}total_variation= {"option": "study", "process_spread": null, "target_pp": null, "tolerance": null, "intended_use": "process"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/range_method/average_range | tolerance | 0.07 | 0.07 | 6.66E-18 | 16 | passed |
/range_method/d2_star | tolerance | 1.19105 | 1.19105 | 5.79E-17 | 16 | passed |
/range_method/grr_sd | tolerance | 0.0588 | 0.05877167205406995 | imprecise_reference | ||
/range_method/pct_grr | tolerance | 75.6 | 75.63921757280559 | imprecise_reference |
Convention
- The example divides by the rounded 1.19; Appendix C's 1.19105 is used (Q6, D7).
AIAG MSA-4 Chapter IV Section E control-chart worksheet
Case STAT-MSA-AIAG-WORKSHEET-001 · status: imprecise_reference
Reference
- Evidence type
- Published example
- Source
- MSA-4 worked examples, as recorded in the approved AIAG MSA-4 specification (sections 6 and 7) with its documented printed discrepancies.
- Citation
- AIAG, Measurement Systems Analysis Reference Manual, 4th edition (2010), Chapter III Section B, Chapter IV Sections E and H, Appendices A and B
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MSA_AIAG_FIG_IVE.json
Settings compared
appraiser_column= "appraiser"max_rows= 1000000measurement_column= "y"method= "chart_worksheet"part_column= "part"process_sd= nullreference_column= nullstandard= {"identifier": "aiag-msa-4", "name": "AIAG MSA, 4th ed.", "version": 1, "built_in": true, "external_label": true, "fingerprint": "5d1842e99ace9d1d24abfa59ab42370ee2d3a2c49d650dfbadd88259d31ba67d", "effective_fingerprint": "8fc9f2f1f400754051e434d7497668a5bf0dd29fea1e673cbb3ba179582a4eff", "lineage": [], "settings": {"spread_multiplier": 6.0, "percent_tolerance_basis": "fixed_six_sigma", "guideline_lower_pct": 10.0, "guideline_upper_pct": 30.0, "guidance_wording": "decision_phrases", "guidance_caution": true, "decision_basis": "intended_use", "ndc_constant": 1.41, "ndc_rounding": "truncate_minimum_one", "ndc_guidance_minimum": 5, "interaction_alpha": 0.25, "interaction_explanation": true, "interaction_row": "separate", "main_effect_f": "not_reported", "confidence_limits": "none", "confidence_level": 0.95, "zero_residual_ms": "withhold_model", "unbalanced_data": "refuse", "k_decimals": 4, "range_d2_star_decimals": 5, "control_factor_rule": "report_form", "constants_beyond_tables": "formula", "display_precision": "report_form", "report_layout": "report_form", "design_min_parts": 10, "design_min_ranges": 15, "show_assumptions": true, "appraiser_label": "Appraiser (or fixture)", "out_of_control_ranges": "flag_and_compute", "negative_pv_squared": "boundary_zero", "appendix_e_pv": false, "methods": ["anova", "average_range", "range", "chart_worksheet", "pooled_sd"], "default_method": "anova", "graphical_analysis": true, "gage_r_study": true, "gage_r_readings": 10, "gage_r_estimator": "sample_sd", "cp_impact_panel": true, "chart_worksheet_constants": "section_e_tables", "chart_worksheet_category_meanings": true, "pooled_sd_chart_limits": "pooled_c4", "pooled_sd_descriptive_h_index": true}, "study_choices": {}, "changes_from_base": [], "documentation": "User manual, Gage R&R chapter, section on measurement-system standards", "recorded_only": false}total_variation= {"option": "study", "process_spread": null, "target_pp": null, "tolerance": null, "intended_use": "process"}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/worksheet/average_range | tolerance | 7.6 | 7.6 | 3.55E-16 | 16 | passed |
/worksheet/range_upper_limit | tolerance | 24.8 | 24.836799999999997 | imprecise_reference | ||
/worksheet/measurement_sd | tolerance | 7.289 | 7.288851206246975 | 1.49E-4 | 4 | passed |
/worksheet/signal_to_noise | tolerance | 1.698 | 1.6985623030218318 | imprecise_reference | ||
/worksheet/ndc/value | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Uses the Section E printed d2 and d2* tables (Q21).
Deming regression with lambda 1
Case STAT-MSA-DEMING-001 · status: passed
Reference
- Evidence type
- R
- Source
- mcr 1.3.3.1 Deming point estimates and Linnet jackknife intervals; independent R arithmetic for other fields
- Citation
- mcr 1.3.3.1 mcreg documentation; NCSS Deming Regression chapter 303, Program 1; NIST Dataplot reproduces that NCSS example in case 007
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, mcr 1.3.3.1
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING.json
Settings compared
x_column= "method_a"y_column= "method_b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/slope | tolerance | 1.0309691752882242 | 1.0309691752882242 | 1.78E-17 | 16 | passed |
/intercept | tolerance | 0.50842217430130709 | 0.5084221743012982 | 8.88E-15 | 13 | passed |
/sxy | tolerance | 1365.4039025060001 | 1365.4039025060003 | 2.50E-13 | 15 | passed |
/rows/0/xhat | tolerance | 8.7204721265056406 | 8.72047212650564 | 3.10E-17 | 17 | passed |
/rows/0/y_residual | tolerance | -0.32186013068876917 | -0.3218601306887656 | 3.55E-15 | 13 | passed |
/rows/17/xhat | tolerance | 7.0748634114385238 | 7.074863411438524 | 1.92E-17 | 17 | passed |
/rows/17/y_residual | tolerance | -0.20498827086890881 | -0.20498827086890525 | 3.56E-15 | 13 | passed |
/rows/39/xhat | tolerance | 6.0384153765039983 | 6.038415376503998 | 1.14E-17 | 17 | passed |
/rows/39/y_residual | tolerance | 0.27955770493663934 | 0.2795577049366429 | 3.55E-15 | 13 | passed |
Convention
- Orthogonal regression at lambda = 1.
- mcr supplies slope/intercept; closed-form R supplies Sxy and latent row outputs.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
76 set.seed(20261027)
77 truth <- runif(40, 5, 25)
78 x <- round(truth + rnorm(40, 0, 0.4), 4); y <- round(0.3 + 1.04 * truth + rnorm(40, 0, 0.6), 4)
79 export_dataset(data.frame(method_a = x, method_b = y), "MSA_DEMING", "Constructed method comparison: 40 pairs, X error SD 0.4, Y error SD 0.6, seed 20261027",
80 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(method_a = "Float64", method_b = "Float64"))
81 d <- read_dataset("MSA_DEMING")
82 fit1 <- mcr_fit(d$method_a, d$method_b, 1)
83 out1 <- outputs(deming(d$method_a, d$method_b, 1), d$method_a, d$method_b, c(0L, 17L, 39L))
84 out1[["/slope"]] <- mcr_point(fit1, "Slope"); out1[["/intercept"]] <- mcr_point(fit1, "Intercept")
85 emit("STAT-MSA-DEMING-001", "Deming regression with lambda 1", "MSA_DEMING", list(x_column = "method_a", y_column = "method_b"),
86 out1, c("Orthogonal regression at lambda = 1.", "mcr supplies slope/intercept; closed-form R supplies Sxy and latent row outputs."), oracle = "mcr")
Deming regression with lambda 2.25
Case STAT-MSA-DEMING-002 · status: passed
Reference
- Evidence type
- R
- Source
- mcr 1.3.3.1 Deming point estimates and Linnet jackknife intervals; independent R arithmetic for other fields
- Citation
- mcr 1.3.3.1 mcreg documentation; NCSS Deming Regression chapter 303, Program 1; NIST Dataplot reproduces that NCSS example in case 007
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, mcr 1.3.3.1
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING.json
Settings compared
comparable_units= truelambda_ratio= 2.25x_column= "method_a"y_column= "method_b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/slope | tolerance | 1.0285273327945612 | 1.0285273327945612 | 1.10E-17 | 16 | passed |
/intercept | tolerance | 0.54330158067751988 | 0.543301580677511 | 8.88E-15 | 13 | passed |
/sxy | tolerance | 1365.4039025060001 | 1365.4039025060003 | 2.50E-13 | 15 | passed |
/rows/0/xhat | tolerance | 8.8418789583985475 | 8.84187895839855 | 1.82E-15 | 15 | passed |
/rows/0/y_residual | tolerance | -0.46031576265152729 | -0.46031576265152374 | 3.55E-15 | 14 | passed |
/rows/39/xhat | tolerance | 5.9230357017921182 | 5.923035701792118 | 4.61E-17 | 17 | passed |
/rows/39/y_residual | tolerance | 0.37809430691127677 | 0.37809430691127943 | 2.66E-15 | 14 | passed |
Convention
- lambda = 0.6^2 / 0.4^2 = 2.25; mcr error.ratio = 1/2.25.
- mcr supplies slope/intercept; closed-form R supplies Sxy and latent row outputs.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
87 fit2 <- mcr_fit(d$method_a, d$method_b, 2.25)
88 out2 <- outputs(deming(d$method_a, d$method_b, 2.25), d$method_a, d$method_b, c(0L, 39L))
89 out2[["/slope"]] <- mcr_point(fit2, "Slope"); out2[["/intercept"]] <- mcr_point(fit2, "Intercept")
90 emit("STAT-MSA-DEMING-002", "Deming regression with lambda 2.25", "MSA_DEMING",
91 list(x_column = "method_a", y_column = "method_b", lambda_ratio = 2.25, comparable_units = TRUE),
92 out2,
93 c("lambda = 0.6^2 / 0.4^2 = 2.25; mcr error.ratio = 1/2.25.",
94 "mcr supplies slope/intercept; closed-form R supplies Sxy and latent row outputs."),
95 kind = "axis_coverage", oracle = "mcr")
Swapping X and Y with 1/lambda gives the inverse line
Case STAT-MSA-DEMING-003 · status: passed
Reference
- Evidence type
- R
- Source
- mcr 1.3.3.1 Deming point estimates and Linnet jackknife intervals; independent R arithmetic for other fields
- Citation
- mcr 1.3.3.1 mcreg documentation; NCSS Deming Regression chapter 303, Program 1; NIST Dataplot reproduces that NCSS example in case 007
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, mcr 1.3.3.1
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING.json
Settings compared
lambda_ratio= 0.444444444444444x_column= "method_b"y_column= "method_a"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/slope | tolerance | 0.97226390404516416 | 0.9722639040451642 | 2.33E-18 | 17 | passed |
/intercept | tolerance | -0.5282325159034329 | -0.528232515903424 | 8.88E-15 | 13 | passed |
Convention
- R: 1 / b(lambda 2.25) = 0.972263904045164 and b(swapped, 1/2.25) = 0.972263904045164.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
96 inv <- deming(d$method_b, d$method_a, 1 / 2.25)
97 fit3 <- mcr_fit(d$method_b, d$method_a, 1 / 2.25)
98 emit("STAT-MSA-DEMING-003", "Swapping X and Y with 1/lambda gives the inverse line", "MSA_DEMING",
99 list(x_column = "method_b", y_column = "method_a", lambda_ratio = 1 / 2.25),
100 list("/slope" = mcr_point(fit3, "Slope"), "/intercept" = mcr_point(fit3, "Intercept")),
101 c(sprintf("R: 1 / b(lambda 2.25) = %.15g and b(swapped, 1/2.25) = %.15g.", 1 / deming(d$method_a, d$method_b, 2.25)$b, inv$b)),
102 kind = "axis_coverage", oracle = "mcr")
Missing and excluded pairs keep their rows without fitted values
Case STAT-MSA-DEMING-004 · status: passed
Reference
- Evidence type
- R
- Source
- mcr 1.3.3.1 Deming point estimates and Linnet jackknife intervals; independent R arithmetic for other fields
- Citation
- mcr 1.3.3.1 mcreg documentation; NCSS Deming Regression chapter 303, Program 1; NIST Dataplot reproduces that NCSS example in case 007
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, mcr 1.3.3.1
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING_MISSING.json
Settings compared
x_column= "method_a"y_column= "method_b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/slope | tolerance | 1.0218922588861608 | 1.0218922588861608 | 4.63E-17 | 16 | passed |
/rows/0/xhat | absent | None | passed | |||
/rows/4/xhat | absent | None | passed | |||
/rows/1/xhat | tolerance | 23.409272241106173 | 23.409272241106166 | 7.22E-15 | 15 | passed |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed | |
/missing_count | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Rows 0 and 20 (0-based) are excluded; mcr fits the 36 matched eligible pairs only.
- Row identities, exclusions and latent projection come from the Tabelz policy and closed form, not mcr.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
103 m <- read_dataset("MSA_DEMING"); m$method_b[c(5, 30)] <- NA
104 export_dataset(m, "MSA_DEMING_MISSING", "MSA_DEMING with method_b missing in rows 5 and 30 (1-based)", "R stats::rnorm documentation",
105 "Constructed validation data; no third-party license.", c(method_a = "Float64", method_b = "Float64"))
106 mm <- read_dataset("MSA_DEMING_MISSING")
107 excluded <- c(0L, 20L)
108 keep <- setdiff(which(!is.na(mm$method_b)), excluded + 1L)
109 r <- deming(mm$method_a[keep], mm$method_b[keep], 1)
110 fit4 <- mcr_fit(mm$method_a[keep], mm$method_b[keep], 1)
111 emit("STAT-MSA-DEMING-004", "Missing and excluded pairs keep their rows without fitted values", "MSA_DEMING_MISSING",
112 list(x_column = "method_a", y_column = "method_b"),
113 list("/slope" = mcr_point(fit4, "Slope"),
114 "/rows/0/xhat" = absent("An excluded row keeps its identity with fitted fields unavailable (line 81-82)."),
115 "/rows/4/xhat" = absent("A missing pair has no projection."),
116 "/rows/1/xhat" = tol(r$xhat[1], "The first retained pair."),
117 "/excluded_count" = exact(2L, "Two excluded rows."), "/missing_count" = exact(2L, "Two missing pairs.")),
118 c("Rows 0 and 20 (0-based) are excluded; mcr fits the 36 matched eligible pairs only.",
119 "Row identities, exclusions and latent projection come from the Tabelz policy and closed form, not mcr."),
120 kind = "missing_excluded", excluded = excluded, oracle = "mcr")
Jackknife t intervals on the NCSS ten-pair example
Case STAT-MSA-DEMING-007 · status: passed
Reference
- Evidence type
- R
- Source
- mcr 1.3.3.1 Deming point estimates and Linnet jackknife intervals; independent R arithmetic for other fields
- Citation
- mcr 1.3.3.1 mcreg documentation; NCSS Deming Regression chapter 303, Program 1; NIST Dataplot reproduces that NCSS example in case 007
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, mcr 1.3.3.1
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING_NCSS.json
Settings compared
interval_method= "jackknife_t"lambda_ratio= 0.25x_column= "method_a"y_column= "method_b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/slope | tolerance | 1.0011942278194907 | 1.0011942278194905 | 1.77E-16 | 15 | passed |
/intercept | tolerance | -0.08974489900704441 | -0.08974489900704263 | 1.78E-15 | 13 | passed |
/interval_method | exact | jackknife_t | jackknife_t | passed | ||
/jackknife_degrees_of_freedom | exact | 8 | 8 | 0.00E+2 | passed | |
/jackknife_slope_se | tolerance | 0.18717705279939637 | 0.1871770527993965 | 1.34E-16 | 15 | passed |
/jackknife_slope_interval/0 | tolerance | 0.56956317004875423 | 0.5695631700487538 | 4.44E-16 | 15 | passed |
/jackknife_slope_interval/1 | tolerance | 1.4328252855902273 | 1.4328252855902273 | 4.00E-17 | 16 | passed |
/jackknife_intercept_se | tolerance | 1.7219874128186983 | 1.721987412818701 | 2.64E-15 | 14 | passed |
/jackknife_intercept_interval/0 | tolerance | -4.0606549937364864 | -4.06065499373649 | 3.57E-15 | 15 | passed |
/jackknife_intercept_interval/1 | tolerance | 3.8811651957223976 | 3.8811651957224047 | 7.10E-15 | 14 | passed |
/bootstrap_slope_interval | absent | None | passed |
Convention
- NCSS-origin example reproduced by NIST Dataplot; delta = Var(e_x)/Var(e_y) = 4 corresponds to lambda = 0.25 here.
- mcr error.ratio = 4; its slope and Linnet jackknife SEs agree with NIST's reproduced five-decimal values within 5.1e-6.
- Interval method, degrees of freedom and bootstrap-field absence are Tabelz contract checks.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
137 jk_outputs <- function(coef, n) list(
138 "/slope" = mcr_point(coef, "Slope"),
139 "/intercept" = mcr_point(coef, "Intercept"),
140 "/interval_method" = exact("jackknife_t", "The configured interval method."),
141 "/jackknife_degrees_of_freedom" = exact(n - 2L, "Tabelz/CLSI n - 2 interval convention; mcr uses the same degrees of freedom."),
142 "/jackknife_slope_se" = mcr_tol(coef["Slope", "SE"], "Linnet leave-one-out slope standard error."),
143 "/jackknife_slope_interval/0" = mcr_tol(coef["Slope", "LCI"], "Slope lower bound, centred on full-data estimate."),
144 "/jackknife_slope_interval/1" = mcr_tol(coef["Slope", "UCI"], "Slope upper bound."),
145 "/jackknife_intercept_se" = mcr_tol(coef["Intercept", "SE"], "Linnet leave-one-out intercept standard error."),
146 "/jackknife_intercept_interval/0" = mcr_tol(coef["Intercept", "LCI"], "Intercept lower bound."),
147 "/jackknife_intercept_interval/1" = mcr_tol(coef["Intercept", "UCI"], "Intercept upper bound."),
148 "/bootstrap_slope_interval" = absent("Jackknife bounds never appear in the bootstrap fields."))
149 export_dataset(data.frame(method_a = c(7, 8.3, 10.5, 9, 5.1, 8.2, 10.2, 10.3, 7.1, 5.9),
150 method_b = c(7.9, 8.2, 9.6, 9, 6.5, 7.3, 10.2, 10.6, 6.3, 5.2)),
151 "MSA_DEMING_NCSS", "NCSS Deming Regression Program 1: ten pairs; reproduced by NIST Dataplot",
152 "NCSS Deming Regression chapter 303, Program 1; https://www.itl.nist.gov/div898/software/dataplot/refman1/auxillar/demfit.htm",
153 "Small numeric example transcribed for validation; NCSS source and NIST reproduction credited.", c(method_a = "Float64", method_b = "Float64"))
154 dn <- read_dataset("MSA_DEMING_NCSS")
155 jn <- mcr_fit(dn$method_a, dn$method_b, 0.25, jackknife = TRUE)
156 stopifnot(abs(jn["Slope", "EST"] - 1.00119) < 5.1e-6,
157 abs(jn["Slope", "SE"] - 0.18718) < 5.1e-6,
158 abs(jn["Intercept", "SE"] - 1.72199) < 5.1e-6)
159 emit("STAT-MSA-DEMING-007", "Jackknife t intervals on the NCSS ten-pair example", "MSA_DEMING_NCSS",
160 list(x_column = "method_a", y_column = "method_b", lambda_ratio = 0.25, interval_method = "jackknife_t"),
161 jk_outputs(jn, nrow(dn)),
162 c("NCSS-origin example reproduced by NIST Dataplot; delta = Var(e_x)/Var(e_y) = 4 corresponds to lambda = 0.25 here.",
163 "mcr error.ratio = 4; its slope and Linnet jackknife SEs agree with NIST's reproduced five-decimal values within 5.1e-6.",
164 "Interval method, degrees of freedom and bootstrap-field absence are Tabelz contract checks."), oracle = "mcr")
Jackknife t intervals with lambda 2.25 on 40 pairs
Case STAT-MSA-DEMING-008 · status: passed
Reference
- Evidence type
- R
- Source
- mcr 1.3.3.1 Deming point estimates and Linnet jackknife intervals; independent R arithmetic for other fields
- Citation
- mcr 1.3.3.1 mcreg documentation; NCSS Deming Regression chapter 303, Program 1; NIST Dataplot reproduces that NCSS example in case 007
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, mcr 1.3.3.1
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING.json
Settings compared
interval_method= "jackknife_t"lambda_ratio= 2.25x_column= "method_a"y_column= "method_b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/slope | tolerance | 1.0285273327945612 | 1.0285273327945612 | 1.10E-17 | 16 | passed |
/intercept | tolerance | 0.54330158067751988 | 0.543301580677511 | 8.88E-15 | 13 | passed |
/interval_method | exact | jackknife_t | jackknife_t | passed | ||
/jackknife_degrees_of_freedom | exact | 38 | 38 | 0.00E+2 | passed | |
/jackknife_slope_se | tolerance | 0.020647649540388745 | 0.020647649540388408 | 3.37E-16 | 13 | passed |
/jackknife_slope_interval/0 | tolerance | 0.98672835156649863 | 0.9867283515664993 | 6.65E-16 | 15 | passed |
/jackknife_slope_interval/1 | tolerance | 1.0703263140226238 | 1.0703263140226231 | 6.74E-16 | 15 | passed |
/jackknife_intercept_se | tolerance | 0.31380300663605248 | 0.31380300663605043 | 2.05E-15 | 14 | passed |
/jackknife_intercept_interval/0 | tolerance | -0.091959394574533726 | -0.0919593945745385 | 4.77E-15 | 13 | passed |
/jackknife_intercept_interval/1 | tolerance | 1.1785625559295734 | 1.1785625559295605 | 1.29E-14 | 13 | passed |
/bootstrap_slope_interval | absent | None | passed |
Convention
- mcr error.ratio = 1/2.25 on 40 matched pairs; 38 degrees of freedom.
- Interval method, degrees of freedom and bootstrap-field absence are Tabelz contract checks.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
165 jm <- mcr_fit(d$method_a, d$method_b, 2.25, jackknife = TRUE)
166 emit("STAT-MSA-DEMING-008", "Jackknife t intervals with lambda 2.25 on 40 pairs", "MSA_DEMING",
167 list(x_column = "method_a", y_column = "method_b", lambda_ratio = 2.25, interval_method = "jackknife_t"),
168 jk_outputs(jm, nrow(d)), c("mcr error.ratio = 1/2.25 on 40 matched pairs; 38 degrees of freedom.",
169 "Interval method, degrees of freedom and bootstrap-field absence are Tabelz contract checks."),
170 oracle = "mcr")
Classic crossed structure reproduces the crossed engine
Case STAT-MSA-EXPANDED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::anova and lme4::lmer REML
- Citation
- R stats::anova.lm and lme4::lmer documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, jsonlite 2.0.0
- Reference script
- generators/r/measurement_expanded.R · sha256 55edc5d437caddcd
- Dataset
- reference_data/datasets/MSA_GRR_POOLED.json
Settings compared
operator_column= "operator"part_column= "part"response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/components/[source=Repeatability]/variance | tolerance | 0.25605792452136766 | 0.2560579245213672 | 4.41E-16 | 14 | passed |
/components/[source=Total Gage R&R]/variance | tolerance | 0.33361008719658292 | 0.3336100871965839 | 9.95E-16 | 14 | passed |
/components/[source=Part-To-Part]/variance | tolerance | 2.867138605374171 | 2.8671386053741763 | 5.31E-15 | 14 | passed |
/path | exact | classic_crossed | classic_crossed | passed |
Convention
- Dataset written by measurement_gage.R; 10 parts x 3 operators x 3 trials, interaction pooled.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
54 g <- read_dataset("MSA_GRR_POOLED")
55 g$part <- factor(g$part); g$operator <- factor(g$operator)
56 full <- anova(lm(y ~ part * operator, data = g)); ms <- full[["Mean Sq"]]; df <- full[["Df"]]; ss <- full[["Sum Sq"]]
57 p_int <- pf(ms[3] / ms[4], df[3], df[4], lower.tail = FALSE); if (p_int < 0.05) stop("expected pooling")
58 ms_err <- (ss[3] + ss[4]) / (df[3] + df[4])
59 v_op <- max(0, (ms[2] - ms_err) / 30); v_part <- max(0, (ms[1] - ms_err) / 9)
60 emit("STAT-MSA-EXPANDED-001", "Classic crossed structure reproduces the crossed engine", "MSA_GRR_POOLED",
61 list(response_column = "y", part_column = "part", operator_column = "operator"),
62 c(component("Repeatability", ms_err, "Pooled error mean square.", "1e-9"),
63 component("Total Gage R&R", ms_err + v_op, "Repeatability + operator.", "1e-9"),
64 # The classic structure reproduces the crossed engine's components,
65 # labels included (tests/unit/analysis/test_gage_expanded.py), so the part
66 # component keeps the crossed spelling; until 2026-09-25 this used "Part-to-part".
67 component("Part-To-Part", v_part, "(MS_part - MS_error) / (o r).", "1e-9"),
68 list("/path" = exact("classic_crossed", "Delegated to the crossed engine (line 177-178)."))),
69 c("Dataset written by measurement_gage.R; 10 parts x 3 operators x 3 trials, interaction pooled."))
Fully crossed part, operator and site
Case STAT-MSA-EXPANDED-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::anova and lme4::lmer REML
- Citation
- R stats::anova.lm and lme4::lmer documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, jsonlite 2.0.0
- Reference script
- generators/r/measurement_expanded.R · sha256 55edc5d437caddcd
- Dataset
- reference_data/datasets/MSA_EXPANDED_CROSSED.json
Settings compared
operator_column= "operator"part_column= "part"response_column= "y"site_column= "site"structure= "fully_crossed"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/components/[source=Repeatability]/variance | tolerance | 0.080620579881185123 | 0.08062058085786168 | 9.77E-10 | 7 | passed |
/components/[source=Reproducibility]/variance | tolerance | 0.98723163444307216 | 0.9872314384198148 | 1.96E-7 | 6 | passed |
/components/[source=Site (measurement system)]/variance | tolerance | 0.064725272581322268 | 0.06472524678547359 | 2.58E-8 | 6 | passed |
/components/[source=Total Gage R&R]/variance | tolerance | 1.1325774869055796 | 1.13257726606315 | 2.21E-7 | 6 | passed |
/components/[source=Part-to-part]/variance | tolerance | 3.0493280234925084 | 3.0493280103463714 | 1.31E-8 | 8 | passed |
/path | exact | reml_expanded | reml_expanded | passed |
Convention
- lmer(y ~ (1|part) + (1|operator) + (1|site), REML) with bobyqa rhoend 1e-12.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
72 set.seed(20261028)
73 rows <- expand.grid(trial = 1:2, site = c("S1", "S2", "S3"), operator = c("A", "B", "C"), part = sprintf("P%d", 1:6), stringsAsFactors = FALSE)
74 pe <- rnorm(6, 0, 1.8); oe <- rnorm(3, 0, 0.5); se <- rnorm(3, 0, 0.4)
75 rows$y <- round(30 + pe[match(rows$part, sprintf("P%d", 1:6))] + oe[match(rows$operator, c("A", "B", "C"))] +
76 se[match(rows$site, c("S1", "S2", "S3"))] + rnorm(nrow(rows), 0, 0.3), 4)
77 export_dataset(rows[c("part", "operator", "site", "y")], "MSA_EXPANDED_CROSSED",
78 "Constructed: 6 parts x 3 operators x 3 sites x 2 trials, fully crossed, seed 20261028",
79 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
80 c(part = "String", operator = "String", site = "String", y = "Float64"))
81 e <- read_dataset("MSA_EXPANDED_CROSSED")
82 vc <- reml(y ~ (1 | part) + (1 | operator) + (1 | site), e)
83 emit("STAT-MSA-EXPANDED-002", "Fully crossed part, operator and site", "MSA_EXPANDED_CROSSED",
84 list(response_column = "y", part_column = "part", operator_column = "operator", site_column = "site", structure = "fully_crossed"),
85 c(component("Repeatability", vc[["Residual"]], "REML residual variance."),
86 component("Reproducibility", vc[["operator"]], "The operator component."),
87 component("Site (measurement system)", vc[["site"]], "A crossed site counts toward Gage R&R (line 190-191)."),
88 component("Total Gage R&R", vc[["Residual"]] + vc[["operator"]] + vc[["site"]], "Repeatability + reproducibility + site."),
89 component("Part-to-part", vc[["part"]], "The part component."),
90 list("/path" = exact("reml_expanded", "REML path."))),
91 c("lmer(y ~ (1|part) + (1|operator) + (1|site), REML) with bobyqa rhoend 1e-12."), kind = "axis_coverage")
Site nested in part counts toward part-to-part
Case STAT-MSA-EXPANDED-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::anova and lme4::lmer REML
- Citation
- R stats::anova.lm and lme4::lmer documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, jsonlite 2.0.0
- Reference script
- generators/r/measurement_expanded.R · sha256 55edc5d437caddcd
- Dataset
- reference_data/datasets/MSA_EXPANDED_NESTED.json
Settings compared
operator_column= "operator"part_column= "part"response_column= "y"site_column= "site"structure= "site_nested_in_part"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/components/[source=Repeatability]/variance | tolerance | 0.07330648469066528 | 0.07330648332303656 | 1.37E-9 | 7 | passed |
/components/[source=Reproducibility]/variance | tolerance | 0.071340729428858315 | 0.07134071001670042 | 1.94E-8 | 6 | passed |
/components/[source=Part-to-part]/variance | tolerance | 3.9241432626945727 | 3.9241431529644926 | 1.10E-7 | 7 | passed |
/components/[source=Total Gage R&R]/variance | tolerance | 0.14464721411952358 | 0.14464719333973697 | 2.08E-8 | 6 | passed |
Convention
- lmer(y ~ (1|part) + (1|part:site) + (1|operator), REML).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
94 set.seed(20261029)
95 rows <- expand.grid(trial = 1:2, operator = c("A", "B", "C"), site = 1:2, part = sprintf("P%d", 1:8), stringsAsFactors = FALSE)
96 rows$site_id <- sprintf("%s-s%d", rows$part, rows$site)
97 pe <- setNames(rnorm(8, 0, 2), sprintf("P%d", 1:8)); sw <- setNames(rnorm(16, 0, 0.7), unique(rows$site_id)); oe <- c(A = 0.3, B = -0.2, C = 0.1)
98 rows$y <- round(12 + pe[rows$part] + sw[rows$site_id] + oe[rows$operator] + rnorm(nrow(rows), 0, 0.25), 4)
99 export_dataset(data.frame(part = rows$part, operator = rows$operator, site = rows$site_id, y = rows$y), "MSA_EXPANDED_NESTED",
100 "Constructed: 8 parts, 2 sites within each part, 3 operators, 2 trials, seed 20261029",
101 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
102 c(part = "String", operator = "String", site = "String", y = "Float64"))
103 n <- read_dataset("MSA_EXPANDED_NESTED")
104 vn <- reml(y ~ (1 | part) + (1 | part:site) + (1 | operator), n)
105 emit("STAT-MSA-EXPANDED-003", "Site nested in part counts toward part-to-part", "MSA_EXPANDED_NESTED",
106 list(response_column = "y", part_column = "part", operator_column = "operator", site_column = "site", structure = "site_nested_in_part"),
107 c(component("Repeatability", vn[["Residual"]], "REML residual variance."),
108 component("Reproducibility", vn[["operator"]], "The operator component."),
109 component("Part-to-part", vn[["part"]] + vn[["part:site"]], "Part plus site-within-part (line 191-192)."),
110 component("Total Gage R&R", vn[["Residual"]] + vn[["operator"]], "Repeatability + reproducibility.")),
111 c("lmer(y ~ (1|part) + (1|part:site) + (1|operator), REML)."), kind = "axis_coverage")
A part-by-site interaction is confounded when sites nest in parts
Case STAT-MSA-EXPANDED-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::anova and lme4::lmer REML
- Citation
- R stats::anova.lm and lme4::lmer documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, jsonlite 2.0.0
- Reference script
- generators/r/measurement_expanded.R · sha256 55edc5d437caddcd
- Dataset
- reference_data/datasets/MSA_EXPANDED_NESTED.json
Settings compared
interactions= ["part_site"]operator_column= "operator"part_column= "part"response_column= "y"site_column= "site"structure= "site_nested_in_part"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 183-185: a declaration confounded with the nesting is rejected.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
112 emit("STAT-MSA-EXPANDED-004", "A part-by-site interaction is confounded when sites nest in parts", "MSA_EXPANDED_NESTED",
113 list(response_column = "y", part_column = "part", operator_column = "operator", site_column = "site",
114 structure = "site_nested_in_part", interactions = list("part_site")), list(),
115 c("Line 183-185: a declaration confounded with the nesting is rejected."), kind = "invalid_input",
116 error = list(error_class = "ValueError", message_contains = "confounded with the declared nesting"))
Crossed Gage R&R with a pooled interaction and a tolerance
Case STAT-MSA-GRR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_GRR_POOLED.json
Settings compared
measurement_column= "y"operator_column= "operator"part_column= "part"tolerance= 12
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/components/[source=Total Gage R&R]/variance | tolerance | 0.33361008719658292 | 0.3336100871965839 | 9.95E-16 | 14 | passed |
/components/[source=Total Gage R&R]/pct_contribution | tolerance | 10.422876621676799 | 10.42287662167681 | 1.11E-14 | 14 | passed |
/components/[source=Total Gage R&R]/pct_study_var | tolerance | 32.284480205939197 | 32.28448020593922 | 2.10E-14 | 15 | passed |
/components/[source=Total Gage R&R]/study_var | tolerance | 3.4655393720281098 | 3.465539372028115 | 5.33E-15 | 14 | passed |
/components/[source=Total Gage R&R]/pct_tolerance | tolerance | 28.879494766900915 | 28.87949476690096 | 4.66E-14 | 14 | passed |
/components/[source=Repeatability]/variance | tolerance | 0.25605792452136766 | 0.2560579245213672 | 4.41E-16 | 14 | passed |
/components/[source=Repeatability]/pct_contribution | tolerance | 7.999938424272508 | 7.999938424272478 | 3.02E-14 | 14 | passed |
/components/[source=Repeatability]/pct_study_var | tolerance | 28.28416239571628 | 28.284162395716226 | 5.37E-14 | 14 | passed |
/components/[source=Repeatability]/study_var | tolerance | 3.0361299844982321 | 3.0361299844982295 | 2.64E-15 | 15 | passed |
/components/[source=Repeatability]/pct_tolerance | tolerance | 25.301083204151936 | 25.30108320415191 | 2.44E-14 | 15 | passed |
/components/[source=Reproducibility]/variance | tolerance | 0.077552162675215267 | 0.07755216267521672 | 1.46E-15 | 13 | passed |
/components/[source=Reproducibility]/pct_contribution | tolerance | 2.4229381974042918 | 2.4229381974043327 | 4.09E-14 | 13 | passed |
/components/[source=Reproducibility]/pct_study_var | tolerance | 15.565790045494934 | 15.565790045495065 | 1.31E-13 | 14 | passed |
/components/[source=Reproducibility]/study_var | tolerance | 1.6708913358766782 | 1.6708913358766937 | 1.55E-14 | 14 | passed |
/components/[source=Reproducibility]/pct_tolerance | tolerance | 13.924094465638985 | 13.924094465639115 | 1.30E-13 | 14 | passed |
/components/[source=Operator]/variance | tolerance | 0.077552162675215267 | 0.07755216267521672 | 1.46E-15 | 13 | passed |
/components/[source=Operator]/pct_contribution | tolerance | 2.4229381974042918 | 2.4229381974043327 | 4.09E-14 | 13 | passed |
/components/[source=Operator]/pct_study_var | tolerance | 15.565790045494934 | 15.565790045495065 | 1.31E-13 | 14 | passed |
/components/[source=Operator]/study_var | tolerance | 1.6708913358766782 | 1.6708913358766937 | 1.55E-14 | 14 | passed |
/components/[source=Operator]/pct_tolerance | tolerance | 13.924094465638985 | 13.924094465639115 | 1.30E-13 | 14 | passed |
/components/[source=Part-To-Part]/variance | tolerance | 2.867138605374171 | 2.8671386053741763 | 5.31E-15 | 14 | passed |
/components/[source=Part-To-Part]/pct_contribution | tolerance | 89.577123378323193 | 89.5771233783232 | 4.92E-16 | 17 | passed |
/components/[source=Part-To-Part]/pct_study_var | tolerance | 94.645191836840397 | 94.6451918368404 | 3.96E-16 | 17 | passed |
/components/[source=Part-To-Part]/study_var | tolerance | 10.159576260527313 | 10.159576260527324 | 1.07E-14 | 14 | passed |
/components/[source=Part-To-Part]/pct_tolerance | tolerance | 84.663135504394276 | 84.66313550439436 | 8.54E-14 | 14 | passed |
/components/[source=Total Variation]/variance | tolerance | 3.200748692570754 | 3.2007486925707602 | 6.22E-15 | 14 | passed |
/components/[source=Total Variation]/pct_contribution | tolerance | 100 | 100.00000000000001 | 1.42E-14 | 15 | passed |
/components/[source=Total Variation]/pct_study_var | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/components/[source=Total Variation]/study_var | tolerance | 10.734381814177617 | 10.734381814177627 | 1.05E-14 | 15 | passed |
/components/[source=Total Variation]/pct_tolerance | tolerance | 89.453181784813466 | 89.45318178481357 | 1.00E-13 | 14 | passed |
/ndc | exact | 4 | 4 | 0.00E+2 | passed | |
/interaction_dropped | exact | True | True | passed | ||
/anova_with_interaction/[source=Operator*Part]/p_value | tail_probability | 0.90482534849068119 | 0.9048253484906792 | 2.00E-15 | 14 | passed |
Convention
- Interaction p = 0.904825 >= 0.05, so its SS and df join repeatability (line 126-127).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
96 interval_deferral <- list(list(path = "/components/[source=Operator]/variance_lower",
97 reason = "The manual names component-specific F/chi-square intervals without a formula for non-repeatability components."))
98 export_dataset(crossed_data(20261018, 0.05), "MSA_GRR_POOLED", "Constructed crossed study: 10 parts x 3 operators x 3 trials, negligible interaction, seed 20261018",
99 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
100 c(part = "String", operator = "String", y = "Float64"))
101 g1 <- read_dataset("MSA_GRR_POOLED")
102 r1 <- crossed_ref(g1, tolerance = 12)
103 if (!r1$pooled) stop("expected a pooled interaction")
104 emit("STAT-MSA-GRR-001", "tabelz.analysis.gage_rr:compute_gage_rr", "gageRrMenuItem", "Crossed Gage R&R with a pooled interaction and a tolerance",
105 "MSA_GRR_POOLED", list(measurement_column = "y", part_column = "part", operator_column = "operator", tolerance = 12),
106 c(component_outputs(r1),
107 list("/anova_with_interaction/[source=Operator*Part]/p_value" = tail_p(r1$p_int, "Interaction F test against repeatability."))),
108 c(sprintf("Interaction p = %.6g >= 0.05, so its SS and df join repeatability (line 126-127).", r1$p_int)),
109 deferred = interval_deferral)
Crossed Gage R&R with a retained interaction
Case STAT-MSA-GRR-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_GRR_INTERACTION.json
Settings compared
measurement_column= "y"operator_column= "operator"part_column= "part"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/components/[source=Total Gage R&R]/variance | tolerance | 2.1010571888518612 | 2.101057188851855 | 6.20E-15 | 14 | passed |
/components/[source=Total Gage R&R]/pct_contribution | tolerance | 21.30685125941541 | 21.306851259415353 | 5.68E-14 | 14 | passed |
/components/[source=Total Gage R&R]/pct_study_var | tolerance | 46.159344947058564 | 46.1593449470585 | 6.40E-14 | 14 | passed |
/components/[source=Total Gage R&R]/study_var | tolerance | 8.6970143611855093 | 8.697014361185497 | 1.24E-14 | 14 | passed |
/components/[source=Repeatability]/variance | tolerance | 0.26162775466666965 | 0.261627754666667 | 2.66E-15 | 13 | passed |
/components/[source=Repeatability]/pct_contribution | tolerance | 2.6531708339951301 | 2.653170833995104 | 2.62E-14 | 14 | passed |
/components/[source=Repeatability]/pct_study_var | tolerance | 16.2885568237187 | 16.28855682371862 | 8.15E-14 | 14 | passed |
/components/[source=Repeatability]/study_var | tolerance | 3.0689736342953662 | 3.06897363429535 | 1.60E-14 | 14 | passed |
/components/[source=Reproducibility]/variance | tolerance | 1.8394294341851918 | 1.839429434185188 | 3.79E-15 | 14 | passed |
/components/[source=Reproducibility]/pct_contribution | tolerance | 18.653680425420283 | 18.65368042542025 | 3.15E-14 | 14 | passed |
/components/[source=Reproducibility]/pct_study_var | tolerance | 43.189906720691447 | 43.18990672069141 | 3.59E-14 | 15 | passed |
/components/[source=Reproducibility]/study_var | tolerance | 8.1375340018132576 | 8.13753400181325 | 7.12E-15 | 15 | passed |
/components/[source=Operator]/variance | tolerance | 0.35058298237448882 | 0.3505829823744875 | 1.34E-15 | 14 | passed |
/components/[source=Operator]/pct_contribution | tolerance | 3.5552670813389082 | 3.555267081338896 | 1.24E-14 | 14 | passed |
/components/[source=Operator]/pct_study_var | tolerance | 18.855415883344783 | 18.85541588334475 | 3.21E-14 | 14 | passed |
/components/[source=Operator]/study_var | tolerance | 3.5526029000553376 | 3.552602900055331 | 6.63E-15 | 14 | passed |
/components/[source=Part-To-Part]/variance | tolerance | 7.7598892422798276 | 7.75988924227983 | 2.63E-15 | 15 | passed |
/components/[source=Part-To-Part]/pct_contribution | tolerance | 78.69314874058459 | 78.69314874058465 | 5.68E-14 | 15 | passed |
/components/[source=Part-To-Part]/pct_study_var | tolerance | 88.709158907400649 | 88.70915890740068 | 2.87E-14 | 15 | passed |
/components/[source=Part-To-Part]/study_var | tolerance | 16.713946653082083 | 16.71394665308209 | 6.71E-15 | 15 | passed |
/components/[source=Total Variation]/variance | tolerance | 9.8609464311316888 | 9.860946431131685 | 3.57E-15 | 15 | passed |
/components/[source=Total Variation]/pct_contribution | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/components/[source=Total Variation]/pct_study_var | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/components/[source=Total Variation]/study_var | tolerance | 18.841286355255598 | 18.841286355255594 | 3.97E-15 | 15 | passed |
/ndc | exact | 2 | 2 | 0.00E+2 | passed | |
/interaction_dropped | exact | False | False | passed | ||
/components/[source=Operator*Part]/variance | tolerance | 1.488846451810703 | 1.4888464518107005 | 2.48E-15 | 14 | passed |
Convention
- Interaction p = 7.81388e-18 < 0.05, so it stays in reproducibility (line 127-128).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
110 export_dataset(crossed_data(20261019, 1.2), "MSA_GRR_INTERACTION", "Constructed crossed study with a strong operator-by-part interaction, seed 20261019",
111 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
112 c(part = "String", operator = "String", y = "Float64"))
113 g2 <- read_dataset("MSA_GRR_INTERACTION")
114 r2 <- crossed_ref(g2)
115 if (r2$pooled) stop("expected a retained interaction")
116 emit("STAT-MSA-GRR-002", "tabelz.analysis.gage_rr:compute_gage_rr", "gageRrMenuItem", "Crossed Gage R&R with a retained interaction",
117 "MSA_GRR_INTERACTION", list(measurement_column = "y", part_column = "part", operator_column = "operator"),
118 c(component_outputs(r2), list("/components/[source=Operator*Part]/variance" = tol(r2$v[["int"]], "(MS_OP - MS_E) / r."))),
119 c(sprintf("Interaction p = %.6g < 0.05, so it stays in reproducibility (line 127-128).", r2$p_int)),
120 kind = "axis_coverage", deferred = interval_deferral)
Interaction alpha 0.99 and a 5.15-sigma study variation
Case STAT-MSA-GRR-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_GRR_POOLED.json
Settings compared
interaction_alpha= 0.99measurement_column= "y"operator_column= "operator"part_column= "part"study_var_multiplier= 5.15
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/components/[source=Total Gage R&R]/variance | tolerance | 0.36467539760494017 | 0.364675397604941 | 8.28E-16 | 14 | passed |
/components/[source=Total Gage R&R]/pct_contribution | tolerance | 11.247883303792307 | 11.24788330379231 | 3.27E-15 | 15 | passed |
/components/[source=Total Gage R&R]/pct_study_var | tolerance | 33.537864129655468 | 33.53786412965547 | 4.07E-16 | 16 | passed |
/components/[source=Total Gage R&R]/study_var | tolerance | 3.1100005197711829 | 3.1100005197711864 | 3.51E-15 | 14 | passed |
/components/[source=Repeatability]/variance | tolerance | 0.28401670388888917 | 0.28401670388888856 | 6.15E-16 | 14 | passed |
/components/[source=Repeatability]/pct_contribution | tolerance | 8.7600829742035859 | 8.760082974203552 | 3.37E-14 | 14 | passed |
/components/[source=Repeatability]/pct_study_var | tolerance | 29.597437345492573 | 29.59743734549252 | 5.37E-14 | 14 | passed |
/components/[source=Repeatability]/study_var | tolerance | 2.7446007048190206 | 2.7446007048190175 | 3.08E-15 | 14 | passed |
/components/[source=Reproducibility]/variance | tolerance | 0.080658693716050986 | 0.08065869371605243 | 1.44E-15 | 13 | passed |
/components/[source=Reproducibility]/pct_contribution | tolerance | 2.4878003295887186 | 2.487800329588759 | 4.04E-14 | 13 | passed |
/components/[source=Reproducibility]/pct_study_var | tolerance | 15.772762375654805 | 15.772762375654935 | 1.30E-13 | 14 | passed |
/components/[source=Reproducibility]/study_var | tolerance | 1.4626244234539374 | 1.4626244234539505 | 1.31E-14 | 14 | passed |
/components/[source=Operator]/variance | tolerance | 0.080658693716050986 | 0.08065869371605243 | 1.44E-15 | 13 | passed |
/components/[source=Operator]/pct_contribution | tolerance | 2.4878003295887186 | 2.487800329588759 | 4.04E-14 | 13 | passed |
/components/[source=Operator]/pct_study_var | tolerance | 15.772762375654805 | 15.772762375654935 | 1.30E-13 | 14 | passed |
/components/[source=Operator]/study_var | tolerance | 1.4626244234539374 | 1.4626244234539505 | 1.31E-14 | 14 | passed |
/components/[source=Part-To-Part]/variance | tolerance | 2.8774937088436237 | 2.8774937088436285 | 4.84E-15 | 14 | passed |
/components/[source=Part-To-Part]/pct_contribution | tolerance | 88.752116696207693 | 88.7521166962077 | 2.80E-16 | 17 | passed |
/components/[source=Part-To-Part]/pct_study_var | tolerance | 94.208341826086553 | 94.20834182608655 | 1.72E-16 | 17 | passed |
/components/[source=Part-To-Part]/study_var | tolerance | 8.7360361087168723 | 8.73603610871688 | 7.11E-15 | 15 | passed |
/components/[source=Total Variation]/variance | tolerance | 3.2421691064485638 | 3.2421691064485696 | 5.79E-15 | 14 | passed |
/components/[source=Total Variation]/pct_contribution | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/components/[source=Total Variation]/pct_study_var | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/components/[source=Total Variation]/study_var | tolerance | 9.2731025081027791 | 9.273102508102786 | 7.15E-15 | 15 | passed |
/ndc | exact | 3 | 3 | 0.00E+2 | passed | |
/interaction_dropped | exact | False | False | passed |
Convention
- With alpha 0.99 the interaction p = 0.904825 decides pooling.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
121 r3 <- crossed_ref(g1, alpha = 0.99, m = 5.15)
122 emit("STAT-MSA-GRR-003", "tabelz.analysis.gage_rr:compute_gage_rr", "gageRrMenuItem", "Interaction alpha 0.99 and a 5.15-sigma study variation",
123 "MSA_GRR_POOLED", list(measurement_column = "y", part_column = "part", operator_column = "operator",
124 interaction_alpha = 0.99, study_var_multiplier = 5.15),
125 component_outputs(r3), c(sprintf("With alpha 0.99 the interaction p = %.6g decides pooling.", r3$p_int)),
126 kind = "threshold", deferred = interval_deferral)
Simultaneous full-model repeatability interval
Case STAT-MSA-GRR-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm full crossed ANOVA and stats::qchisq
- Citation
- R stats::lm, stats::anova.lm and stats::qchisq documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_GRR_POOLED.json
Settings compared
measurement_column= "y"operator_column= "operator"part_column= "part"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/components/[source=Repeatability]/variance_lower | tolerance | 0.18762820665470692 | 0.18762820665470636 | 5.56E-16 | 14 | passed |
/components/[source=Repeatability]/variance_upper | tolerance | 0.47156061456866938 | 0.47156061456866816 | 1.22E-15 | 14 | passed |
/confidence_method | exact | Simultaneous Bonferroni intervals from full-model ANOVA (bal | Simultaneous Bonferroni intervals from full-model ANOVA (bal | passed | ||
/interval_joint_confidence | tolerance | 0.94999999999999996 | 0.95 | 4.41E-18 | 17 | passed |
Convention
- The repeatability interval of the Bonferroni simultaneous family: all four full-model ANOVA strata, each chi-square tail alpha/8 = 0.00625 at 95% joint confidence, using the within-cell SS on 60 df whatever the interaction pooling selects for point estimates.
- The coverage claim is for the balanced Normal random-effects variance family, not for ratios or percentages.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
127 # STAT-MSA-GRR-004: the simultaneous full-model repeatability interval (#185 rulings
A missing value unbalances the design and is refused
Case STAT-MSA-GRR-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_GRR_MISSING.json
Settings compared
measurement_column= "y"operator_column= "operator"part_column= "part"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 99-102: every operator measures every part the same number of times unless unbalanced fitting is allowed.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
153 m <- read_dataset("MSA_GRR_POOLED"); m$y[7] <- NA
154 export_dataset(m, "MSA_GRR_MISSING", "MSA_GRR_POOLED with y missing in row 7 (1-based)", "R stats::rnorm documentation",
155 "Constructed validation data; no third-party license.", c(part = "String", operator = "String", y = "Float64"))
156 emit("STAT-MSA-GRR-005", "tabelz.analysis.gage_rr:compute_gage_rr", "gageRrMenuItem", "A missing value unbalances the design and is refused", "MSA_GRR_MISSING",
157 list(measurement_column = "y", part_column = "part", operator_column = "operator"), list(),
158 c("Line 99-102: every operator measures every part the same number of times unless unbalanced fitting is allowed."),
159 kind = "invalid_input", error = list(error_class = "ValueError", message_contains = "balanced"))
One trial per cell is refused
Case STAT-MSA-GRR-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_GRR_ONETRIAL.json
Settings compared
measurement_column= "y"operator_column= "operator"part_column= "part"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 100-101: at least two trials in every cell.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
160 two <- read_dataset("MSA_GRR_POOLED"); two <- two[!duplicated(two[c("part", "operator")]), ]
161 export_dataset(two, "MSA_GRR_ONETRIAL", "MSA_GRR_POOLED with one trial per cell", "Hand-constructed",
162 "Constructed validation data; no third-party license.", c(part = "String", operator = "String", y = "Float64"))
163 emit("STAT-MSA-GRR-006", "tabelz.analysis.gage_rr:compute_gage_rr", "gageRrMenuItem", "One trial per cell is refused", "MSA_GRR_ONETRIAL",
164 list(measurement_column = "y", part_column = "part", operator_column = "operator"), list(),
165 c("Line 100-101: at least two trials in every cell."), kind = "invalid_input",
166 error = list(error_class = "ValueError", message_contains = "trial"))
Gage linearity and bias
Case STAT-MSA-LIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_LINEARITY.json
Settings compared
measurement_column= "y"reference_column= "reference"tolerance= 4
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/metrics/[key=average_bias]/value | tolerance | 0.13925999999999988 | 0.13925999999999963 | 2.46E-16 | 14 | passed |
/metrics/[key=bias_p]/value | tail_probability | 4.6562665468056675e-10 | 4.6562665468055666e-10 | 1.01E-23 | 13 | passed |
/metrics/[key=slope]/value | tolerance | 0.011935833333333288 | 0.011935833333333172 | 1.16E-16 | 14 | passed |
/metrics/[key=linearity_p]/value | tail_probability | 0.02356450935412531 | 0.02356450935412641 | 1.10E-15 | 13 | passed |
/metrics/[key=linearity]/value | tolerance | 0.095486666666666303 | 0.09548666666666537 | 9.29E-16 | 14 | passed |
/metrics/[key=r_squared]/value | tolerance | 0.17000147136373844 | 0.1700014713637362 | 2.24E-15 | 13 | passed |
Convention
- Line 225-231.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
190 set.seed(20261021)
191 ref <- rep(c(2, 4, 6, 8, 10), each = 6)
192 meas <- round(ref + 0.05 + 0.012 * ref + rnorm(30, 0, 0.08), 4)
193 export_dataset(data.frame(reference = ref, y = meas), "MSA_LINEARITY", "Constructed: five reference levels x six measurements, seed 20261021",
194 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(reference = "Float64", y = "Float64"))
195 dl <- read_dataset("MSA_LINEARITY")
196 bias <- dl$y - dl$reference; lf <- summary(lm(bias ~ dl$reference)); tt <- t.test(bias)
197 emit("STAT-MSA-LIN-001", "tabelz.analysis.gage_studies:compute_linearity_bias", "extendedGageMenuItem", "Gage linearity and bias", "MSA_LINEARITY",
198 list(measurement_column = "y", reference_column = "reference", tolerance = 4),
199 list("/metrics/[key=average_bias]/value" = tol(mean(bias), "Mean of y - r."),
200 "/metrics/[key=bias_p]/value" = tail_p(tt$p.value, "One-sample t test of bias against zero."),
201 "/metrics/[key=slope]/value" = tol(coef(lf)[2, 1], "Slope of bias on reference."),
202 "/metrics/[key=linearity_p]/value" = tail_p(coef(lf)[2, 4], "Slope t test."),
203 "/metrics/[key=linearity]/value" = tol(coef(lf)[2, 1] * diff(range(dl$reference)), "Slope times the reference range (line 230)."),
204 "/metrics/[key=r_squared]/value" = tol(lf$r.squared, "R^2 of the bias regression.")),
205 c("Line 225-231."))
Nested destructive Gage R&R
Case STAT-MSA-NESTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_NESTED.json
Settings compared
measurement_column= "y"operator_column= "operator"part_column= "part"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/metrics/[key=grr_pct]/value | tolerance | 21.675426123281888 | 21.675426123281916 | 2.81E-14 | 14 | passed |
/metrics/[key=ndc]/value | exact | 6 | 6 | 0.00E+2 | passed | |
/tables/1/rows/1/3 | tolerance | 8.3956043713888988 | 8.395604371388892 | 7.09E-15 | 15 | passed |
/tables/0/rows/0/1 | tolerance | 0.1357332930555554 | 0.13573329305555562 | 2.21E-16 | 14 | passed |
Convention
- lm(y ~ operator + operator:part): Operator, Part within Operator and Repeatability (line 215-217).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
169 set.seed(20261020)
170 rows <- expand.grid(trial = 1:3, part = 1:4, operator = c("A", "B", "C"), stringsAsFactors = FALSE)
171 rows$part_id <- sprintf("%s-%d", rows$operator, rows$part)
172 pe <- setNames(rnorm(12, 0, 1.5), unique(rows$part_id)); oe <- c(A = -0.3, B = 0.2, C = 0.5)
173 rows$y <- round(20 + pe[rows$part_id] + oe[rows$operator] + rnorm(nrow(rows), 0, 0.4), 4)
174 export_dataset(data.frame(operator = rows$operator, part = rows$part_id, y = rows$y), "MSA_NESTED",
175 "Constructed nested study: 3 operators x 4 own parts x 3 trials, seed 20261020", "R stats::rnorm documentation",
176 "Constructed validation data; no third-party license.", c(operator = "String", part = "String", y = "Float64"))
177 dn <- read_dataset("MSA_NESTED")
178 fit <- anova(lm(y ~ operator + operator:part, data = transform(dn, operator = factor(operator), part = factor(part))))
179 ms_o <- fit[["Mean Sq"]][1]; ms_p <- fit[["Mean Sq"]][2]; ms_e <- fit[["Mean Sq"]][3]
180 v_o <- max(0, (ms_o - ms_p) / (4 * 3)); v_p <- max(0, (ms_p - ms_e) / 3); v_g <- ms_e + v_o
181 emit("STAT-MSA-NESTED-001", "tabelz.analysis.gage_studies:compute_nested_gage_rr", "extendedGageMenuItem", "Nested destructive Gage R&R", "MSA_NESTED",
182 list(measurement_column = "y", part_column = "part", operator_column = "operator"),
183 list("/metrics/[key=grr_pct]/value" = tol(100 * sqrt(v_g / (v_g + v_p)), "100 SD_GRR / SD_total."),
184 "/metrics/[key=ndc]/value" = exact(max(1L, as.integer(floor(sqrt(2) * sqrt(v_p / v_g)))), "floor(sqrt(2) SD_part / SD_GRR), minimum 1."),
185 "/tables/1/rows/1/3" = tol(ms_p, "Part(Operator) mean square."),
186 "/tables/0/rows/0/1" = tol(v_g, "Total Gage R&R variance = repeatability + operator.")),
187 c("lm(y ~ operator + operator:part): Operator, Part within Operator and Repeatability (line 215-217)."))
NIST (52,3) binomial operating-characteristic example
Case STAT-MSA-OC-NIST-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::pbinom applied to NIST (52,3) binomial OC example
- Citation
- NIST/SEMATECH e-Handbook 6.2.3.2, Choosing a Sampling Plan with a given OC Curve, https://www.itl.nist.gov/div898/handbook/pmc/section2/pmc232.htm; R stats::Binomial documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_nist_oc.R · sha256 9f719ee61df305c2
- Dataset
- reference_data/datasets/MSA_NIST_OC_52_3.json
Settings compared
accept_number= 3fraction_column= "fraction_defective"sample_size= 52
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/probabilities/0 | tolerance | 0.99815306526001724 | 0.9981530652600172 | 4.03E-18 | 17 | passed |
/probabilities/1 | tolerance | 0.92953738386812079 | 0.9295373838681209 | 1.13E-16 | 15 | passed |
/probabilities/2 | tolerance | 0.73831741079662061 | 0.7383174107966207 | 1.11E-16 | 15 | passed |
Convention
- NIST prints Pa=0.998 at p=.01, 0.930 at p=.03, and 0.739 at p=.05 for n=52,c=3.
- The binomial sum/R pbinom at p=.05 is about 0.7383174108, which rounds to .738 at three decimals; NIST's printed .739 is discrepant and is retained as published text, not the full-precision expected value.
- Large or unspecified lot only; this case does not assert the finite-lot hypergeometric extension.
- The public probability_of_acceptance helper evaluates each declared p at n=52,c=3; it does not search for a plan.
Reference code
The lines of the reference script that produce this case's expected values.
6 run <- generator_run(c("stats", "jsonlite"))
7 id <- "STAT-MSA-OC-NIST-001"
Right-censored Weibull life model
Case STAT-MSA-REL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::pbinom, stats::qt (noncentral) and survival::survreg
- Citation
- R stats::Binomial, stats::TDist and survival::survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/measurement_manufacturing.R · sha256 5a42bd20f26f6b22
- Dataset
- reference_data/datasets/MSA_RELIABILITY.json
Settings compared
event_column= "status"failure_value= "failed"time_column= "hours"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/shape | tolerance | 2.7503330039434841 | 2.7503333043370666 | 3.00E-7 | 6 | passed |
/scale | tolerance | 949.50608045453725 | 949.5060417178146 | 3.87E-5 | 7 | passed |
/log_likelihood | tolerance | -141.76345898726697 | -141.76345898726726 | 2.86E-13 | 14 | passed |
/median_life | tolerance | 831.04225782406047 | 831.0422360160113 | 2.18E-5 | 7 | passed |
/failures | exact | 19 | 19 | 0.00E+2 | passed | |
/censored | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- survreg(Surv(hours, failed) ~ 1, dist = 'weibull'), rel.tolerance 1e-12; shape = 1/scale, scale = exp(intercept).
Reference code
The lines of the reference script that produce this case's expected values.
117 set.seed(20261031)
118 life <- round(rweibull(24, shape = 2.2, scale = 900), 2); cens <- life > 1100; life[cens] <- 1100
119 export_dataset(data.frame(hours = life, status = ifelse(cens, "suspended", "failed")), "MSA_RELIABILITY",
120 "Constructed: 24 Weibull(2.2, 900) lives, Type I censored at 1100 h, seed 20261031",
121 "R stats::rweibull documentation", "Constructed validation data; no third-party license.",
122 c(hours = "Float64", status = "String"))
123 rl <- read_dataset("MSA_RELIABILITY")
124 fit <- survival::survreg(survival::Surv(hours, status == "failed") ~ 1, data = rl, dist = "weibull",
125 control = survival::survreg.control(rel.tolerance = 1e-12, maxiter = 200))
126 shape <- 1 / fit$scale; scale <- exp(unname(coef(fit)))
127 emit("STAT-MSA-REL-001", "tabelz.analysis.manufacturing_studies:reliability_study", "Right-censored Weibull life model", "MSA_RELIABILITY",
128 list(time_column = "hours", event_column = "status", failure_value = "failed"),
129 list("/shape" = tol(shape, "1 / survreg scale.", "1e-6"), "/scale" = tol(scale, "exp(survreg intercept).", "1e-6"),
130 "/log_likelihood" = tol(fit$loglik[2], "Censored Weibull log likelihood.", "1e-6"),
131 "/median_life" = tol(scale * log(2)^(1 / shape), "scale (ln 2)^(1/shape).", "1e-6"),
132 "/failures" = exact(sum(rl$status == "failed"), "Observed failures."), "/censored" = exact(sum(rl$status != "failed"), "Suspensions.")),
133 c("survreg(Surv(hours, failed) ~ 1, dist = 'weibull'), rel.tolerance 1e-12; shape = 1/scale, scale = exp(intercept)."),
134 deferred = list(list(path = "/shape_lower", reason = "No stated interval convention for the life-model parameters.")))
Probit gage response with Fieller intervals
Case STAT-MSA-RESP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm probit and twopartm::FiellerRatio 0.1.0 for bounded Fieller outputs
- Citation
- R stats::glm documentation; twopartm 0.1.0 FiellerRatio; Franz (2007), equations (3)-(5)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0, twopartm 0.1.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_GAGE_RESPONSE.json
Settings compared
pass_count_column= "passes"reference_column= "reference"threshold= 10trials_column= "trials"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 14.44017182868981 | 14.440171669973122 | 1.59E-7 | 7 | passed |
/midpoint/estimate | tolerance | 9.999984269893222 | 9.999984269911431 | 1.82E-11 | 11 | passed |
/midpoint/lower | tolerance | 9.9823368851216614 | 9.982336887748845 | 2.63E-9 | 9 | passed |
/midpoint/upper | tolerance | 10.017631605217474 | 10.017631602578238 | 2.64E-9 | 9 | passed |
/lower_point/estimate | tolerance | 9.8860760943905284 | 9.886076093156735 | 1.23E-9 | 9 | passed |
/upper_point/estimate | tolerance | 10.113892445395916 | 10.11389244666613 | 1.27E-9 | 9 | passed |
/bias | tolerance | -1.5730106778022446e-05 | -1.5730088568588485e-05 | 1.82E-11 | 5 | passed |
/spread | tolerance | 0.22781635100539013 | 0.22781635350939483 | 2.50E-9 | 7 | passed |
/spread_lower | tolerance | 0.18561263174604017 | 0.18561264694887158 | 1.52E-8 | 7 | passed |
/probit_scale | tolerance | 0.069251253507468288 | 0.06925125426863166 | 7.61E-10 | 7 | passed |
/pearson_chi_square | tolerance | 5.2127825071587974 | 5.212782407510251 | 9.96E-8 | 7 | passed |
/goodness_of_fit_df | exact | 9 | 9 | 0.00E+2 | passed |
Convention
- glm(binomial(link = 'probit')) with epsilon 1e-14; normal quantile in the Fieller equation.
- twopartm supplies only bounded Fieller ratio limits; GLM estimates, row policy, spread and diagnostics have separate R provenance.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
173 "/bias" = list(comparison = "tolerance", value = dec(unname(pr$mid$est - threshold)),
174 absolute_tolerance = dec(1e-6 * abs(pr$mid$est)), relative_tolerance = "0",
175 rationale = "Iterative probit fit; owner 1e-6 tier on x_0.5, propagated to x_0.5 minus the exact threshold."),
176 "/spread" = tol(pr$spread, "(qnorm(0.95) - qnorm(0.05)) / |b1|.", "1e-6"),
177 "/spread_lower" = tol(pr$spread_lo, "Inverted Wald slope interval.", "1e-6"),
178 "/probit_scale" = tol(pr$scale, "1 / |b1|.", "1e-6"),
179 "/pearson_chi_square" = tol(pr$pearson, "Pearson chi-square over the pooled levels.", "1e-6"),
180 "/goodness_of_fit_df" = exact(9L, "k - 2 = 11 - 2."))
181 emit("STAT-MSA-RESP-001", resp_entry, "attributeGageResponseMenuItem", "Probit gage response with Fieller intervals", "MSA_GAGE_RESPONSE",
182 list(reference_column = "reference", pass_count_column = "passes", trials_column = "trials", threshold = 10),
183 resp_outputs(pr, 10), c("glm(binomial(link = 'probit')) with epsilon 1e-14; normal quantile in the Fieller equation."))
Modelling the fail event reverses the curve
Case STAT-MSA-RESP-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm probit and twopartm::FiellerRatio 0.1.0 for bounded Fieller outputs
- Citation
- R stats::glm documentation; twopartm 0.1.0 FiellerRatio; Franz (2007), equations (3)-(5)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0, twopartm 0.1.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_GAGE_RESPONSE.json
Settings compared
modeled_event= "fail"pass_count_column= "passes"reference_column= "reference"threshold= 10trials_column= "trials"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/midpoint/estimate | tolerance | 9.999984269893222 | 9.999984269911431 | 1.82E-11 | 11 | passed |
/spread | tolerance | 0.2278163510053921 | 0.22781635350939483 | 2.50E-9 | 7 | passed |
/direction | exact | decreasing | decreasing | passed |
Convention
- The fail count n - y is modelled.
- twopartm supplies only bounded Fieller ratio limits; GLM estimates, row policy, spread and diagnostics have separate R provenance.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
184 prf <- probit_ref(g$reference, g$trials - g$passes, g$trials)
185 emit("STAT-MSA-RESP-002", resp_entry, "attributeGageResponseMenuItem", "Modelling the fail event reverses the curve", "MSA_GAGE_RESPONSE",
186 list(reference_column = "reference", pass_count_column = "passes", trials_column = "trials", threshold = 10, modeled_event = "fail"),
187 list("/midpoint/estimate" = tol(prf$mid$est, "The 50% point is unchanged (line 364-365).", "1e-6"),
188 "/spread" = tol(prf$spread, "The spread is unchanged.", "1e-6"),
189 "/direction" = exact("decreasing", "The fail probability falls with the reference.")),
190 c("The fail count n - y is modelled."), kind = "axis_coverage")
10/90 transition points at 90% confidence
Case STAT-MSA-RESP-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm probit and twopartm::FiellerRatio 0.1.0 for bounded Fieller outputs
- Citation
- R stats::glm documentation; twopartm 0.1.0 FiellerRatio; Franz (2007), equations (3)-(5)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0, twopartm 0.1.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_GAGE_RESPONSE.json
Settings compared
confidence_level= 0.9lower_percentile= 0.1pass_count_column= "passes"reference_column= "reference"threshold= 10trials_column= "trials"upper_percentile= 0.9
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/lower_point/estimate | tolerance | 9.9112352175448013 | 9.91123521658754 | 9.57E-10 | 10 | passed |
/spread | tolerance | 0.17749810469684404 | 0.17749810664778418 | 1.95E-9 | 7 | passed |
/midpoint/lower | tolerance | 9.985292073693623 | 9.985292075792762 | 2.10E-9 | 9 | passed |
Convention
- Non-default transition points and confidence.
- twopartm supplies only bounded Fieller ratio limits; GLM estimates, row policy, spread and diagnostics have separate R provenance.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
191 pr90 <- probit_ref(g$reference, g$passes, g$trials, level = 0.9, lower = 0.1, upper = 0.9)
192 emit("STAT-MSA-RESP-003", resp_entry, "attributeGageResponseMenuItem", "10/90 transition points at 90% confidence", "MSA_GAGE_RESPONSE",
193 list(reference_column = "reference", pass_count_column = "passes", trials_column = "trials", threshold = 10,
194 lower_percentile = 0.1, upper_percentile = 0.9, confidence_level = 0.9),
195 list("/lower_point/estimate" = tol(pr90$low$est, "x_0.10.", "1e-6"), "/spread" = tol(pr90$spread, "Spread between 10% and 90%.", "1e-6"),
196 "/midpoint/lower" = tol(pr90$mid$lo, "90% Fieller limit.", "1e-6")),
197 c("Non-default transition points and confidence."), kind = "axis_coverage")
Separated outcomes have no finite estimate
Case STAT-MSA-RESP-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm probit and twopartm::FiellerRatio 0.1.0 for bounded Fieller outputs
- Citation
- R stats::glm documentation; twopartm 0.1.0 FiellerRatio; Franz (2007), equations (3)-(5)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, irr 0.85, jsonlite 2.0.0, twopartm 0.1.0
- Reference script
- generators/r/measurement_attribute.R · sha256 beefb4724be48657
- Dataset
- reference_data/datasets/MSA_GAGE_RESPONSE_SEPARATED.json
Settings compared
pass_count_column= "passes"reference_column= "reference"threshold= 2.5trials_column= "trials"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 367-371: separated outcomes are an error.
- twopartm supplies only bounded Fieller ratio limits; GLM estimates, row policy, spread and diagnostics have separate R provenance.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
198 sep <- data.frame(reference = c(1, 2, 3, 4), passes = c(0L, 0L, 10L, 10L), trials = rep(10L, 4))
199 export_dataset(sep, "MSA_GAGE_RESPONSE_SEPARATED", "Constructed: outcomes separated along the reference axis", "Hand-constructed",
200 "Constructed validation data; no third-party license.", c(reference = "Float64", passes = "Int64", trials = "Int64"))
201 emit("STAT-MSA-RESP-004", resp_entry, "attributeGageResponseMenuItem", "Separated outcomes have no finite estimate", "MSA_GAGE_RESPONSE_SEPARATED",
202 list(reference_column = "reference", pass_count_column = "passes", trials_column = "trials", threshold = 2.5), list(),
203 c("Line 367-371: separated outcomes are an error."), kind = "invalid_input",
204 error = list(error_class = "ValueError", message_contains = "separat"))
Gage run chart means and trial layout on a hand-checked crossed study
Case STAT-MSA-RUNCHART-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand arithmetic means of the constructed readings
- Citation
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MSA_RUN_CHART_01.json
Settings compared
measurement_column= "y"operator_column= "operator"part_column= "part"trial_column= "trial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/overall_mean | tolerance | 11.0625 | 11.0625 | 0.00E-2 | passed | |
/parts/[part=P1]/mean | tolerance | 10.025 | 10.025 | 3.55E-16 | 16 | passed |
/parts/[part=P2]/mean | tolerance | 12.1 | 12.1 | 3.55E-16 | 16 | passed |
/reference_source | exact | overall_mean | overall_mean | passed | ||
/max_trials | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- The run chart computes only the overall mean, the part means and counts (F120).
Gage stability sorted by an order column
Case STAT-MSA-STAB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_STABILITY.json
Settings compared
measurement_column= "y"order_column= "order"reference= 5.1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/metrics/[key=mean]/value | tolerance | 5.1154299999999999 | 5.115429999999999 | 8.67E-16 | 15 | passed |
/metrics/[key=sigma]/value | tolerance | 0.11312228310167166 | 0.11312228310167166 | 1.23E-18 | 16 | passed |
/metrics/[key=upper]/value | tolerance | 5.4547968493050147 | 5.454796849305014 | 8.49E-16 | 15 | passed |
/metrics/[key=slope]/value | tolerance | 0.014014215795328164 | 0.014014215795328142 | 2.21E-17 | 14 | passed |
/metrics/[key=drift_p]/value | tail_probability | 9.4588733955102822e-07 | 9.458873395510365e-07 | 8.26E-21 | 14 | passed |
/metrics/[key=bias]/value | tolerance | 0.015430000000000277 | 0.015429999999999389 | 8.88E-16 | 13 | passed |
Convention
- The order column actively sorts the sequence (line 257-260).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
235 set.seed(20261023)
236 yst <- round(5 + seq(0, 0.3, length.out = 30) + rnorm(30, 0, 0.1), 4)
237 ord <- sample(30)
238 export_dataset(data.frame(order = ord, y = yst[ord]), "MSA_STABILITY", "Constructed: a drifting check standard stored out of order, seed 20261023",
239 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(order = "Int64", y = "Float64"))
240 ds <- read_dataset("MSA_STABILITY"); ys <- ds$y[order(ds$order)]
241 sig <- mean(abs(diff(ys))) / (2 / sqrt(pi)); lf <- summary(lm(ys ~ seq_along(ys)))
242 emit("STAT-MSA-STAB-001", "tabelz.analysis.gage_studies:compute_gage_stability", "extendedGageMenuItem", "Gage stability sorted by an order column", "MSA_STABILITY",
243 list(measurement_column = "y", order_column = "order", reference = 5.1),
244 list("/metrics/[key=mean]/value" = tol(mean(ys), "Centre."),
245 "/metrics/[key=sigma]/value" = tol(sig, "MR-bar / d2 on the sorted sequence."),
246 "/metrics/[key=upper]/value" = tol(mean(ys) + 3 * sig, "Mean + 3 sigma."),
247 "/metrics/[key=slope]/value" = tol(coef(lf)[2, 1], "Drift per observation."),
248 "/metrics/[key=drift_p]/value" = tail_p(coef(lf)[2, 4], "Slope t test."),
249 "/metrics/[key=bias]/value" = tol(mean(ys) - 5.1, "Mean minus the reference.")),
250 c("The order column actively sorts the sequence (line 257-260)."))
One-sided normal upper tolerance bound
Case STAT-MSA-TOL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::pbinom, stats::qt (noncentral) and survival::survreg
- Citation
- R stats::Binomial, stats::TDist and survival::survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/measurement_manufacturing.R · sha256 5a42bd20f26f6b22
- Dataset
- reference_data/datasets/MSA_TOLERANCE.json
Settings compared
column= "x"confidence= 0.95content= 0.99method= "normal"sided= "one_upper"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/factor | tolerance | 3.0639011262403977 | 3.0639011262381683 | 2.23E-12 | 12 | passed |
/upper | tolerance | 112.72846480060377 | 112.72846480059425 | 9.52E-12 | 13 | passed |
/n | exact | 30 | 30 | 0.00E+2 | passed |
Convention
- 99% content, 95% confidence, one-sided upper.
Reference code
The lines of the reference script that produce this case's expected values.
78 set.seed(20261030)
79 export_dataset(data.frame(x = round(rnorm(30, 100, 4), 4)), "MSA_TOLERANCE", "Constructed: 30 values N(100, 4^2), seed 20261030",
80 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(x = "Float64"))
81 x <- read_dataset("MSA_TOLERANCE")$x; n <- length(x); m <- mean(x); s <- sd(x)
82 tolx <- "tabelz.analysis.manufacturing_studies:tolerance_interval_study"
83 k1 <- qt(0.95, n - 1, ncp = qnorm(0.99) * sqrt(n)) / sqrt(n)
84 emit("STAT-MSA-TOL-001", tolx, "One-sided normal upper tolerance bound", "MSA_TOLERANCE",
85 list(column = "x", method = "normal", content = 0.99, confidence = 0.95, sided = "one_upper"),
86 list("/factor" = tol(k1, "Exact noncentral-t factor."), "/upper" = tol(m + k1 * s, "Mean + k s."), "/n" = exact(30L, "Thirty values.")),
87 c("99% content, 95% confidence, one-sided upper."))
Two-sided normal tolerance interval (Howe)
Case STAT-MSA-TOL-002 · status: passed
Reference
- Evidence type
- R
- Source
- R tolerance::K.factor 3.0.0, explicit HE2
- Citation
- Howe (1969), equation (2.13) and Table 1; R tolerance 3.0.0 K.factor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/measurement_manufacturing.R · sha256 5a42bd20f26f6b22
- Dataset
- reference_data/datasets/MSA_TOLERANCE.json
Settings compared
column= "x"confidence= 0.99content= 0.95method= "normal"sided= "two_sided"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/factor | tolerance | 2.8415908272906911 | 2.8415908272906916 | 4.68E-16 | 15 | passed |
/lower | tolerance | 87.501913736329499 | 87.5019137363295 | 2.39E-16 | 17 | passed |
/upper | tolerance | 111.77881959700383 | 111.77881959700383 | 1.63E-15 | 16 | passed |
Convention
- 95% content, 99% confidence.
Reference code
The lines of the reference script that produce this case's expected values.
29 emit <- function(id, entry, title, dataset, config, outputs, notes, kind = "nominal", error = NULL, deferred = list()) {
30 write_expected(family, id, list(
31 schema_version = "2.0.0", case_id = id,
32 outputs = if (is.null(error)) outputs else setNames(list(), character()),
33 expected_error = error, deferred_outputs = deferred, generator_run = run))
34 write_case(family, id, list(
35 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = family, entry_point = entry,
36 menu_items = list(menu), title = title, case_kind = kind,
37 dataset = if (is.null(dataset)) NULL else list(path = paste0("reference_data/datasets/", dataset, ".json"), sha256 = ""),
38 excluded_rows = list(), configuration = config, "repeat" = 1L,
39 expected = list(path = paste0("reference_data/expected/", family, "/", id, ".json"), sha256 = ""),
40 oracle = list(
41 oracle_class = "independent_implementation",
42 source = if (id %in% c("STAT-MSA-TOL-002", "STAT-MSA-TOL-004"))
43 "R tolerance::K.factor 3.0.0, explicit HE2" else
44 "R stats::pbinom, stats::qt (noncentral) and survival::survreg",
45 citation = if (id %in% c("STAT-MSA-TOL-002", "STAT-MSA-TOL-004"))
46 "Howe (1969), equation (2.13) and Table 1; R tolerance 3.0.0 K.factor documentation" else
47 "R stats::Binomial, stats::TDist and survival::survreg documentation",
48 generator = list(path = generator, sha256 = ""), independent = TRUE,
49 convention_notes = as.list(notes)),
50 supported = TRUE, unsupported_reason = NULL, requirement_ids = list("REQ-STAT-MSA-001"),
51 risk_ids = list("RISK-NUMERIC-001"), review_reference = NULL))
Distribution-free intervals are two-sided only
Case STAT-MSA-TOL-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::pbinom, stats::qt (noncentral) and survival::survreg
- Citation
- R stats::Binomial, stats::TDist and survival::survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/measurement_manufacturing.R · sha256 5a42bd20f26f6b22
- Dataset
- reference_data/datasets/MSA_TOLERANCE.json
Settings compared
column= "x"confidence= 0.9content= 0.9method= "distribution_free"sided= "one_upper"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The distribution-free interval is two-sided.
Reference code
The lines of the reference script that produce this case's expected values.
111 emit("STAT-MSA-TOL-003", tolx, "Distribution-free intervals are two-sided only", "MSA_TOLERANCE",
112 list(column = "x", method = "distribution_free", content = 0.9, confidence = 0.9, sided = "one_upper"), list(),
113 c("The distribution-free interval is two-sided."), kind = "invalid_input",
114 error = list(error_class = "ValueError", message_contains = "two-sided"))
Howe Table 1 HE2 factor, N=13
Case STAT-MSA-TOL-004 · status: passed
Reference
- Evidence type
- R
- Source
- R tolerance::K.factor 3.0.0, explicit HE2
- Citation
- Howe (1969), equation (2.13) and Table 1; R tolerance 3.0.0 K.factor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0, tolerance 3.0.0
- Reference script
- generators/r/measurement_manufacturing.R · sha256 5a42bd20f26f6b22
- Dataset
- reference_data/datasets/MSA_HOWE_TABLE1.json
Settings compared
column= "x"confidence= 0.95content= 0.95method= "normal"sided= "two_sided"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/factor | tolerance | 3.0820886613382386 | 3.08208866133824 | 1.29E-15 | 15 | passed |
/lower | tolerance | -5.0030108513643761 | -5.003010851364381 | 5.30E-15 | 14 | passed |
/upper | tolerance | 19.003010851364376 | 19.00301085136438 | 3.62E-15 | 15 | passed |
/n | exact | 13 | 13 | 0.00E+2 | passed |
Convention
- Howe Table 1 lambda1 prints 3.082 and achieved probability 0.9486; lambda2 has 0.9485.
- Only the factor is source-published; dataset and bounds are constructed.
Reference code
The lines of the reference script that produce this case's expected values.
29 emit <- function(id, entry, title, dataset, config, outputs, notes, kind = "nominal", error = NULL, deferred = list()) {
30 write_expected(family, id, list(
31 schema_version = "2.0.0", case_id = id,
32 outputs = if (is.null(error)) outputs else setNames(list(), character()),
33 expected_error = error, deferred_outputs = deferred, generator_run = run))
34 write_case(family, id, list(
35 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = family, entry_point = entry,
36 menu_items = list(menu), title = title, case_kind = kind,
37 dataset = if (is.null(dataset)) NULL else list(path = paste0("reference_data/datasets/", dataset, ".json"), sha256 = ""),
38 excluded_rows = list(), configuration = config, "repeat" = 1L,
39 expected = list(path = paste0("reference_data/expected/", family, "/", id, ".json"), sha256 = ""),
40 oracle = list(
41 oracle_class = "independent_implementation",
42 source = if (id %in% c("STAT-MSA-TOL-002", "STAT-MSA-TOL-004"))
43 "R tolerance::K.factor 3.0.0, explicit HE2" else
44 "R stats::pbinom, stats::qt (noncentral) and survival::survreg",
45 citation = if (id %in% c("STAT-MSA-TOL-002", "STAT-MSA-TOL-004"))
46 "Howe (1969), equation (2.13) and Table 1; R tolerance 3.0.0 K.factor documentation" else
47 "R stats::Binomial, stats::TDist and survival::survreg documentation",
48 generator = list(path = generator, sha256 = ""), independent = TRUE,
49 convention_notes = as.list(notes)),
50 supported = TRUE, unsupported_reason = NULL, requirement_ids = list("REQ-STAT-MSA-001"),
51 risk_ids = list("RISK-NUMERIC-001"), review_reference = NULL))
Type-1 gage Cg and Cgk
Case STAT-MSA-TYPE1-001 · status: passed
Reference
- Evidence type
- R
- Source
- Minitab Type 1 Gage Study Cg/Cgk formulas; R stats::sd and stats::t.test for sample statistics and bias test
- Citation
- Minitab Support, Methods and formulas for Type 1 Gage Study, Cg and CgK formula images; R stats::sd and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_TYPE1.json
Settings compared
measurement_column= "y"reference= 10tolerance= 0.6
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/metrics/[key=bias]/value | tolerance | 0.019235200000000674 | 0.019235199999998898 | 1.78E-15 | 13 | passed |
/metrics/[key=std]/value | tolerance | 0.015385432807258251 | 0.015385432807258131 | 1.20E-16 | 14 | passed |
/metrics/[key=cg]/value | tolerance | 1.2999309314564602 | 1.2999309314564704 | 1.02E-14 | 14 | passed |
/metrics/[key=cgk]/value | tolerance | 0.88319040724392384 | 0.8831904072439692 | 4.54E-14 | 13 | passed |
/metrics/[key=bias_p]/value | tail_probability | 1.8436166959158541e-06 | 1.8436166959163587e-06 | 5.05E-19 | 12 | passed |
Convention
- Type 1 Tabelz defaults K=20 percent and SV=6s: Minitab Cg=(K/100*T)/SV and Cgk=(K/200*T-|mean-reference|)/(SV/2). T=0.6 response units.
- The numeric Cg/Cgk values are analytic applications of the Minitab image formulas to constructed measurements, not a published numerical example.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
208 set.seed(20261022)
209 export_dataset(data.frame(y = round(10.02 + rnorm(25, 0, 0.015), 5), run = seq_len(25)), "MSA_TYPE1",
210 "Constructed: 25 repeated measurements of a 10.00 standard, seed 20261022", "R stats::rnorm documentation",
211 "Constructed validation data; no third-party license.", c(y = "Float64", run = "Int64"))
212 d1 <- read_dataset("MSA_TYPE1")$y
213 s <- sd(d1); B <- mean(d1) - 10; W <- 0.2 * 0.6
214 emit("STAT-MSA-TYPE1-001", "tabelz.analysis.gage_studies:compute_type_1_gage", "extendedGageMenuItem", "Type-1 gage Cg and Cgk", "MSA_TYPE1",
215 list(measurement_column = "y", reference = 10, tolerance = 0.6),
216 list("/metrics/[key=bias]/value" = tol(B, "Mean minus reference."),
217 "/metrics/[key=std]/value" = tol(s, "Sample standard deviation."),
218 "/metrics/[key=cg]/value" = list(comparison = "tolerance", value = dec(W / (6 * s)),
219 absolute_tolerance = "0", relative_tolerance = "1e-9",
220 rationale = "Minitab Type 1 Cg image formula (K/100*T)/SV with T=0.6, K=20, SV=6 sample SD; owner 1e-9 tier."),
221 "/metrics/[key=cgk]/value" = list(comparison = "tolerance", value = dec((W / 2 - abs(B)) / (3 * s)),
222 absolute_tolerance = "0", relative_tolerance = "1e-9",
223 rationale = "Minitab Type 1 CgK image formula (K/200*T-|mean-reference|)/(SV/2), K=20 and SV=6 sample SD; owner 1e-9 tier."),
224 "/metrics/[key=bias_p]/value" = tail_p(t.test(d1, mu = 10)$p.value, "t test of the bias.")),
225 c("Type 1 Tabelz defaults K=20 percent and SV=6s: Minitab Cg=(K/100*T)/SV and Cgk=(K/200*T-|mean-reference|)/(SV/2). T=0.6 response units.",
226 "The numeric Cg/Cgk values are analytic applications of the Minitab image formulas to constructed measurements, not a published numerical example."),
227 oracle_source = "Minitab Type 1 Gage Study Cg/Cgk formulas; R stats::sd and stats::t.test for sample statistics and bias test",
228 oracle_citation = "Minitab Support, Methods and formulas for Type 1 Gage Study, Cg and CgK formula images; R stats::sd and stats::t.test documentation")
Fewer than ten measurements are refused
Case STAT-MSA-TYPE1-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::aov, stats::lm and stats::t.test
- Citation
- R stats::aov, stats::anova.lm, stats::lm and stats::t.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_gage.R · sha256 865663d557479688
- Dataset
- reference_data/datasets/MSA_TYPE1.json
Settings compared
measurement_column= "y"reference= 10tolerance= 0.6
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 240: at least ten measurements; rows 0-15 (0-based) are excluded, leaving nine.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
229 emit("STAT-MSA-TYPE1-002", "tabelz.analysis.gage_studies:compute_type_1_gage", "extendedGageMenuItem", "Fewer than ten measurements are refused", "MSA_TYPE1",
230 list(measurement_column = "y", reference = 10, tolerance = 0.6), list(),
231 c("Line 240: at least ten measurements; rows 0-15 (0-based) are excluded, leaving nine."), kind = "invalid_input",
232 excluded = 0:15, error = list(error_class = "ValueError", message_contains = "10"))
Multivariate STAT-MV-ALPHA-001
Case STAT-MV-ALPHA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_core.R · sha256 90e434c114270562
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
items= ["i1", "i2", "i3"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cronbach_alpha | tolerance | 0.94285714285714284 | 0.9428571428571428 | 1.89E-18 | 17 | passed |
/standardized_alpha | tolerance | 0.94285714285714295 | 0.9428571428571427 | 2.23E-16 | 15 | passed |
Convention
- Raw alpha is k/(k-1)*(1-sum sample item variances/sample total variance).
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
80 items <- as.matrix(d[c("i1","i2","i3")])
81 k <- ncol(items)
82 alpha <- k/(k-1) * (1-sum(apply(items,2,stats::var))/stats::var(rowSums(items)))
83 rbar <- mean(stats::cor(items)[upper.tri(stats::cor(items))])
84 standard_alpha <- k*rbar/(1+(k-1)*rbar)
85 emit("STAT-MV-ALPHA-001", "tabelz.executor.item_analysis", "itemAnalysisMenuItem",
86 list(items=list("i1","i2","i3")),
87 list("/cronbach_alpha"=tol(alpha, "sample-variance raw Cronbach alpha"),
88 "/standardized_alpha"=tol(standard_alpha, "mean-correlation standardized alpha")),
89 c("Raw alpha is k/(k-1)*(1-sum sample item variances/sample total variance)."))
Special boundary STAT-MV-ALPHA-CONSTANT-001
Case STAT-MV-ALPHA-CONSTANT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_boundaries.R · sha256 420706593513ebf0
- Dataset
- reference_data/datasets/MV_TIES.json
Settings compared
items= ["i1", "i2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cronbach_alpha | tolerance | 0 | 0.0 | 0.00E+2 | 15 | passed |
Convention
- One item is constant; total-score variance remains positive, so raw alpha is defined.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
47 items <- as.matrix(d[c("i1","i2")]); k <- ncol(items)
48 alpha <- k/(k-1)*(1-sum(apply(items,2,stats::var))/stats::var(rowSums(items)))
49 emit("STAT-MV-ALPHA-CONSTANT-001","tabelz.executor.item_analysis","itemAnalysisMenuItem",
50 "MV_TIES",list(items=list("i1","i2")),
51 list("/cronbach_alpha"=tol(alpha,"raw alpha with one zero-variance item")),
52 c("One item is constant; total-score variance remains positive, so raw alpha is defined."))
Hard-numeric STAT-MV-ALPHA-HARD-001
Case STAT-MV-ALPHA-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova and chisq.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_hard.R · sha256 06eca51b7d1d3ab6
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
items= ["i1", "i2", "i3"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cronbach_alpha | tolerance | 0.94285714285714284 | 0.9428571428571428 | 1.89E-18 | 17 | passed |
Convention
- Large identical item offsets must cancel in sample-variance alpha formula.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
82 items <- as.matrix(d[c("i1","i2","i3")]); k <- ncol(items)
83 alpha <- k/(k-1)*(1-sum(apply(items,2,stats::var))/stats::var(rowSums(items)))
84 emit("STAT-MV-ALPHA-HARD-001","tabelz.executor.item_analysis","itemAnalysisMenuItem",
85 "MV_HARD",list(items=list("i1","i2","i3")),
86 list("/cronbach_alpha"=tol(alpha,"analytic raw alpha from sample variances")),
87 c("Large identical item offsets must cancel in sample-variance alpha formula."))
Invalid multivariate request STAT-MV-ALPHA-INVALID-001
Case STAT-MV-ALPHA-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
items= ["i1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Cronbach alpha needs at least two items.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-ALPHA-INVALID-002
Case STAT-MV-ALPHA-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
items= ["i1", "i2"]reverse_items= ["i3"]scale_high= 5scale_low= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Reverse-coded item must be a selected item.
- The rejection follows from the declared request schema without statistical computation.
Minimum-sample STAT-MV-ALPHA-MIN-001
Case STAT-MV-ALPHA-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_minimum.R · sha256 bcd4094568b73b37
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
items= ["i1", "i3"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cronbach_alpha | tolerance | 1 | 1.0 | 0.00E+2 | passed |
Convention
- Two rows and two items are the documented minimum for item analysis.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
44 items <- as.matrix(d[c("i1","i3")]); k <- ncol(items)
45 alpha <- k/(k-1)*(1-sum(apply(items,2,stats::var))/stats::var(rowSums(items)))
46 emit("STAT-MV-ALPHA-MIN-001","tabelz.executor.item_analysis","itemAnalysisMenuItem",
47 "MV_MIN_TWO",list(items=list("i1","i3")),
48 list("/cronbach_alpha"=tol(alpha,"two-row two-item sample-variance alpha")),
49 c("Two rows and two items are the documented minimum for item analysis."))
Missing and excluded multivariate population STAT-MV-ALPHA-POP-001
Case STAT-MV-ALPHA-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic identities
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_population.R · sha256 8a6d148e9316e21f
- Dataset
- reference_data/datasets/MV_POP.json
Settings compared
items= ["i1", "i2", "i3"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/cronbach_alpha | tolerance | 0.94246782740348223 | 0.9424678274034822 | 2.16E-18 | 17 | passed |
Convention
- Raw alpha uses complete rows and sample variances after exclusions.
- R re-reads exported CSV, drops ordinal 9 by stable-row-ID exclusion, then uses complete cases.
Reference code
The lines of the reference script that produce this case's expected values.
65 itemd <- eligible[stats::complete.cases(eligible[c("i1","i2","i3")]),c("i1","i2","i3")]
66 itemm <- as.matrix(itemd); k <- ncol(itemm)
67 alpha <- k/(k-1)*(1-sum(apply(itemm,2,stats::var))/stats::var(rowSums(itemm)))
68 emit("STAT-MV-ALPHA-POP-001","tabelz.executor.item_analysis","itemAnalysisMenuItem",
69 list(items=list("i1","i2","i3")),
70 list("/excluded_count"=exact(1L,"One stable row ID excluded"),
71 "/missing_count"=exact(1L,"One item-missing row"),
72 "/cronbach_alpha"=tol(alpha,"Analytic raw alpha on complete selected items")),
73 c("Raw alpha uses complete rows and sample variances after exclusions."))
Multivariate option STAT-MV-ALPHA-REVERSE-001
Case STAT-MV-ALPHA-REVERSE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
items= ["i1", "i2", "i3"]reverse_items= ["i3"]scale_high= 5scale_low= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cronbach_alpha | tolerance | -1.7865168539325846 | -1.7865168539325833 | 1.30E-15 | 15 | passed |
Convention
- Reverse coding uses low+high-value once; raw alpha uses sample variances.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
69 items <- as.matrix(d[c("i1","i2","i3")]); items[,3] <- 6-items[,3]
70 k <- ncol(items)
71 alpha <- k/(k-1)*(1-sum(apply(items,2,stats::var))/stats::var(rowSums(items)))
72 emit("STAT-MV-ALPHA-REVERSE-001","tabelz.executor.item_analysis","itemAnalysisMenuItem",
73 list(items=list("i1","i2","i3"),reverse_items=list("i3"),scale_low=1,scale_high=5),
74 list("/cronbach_alpha"=tol(alpha,"Analytic sample-variance alpha after reflecting i3 as 6-i3")),
75 c("Reverse coding uses low+high-value once; raw alpha uses sample variances."))
Retained scoring STAT-MV-ALPHA-SCORE-001
Case STAT-MV-ALPHA-SCORE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic
- Citation
- R stats::prcomp, kmeans, hclust and matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring.R · sha256 6aa292c3e1b1894b
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
aggregation= "mean"model= {"item_analysis": {"items": ["i1", "i2", "i3"], "reverse_items": [], "scale_low": null, "scale_high": null, "row_ids": ["STAT-MV-ALPHA-SCORE-001:0", "STAT-MV-ALPHA-SCORE-001:1", "STAT-MV-ALPHA-SCORE-001:3", "STAT-MV-ALPHA-SCORE-001:4", "STAT-MV-ALPHA-SCORE-001:5", "STAT-MV-ALPHA-SCORE-001:6", "STAT-MV-ALPHA-SCORE-001:7", "STAT-MV-ALPHA-SCORE-001:8", "STAT-MV-ALPHA-SCORE-001:9", "STAT-MV-ALPHA-SCORE-001:10", "STAT-MV-ALPHA-SCORE-001:11"]}}names= ["scale_score"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/scale_score | tolerance | 1.3333333333333333 | 1.3333333333333333 | 4.07E-17 | 16 | passed |
/1/scale_score | tolerance | 1.3333333333333333 | 1.3333333333333333 | 4.07E-17 | 16 | passed |
/2/scale_score | absent | None | passed | |||
/3/scale_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/4/scale_score | tolerance | 3.3333333333333335 | 3.3333333333333335 | 1.86E-17 | 17 | passed |
/5/scale_score | tolerance | 3.3333333333333335 | 3.3333333333333335 | 1.86E-17 | 17 | passed |
/6/scale_score | tolerance | 3.3333333333333335 | 3.3333333333333335 | 1.86E-17 | 17 | passed |
/7/scale_score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/8/scale_score | tolerance | 4.666666666666667 | 4.666666666666667 | 3.73E-17 | 17 | passed |
/9/scale_score | tolerance | 4.333333333333333 | 4.333333333333333 | 3.73E-17 | 17 | passed |
/10/scale_score | tolerance | 4.666666666666667 | 4.666666666666667 | 3.73E-17 | 17 | passed |
/11/scale_score | tolerance | 4.333333333333333 | 4.333333333333333 | 3.73E-17 | 17 | passed |
Convention
- The item score is the arithmetic row mean; one row is outside retained membership.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
86 id <- "STAT-MV-ALPHA-SCORE-001"
Retained correction STAT-MV-ALPHA-SCORE-HARD-001
Case STAT-MV-ALPHA-SCORE-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and analytic row-identity join
- Citation
- R stats::prcomp, scale and base matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_corrections.R · sha256 d22bd7a20d0e25a3
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
aggregation= "mean"model= {"item_analysis": {"items": ["i1", "i3"], "reverse_items": [], "scale_low": null, "scale_high": null, "row_ids": ["STAT-MV-ALPHA-SCORE-HARD-001:0", "STAT-MV-ALPHA-SCORE-HARD-001:1", "STAT-MV-ALPHA-SCORE-HARD-001:2", "STAT-MV-ALPHA-SCORE-HARD-001:3", "STAT-MV-ALPHA-SCORE-HARD-001:4", "STAT-MV-ALPHA-SCORE-HARD-001:5", "STAT-MV-ALPHA-SCORE-HARD-001:6", "STAT-MV-ALPHA-SCORE-HARD-001:7", "STAT-MV-ALPHA-SCORE-HARD-001:8", "STAT-MV-ALPHA-SCORE-HARD-001:9", "STAT-MV-ALPHA-SCORE-HARD-001:10", "STAT-MV-ALPHA-SCORE-HARD-001:11"]}}names= ["scale_score"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/scale_score | tolerance | 1000001.5 | 1000001.5 | 0.00E+1 | passed | |
/1/scale_score | tolerance | 1000001.5 | 1000001.5 | 0.00E+1 | passed | |
/2/scale_score | tolerance | 1000001 | 1000001.0 | 0.00E+2 | passed | |
/3/scale_score | tolerance | 1000002 | 1000002.0 | 0.00E+2 | passed | |
/4/scale_score | tolerance | 1000003.5 | 1000003.5 | 0.00E+1 | passed | |
/5/scale_score | tolerance | 1000003.5 | 1000003.5 | 0.00E+1 | passed | |
/6/scale_score | tolerance | 1000003 | 1000003.0 | 0.00E+2 | passed | |
/7/scale_score | tolerance | 1000004 | 1000004.0 | 0.00E+2 | passed | |
/8/scale_score | tolerance | 1000005 | 1000005.0 | 0.00E+2 | passed | |
/9/scale_score | tolerance | 1000004 | 1000004.0 | 0.00E+2 | passed | |
/10/scale_score | tolerance | 1000004.5 | 1000004.5 | 0.00E+1 | passed | |
/11/scale_score | tolerance | 1000004.5 | 1000004.5 | 0.00E+1 | passed |
Convention
- Retained two-item score is the mean of million-offset integer responses.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
114 x <- as.matrix(hard[c("x","y","z")])
115 mu <- as.vector(as_serialized(colMeans(x))); sd <- as.vector(as_serialized(apply(x,2,stats::sd)))
116 scores <- as.vector(scale(x,center=mu,scale=sd)%*%as_serialized(weights))
117 model <- list(factor_analysis=list(columns=list("x","y","z"),means=nums(mu),
118 scales=nums(sd),weights=rows(weights),row_ids=ids(id,nrow(hard))))
119 emit(id,"operation:tabelz.factor_scores","factorAnalysisMenuItem",
120 "MV_HARD",list(names=list("factor1"),model=model),scores,"factor1",
121 c("Scoring subtracts 1e8-scale means before applying explicit factor weights."),kind="hard_numeric")
122 id <- "STAT-MV-ALPHA-SCORE-HARD-001"Whole script generators/r/multivariate_scoring_corrections.R
Invalid multivariate request STAT-MV-ALPHA-SCORE-INVALID-001
Case STAT-MV-ALPHA-SCORE-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
aggregation= "mean"model= {}names= ["score"]unknown_option= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Retained scoring rejects unknown request keys before creating an operation.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-ALPHA-SCORE-INVALID-002
Case STAT-MV-ALPHA-SCORE-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
aggregation= "mean"model= {}names= ["score"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A retained operation needs a model envelope matching its operation type.
- The rejection follows from the declared request schema without statistical computation.
Retained boundary STAT-MV-ALPHA-SCORE-MIN-001
Case STAT-MV-ALPHA-SCORE-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and retained identity join
- Citation
- R stats::prcomp and base matrix arithmetic documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_boundaries.R · sha256 4cdf60725804542b
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
aggregation= "mean"model= {"item_analysis": {"items": ["i1", "i3"], "reverse_items": [], "scale_low": null, "scale_high": null, "row_ids": ["STAT-MV-ALPHA-SCORE-MIN-001:0", "STAT-MV-ALPHA-SCORE-MIN-001:1"]}}names= ["scale_score"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/scale_score | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/1/scale_score | tolerance | 3.5 | 3.5 | 0.00E+1 | passed |
Convention
- Two-item arithmetic row mean; one retained row in OMIT case.
- R re-reads the exported CSV.
Reference code
Retained correction STAT-MV-ALPHA-SCORE-OMIT-CORRECTED-001
Case STAT-MV-ALPHA-SCORE-OMIT-CORRECTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and analytic row-identity join
- Citation
- R stats::prcomp, scale and base matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_corrections.R · sha256 d22bd7a20d0e25a3
- Dataset
- reference_data/datasets/MV_SCORE_FOUR.json
Settings compared
aggregation= "mean"model= {"item_analysis": {"items": ["i1", "i3"], "reverse_items": [], "scale_low": null, "scale_high": null, "row_ids": ["STAT-MV-ALPHA-SCORE-OMIT-CORRECTED-001:0", "STAT-MV-ALPHA-SCORE-OMIT-CORRECTED-001:1", "STAT-MV-ALPHA-SCORE-OMIT-CORRECTED-001:2"]}}names= ["scale_score"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/scale_score | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/1/scale_score | tolerance | 3.5 | 3.5 | 0.00E+1 | passed | |
/2/scale_score | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/3/scale_score | absent | None | passed |
Convention
- Two-item row mean for three retained rows; one nonmember.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
84 model <- list(kmeans=list(k=2L,seed=11L,restarts=50L,standardize=TRUE,
85 row_ids=ids(id,3L),labels=as.list(c(1L,2L,2L))))
86 emit(id,"operation:tabelz.kmeans_cluster_labels","kmeansClusteringMenuItem",
87 "MV_SCORE_FOUR",list(name="kcluster",model=model),c(1L,2L,2L,1L),"kcluster",
88 c("Three retained labels, one nonmember; the test concerns replay identity, not refitting k-means."),
89 omitted=4L,numeric=FALSE)
90 id <- "STAT-MV-ALPHA-SCORE-OMIT-CORRECTED-001"Whole script generators/r/multivariate_scoring_corrections.R
Configuration axis STAT-MV-ALPHA-SCORE-SUM-001
Case STAT-MV-ALPHA-SCORE-SUM-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and matrix arithmetic
- Citation
- R stats::hclust and base rowSums documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_axes.R · sha256 8e53089af57e269e
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
aggregation= "sum"model= {"item_analysis": {"items": ["i1", "i2", "i3"], "reverse_items": [], "scale_low": null, "scale_high": null, "row_ids": ["STAT-MV-ALPHA-SCORE-SUM-001:0", "STAT-MV-ALPHA-SCORE-SUM-001:1", "STAT-MV-ALPHA-SCORE-SUM-001:2", "STAT-MV-ALPHA-SCORE-SUM-001:3", "STAT-MV-ALPHA-SCORE-SUM-001:4", "STAT-MV-ALPHA-SCORE-SUM-001:5", "STAT-MV-ALPHA-SCORE-SUM-001:6", "STAT-MV-ALPHA-SCORE-SUM-001:7", "STAT-MV-ALPHA-SCORE-SUM-001:8", "STAT-MV-ALPHA-SCORE-SUM-001:9", "STAT-MV-ALPHA-SCORE-SUM-001:10", "STAT-MV-ALPHA-SCORE-SUM-001:11"]}}names= ["scale_sum"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/scale_sum | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/11/scale_sum | tolerance | 13 | 13.0 | 0.00E+2 | passed |
Convention
- The sum aggregation changes only the retained score operation, not the item-analysis fit.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
28 id <- "STAT-MV-ALPHA-SCORE-SUM-001"
Multivariate STAT-MV-CA-001
Case STAT-MV-CA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_core.R · sha256 90e434c114270562
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
column_column= "cat"mode= "categorical"row_column= "group"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chi_square | tolerance | 10.500000000000002 | 10.500000000000002 | 2.24E-16 | 16 | passed |
/total_inertia | tolerance | 0.87500000000000011 | 0.8750000000000001 | 1.02E-18 | 17 | passed |
Convention
- First-appearance row/column levels; inertia is chi-square divided by total count.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
97 tab <- table(factor(d$group, levels=c("A","B","C")),
98 factor(d$cat, levels=c("U","V","W")))
99 chi <- suppressWarnings(stats::chisq.test(tab, correct=FALSE))$statistic
100 emit("STAT-MV-CA-001", "tabelz.executor.correspondence_analysis",
101 "correspondenceAnalysisMenuItem",
102 list(mode="categorical", row_column="group", column_column="cat"),
103 list("/chi_square"=tol(chi, "Pearson chi-square for contingency table"),
104 "/total_inertia"=tol(chi/sum(tab), "CA total inertia = chi-square / n")),
105 c("First-appearance row/column levels; inertia is chi-square divided by total count."))
CA principal-coordinate sign convention
Case STAT-MV-CA-COORD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R ca::ca
- Citation
- R ca package simple correspondence-analysis documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · ca 0.72, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_ca_coordinates.R · sha256 4b100972a8c30fac
- Dataset
- reference_data/datasets/MV_CA_COORD.json
Settings compared
count_columns= ["U", "V", "W"]dimensions= 1mode= "count_table"row_label_column= "label"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/singular_values/0 | tolerance | 0.54170836383049903 | 0.5417083638304991 | 1.10E-16 | 15 | passed |
/row_categories/0/coordinates | sign_invariant_sequence | ['-0.61106269520984557'] | [0.6110626952098457] | passed | ||
/column_categories/0/coordinates | sign_invariant_sequence | ['-0.63200213675150896'] | [0.6320021367515091] | passed |
Convention
- R ca rowcoord/colcoord are standard coordinates; multiply by singular value for principal coordinates.
- The two positive singular values are distinct, so axis ordering is unique; each axis sign may flip.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
1 source("common.R",local=TRUE)
2 d <- data.frame(label=c("A","B","C"),U=c(8L,1L,2L),
3 V=c(2L,5L,1L),W=c(1L,2L,4L))
4 export_dataset(d,"MV_CA_COORD","Asymmetric positive three-by-three count table",
5 "R ca::ca principal-coordinate map with distinct inertias",
6 "Constructed validation data; no third-party license.",
7 c(label="String",U="Int64",V="Int64",W="Int64"))
8 d <- read_dataset("MV_CA_COORD")
9 tab <- as.matrix(d[c("U","V","W")])
10 fit <- ca::ca(tab)
11 stopifnot(fit$sv[1L]>fit$sv[2L],fit$sv[2L]>0)
12 principal_row <- fit$rowcoord[1L,1L]*fit$sv[1L]
13 principal_col <- fit$colcoord[1L,1L]*fit$sv[1L]
14 sign_one <- function(x,note) list(comparison="sign_invariant_sequence",
15 values=list(dec(unname(x))),absolute_tolerance="0",relative_tolerance="1e-9",
16 rationale=note)
17 tol <- function(x,note) list(comparison="tolerance",value=dec(unname(x)),
18 absolute_tolerance="0",relative_tolerance="1e-9",rationale=note)
19 id <- "STAT-MV-CA-COORD-001"
Multivariate option STAT-MV-CA-COUNTS-001
Case STAT-MV-CA-COUNTS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CA_COUNTS.json
Settings compared
count_columns= ["U", "V", "W"]mode= "count_table"row_label_column= "label"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chi_square | tolerance | 10.500000000000002 | 10.500000000000002 | 2.24E-16 | 16 | passed |
/total_inertia | tolerance | 0.87500000000000011 | 0.8750000000000001 | 1.02E-18 | 17 | passed |
Convention
- Count-table mode uses literal nonnegative integer cell counts.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
86 ca <- data.frame(label=c("A","B","C"),U=c(3L,0L,1L),V=c(1L,3L,0L),W=c(0L,1L,3L))
87 export_dataset(ca,"MV_CA_COUNTS","Constructed three-by-three count table",
88 "R stats::chisq.test and correspondence-analysis inertia identity",
89 "Constructed validation data; no third-party license.",
90 c(label="String",U="Int64",V="Int64",W="Int64"))
91 counts <- read_dataset("MV_CA_COUNTS")
92 table <- as.matrix(counts[c("U","V","W")])
93 chi <- suppressWarnings(stats::chisq.test(table,correct=FALSE))$statistic
94 emit("STAT-MV-CA-COUNTS-001","tabelz.executor.correspondence_analysis",
95 "correspondenceAnalysisMenuItem",
96 list(mode="count_table",row_label_column="label",count_columns=list("U","V","W")),
97 list("/chi_square"=tol(chi,"Pearson chi-square from R count table"),
98 "/total_inertia"=tol(chi/sum(table),"CA total inertia equals chi-square/n")),
99 c("Count-table mode uses literal nonnegative integer cell counts."),dataset="MV_CA_COUNTS")
Hard-numeric STAT-MV-CA-HARD-001
Case STAT-MV-CA-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova and chisq.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_hard.R · sha256 06eca51b7d1d3ab6
- Dataset
- reference_data/datasets/MV_CA_HARD.json
Settings compared
count_columns= ["U", "V", "W"]mode= "count_table"row_label_column= "label"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chi_square | tolerance | 1.3999981333358222e-05 | 1.3999981333358222e-05 | 1.76E-22 | 16 | passed |
Convention
- Large balanced cells with small departures; chi-square uses observed-expected squared/expected.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
88 mat <- as.matrix(ca[c("U","V","W")])
89 chi <- suppressWarnings(stats::chisq.test(mat,correct=FALSE))$statistic
90 emit("STAT-MV-CA-HARD-001","tabelz.executor.correspondence_analysis",
91 "correspondenceAnalysisMenuItem","MV_CA_HARD",
92 list(mode="count_table",row_label_column="label",count_columns=list("U","V","W")),
93 list("/chi_square"=tol(chi,"Pearson chi square with million-count baseline")),
94 c("Large balanced cells with small departures; chi-square uses observed-expected squared/expected."))
Invalid multivariate request STAT-MV-CA-INVALID-001
Case STAT-MV-CA-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
mode= "categorical"row_column= "group"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Categorical CA requires both category roles.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-CA-INVALID-002
Case STAT-MV-CA-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
column_column= "cat"dimensions= 0mode= "categorical"row_column= "group"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Requested dimensions must be positive.
- The rejection follows from the declared request schema without statistical computation.
Minimum-sample STAT-MV-CA-MIN-001
Case STAT-MV-CA-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_minimum.R · sha256 bcd4094568b73b37
- Dataset
- reference_data/datasets/MV_MIN_CA.json
Settings compared
count_columns= ["U", "V"]mode= "count_table"row_label_column= "label"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chi_square | tolerance | 0.66666666666666663 | 0.6666666666666666 | 3.41E-19 | 18 | passed |
Convention
- Two rows and two columns give one correspondence-analysis dimension.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
77 ct <- data.frame(label=c("A","B"),U=c(1L,2L),V=c(2L,1L))
78 export_dataset(ct,"MV_MIN_CA","Two-by-two positive count table",
79 "R chisq.test correspondence-analysis boundary",
80 "Constructed validation data; no third-party license.",
81 c(label="String",U="Int64",V="Int64"))
82 ct <- read_dataset("MV_MIN_CA")
83 chi <- suppressWarnings(stats::chisq.test(as.matrix(ct[c("U","V")]),correct=FALSE))$statistic
84 emit("STAT-MV-CA-MIN-001","tabelz.executor.correspondence_analysis",
85 "correspondenceAnalysisMenuItem","MV_MIN_CA",
86 list(mode="count_table",row_label_column="label",count_columns=list("U","V")),
87 list("/chi_square"=tol(chi,"Pearson chi-square of a two-by-two table")),
88 c("Two rows and two columns give one correspondence-analysis dimension."))
Missing and excluded multivariate population STAT-MV-CA-POP-001
Case STAT-MV-CA-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic identities
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_population.R · sha256 8a6d148e9316e21f
- Dataset
- reference_data/datasets/MV_POP.json
Settings compared
column_column= "cat"mode= "categorical"row_column= "group"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/chi_square | tolerance | 11.111111111111112 | 11.111111111111112 | 4.93E-16 | 16 | passed |
Convention
- Event rows with either category missing are omitted after exclusion.
- R re-reads exported CSV, drops ordinal 9 by stable-row-ID exclusion, then uses complete cases.
Reference code
The lines of the reference script that produce this case's expected values.
75 cad <- eligible[stats::complete.cases(eligible[c("group","cat")]),,drop=FALSE]
76 tab <- table(factor(cad$group,levels=c("A","B","C")),
77 factor(cad$cat,levels=c("U","V","W")))
78 chi <- suppressWarnings(stats::chisq.test(tab,correct=FALSE))$statistic
79 emit("STAT-MV-CA-POP-001","tabelz.executor.correspondence_analysis",
80 "correspondenceAnalysisMenuItem",list(mode="categorical",row_column="group",column_column="cat"),
81 list("/excluded_count"=exact(1L,"One stable row ID excluded"),
82 "/missing_count"=exact(1L,"One category-missing row"),
83 "/chi_square"=tol(chi,"R complete-case contingency chi-square")),
84 c("Event rows with either category missing are omitted after exclusion."))
Special boundary STAT-MV-CA-ZERO-001
Case STAT-MV-CA-ZERO-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_boundaries.R · sha256 420706593513ebf0
- Dataset
- reference_data/datasets/MV_CA_ZERO.json
Settings compared
count_columns= ["U", "V"]mode= "count_table"row_label_column= "label"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chi_square | tolerance | 3 | 3.0 | 0.00E+2 | passed |
Convention
- A zero observed cell is valid because both row and column margins remain positive.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
80 ct <- data.frame(label=c("A","B"),U=c(0L,3L),V=c(2L,1L))
81 export_dataset(ct,"MV_CA_ZERO","Two-by-two table with one zero cell and nonzero margins",
82 "R chisq.test zero-cell correspondence-analysis boundary",
83 "Constructed validation data; no third-party license.",
84 c(label="String",U="Int64",V="Int64"))
85 ct <- read_dataset("MV_CA_ZERO")
86 chi <- suppressWarnings(stats::chisq.test(as.matrix(ct[c("U","V")]),correct=FALSE))$statistic
87 emit("STAT-MV-CA-ZERO-001","tabelz.executor.correspondence_analysis",
88 "correspondenceAnalysisMenuItem","MV_CA_ZERO",
89 list(mode="count_table",row_label_column="label",count_columns=list("U","V")),
90 list("/chi_square"=tol(chi,"Pearson chi-square with one zero observed cell")),
91 c("A zero observed cell is valid because both row and column margins remain positive."))
Canonical correlation of three and two variables
Case STAT-MV-CANCOR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cancor plus closed-form Bartlett test, structure correlations and redundancy
- Citation
- R Core Team, stats package help: cancor; Bartlett (1941) sequential chi-square; Stewart and Love (1968) redundancy index.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_canonical.R · sha256 32ebf68ddffb5b14
- Dataset
- reference_data/datasets/MV_CANCOR.json
Settings compared
first= ["x1", "x2", "x3"]second= ["y1", "y2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/bartlett_multiplier | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/roots/0/correlation | tolerance | 0.79807559515563187 | 0.7980755951556321 | 2.19E-16 | 15 | passed |
/roots/0/squared | tolerance | 0.63692465558301603 | 0.6369246555830164 | 3.34E-16 | 15 | passed |
/roots/0/wilks_lambda | tolerance | 0.34234566342891148 | 0.3423456634289112 | 2.73E-16 | 15 | passed |
/roots/0/chi_square | tolerance | 16.079015108465114 | 16.07901510846513 | 1.45E-14 | 15 | passed |
/roots/0/df | exact | 6 | 6 | 0.00E+2 | passed | |
/roots/0/p_value | tail_probability | 0.013336086920075348 | 0.013336086920075268 | 7.98E-17 | 14 | passed |
/redundancy/0/first_own_variance | tolerance | 0.36386715396321445 | 0.36386715396321456 | 1.12E-16 | 15 | passed |
/redundancy/0/first_redundancy | tolerance | 0.23175596171599264 | 0.23175596171599283 | 1.91E-16 | 15 | passed |
/redundancy/0/second_own_variance | tolerance | 0.5232650083495336 | 0.5232650083495338 | 2.22E-16 | 15 | passed |
/redundancy/0/second_redundancy | tolerance | 0.33328038522167069 | 0.333280385221671 | 3.37E-16 | 14 | passed |
/roots/1/correlation | tolerance | 0.23894499073328559 | 0.2389449907332857 | 1.16E-16 | 15 | passed |
/roots/1/squared | tolerance | 0.057094708596529938 | 0.05709470859652999 | 5.50E-17 | 15 | passed |
/roots/1/wilks_lambda | tolerance | 0.94290529140347001 | 0.94290529140347 | 3.91E-18 | 17 | passed |
/roots/1/chi_square | tolerance | 0.88184152030118956 | 0.8818415203011896 | 3.11E-18 | 17 | passed |
/roots/1/df | exact | 2 | 2 | 0.00E+2 | passed | |
/roots/1/p_value | tail_probability | 0.64344369093410336 | 0.6434436909341033 | 1.08E-16 | 15 | passed |
/redundancy/1/first_own_variance | tolerance | 0.30889374876402664 | 0.3088937487640265 | 1.63E-16 | 15 | passed |
/redundancy/1/first_redundancy | tolerance | 0.017636198572971832 | 0.01763619857297184 | 6.88E-18 | 15 | passed |
/redundancy/1/second_own_variance | tolerance | 0.47673499165046634 | 0.47673499165046657 | 2.26E-16 | 15 | passed |
/redundancy/1/second_redundancy | tolerance | 0.02721904542605251 | 0.027219045426052548 | 3.81E-17 | 14 | passed |
/loadings/0/variable | exact | x1 | x1 | passed | ||
/loadings/0/raw | sequence | ['0.38602700140414303', '0.17398644948956274'] | [0.38602700140414303, 0.17398644948956274] | passed | ||
/loadings/0/standardized | sequence | ['1.136293706597068', '0.51213958316138908'] | [1.136293706597068, 0.5121395831613891] | passed | ||
/loadings/0/own_structure | sequence | ['0.95223722557777302', '-0.17059829954689215'] | [0.9522372255777731, -0.17059829954689223] | passed | ||
/loadings/0/cross_structure | sequence | ['0.75995729053232886', '-0.040763609104346392'] | [0.7599572905323292, -0.040763609104346406] | passed | ||
/loadings/1/variable | exact | x2 | x2 | passed | ||
/loadings/1/raw | sequence | ['0.19015806504951616', '0.75662662264390179'] | [0.19015806504951618, 0.7566266226439019] | passed | ||
/loadings/1/standardized | sequence | ['0.29794460641193748', '1.1855022884552877'] | [0.29794460641193754, 1.185502288455288] | passed | ||
/loadings/1/own_structure | sequence | ['-0.40292602124656329', '0.90068286005104004'] | [-0.40292602124656335, 0.9006828600510398] | passed | ||
/loadings/1/cross_structure | sequence | ['-0.32156542421004181', '0.21521365764852493'] | [-0.32156542421004186, 0.21521365764852488] | passed | ||
/loadings/2/variable | exact | x3 | x3 | passed | ||
/loadings/2/raw | sequence | ['0.17423645579878752', '-0.045857031487328781'] | [0.17423645579878744, -0.04585703148732876] | passed | ||
/loadings/2/standardized | sequence | ['0.25354369011812677', '-0.066729783545341023'] | [0.25354369011812666, -0.066729783545341] | passed | ||
/loadings/2/own_structure | sequence | ['0.14998783122641271', '-0.29385005035573397'] | [0.14998783122641257, -0.29385005035573397] | passed | ||
/loadings/2/cross_structure | sequence | ['0.11970162767212184', '-0.070213997559226332'] | [0.11970162767212184, -0.07021399755922635] | passed | ||
/loadings/3/variable | exact | y1 | y1 | passed | ||
/loadings/3/raw | sequence | ['0.5077080195901108', '-0.11220270973072193'] | [0.5077080195901109, -0.11220270973072197] | passed | ||
/loadings/3/standardized | sequence | ['0.99869338568718635', '-0.22070973815760844'] | [0.9986933856871866, -0.22070973815760853] | passed | ||
/loadings/3/own_structure | sequence | ['0.99998199054457437', '-0.0060015486760309107'] | [0.9999819905445746, -0.006001548676030933] | passed | ||
/loadings/3/cross_structure | sequence | ['0.79806122224877463', '-0.0014340399927795303'] | [0.7980612222487747, -0.0014340399927796343] | passed | ||
/loadings/4/variable | exact | y2 | y2 | passed | ||
/loadings/4/raw | sequence | ['-0.005015652493060966', '-0.83571131963358025'] | [-0.005015652493060886, -0.8357113196335805] | passed | ||
/loadings/4/standardized | sequence | ['-0.0061383294950053055', '-1.0227725006295123'] | [-0.0061383294950052075, -1.0227725006295125] | passed | ||
/loadings/4/own_structure | sequence | ['-0.21579164785871111', '-0.97643943217919149'] | [-0.21579164785871102, -0.9764394321791917] | passed | ||
/loadings/4/cross_structure | sequence | ['-0.17221804779445546', '-0.23331531107367159'] | [-0.1722180477944555, -0.23331531107367162] | passed |
Convention
- stats::cancor on the 19 complete rows (one x2 is missing); p = 3, q = 2, k = 2.
- Bartlett's chi-square: -(N - 1 - (p + q + 1)/2) sum_{i >= k} log(1 - r_i^2) on (p - k + 1)(q - k + 1) df, upper tail.
- Sign convention replicated from the product: each pair of variates is reflected so that the sum of the first set's structure correlations with its own variate is positive (the manual calls the sign arbitrary).
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:52-58: linear combinations U = a'X and V = b'Y with maximal correlation, successive pairs uncorrelated with the preceding ones; complete independent rows.
- docs/manual/chapters/92-dimensions-and-categories.tex:60-64: structure correlations are each variable with its own canonical variate, cross-structure with the other set's; redundancy = mean squared structure correlation times the squared canonical correlation.
- docs/manual/chapters/92-dimensions-and-categories.tex:73-79: Bartlett's sequential test -(N - 1 - (p + q + 1)/2) sum_{i >= k} log(1 - r_i^2) ~ chi-square with (p - k + 1)(q - k + 1) df; the sign of a canonical pair is arbitrary.
Reference code
The lines of the reference script that produce this case's expected values.
28 emit <- function(id, title, kind, configuration, outputs, notes, excluded = list()) {
29 expected <- list(schema_version = "2.0.0", case_id = id, outputs = outputs,
30 expected_error = NULL, deferred_outputs = list(), generator_run = run)
31 write_expected("multivariate", id, expected)
32 case <- list(
33 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "multivariate",
34 entry_point = "tabelz.analysis.canonical_correlation:compute_canonical_correlation",
35 menu_items = list("canonicalCorrelationMenuItem"), title = title, case_kind = kind,
36 dataset = list(path = "reference_data/datasets/MV_CANCOR.json", sha256 = ""),
37 excluded_rows = excluded, configuration = configuration, "repeat" = 1L,
38 expected = list(path = paste0("reference_data/expected/multivariate/", id, ".json"),
39 sha256 = ""),
40 oracle = list(oracle_class = "independent_implementation",
41 source = "R stats::cancor plus closed-form Bartlett test, structure correlations and redundancy",
42 citation = "R Core Team, stats package help: cancor; Bartlett (1941) sequential chi-square; Stewart and Love (1968) redundancy index.",
43 generator = list(path = "generators/r/multivariate_canonical.R", sha256 = ""),
44 independent = TRUE,
45 convention_notes = c(notes, "Expected computed from the exported CSV.", manual)),
46 supported = TRUE, unsupported_reason = NULL,
47 requirement_ids = list("REQ-STAT-MV-CANCOR-001"), risk_ids = list("RISK-REFERENCE-001"),
48 review_reference = NULL
49 )
50 write_case("multivariate", id, case)
Canonical correlation of one variable against one
Case STAT-MV-CANCOR-SINGLE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cancor plus closed-form Bartlett test, structure correlations and redundancy
- Citation
- R Core Team, stats package help: cancor; Bartlett (1941) sequential chi-square; Stewart and Love (1968) redundancy index.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_canonical.R · sha256 32ebf68ddffb5b14
- Dataset
- reference_data/datasets/MV_CANCOR.json
Settings compared
first= ["x1"]second= ["y1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/bartlett_multiplier | tolerance | 17.5 | 17.5 | 0.00E+1 | passed | |
/roots/0/correlation | tolerance | 0.76034586146243055 | 0.7603458614624302 | 3.33E-16 | 15 | passed |
/roots/0/squared | tolerance | 0.57812582904304566 | 0.5781258290430451 | 5.57E-16 | 15 | passed |
/roots/0/wilks_lambda | tolerance | 0.42187417095695434 | 0.4218741709569549 | 5.57E-16 | 14 | passed |
/roots/0/chi_square | tolerance | 15.103343193686035 | 15.103343193686012 | 2.31E-14 | 14 | passed |
/roots/0/df | exact | 1 | 1 | 0.00E+2 | passed | |
/roots/0/p_value | tail_probability | 0.00010178287360861925 | 0.00010178287360862053 | 1.28E-18 | 13 | passed |
/redundancy/0/first_own_variance | tolerance | 1 | 1.0000000000000004 | 4.44E-16 | 15 | passed |
/redundancy/0/first_redundancy | tolerance | 0.57812582904304566 | 0.5781258290430453 | 3.35E-16 | 15 | passed |
/redundancy/0/second_own_variance | tolerance | 1 | 0.9999999999999998 | 2.22E-16 | 15 | passed |
/redundancy/0/second_redundancy | tolerance | 0.57812582904304566 | 0.578125829043045 | 6.68E-16 | 14 | passed |
/loadings/0/variable | exact | x1 | x1 | passed | ||
/loadings/0/raw | sequence | ['0.34718947895486757'] | [0.3471894789548675] | passed | ||
/loadings/0/standardized | sequence | ['1.0000000000000002'] | [0.9999999999999999] | passed | ||
/loadings/0/own_structure | sequence | ['1'] | [1.0000000000000002] | passed | ||
/loadings/0/cross_structure | sequence | ['0.76034586146243044'] | [0.7603458614624308] | passed | ||
/loadings/1/variable | exact | y1 | y1 | passed | ||
/loadings/1/raw | sequence | ['0.52165474526221467'] | [0.5216547452622147] | passed | ||
/loadings/1/standardized | sequence | ['1.0000000000000002'] | [1.0] | passed | ||
/loadings/1/own_structure | sequence | ['1'] | [0.9999999999999999] | passed | ||
/loadings/1/cross_structure | sequence | ['0.76034586146243033'] | [0.7603458614624306] | passed |
Convention
- With one variable in each set the canonical correlation is |cor(x1, y1)| (checked in the generator), the structure correlations are +1 and +/-r, and Bartlett's test has one degree of freedom.
- Sign convention replicated from the product: each pair of variates is reflected so that the sum of the first set's structure correlations with its own variate is positive (the manual calls the sign arbitrary).
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:52-58: linear combinations U = a'X and V = b'Y with maximal correlation, successive pairs uncorrelated with the preceding ones; complete independent rows.
- docs/manual/chapters/92-dimensions-and-categories.tex:60-64: structure correlations are each variable with its own canonical variate, cross-structure with the other set's; redundancy = mean squared structure correlation times the squared canonical correlation.
- docs/manual/chapters/92-dimensions-and-categories.tex:73-79: Bartlett's sequential test -(N - 1 - (p + q + 1)/2) sum_{i >= k} log(1 - r_i^2) ~ chi-square with (p - k + 1)(q - k + 1) df; the sign of a canonical pair is arbitrary.
Reference code
The lines of the reference script that produce this case's expected values.
173 ref <- reference(d, "x1", "y1")
174 stopifnot(ref$N == 20, ref$k == 1, abs(ref$roots[[1]]$correlation - abs(cor(d$x1, d$y1))) < 1e-12)
175 emit("STAT-MV-CANCOR-SINGLE-001", "Canonical correlation of one variable against one", "boundary",
176 list(first = list("x1"), second = list("y1")),
177 outputs_for(ref, 0L, 0L),
178 list("With one variable in each set the canonical correlation is |cor(x1, y1)| (checked in the generator), the structure correlations are +1 and +/-r, and Bartlett's test has one degree of freedom.",
179 sign_note))
Canonical correlation of two and two variables with an excluded row
Case STAT-MV-CANCOR-SQUARE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cancor plus closed-form Bartlett test, structure correlations and redundancy
- Citation
- R Core Team, stats package help: cancor; Bartlett (1941) sequential chi-square; Stewart and Love (1968) redundancy index.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_canonical.R · sha256 32ebf68ddffb5b14
- Dataset
- reference_data/datasets/MV_CANCOR.json
Settings compared
first= ["x1", "x3"]second= ["y1", "y2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/bartlett_multiplier | tolerance | 15.5 | 15.5 | 0.00E+1 | passed | |
/roots/0/correlation | tolerance | 0.78152101261315443 | 0.7815210126131549 | 4.45E-16 | 15 | passed |
/roots/0/squared | tolerance | 0.61077509315589029 | 0.610775093155891 | 6.68E-16 | 14 | passed |
/roots/0/wilks_lambda | tolerance | 0.38904765948648917 | 0.38904765948648856 | 6.08E-16 | 14 | passed |
/roots/0/chi_square | tolerance | 14.632828086078288 | 14.632828086078312 | 2.44E-14 | 14 | passed |
/roots/0/df | exact | 4 | 4 | 0.00E+2 | passed | |
/roots/0/p_value | tail_probability | 0.0055265977627470004 | 0.005526597762746941 | 5.90E-17 | 13 | passed |
/redundancy/0/first_own_variance | tolerance | 0.49112211703906394 | 0.491122117039064 | 5.90E-17 | 15 | passed |
/redundancy/0/first_redundancy | tolerance | 0.29996515678545232 | 0.2999651567854527 | 3.93E-16 | 14 | passed |
/redundancy/0/second_own_variance | tolerance | 0.50736466879929321 | 0.5073646687992933 | 1.07E-16 | 15 | passed |
/redundancy/0/second_redundancy | tolerance | 0.30988570284989575 | 0.30988570284989614 | 3.89E-16 | 14 | passed |
/roots/1/correlation | tolerance | 0.021339762077989884 | 0.021339762077989762 | 1.22E-16 | 14 | passed |
/roots/1/squared | tolerance | 0.00045538544554521513 | 0.00045538544554520993 | 5.20E-18 | 13 | passed |
/roots/1/wilks_lambda | tolerance | 0.99954461455445476 | 0.9995446145544548 | 2.18E-18 | 17 | passed |
/roots/1/chi_square | tolerance | 0.0070600820572932401 | 0.0070600820572927405 | 5.00E-16 | 13 | passed |
/roots/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/roots/1/p_value | tail_probability | 0.93303711589230931 | 0.9330371158923115 | 2.22E-15 | 14 | passed |
/redundancy/1/first_own_variance | tolerance | 0.50887788296093606 | 0.5088778829609356 | 4.48E-16 | 15 | passed |
/redundancy/1/first_redundancy | tolerance | 0.0002317355814602717 | 0.00023173558146026885 | 2.85E-18 | 13 | passed |
/redundancy/1/second_own_variance | tolerance | 0.49263533120070674 | 0.4926353312007066 | 1.12E-16 | 15 | passed |
/redundancy/1/second_redundancy | tolerance | 0.00022433895979014846 | 0.00022433895979014586 | 2.60E-18 | 13 | passed |
/loadings/0/variable | exact | x1 | x1 | passed | ||
/loadings/0/raw | sequence | ['0.33706444282438358', '-0.037295061810982348'] | [0.33706444282438347, -0.037295061810982355] | passed | ||
/loadings/0/standardized | sequence | ['0.99593811401855303', '-0.11019724658880013'] | [0.9959381140185527, -0.11019724658880015] | passed | ||
/loadings/0/own_structure | sequence | ['0.984961733639663', '-0.1727726345968868'] | [0.984961733639663, -0.1727726345968868] | passed | ||
/loadings/0/cross_structure | sequence | ['0.76976829145927794', '-0.0036869269158850181'] | [0.7697682914592783, -0.0036869269158850432] | passed | ||
/loadings/1/variable | exact | x3 | x3 | passed | ||
/loadings/1/raw | sequence | ['0.11689898960892811', '0.66643095264815411'] | [0.11689898960892812, 0.666430952648154] | passed | ||
/loadings/1/standardized | sequence | ['0.17312095249209869', '0.98694746360625163'] | [0.17312095249209872, 0.9869474636062514] | passed | ||
/loadings/1/own_structure | sequence | ['0.10997553065876746', '0.99393429493921914'] | [0.10997553065876749, 0.9939342949392187] | passed | ||
/loadings/1/cross_structure | sequence | ['0.085948188083108987', '0.021210321375157451'] | [0.08594818808310899, 0.021210321375157503] | passed | ||
/loadings/2/variable | exact | y1 | y1 | passed | ||
/loadings/2/raw | sequence | ['0.5180819336156407', '-0.079552636785159392'] | [0.5180819336156407, -0.07955263678515939] | passed | ||
/loadings/2/standardized | sequence | ['1.0184914743619644', '-0.15639163821684121'] | [1.0184914743619642, -0.1563916382168412] | passed | ||
/loadings/2/own_structure | sequence | ['0.99583843042680975', '0.091136274254918617'] | [0.9958384304268099, 0.0911362742549186] | passed | ||
/loadings/2/cross_structure | sequence | ['0.77826865854625527', '0.0019448264092744717'] | [0.7782686585462553, 0.0019448264092744487] | passed | ||
/loadings/3/variable | exact | y2 | y2 | passed | ||
/loadings/3/raw | sequence | ['0.080711847017508415', '-0.88193158770067281'] | [0.08071184701750833, -0.8819315877006728] | passed | ||
/loadings/3/standardized | sequence | ['0.093909429157011642', '-1.0261404616170045'] | [0.09390942915701155, -1.0261404616170045] | passed | ||
/loadings/3/own_structure | sequence | ['-0.15177337738765148', '-0.98841531853586007'] | [-0.15177337738765162, -0.98841531853586] | passed | ||
/loadings/3/cross_structure | sequence | ['-0.11861408358371597', '-0.021092547731795766'] | [-0.11861408358371597, -0.021092547731795724] | passed |
Convention
- stats::cancor on rows 2-20 (row 1 is excluded by identity; no selected value is missing): p = q = 2, so both roots have a square set of coefficients.
- Sign convention replicated from the product: each pair of variates is reflected so that the sum of the first set's structure correlations with its own variate is positive (the manual calls the sign arbitrary).
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:52-58: linear combinations U = a'X and V = b'Y with maximal correlation, successive pairs uncorrelated with the preceding ones; complete independent rows.
- docs/manual/chapters/92-dimensions-and-categories.tex:60-64: structure correlations are each variable with its own canonical variate, cross-structure with the other set's; redundancy = mean squared structure correlation times the squared canonical correlation.
- docs/manual/chapters/92-dimensions-and-categories.tex:73-79: Bartlett's sequential test -(N - 1 - (p + q + 1)/2) sum_{i >= k} log(1 - r_i^2) ~ chi-square with (p - k + 1)(q - k + 1) df; the sign of a canonical pair is arbitrary.
Reference code
The lines of the reference script that produce this case's expected values.
164 ref <- reference(d[-1, ], c("x1", "x3"), c("y1", "y2"))
165 stopifnot(ref$N == 19, ref$k == 2)
166 emit("STAT-MV-CANCOR-SQUARE-001", "Canonical correlation of two and two variables with an excluded row", "axis_coverage",
167 list(first = list("x1", "x3"), second = list("y1", "y2")),
168 outputs_for(ref, 0L, 1L),
169 list("stats::cancor on rows 2-20 (row 1 is excluded by identity; no selected value is missing): p = q = 2, so both roots have a square set of coefficients.",
170 sign_note),
171 excluded = list(0L))
Categorical PCA with a binary nominal variable, one dimension
Case STAT-MV-CATPCA-NOMINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prcomp / eigen(cor(.)) on the uniquely quantified variables
- Citation
- Gifi (1990) Nonlinear Multivariate Analysis, ch. 4 (princals single quantification); Linting, Meulman, Groenen and van der Kooij (2007) Nonlinear principal components analysis, Psychological Methods 12(3) (Cronbach's alpha of a CATPCA dimension); R Core Team, stats package help: prcomp.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_catpca.R · sha256 a00047c7f5c09357
- Dataset
- reference_data/datasets/MV_CATPCA.json
Settings compared
dimensions= 1nominal= ["site"]numeric= ["x1", "x2", "x3"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 18 | 18 | 0.00E+2 | passed | |
/missing_count | exact | 2 | 2 | 0.00E+2 | passed | |
/converged | exact | True | True | passed | ||
/loss | tolerance | 0.56363309383193472 | 0.5636330938319349 | 2.19E-16 | 15 | passed |
/dimensions/0/eigenvalue | tolerance | 1.7454676246722609 | 1.74546762467226 | 8.79E-16 | 15 | passed |
/dimensions/0/percent | tolerance | 43.636690616806526 | 43.6366906168065 | 2.88E-14 | 15 | passed |
/dimensions/0/alpha | tolerance | 0.56945016845155116 | 0.5694501684515507 | 4.40E-16 | 15 | passed |
/variables/0/variable | exact | site | site | passed | ||
/variables/0/level | exact | nominal | nominal | passed | ||
/variables/0/loadings | sign_invariant_sequence | ['-0.27487959813455592'] | [-0.2748795981345563] | passed | ||
/variables/1/loadings | sign_invariant_sequence | ['0.88504957226925862'] | [0.8850495722692578] | passed | ||
/variables/2/loadings | sign_invariant_sequence | ['-0.86423325038628296'] | [-0.8642332503862818] | passed | ||
/variables/3/loadings | sign_invariant_sequence | ['0.37376058480584778'] | [0.37376058480584823] | passed | ||
/categories/0/category | exact | east | east | passed | ||
/categories/0/count | exact | 9 | 9 | 0.00E+2 | passed | |
/artifact/variables/0/quantifications | sign_invariant_sequence | ['-1', '1'] | [-1.0, 1.0] | passed |
Convention
- A binary nominal variable has one centred normalized quantification up to sign, so the optimum is the first principal component of cor(quantified site, x1, x2, x3) on the 18 rows complete on all four variables.
- Because the nominal sign is free, the site quantifications and every loading (one per variable in one dimension) are compared sign-invariantly; eigenvalue, percent, alpha and loss are sign-free.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:83-91: nominal variables permit unrestricted category values, ordinal ones a monotone order, numeric ones a linear transformation; one quantification per variable shared across dimensions, complete rows, equal weights.
- docs/manual/chapters/92-dimensions-and-categories.tex:93-98: read the achieved loss and convergence, component eigenvalues, loadings and category values; numeric-only inputs reduce to correlation-based PCA; the CATPCA alpha of a component is a function of its eigenvalue.
Reference code
The lines of the reference script that produce this case's expected values.
183 outputs[["/categories/0/category"]] <- exact("east", "categories in code-point order")
184 outputs[["/categories/0/count"]] <- exact(as.integer(counts[["east"]]), "rows at east")
185 outputs[["/artifact/variables/0/quantifications"]] <- sign_seq(c(y_east, y_west), "(-sqrt(n_west/n_east), sqrt(n_east/n_west)) up to a common sign: the pair flips together", rel = "1e-8")
186 emit("STAT-MV-CATPCA-NOMINAL-001", "Categorical PCA with a binary nominal variable, one dimension", "axis_coverage",
187 list(nominal = list("site"), numeric = list("x1", "x2", "x3"), dimensions = 1L),
188 outputs,
189 list("A binary nominal variable has one centred normalized quantification up to sign, so the optimum is the first principal component of cor(quantified site, x1, x2, x3) on the 18 rows complete on all four variables.",
190 "Because the nominal sign is free, the site quantifications and every loading (one per variable in one dimension) are compared sign-invariantly; eigenvalue, percent, alpha and loss are sign-free."))
Categorical PCA of numeric variables equals correlation PCA
Case STAT-MV-CATPCA-NUMERIC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prcomp / eigen(cor(.)) on the uniquely quantified variables
- Citation
- Gifi (1990) Nonlinear Multivariate Analysis, ch. 4 (princals single quantification); Linting, Meulman, Groenen and van der Kooij (2007) Nonlinear principal components analysis, Psychological Methods 12(3) (Cronbach's alpha of a CATPCA dimension); R Core Team, stats package help: prcomp.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_catpca.R · sha256 a00047c7f5c09357
- Dataset
- reference_data/datasets/MV_CATPCA.json
Settings compared
dimensions= 2numeric= ["x1", "x2", "x3"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 19 | 19 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/converged | exact | True | True | passed | ||
/loss | tolerance | 1.1198493852351499 | 1.1198493852351503 | 4.19E-16 | 15 | passed |
/dimensions/0/eigenvalue | tolerance | 1.6900838487006877 | 1.690083848700687 | 6.36E-16 | 15 | passed |
/dimensions/0/percent | tolerance | 56.33612829002292 | 56.336128290022906 | 1.43E-14 | 15 | passed |
/dimensions/0/alpha | tolerance | 0.61247006995944098 | 0.6124700699594408 | 2.25E-16 | 15 | passed |
/dimensions/1/eigenvalue | tolerance | 0.95036799559386276 | 0.9503679955938615 | 1.22E-15 | 14 | passed |
/dimensions/1/percent | tolerance | 31.678933186462093 | 31.67893318646205 | 4.30E-14 | 14 | passed |
/dimensions/1/alpha | tolerance | -0.078335978225661074 | -0.07833597822566307 | 2.00E-15 | 13 | passed |
/variables/0/variable | exact | x1 | x1 | passed | ||
/variables/0/level | exact | numeric | numeric | passed | ||
/variables/0/loadings | sequence | ['0.85707623106730413', '-0.31617448641347418'] | [0.8570762310673037, -0.3161744864134746] | passed | ||
/variables/1/variable | exact | x2 | x2 | passed | ||
/variables/1/level | exact | numeric | numeric | passed | ||
/variables/1/loadings | sequence | ['-0.89822253197929802', '0.092223177017479313'] | [-0.8982225319792981, 0.09222317701747873] | passed | ||
/variables/2/variable | exact | x3 | x3 | passed | ||
/variables/2/level | exact | numeric | numeric | passed | ||
/variables/2/loadings | sequence | ['0.38561699377082914', '0.91754922230681513'] | [0.38561699377082925, 0.9175492223068142] | passed | ||
/categories/0/variable | exact | x1 | x1 | passed | ||
/categories/0/quantification | tolerance | -1.6581154019395148 | -1.6581154019395148 | 1.19E-17 | 17 | passed |
/categories/0/count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- With numeric scaling levels only, each quantification is the linear standardization, so the princals optimum is the PCA of the Pearson correlation matrix: eigen(cor(x)) cross-checked with prcomp(scale. = TRUE) on the 19 complete rows.
- Loss at the optimum: dimensions - (lambda_1 + lambda_2)/m. Sign convention replicated from the product: the loadings of each dimension sum to a positive value.
- The eigenvalues are distinct, so the loadings are unique up to the stated sign.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:83-91: nominal variables permit unrestricted category values, ordinal ones a monotone order, numeric ones a linear transformation; one quantification per variable shared across dimensions, complete rows, equal weights.
- docs/manual/chapters/92-dimensions-and-categories.tex:93-98: read the achieved loss and convergence, component eigenvalues, loadings and category values; numeric-only inputs reduce to correlation-based PCA; the CATPCA alpha of a component is a function of its eigenvalue.
Reference code
The lines of the reference script that produce this case's expected values.
122 sd_pop <- function(v) sqrt(mean((v - mean(v))^2))
123 stopifnot(!anyDuplicated(q[, "x1"]))
124 first_x1 <- sort(unique(q[, "x1"]))[1]
125 outputs[["/categories/0/variable"]] <- exact("x1", "the first category row belongs to x1")
126 outputs[["/categories/0/quantification"]] <- tol((first_x1 - mean(q[, "x1"])) / sd_pop(q[, "x1"]), "numeric quantification: (x - mean)/population SD of the smallest x1 value", rel = "1e-8")
127 outputs[["/categories/0/count"]] <- exact(1L, "distinct x1 values occur once")
128 emit("STAT-MV-CATPCA-NUMERIC-001", "Categorical PCA of numeric variables equals correlation PCA", "nominal",
129 list(numeric = list("x1", "x2", "x3"), dimensions = 2L),
130 outputs,
131 list("With numeric scaling levels only, each quantification is the linear standardization, so the princals optimum is the PCA of the Pearson correlation matrix: eigen(cor(x)) cross-checked with prcomp(scale. = TRUE) on the 19 complete rows.",
132 "Loss at the optimum: dimensions - (lambda_1 + lambda_2)/m. Sign convention replicated from the product: the loadings of each dimension sum to a positive value.",
133 "The eigenvalues are distinct, so the loadings are unique up to the stated sign."))
Categorical PCA with a binary ordinal variable
Case STAT-MV-CATPCA-ORDINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prcomp / eigen(cor(.)) on the uniquely quantified variables
- Citation
- Gifi (1990) Nonlinear Multivariate Analysis, ch. 4 (princals single quantification); Linting, Meulman, Groenen and van der Kooij (2007) Nonlinear principal components analysis, Psychological Methods 12(3) (Cronbach's alpha of a CATPCA dimension); R Core Team, stats package help: prcomp.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_catpca.R · sha256 a00047c7f5c09357
- Dataset
- reference_data/datasets/MV_CATPCA.json
Settings compared
dimensions= 2numeric= ["x1", "x2"]orders= ["rating: low < high"]ordinal= ["rating"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/converged | exact | True | True | passed | ||
/loss | tolerance | 1.0907898068095592 | 1.0907898068095587 | 4.74E-16 | 15 | passed |
/dimensions/0/eigenvalue | tolerance | 2.33599353865052 | 2.33599353865052 | 4.83E-17 | 16 | passed |
/dimensions/0/percent | tolerance | 77.86645128835066 | 77.86645128835066 | 3.20E-16 | 17 | passed |
/dimensions/0/alpha | tolerance | 0.85787493621813049 | 0.8578749362181305 | 4.95E-19 | 18 | passed |
/dimensions/1/eigenvalue | tolerance | 0.39163704092080254 | 0.391637040920803 | 4.41E-16 | 14 | passed |
/dimensions/1/percent | tolerance | 13.054568030693417 | 13.054568030693432 | 1.45E-14 | 14 | passed |
/dimensions/1/alpha | tolerance | -2.3300769418368996 | -2.3300769418368947 | 4.87E-15 | 14 | passed |
/variables/0/variable | exact | rating | rating | passed | ||
/variables/0/level | exact | ordinal | ordinal | passed | ||
/variables/0/categories | exact | 2 | 2 | 0.00E+2 | passed | |
/variables/0/loadings | sequence | ['0.90719547188237959', '0.04388715389750688'] | [0.9071954718823804, 0.04388715389750762] | passed | ||
/variables/1/loadings | sequence | ['0.87414237656941896', '0.41559888847014059'] | [0.8741423765694183, 0.4155988884701403] | passed | ||
/variables/2/loadings | sequence | ['-0.86536987463869763', '0.46582026850059105'] | [-0.8653698746386972, 0.46582026850059166] | passed | ||
/categories/0/category | exact | low | low | passed | ||
/categories/0/count | exact | 13 | 13 | 0.00E+2 | passed | |
/categories/0/quantification | tolerance | -0.73379938570534275 | -0.7337993857053428 | 4.88E-18 | 17 | passed |
/categories/1/category | exact | high | high | passed | ||
/categories/1/quantification | tolerance | 1.3627702877384937 | 1.3627702877384937 | 3.52E-17 | 16 | passed |
Convention
- A two-category variable has exactly one centred quantification with sum of squared values n (up to sign); the ordinal restriction low < high fixes the sign, so the quantification is -sqrt(n_high/n_low) for low and sqrt(n_low/n_high) for high and the princals optimum is the PCA of cor(quantified rating, x1, x2).
- Sign convention replicated from the product: the loadings of each dimension sum to a positive value.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:83-91: nominal variables permit unrestricted category values, ordinal ones a monotone order, numeric ones a linear transformation; one quantification per variable shared across dimensions, complete rows, equal weights.
- docs/manual/chapters/92-dimensions-and-categories.tex:93-98: read the achieved loss and convergence, component eigenvalues, loadings and category values; numeric-only inputs reduce to correlation-based PCA; the CATPCA alpha of a component is a function of its eigenvalue.
Reference code
The lines of the reference script that produce this case's expected values.
155 outputs[["/categories/0/category"]] <- exact("low", "categories in the declared order")
156 outputs[["/categories/0/count"]] <- exact(as.integer(counts[["low"]]), "rows rated low")
157 outputs[["/categories/0/quantification"]] <- tol(y_low, "-sqrt(n_high/n_low): the centred, normalized non-decreasing quantification of a binary ordinal variable", rel = "1e-8")
158 outputs[["/categories/1/category"]] <- exact("high", "categories in the declared order")
159 outputs[["/categories/1/quantification"]] <- tol(y_high, "sqrt(n_low/n_high)", rel = "1e-8")
160 emit("STAT-MV-CATPCA-ORDINAL-001", "Categorical PCA with a binary ordinal variable", "axis_coverage",
161 list(ordinal = list("rating"), orders = list("rating: low < high"), numeric = list("x1", "x2"),
162 dimensions = 2L),
163 outputs,
164 list("A two-category variable has exactly one centred quantification with sum of squared values n (up to sign); the ordinal restriction low < high fixes the sign, so the quantification is -sqrt(n_high/n_low) for low and sqrt(n_low/n_high) for high and the princals optimum is the PCA of cor(quantified rating, x1, x2).",
165 "Sign convention replicated from the product: the loadings of each dimension sum to a positive value."))
Multivariate STAT-MV-CORR-001
Case STAT-MV-CORR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_core.R · sha256 90e434c114270562
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]max_scatter_columns= 0metric= "pearson"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/0/value | tolerance | 1 | 0.9999999999999999 | 1.11E-16 | 15 | passed |
/cells/1/value | tolerance | 0.18721076777216533 | 0.18721076777216525 | 8.14E-17 | 15 | passed |
Convention
- Pearson product-moment correlation, complete pairwise finite observations.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
91 emit("STAT-MV-CORR-001", "tabelz.analysis.correlation:compute_correlation",
92 "correlationMenuItem", list(columns=list("x","y","z"), metric="pearson", max_scatter_columns=0L),
93 list("/cells/0/value"=tol(1, "diagonal correlation"),
94 "/cells/1/value"=tol(stats::cor(d$x,d$y), "Pearson x-y correlation")),
95 c("Pearson product-moment correlation, complete pairwise finite observations."))
Multivariate option STAT-MV-CORR-COVARIANCE-001
Case STAT-MV-CORR-COVARIANCE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]max_scatter_columns= 0metric= "covariance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/1/value | tolerance | 1.4352272727272728 | 1.4352272727272724 | 4.48E-16 | 15 | passed |
Convention
- All rows finite; R cor or cov uses the complete pair and sample covariance.
- R re-reads the exported CSV.
Reference code
Hard-numeric STAT-MV-CORR-HARD-001
Case STAT-MV-CORR-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova and chisq.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_hard.R · sha256 06eca51b7d1d3ab6
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
columns= ["x", "y", "z"]max_scatter_columns= 0metric= "covariance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/1/value | tolerance | 1.4352272790828438 | 1.4352272816666667 | 2.58E-9 | 8 | passed |
Convention
- R sample covariance uses n-1 and centered products at 1e8 offset.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
95 emit("STAT-MV-CORR-HARD-001","tabelz.analysis.correlation:compute_correlation",
96 "correlationMenuItem","MV_HARD",
97 list(columns=xyz,metric="covariance",max_scatter_columns=0L),
98 list("/cells/1/value"=tol(stats::cov(d$x,d$y),"sample covariance after common offsets")),
99 c("R sample covariance uses n-1 and centered products at 1e8 offset."))
Invalid multivariate request STAT-MV-CORR-INVALID-001
Case STAT-MV-CORR-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Correlation columns must be supplied as a list.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-CORR-INVALID-002
Case STAT-MV-CORR-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]unknown_option= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The validation binding refuses unknown correlation settings.
- The rejection follows from the declared request schema without statistical computation.
Minimum-sample STAT-MV-CORR-MIN-001
Case STAT-MV-CORR-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_minimum.R · sha256 bcd4094568b73b37
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
columns= ["x", "y"]max_scatter_columns= 0metric= "pearson"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/1/value | tolerance | 1 | 0.9999999999999999 | 1.11E-16 | 15 | passed |
Convention
- Two distinct pairs are the smallest nonconstant sample for Pearson r.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
50 emit("STAT-MV-CORR-MIN-001","tabelz.analysis.correlation:compute_correlation",
51 "correlationMenuItem","MV_MIN_TWO",
52 list(columns=list("x","y"),metric="pearson",max_scatter_columns=0L),
53 list("/cells/1/value"=tol(stats::cor(d$x,d$y),"two-row Pearson r is exactly signed one")),
54 c("Two distinct pairs are the smallest nonconstant sample for Pearson r."))
Missing and excluded multivariate population STAT-MV-CORR-POP-001
Case STAT-MV-CORR-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic identities
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_population.R · sha256 8a6d148e9316e21f
- Dataset
- reference_data/datasets/MV_POP.json
Settings compared
columns= ["x", "y"]max_scatter_columns= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/1/value | tolerance | 0.13746837529560801 | 0.13746837529560796 | 5.15E-17 | 15 | passed |
/cells/1/pair_count | exact | 10 | 10 | 0.00E+2 | passed |
Convention
- Correlation uses pairwise finite rows rather than all-variable complete cases.
- R re-reads exported CSV, drops ordinal 9 by stable-row-ID exclusion, then uses complete cases.
Reference code
The lines of the reference script that produce this case's expected values.
96 pair <- eligible[stats::complete.cases(eligible[c("x","y")]),,drop=FALSE]
97 emit("STAT-MV-CORR-POP-001","tabelz.analysis.correlation:compute_correlation",
98 "correlationMenuItem",list(columns=list("x","y"),max_scatter_columns=0L),
99 list("/cells/1/value"=tol(stats::cor(pair$x,pair$y),"R pairwise-complete Pearson x-y"),
100 "/cells/1/pair_count"=exact(nrow(pair),"Pairwise finite rows after exclusion")),
101 c("Correlation uses pairwise finite rows rather than all-variable complete cases."))
Multivariate option STAT-MV-CORR-SPEARMAN-001
Case STAT-MV-CORR-SPEARMAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]max_scatter_columns= 0metric= "spearman"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/1/value | tolerance | 0.43356643356643365 | 0.43356643356643365 | 1.06E-18 | 17 | passed |
Convention
- All rows finite; R cor or cov uses the complete pair and sample covariance.
- R re-reads the exported CSV.
Reference code
Special boundary STAT-MV-CORR-TIES-001
Case STAT-MV-CORR-TIES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_boundaries.R · sha256 420706593513ebf0
- Dataset
- reference_data/datasets/MV_TIES.json
Settings compared
columns= ["x", "y"]max_scatter_columns= 0metric= "spearman"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cells/1/value | tolerance | 0.7777777777777779 | 0.7777777777777779 | 1.14E-18 | 17 | passed |
Convention
- Tied ranks use R average/midrank convention.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
53 emit("STAT-MV-CORR-TIES-001","tabelz.analysis.correlation:compute_correlation",
54 "correlationMenuItem","MV_TIES",
55 list(columns=list("x","y"),metric="spearman",max_scatter_columns=0L),
56 list("/cells/1/value"=tol(stats::cor(d$x,d$y,method="spearman"),"midrank Spearman correlation with ties")),
57 c("Tied ranks use R average/midrank convention."))
One-factor maximum-likelihood fit
Case STAT-MV-FA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::factanal
- Citation
- R stats::factanal maximum-likelihood factor analysis documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_factor.R · sha256 c9e6d06b9a729e97
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]n_factors= 1rotation= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlation_eigenvalues/0 | tolerance | 1.9974590554819613 | 1.9974590554819616 | 2.65E-16 | 15 | passed |
/status | exact | heywood | heywood | passed | ||
/uniquenesses/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/uniquenesses/1 | tolerance | 0.96495212843015643 | 0.9649521386877041 | 1.03E-8 | 7 | passed |
/uniquenesses/2 | tolerance | 0.042237444955563586 | 0.042237445281103625 | 3.26E-10 | 8 | passed |
/source_count | exact | 12 | 12 | 0.00E+2 | passed |
Convention
- Issue #14 ruling: the ML optimum is a verified zero-uniqueness boundary, derived in closed form and checked by its KKT conditions in R.
- Until 2026-09-25 this case compared R factanal's lower = 0.005 floor value.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
10 r <- stats::cor(d[c("x","y","z")])
11 stopifnot(r[1,2] * r[1,3] / r[2,3] > 1)
12 lambda <- c(1, r[1,2], r[1,3]); psi <- c(0, 1 - r[1,2]^2, 1 - r[1,3]^2)
13 Sigma <- outer(lambda, lambda) + diag(psi); Si <- solve(Sigma); G <- Si - Si %*% r %*% Si
14 stopifnot(max(abs(2 * G %*% lambda)) < 1e-10, max(abs(diag(G)[2:3])) < 1e-10, G[1,1] > 0)
15 eig <- eigen(r, symmetric=TRUE)$values
16 id <- "STAT-MV-FA-001"
Stable ML factor fit none
Case STAT-MV-FA-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::factanal
- Citation
- R stats::factanal maximum-likelihood factor analysis documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_factor_stable.R · sha256 ffea0161e03a21ed
- Dataset
- reference_data/datasets/MV_FACTOR.json
Settings compared
columns= ["a", "b", "c", "d", "e"]n_factors= 1rotation= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/uniquenesses/0 | tolerance | 0.022572310681013421 | 0.022572307497717634 | 3.18E-9 | 6 | passed |
/uniquenesses/2 | tolerance | 0.99088378691611756 | 0.9908837872735816 | 3.57E-10 | 9 | passed |
/correlation_eigenvalues/0 | tolerance | 3.0076852930674587 | 3.007685293067464 | 5.32E-15 | 14 | passed |
Convention
- R maximum likelihood with 20 starts and lower uniqueness 0.005; fitted uniquenesses are interior.
- Orthogonal rotation cannot change uniquenesses.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
41 set.seed(1959L)
42 fit1 <- stats::factanal(d,factors=1L,rotation="none",control=list(nstart=20L,opt=list(factr=1,pgtol=0,maxit=10000)))
43 set.seed(1959L)
44 fit2 <- stats::factanal(d,factors=2L,rotation="varimax",control=list(nstart=20L,opt=list(factr=1,pgtol=0,maxit=10000)))
45 emit("STAT-MV-FA-002",1L,"none",fit1)
Seeded ML factor fit none
Case STAT-MV-FA-003 · status: passed
Reference
- Evidence type
- R
- Source
- Seeded R stats::factanal
- Citation
- R stats::factanal maximum-likelihood factor analysis documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_factor_seeded.R · sha256 d0fd8847879330e0
- Dataset
- reference_data/datasets/MV_FACTOR.json
Settings compared
columns= ["a", "b", "c", "d", "e"]n_factors= 1rotation= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/uniquenesses/0 | tolerance | 0.022572310681013421 | 0.022572307497717634 | 3.18E-9 | 6 | passed |
/uniquenesses/2 | tolerance | 0.99088378691611756 | 0.9908837872735816 | 3.57E-10 | 9 | passed |
/correlation_eigenvalues/0 | tolerance | 3.0076852930674587 | 3.007685293067464 | 5.32E-15 | 14 | passed |
Convention
- set.seed(1959) before each fit; 20 starts; L-BFGS-B factr=1 (reltol does not apply to L-BFGS-B).
- R uniqueness lower bound 0.005 is not active for these interior fits.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
29 set.seed(1959)
30 fit1 <- stats::factanal(d,factors=1L,rotation="none",
31 control=list(nstart=20L,opt=list(factr=1,pgtol=0,maxit=10000)))
32 set.seed(1959)
33 fit2 <- stats::factanal(d,factors=2L,rotation="varimax",
34 control=list(nstart=20L,opt=list(factr=1,pgtol=0,maxit=10000)))
35 emit("STAT-MV-FA-003",1L,"none",fit1)
Hard-numeric STAT-MV-FA-HARD-001
Case STAT-MV-FA-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova and chisq.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_hard.R · sha256 06eca51b7d1d3ab6
- Dataset
- reference_data/datasets/MV_FACTOR_HARD.json
Settings compared
columns= ["a", "b", "c", "d", "e"]n_factors= 1rotation= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/uniquenesses/0 | tolerance | 0.022572308717974939 | 0.022572307649409158 | 1.07E-9 | 7 | passed |
Convention
- set.seed(1959), 20 starts, L-BFGS-B factr=1; R ML factor analysis on offset data.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
55 set.seed(1959)
56 fa <- stats::factanal(f,factors=1L,rotation="none",
57 control=list(nstart=20L,opt=list(factr=1,pgtol=0,maxit=10000)))
58 emit("STAT-MV-FA-HARD-001","tabelz.executor.factor_analysis","factorAnalysisMenuItem",
59 "MV_FACTOR_HARD",list(columns=as.list(names(f)),n_factors=1L,rotation="none"),
60 list("/uniquenesses/0"=tol(fa$uniquenesses[1],"seeded ML uniqueness","1e-6")),
61 c("set.seed(1959), 20 starts, L-BFGS-B factr=1; R ML factor analysis on offset data."))
Invalid multivariate request STAT-MV-FA-INVALID-001
Case STAT-MV-FA-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y"]n_factors= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- FA needs at least three columns.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-FA-INVALID-002
Case STAT-MV-FA-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]n_factors= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Factor count must be positive.
- The rejection follows from the declared request schema without statistical computation.
Seeded ML factor-loading sign convention
Case STAT-MV-FA-LOADINGS-001 · status: passed
Reference
- Evidence type
- R
- Source
- Seeded R stats::factanal
- Citation
- R stats::factanal maximum-likelihood factor analysis documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_factor_loadings.R · sha256 4c3562f543b3c199
- Dataset
- reference_data/datasets/MV_FACTOR.json
Settings compared
columns= ["a", "b", "c", "d", "e"]n_factors= 1rotation= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/loadings/0 | sign_invariant_sequence | ['0.98864942686416046'] | [0.9886494285114245] | passed | ||
/loadings/2 | sign_invariant_sequence | ['0.09547885970496163'] | [0.09547885879877761] | passed |
Convention
- set.seed(1959) before ML fit; 20 starts, L-BFGS-B factr=1 (reltol does not apply to L-BFGS-B).
- One factor avoids factor-order ambiguity; its common sign may flip.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
1 source("common.R",local=TRUE)
2 d <- read_dataset("MV_FACTOR")
3 set.seed(1959)
4 fit <- stats::factanal(d,factors=1L,rotation="none",
5 control=list(nstart=20L,opt=list(factr=1,pgtol=0,maxit=10000)))
6 sign_one <- function(x,note) list(comparison="sign_invariant_sequence",
7 values=list(dec(unname(x))),absolute_tolerance="0",relative_tolerance="1e-6",
8 rationale=note)
9 id <- "STAT-MV-FA-LOADINGS-001"
Minimum-sample STAT-MV-FA-MIN-001
Case STAT-MV-FA-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_minimum.R · sha256 bcd4094568b73b37
- Dataset
- reference_data/datasets/MV_MIN_FACTOR.json
Settings compared
columns= ["a", "b", "c"]n_factors= 1rotation= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlation_eigenvalues/0 | tolerance | 2.5170977612954761 | 2.5170977612954757 | 4.11E-16 | 15 | passed |
Convention
- Four complete rows exceed the three selected columns by one; only the closed-form correlation eigenvalue is compared because a just-identified ML uniqueness fit is nonunique.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
55 f <- factor[c(1L,6L,12L,18L),c("a","b","c")]
56 export_dataset(f,"MV_MIN_FACTOR","Four complete observations on three variables",
57 "R seeded ML factor-analysis minimum-row boundary",
58 "Constructed validation data; no third-party license.",
59 setNames(rep("Float64",ncol(f)),names(f)))
60 f <- read_dataset("MV_MIN_FACTOR")
61 eig <- eigen(stats::cor(f),symmetric=TRUE)$values[1]
62 emit("STAT-MV-FA-MIN-001","tabelz.executor.factor_analysis","factorAnalysisMenuItem",
63 "MV_MIN_FACTOR",list(columns=as.list(names(f)),n_factors=1L,rotation="none"),
64 list("/correlation_eigenvalues/0"=tol(eig,"sample-correlation eigenvalue at n=p+1")),
65 c("Four complete rows exceed the three selected columns by one; only the closed-form correlation eigenvalue is compared because a just-identified ML uniqueness fit is nonunique."))
Factor preprocessing after missing and exclusion
Case STAT-MV-FA-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor/eigen
- Citation
- R stats::cor and eigen documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_factor_population.R · sha256 12f01f8bd6ff3de3
- Dataset
- reference_data/datasets/MV_FACTOR_POP.json
Settings compared
columns= ["a", "b", "c", "d", "e"]n_factors= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 48 | 48 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/correlation_eigenvalues/0 | tolerance | 2.8976622631661444 | 2.8976622631661497 | 5.32E-15 | 14 | passed |
Convention
- R re-reads the exported CSV, excludes zero-based ordinal 10, then drops incomplete cases.
- The eigenvalue checks factor preprocessing; separate seeded cases compare ML uniquenesses.
Reference code
The lines of the reference script that produce this case's expected values.
1 source("common.R",local=TRUE)
2 raw <- read_dataset("MV_FACTOR")
3 raw$a[4] <- NA_real_
4 export_dataset(raw,"MV_FACTOR_POP","Constructed factor matrix with one missing measurement",
5 "R stats::cor/eigen for complete-case factor preprocessing",
6 "Constructed validation data; no third-party license.",
7 c(a="Float64",b="Float64",c="Float64",d="Float64",e="Float64"))
8 d <- read_dataset("MV_FACTOR_POP")
9 selected <- d[-11L,,drop=FALSE]
10 selected <- selected[stats::complete.cases(selected),,drop=FALSE]
11 eig <- eigen(stats::cor(selected),symmetric=TRUE)$values[1]
12 id <- "STAT-MV-FA-POP-001"
Retained scoring STAT-MV-FA-SCORE-001
Case STAT-MV-FA-SCORE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic
- Citation
- R stats::prcomp, kmeans, hclust and matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring.R · sha256 6aa292c3e1b1894b
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {"factor_analysis": {"columns": ["x", "y", "z"], "means": [5.00833333333333, 4.025, 5.69166666666667], "scales": [3.41479623599027, 2.2450450491532, 2.59000117000091], "weights": [[0.2], [0.3], [0.5]], "row_ids": ["STAT-MV-FA-SCORE-001:0", "STAT-MV-FA-SCORE-001:1", "STAT-MV-FA-SCORE-001:3", "STAT-MV-FA-SCORE-001:4", "STAT-MV-FA-SCORE-001:5", "STAT-MV-FA-SCORE-001:6", "STAT-MV-FA-SCORE-001:7", "STAT-MV-FA-SCORE-001:8", "STAT-MV-FA-SCORE-001:9", "STAT-MV-FA-SCORE-001:10", "STAT-MV-FA-SCORE-001:11"]}}names= ["factor1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/factor1 | tolerance | -1.0056800962632124 | -1.0056800962632118 | 6.46E-16 | 15 | passed |
/1/factor1 | tolerance | -1.0385186375316962 | -1.0385186375316955 | 7.12E-16 | 15 | passed |
/2/factor1 | absent | None | passed | |||
/3/factor1 | tolerance | -0.9344876886373692 | -0.9344876886373686 | 5.59E-16 | 15 | passed |
/4/factor1 | tolerance | 0.30964365596844301 | 0.3096436559684418 | 1.22E-15 | 14 | passed |
/5/factor1 | tolerance | 0.24851594688027384 | 0.24851594688027281 | 1.03E-15 | 14 | passed |
/6/factor1 | tolerance | 0.25164323927876997 | 0.2516432392787688 | 1.17E-15 | 14 | passed |
/7/factor1 | tolerance | 0.25775625892681586 | 0.2577562589268148 | 1.05E-15 | 14 | passed |
/8/factor1 | tolerance | 0.72204417751835126 | 0.7220441775183503 | 9.99E-16 | 14 | passed |
/9/factor1 | tolerance | 0.76980912579630145 | 0.7698091257963005 | 9.97E-16 | 14 | passed |
/10/factor1 | tolerance | 0.69523327096088949 | 0.6952332709608886 | 8.85E-16 | 14 | passed |
/11/factor1 | tolerance | 0.7874651052442454 | 0.7874651052442443 | 1.11E-15 | 14 | passed |
Convention
- The fixed weight vector is an analytic retained basis; this tests replay, not factor fitting.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
50 id <- "STAT-MV-FA-SCORE-001"
Retained correction STAT-MV-FA-SCORE-HARD-001
Case STAT-MV-FA-SCORE-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and analytic row-identity join
- Citation
- R stats::prcomp, scale and base matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_corrections.R · sha256 d22bd7a20d0e25a3
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
model= {"factor_analysis": {"columns": ["x", "y", "z"], "means": [100000005.008333, 100000004.025, 100000005.691667], "scales": [3.4147962360392, 2.24504504951825, 2.59000117126141], "weights": [[0.2], [0.3], [0.5]], "row_ids": ["STAT-MV-FA-SCORE-HARD-001:0", "STAT-MV-FA-SCORE-HARD-001:1", "STAT-MV-FA-SCORE-HARD-001:2", "STAT-MV-FA-SCORE-HARD-001:3", "STAT-MV-FA-SCORE-HARD-001:4", "STAT-MV-FA-SCORE-HARD-001:5", "STAT-MV-FA-SCORE-HARD-001:6", "STAT-MV-FA-SCORE-HARD-001:7", "STAT-MV-FA-SCORE-HARD-001:8", "STAT-MV-FA-SCORE-HARD-001:9", "STAT-MV-FA-SCORE-HARD-001:10", "STAT-MV-FA-SCORE-HARD-001:11"]}}names= ["factor1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/factor1 | tolerance | -1.0056801436500564 | -1.0056801436500564 | 2.40E-17 | 16 | passed |
/1/factor1 | tolerance | -1.0385186849392949 | -1.038518684939295 | 1.07E-17 | 16 | passed |
/2/factor1 | tolerance | -1.0634244049368691 | -1.063424404936869 | 2.79E-17 | 16 | passed |
/3/factor1 | tolerance | -0.93448773542295449 | -0.9344877354229545 | 7.94E-19 | 18 | passed |
/4/factor1 | tolerance | 0.30964360954882408 | 0.3096436095488241 | 3.61E-18 | 16 | passed |
/5/factor1 | tolerance | 0.24851590013407149 | 0.2485159001340715 | 2.06E-18 | 17 | passed |
/6/factor1 | tolerance | 0.25164319258943513 | 0.25164319258943507 | 5.82E-17 | 15 | passed |
/7/factor1 | tolerance | 0.25775621186434028 | 0.2577562118643403 | 1.13E-18 | 17 | passed |
/8/factor1 | tolerance | 0.72204413151028946 | 0.7220441315102895 | 4.72E-18 | 17 | passed |
/9/factor1 | tolerance | 0.76980907803680798 | 0.7698090780368081 | 1.12E-16 | 15 | passed |
/10/factor1 | tolerance | 0.69523322455843661 | 0.6952332245584366 | 3.27E-18 | 17 | passed |
/11/factor1 | tolerance | 0.78746505818318835 | 0.7874650581831883 | 1.09E-18 | 17 | passed |
Convention
- Scoring subtracts 1e8-scale means before applying explicit factor weights.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
104 pc <- stats::prcomp(hard[c("x","y")],center=TRUE,scale.=TRUE)
105 pc_center <- as.vector(as_serialized(pc$center)); pc_scale <- as.vector(as_serialized(pc$scale))
106 pc_loading <- as.vector(as_serialized(pc$rotation[,1]))
107 scores <- as.vector(scale(as.matrix(hard[c("x","y")]),center=pc_center,scale=pc_scale)%*%pc_loading)
108 model <- list(principal_components=list(columns=list("x","y"),means=nums(pc_center),
109 scales=nums(pc_scale),loadings=rows(matrix(pc_loading,ncol=1)),row_ids=ids(id,nrow(hard))))
110 emit(id,"operation:tabelz.principal_component_scores","principalComponentsMenuItem",
111 "MV_HARD",list(names=list("pc1"),model=model),scores,"pc1",
112 c("Scoring subtracts 1e8-scale means before applying retained PCA loading."),kind="hard_numeric")
113 id <- "STAT-MV-FA-SCORE-HARD-001"Whole script generators/r/multivariate_scoring_corrections.R
Retained scoring STAT-MV-FA-SCORE-HARD-VALID-001
Case STAT-MV-FA-SCORE-HARD-VALID-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and centered matrix arithmetic
- Citation
- R stats::prcomp and scale documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_final.R · sha256 90940efd66e73ecd
- Dataset
- reference_data/datasets/MV_SCORE_HARD.json
Settings compared
model= {"factor_analysis": {"columns": ["x", "y", "z"], "means": [100005.008333333, 100004.025, 100005.691666667], "scales": [3.41479623599023, 2.24504504915284, 2.59000116999967], "weights": [[0.2], [0.3], [0.5]], "row_ids": ["STAT-MV-FA-SCORE-HARD-VALID-001:0", "STAT-MV-FA-SCORE-HARD-VALID-001:1", "STAT-MV-FA-SCORE-HARD-VALID-001:2", "STAT-MV-FA-SCORE-HARD-VALID-001:3", "STAT-MV-FA-SCORE-HARD-VALID-001:4", "STAT-MV-FA-SCORE-HARD-VALID-001:5", "STAT-MV-FA-SCORE-HARD-VALID-001:6", "STAT-MV-FA-SCORE-HARD-VALID-001:7", "STAT-MV-FA-SCORE-HARD-VALID-001:8", "STAT-MV-FA-SCORE-HARD-VALID-001:9", "STAT-MV-FA-SCORE-HARD-VALID-001:10", "STAT-MV-FA-SCORE-HARD-VALID-001:11"]}}names= ["factor1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/factor1 | tolerance | -1.005680096261294 | -1.0056800963063046 | 4.50E-11 | 10 | passed |
Convention
- Measurements have a 1e5 offset with O(1) spread; explicit retained weights test scoring, not fitting.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
62 pc <- stats::prcomp(hard[c("x","y")],center=TRUE,scale.=TRUE)
63 model <- list(principal_components=list(columns=list("x","y"),means=nums(pc$center),
64 scales=nums(pc$scale),loadings=rows(pc$rotation[,1,drop=FALSE]),row_ids=ids(id,nrow(hard))))
65 out <- list("/0/pc1"=tol(pc$x[1,1],"Centered PCA score at 1e5 offset"))
66 emit(id,"operation:tabelz.principal_component_scores","principalComponentsMenuItem",
67 "MV_SCORE_HARD",list(names=list("pc1"),model=model),out,"hard_numeric",
68 c("Measurements have a 1e5 offset with O(1) spread; R centers before projecting."))
69 id <- "STAT-MV-FA-SCORE-HARD-VALID-001"
Invalid multivariate request STAT-MV-FA-SCORE-INVALID-001
Case STAT-MV-FA-SCORE-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {}names= ["score"]unknown_option= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Retained scoring rejects unknown request keys before creating an operation.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-FA-SCORE-INVALID-002
Case STAT-MV-FA-SCORE-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {}names= ["score"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A retained operation needs a model envelope matching its operation type.
- The rejection follows from the declared request schema without statistical computation.
Retained scoring STAT-MV-FA-SCORE-MIN-VALID-001
Case STAT-MV-FA-SCORE-MIN-VALID-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and centered matrix arithmetic
- Citation
- R stats::prcomp and scale documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_final.R · sha256 90940efd66e73ecd
- Dataset
- reference_data/datasets/MV_SCORE_FOUR.json
Settings compared
model= {"factor_analysis": {"columns": ["x", "y", "z"], "means": [6, 3.8, 6.6], "scales": [3.86522961801754, 2.2553639765383, 2.95860327406926], "weights": [[0.2], [0.3], [0.5]], "row_ids": ["STAT-MV-FA-SCORE-MIN-VALID-001:0", "STAT-MV-FA-SCORE-MIN-VALID-001:1", "STAT-MV-FA-SCORE-MIN-VALID-001:2", "STAT-MV-FA-SCORE-MIN-VALID-001:3"]}}names= ["factor1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/factor1 | tolerance | -1.0896413684402626 | -1.0896413684402624 | 2.19E-16 | 15 | passed |
/3/factor1 | tolerance | 0.50151527416357355 | 0.5015152741635731 | 4.40E-16 | 15 | passed |
Convention
- Four retained rows are the smallest population strictly exceeding three scoring columns.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
39 weights <- matrix(c(0.2,0.3,0.5),ncol=1) 40 id <- "STAT-MV-FA-SCORE-MIN-VALID-001"
Retained scoring STAT-MV-FA-SCORE-OMIT-VALID-001
Case STAT-MV-FA-SCORE-OMIT-VALID-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and centered matrix arithmetic
- Citation
- R stats::prcomp and scale documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_final.R · sha256 90940efd66e73ecd
- Dataset
- reference_data/datasets/MV_SCORE_FIVE.json
Settings compared
model= {"factor_analysis": {"columns": ["x", "y", "z"], "means": [6, 3.8, 6.6], "scales": [3.86522961801754, 2.2553639765383, 2.95860327406926], "weights": [[0.2], [0.3], [0.5]], "row_ids": ["STAT-MV-FA-SCORE-OMIT-VALID-001:0", "STAT-MV-FA-SCORE-OMIT-VALID-001:1", "STAT-MV-FA-SCORE-OMIT-VALID-001:2", "STAT-MV-FA-SCORE-OMIT-VALID-001:3"]}}names= ["factor1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/factor1 | tolerance | -1.0896413684402626 | -1.0896413684402624 | 2.19E-16 | 15 | passed |
/3/factor1 | tolerance | 0.50151527416357355 | 0.5015152741635731 | 4.40E-16 | 15 | passed |
/4/factor1 | absent | None | passed |
Convention
- Four retained rows satisfy the model schema; fifth source row must remain missing.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
41 x <- as.matrix(four[c("x","y","z")]); mu <- colMeans(x); sd <- apply(x,2,stats::sd)
42 scores <- as.vector(scale(x,center=mu,scale=sd)%*%weights)
43 model <- list(factor_analysis=list(columns=list("x","y","z"),means=nums(mu),
44 scales=nums(sd),weights=rows(weights),row_ids=ids(id,4L)))
45 out <- list("/0/factor1"=tol(scores[1],"Four-row retained FA score"),
46 "/3/factor1"=tol(scores[4],"Fourth retained FA score"))
47 emit(id,"operation:tabelz.factor_scores","factorAnalysisMenuItem","MV_SCORE_FOUR",
48 list(names=list("factor1"),model=model),out,"boundary",
49 c("Four retained rows are the smallest population strictly exceeding three scoring columns."))
50 id <- "STAT-MV-FA-SCORE-OMIT-VALID-001"
Special boundary STAT-MV-FA-SIX-001
Case STAT-MV-FA-SIX-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_boundaries.R · sha256 420706593513ebf0
- Dataset
- reference_data/datasets/MV_FA_SIX.json
Settings compared
columns= ["a", "b", "c", "d", "e"]n_factors= 1rotation= "none"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlation_eigenvalues/0 | tolerance | 2.9187577453933664 | 2.91875774539337 | 3.56E-15 | 14 | passed |
Convention
- Five-variable factor analysis on six complete rows is the n=p+1 boundary; ML uniqueness is not compared on this small sample.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
58 f <- read_dataset("MV_FACTOR")[seq_len(6L),]
59 export_dataset(f,"MV_FA_SIX","Six complete observations on five factor variables",
60 "R sample-correlation eigenvalue at n=p+1",
61 "Constructed validation data; no third-party license.",
62 setNames(rep("Float64",ncol(f)),names(f)))
63 f <- read_dataset("MV_FA_SIX")
64 eig <- eigen(stats::cor(f),symmetric=TRUE)$values[1]
65 emit("STAT-MV-FA-SIX-001","tabelz.executor.factor_analysis","factorAnalysisMenuItem",
66 "MV_FA_SIX",list(columns=as.list(names(f)),n_factors=1L,rotation="none"),
67 list("/correlation_eigenvalues/0"=tol(eig,"leading correlation eigenvalue at n=p+1")),
68 c("Five-variable factor analysis on six complete rows is the n=p+1 boundary; ML uniqueness is not compared on this small sample."))
Stable ML factor fit varimax
Case STAT-MV-FA-VARIMAX-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::factanal
- Citation
- R stats::factanal maximum-likelihood factor analysis documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_factor_stable.R · sha256 ffea0161e03a21ed
- Dataset
- reference_data/datasets/MV_FACTOR.json
Settings compared
columns= ["a", "b", "c", "d", "e"]n_factors= 2rotation= "varimax"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/uniquenesses/0 | tolerance | 0.01298087096473975 | 0.012980870478834693 | 4.86E-10 | 7 | passed |
/uniquenesses/2 | tolerance | 0.033963047069511684 | 0.03396304669479085 | 3.75E-10 | 7 | passed |
/correlation_eigenvalues/0 | tolerance | 3.0076852930674587 | 3.007685293067464 | 5.32E-15 | 14 | passed |
Convention
- R maximum likelihood with 20 starts and lower uniqueness 0.005; fitted uniquenesses are interior.
- Orthogonal rotation cannot change uniquenesses.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
46 emit("STAT-MV-FA-VARIMAX-001",2L,"varimax",fit2)
Seeded ML factor fit varimax
Case STAT-MV-FA-VARIMAX-002 · status: passed
Reference
- Evidence type
- R
- Source
- Seeded R stats::factanal
- Citation
- R stats::factanal maximum-likelihood factor analysis documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_factor_seeded.R · sha256 d0fd8847879330e0
- Dataset
- reference_data/datasets/MV_FACTOR.json
Settings compared
columns= ["a", "b", "c", "d", "e"]n_factors= 2rotation= "varimax"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/uniquenesses/0 | tolerance | 0.01298087096473975 | 0.012980870478834693 | 4.86E-10 | 7 | passed |
/uniquenesses/2 | tolerance | 0.033963047069511684 | 0.03396304669479085 | 3.75E-10 | 7 | passed |
/correlation_eigenvalues/0 | tolerance | 3.0076852930674587 | 3.007685293067464 | 5.32E-15 | 14 | passed |
Convention
- set.seed(1959) before each fit; 20 starts; L-BFGS-B factr=1 (reltol does not apply to L-BFGS-B).
- R uniqueness lower bound 0.005 is not active for these interior fits.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
36 emit("STAT-MV-FA-VARIMAX-002",2L,"varimax",fit2)
Multivariate STAT-MV-HCLUST-001
Case STAT-MV-HCLUST-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_core.R · sha256 90e434c114270562
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]cut_k= 3linkage= "ward"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights | sequence | ['0.065820535503267441', '0.083096677567938343', '0.10141230 | [0.06582053550326754, 0.08309667756793819, 0.101412304199116 | passed | ||
/cluster_labels | partition | [1, 1, 3, 3, 1, 1, 2, 2, 2, 2, 3, 3] | [3, 3, 1, 1, 3, 3, 2, 2, 2, 2, 1, 1] | passed |
Convention
- Rows standardized with sample SD; Ward.D2 uses squared Euclidean update.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
61 id_order <- function(id, n) order(paste0(id, ":", seq_len(n) - 1L), method = "radix")
62 emit("STAT-MV-HCLUST-001", "tabelz.executor.hierarchical_clustering",
63 "hierarchicalClusteringMenuItem",
64 list(columns=list("x","y","z"), linkage="ward", cut_k=3L),
65 list("/merge_heights"=seqtol(hc$height, "ward.D2 linkage heights"),
66 "/cluster_labels"=list(comparison="partition", values=as.list(as.integer(stats::cutree(hc,3L))[id_order("STAT-MV-HCLUST-001", nrow(d))]),
67 rationale="R Ward.D2 three-way partition")),
68 c("Rows standardized with sample SD; Ward.D2 uses squared Euclidean update."))
Ordered multivariate STAT-MV-HCLUST-002
Case STAT-MV-HCLUST-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::hclust/cutree/kmeans documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_ordered.R · sha256 583c4e9cd0e92e8b
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]cut_k= 3linkage= "ward"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/cluster_labels | partition | [1, 1, 2, 2, 1, 1, 3, 3, 3, 3, 2, 2] | [3, 3, 1, 1, 3, 3, 2, 2, 2, 2, 1, 1] | passed |
Convention
- Sample-SD standardization and Euclidean Ward.D2 linkage.
- Engine reports rows sorted lexicographically by stable row ID: ordinal strings 0,1,10,11,2,...
- R re-reads the exported CSV and applies that documented row-ID order before fitting.
Reference code
The lines of the reference script that produce this case's expected values.
29 scaled <- scale(d[order_ids,c("x","y","z")])
30 hc <- stats::hclust(stats::dist(scaled), method="ward.D2")
31 emit("STAT-MV-HCLUST-002", "tabelz.executor.hierarchical_clustering",
32 "hierarchicalClusteringMenuItem",
33 list(columns=list("x","y","z"), linkage="ward", cut_k=3L),
34 list("/cluster_labels"=part(stats::cutree(hc,3L), "R Ward.D2 partition in retained row-ID order")),
35 c("Sample-SD standardization and Euclidean Ward.D2 linkage."))
Multivariate option STAT-MV-HCLUST-AVERAGE-001
Case STAT-MV-HCLUST-AVERAGE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]cut_k= 3linkage= "average"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights/0 | tolerance | 0.065820535503267441 | 0.06582053550326754 | 9.72E-17 | 14 | passed |
/cluster_labels | partition | [1, 1, 2, 2, 1, 1, 3, 3, 3, 3, 2, 2] | [2, 2, 1, 1, 2, 2, 3, 3, 3, 3, 1, 1] | passed |
Convention
- Rows are sample-SD standardized then ordered by stable row ID before clustering.
- R re-reads the exported CSV.
Reference code
Multivariate option STAT-MV-HCLUST-COMPLETE-001
Case STAT-MV-HCLUST-COMPLETE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]cut_k= 3linkage= "complete"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights/0 | tolerance | 0.065820535503267441 | 0.06582053550326754 | 9.72E-17 | 14 | passed |
/cluster_labels | partition | [1, 1, 2, 2, 1, 1, 3, 3, 3, 3, 2, 2] | [1, 1, 3, 3, 1, 1, 2, 2, 2, 2, 3, 3] | passed |
Convention
- Rows are sample-SD standardized then ordered by stable row ID before clustering.
- R re-reads the exported CSV.
Reference code
Hard-numeric STAT-MV-HCLUST-HARD-001
Case STAT-MV-HCLUST-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova and chisq.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_hard.R · sha256 06eca51b7d1d3ab6
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
columns= ["x", "y", "z"]cut_k= 3linkage= "ward"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights/0 | tolerance | 0.065820536880293906 | 0.0658205368802939 | 1.46E-19 | 17 | passed |
Convention
- Rows are in stable row-ID order and standardized with sample SD.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
62 ord <- order(as.character(seq_len(nrow(d))-1L))
63 scaled <- scale(d[ord,c("x","y","z")])
64 hc <- stats::hclust(stats::dist(scaled),method="ward.D2")
65 emit("STAT-MV-HCLUST-HARD-001","tabelz.executor.hierarchical_clustering",
66 "hierarchicalClusteringMenuItem","MV_HARD",
67 list(columns=xyz,linkage="ward",cut_k=3L),
68 list("/merge_heights/0"=tol(hc$height[1],"standardized first Ward.D2 merge")),
69 c("Rows are in stable row-ID order and standardized with sample SD."))
Invalid multivariate request STAT-MV-HCLUST-INVALID-001
Case STAT-MV-HCLUST-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Clustering needs at least two columns.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-HCLUST-INVALID-002
Case STAT-MV-HCLUST-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]linkage= "ward"mode= "variables"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Ward linkage is invalid for non-Euclidean variable correlation distance.
- The rejection follows from the declared request schema without statistical computation.
Retained scoring STAT-MV-HCLUST-LABEL-001
Case STAT-MV-HCLUST-LABEL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic
- Citation
- R stats::prcomp, kmeans, hclust and matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring.R · sha256 6aa292c3e1b1894b
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {"hierarchical_clustering": {"mode": "rows", "linkage": "ward", "cut_k": 3, "row_ids": ["STAT-MV-HCLUST-LABEL-001:0", "STAT-MV-HCLUST-LABEL-001:1", "STAT-MV-HCLUST-LABEL-001:10", "STAT-MV-HCLUST-LABEL-001:11", "STAT-MV-HCLUST-LABEL-001:2", "STAT-MV-HCLUST-LABEL-001:3", "STAT-MV-HCLUST-LABEL-001:4", "STAT-MV-HCLUST-LABEL-001:5", "STAT-MV-HCLUST-LABEL-001:6", "STAT-MV-HCLUST-LABEL-001:7", "STAT-MV-HCLUST-LABEL-001:8", "STAT-MV-HCLUST-LABEL-001:9"], "labels": [1, 1, 2, 2, 1, 1, 3, 3, 3, 3, 2, 2]}}name= "hcluster"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/hcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/1/hcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/2/hcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/3/hcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/4/hcluster | exact | 3 | 3 | 0.00E+2 | passed | |
/5/hcluster | exact | 3 | 3 | 0.00E+2 | passed | |
/6/hcluster | exact | 3 | 3 | 0.00E+2 | passed | |
/7/hcluster | exact | 3 | 3 | 0.00E+2 | passed | |
/8/hcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/9/hcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/10/hcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/11/hcluster | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- R cluster labels are retained in engine row-ID order, then joined into source order.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
61 sorted <- order(as.character(seq_len(nrow(d))-1L))
62 scaled <- scale(d[sorted,c("x","y","z")])
63 id <- "STAT-MV-HCLUST-LABEL-001"
Invalid multivariate request STAT-MV-HCLUST-LABEL-INVALID-001
Case STAT-MV-HCLUST-LABEL-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {}name= "cluster"unknown_option= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Retained scoring rejects unknown request keys before creating an operation.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-HCLUST-LABEL-INVALID-002
Case STAT-MV-HCLUST-LABEL-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {}name= "cluster"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A retained operation needs a model envelope matching its operation type.
- The rejection follows from the declared request schema without statistical computation.
Retained boundary STAT-MV-HCLUST-LABEL-MIN-001
Case STAT-MV-HCLUST-LABEL-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and retained identity join
- Citation
- R stats::prcomp and base matrix arithmetic documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_boundaries.R · sha256 4cdf60725804542b
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
model= {"hierarchical_clustering": {"mode": "rows", "linkage": "ward", "cut_k": 2, "row_ids": ["STAT-MV-HCLUST-LABEL-MIN-001:0", "STAT-MV-HCLUST-LABEL-MIN-001:1"], "labels": [1, 2]}}name= "hcluster"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/hcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/1/hcluster | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Two-row retained partition; labels are joined by stable row ID.
- R re-reads the exported CSV.
Reference code
Retained correction STAT-MV-HCLUST-LABEL-OMIT-CORRECTED-001
Case STAT-MV-HCLUST-LABEL-OMIT-CORRECTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and analytic row-identity join
- Citation
- R stats::prcomp, scale and base matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_corrections.R · sha256 d22bd7a20d0e25a3
- Dataset
- reference_data/datasets/MV_SCORE_FOUR.json
Settings compared
model= {"hierarchical_clustering": {"mode": "rows", "linkage": "ward", "cut_k": 2, "row_ids": ["STAT-MV-HCLUST-LABEL-OMIT-CORRECTED-001:0", "STAT-MV-HCLUST-LABEL-OMIT-CORRECTED-001:1", "STAT-MV-HCLUST-LABEL-OMIT-CORRECTED-001:2"], "labels": [1, 2, 2]}}name= "hcluster"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/hcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/1/hcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/2/hcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/3/hcluster | absent | None | passed |
Convention
- Three retained labels, one nonmember; the test concerns replay identity, not refitting linkage.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
69 x <- as.matrix(ret[c("x","y","z")]); mu <- colMeans(x); sd <- apply(x,2,stats::sd)
70 scores <- as.vector(scale(as.matrix(d[c("x","y","z")]),center=mu,scale=sd)%*%weights)
71 model <- list(factor_analysis=list(columns=list("x","y","z"),means=nums(mu),
72 scales=nums(sd),weights=rows(weights),row_ids=ids(id,3L)))
73 emit(id,"operation:tabelz.factor_scores","factorAnalysisMenuItem",
74 "MV_SCORE_FOUR",list(names=list("factor1"),model=model),scores,"factor1",
75 c("Three retained FA score rows plus one nonmember."),omitted=4L)
76 id <- "STAT-MV-HCLUST-LABEL-OMIT-CORRECTED-001"Whole script generators/r/multivariate_scoring_corrections.R
Minimum-sample STAT-MV-HCLUST-MIN-001
Case STAT-MV-HCLUST-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_minimum.R · sha256 bcd4094568b73b37
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
columns= ["x", "y"]cut_k= 2linkage= "ward"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights/0 | tolerance | 1.9999999999999998 | 1.9999999999999998 | 2.20E-17 | 16 | passed |
Convention
- Two distinct rows give one unambiguous merge.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
34 hc <- stats::hclust(stats::dist(scale(d[c("x","y")])),method="ward.D2")
35 emit("STAT-MV-HCLUST-MIN-001","tabelz.executor.hierarchical_clustering",
36 "hierarchicalClusteringMenuItem","MV_MIN_TWO",
37 list(columns=list("x","y"),linkage="ward",cut_k=2L),
38 list("/merge_heights/0"=tol(hc$height[1],"only Ward.D2 merge height")),
39 c("Two distinct rows give one unambiguous merge."))
Missing and excluded multivariate population STAT-MV-HCLUST-POP-001
Case STAT-MV-HCLUST-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic identities
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_population.R · sha256 8a6d148e9316e21f
- Dataset
- reference_data/datasets/MV_POP.json
Settings compared
columns= ["x", "y", "z"]cut_k= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/cluster_labels | partition | [1, 1, 2, 2, 1, 3, 3, 3, 3, 2] | [2, 2, 1, 1, 2, 3, 3, 3, 3, 1] | passed |
Convention
- R uses sample-SD standardization and Ward.D2 on the same sorted complete rows.
- R re-reads exported CSV, drops ordinal 9 by stable-row-ID exclusion, then uses complete cases.
Reference code
The lines of the reference script that produce this case's expected values.
44 ord <- which(seq_len(nrow(d)) != 10L & stats::complete.cases(d[c("x","y","z")]))
45 ord <- ord[order(as.character(ord-1L))]
46 scaled <- scale(d[ord,c("x","y","z")])
47 hc <- stats::hclust(stats::dist(scaled),method="ward.D2")
48 emit("STAT-MV-HCLUST-POP-001","tabelz.executor.hierarchical_clustering",
49 "hierarchicalClusteringMenuItem",list(columns=list("x","y","z"),cut_k=3L),
50 list("/excluded_count"=exact(1L,"One stable row ID excluded"),
51 "/missing_count"=exact(1L,"One selected-column missing row"),
52 "/cluster_labels"=part(stats::cutree(hc,3L),"R Ward.D2 partition in sorted row-ID order")),
53 c("R uses sample-SD standardization and Ward.D2 on the same sorted complete rows."))
Configuration axis STAT-MV-HCLUST-RAW-001
Case STAT-MV-HCLUST-RAW-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and matrix arithmetic
- Citation
- R stats::hclust and base rowSums documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_axes.R · sha256 8e53089af57e269e
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]cut_k= 3linkage= "ward"mode= "rows"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights/0 | tolerance | 0.17320508075688737 | 0.17320508075688737 | 4.03E-19 | 17 | passed |
Convention
- Row-mode standardize=false uses Euclidean distances in original units.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
21 ord <- order(as.character(seq_len(nrow(d))-1L))
22 hc <- stats::hclust(stats::dist(d[ord,c("x","y","z")]),method="ward.D2")
23 emit("STAT-MV-HCLUST-RAW-001","tabelz.executor.hierarchical_clustering",
24 "hierarchicalClusteringMenuItem",
25 list(columns=list("x","y","z"),mode="rows",linkage="ward",standardize=FALSE,cut_k=3L),
26 list("/merge_heights/0"=tol(hc$height[1],"R Ward.D2 first merge on original measurement scale")),
27 c("Row-mode standardize=false uses Euclidean distances in original units."))
Special boundary STAT-MV-HCLUST-TIES-001
Case STAT-MV-HCLUST-TIES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_boundaries.R · sha256 420706593513ebf0
- Dataset
- reference_data/datasets/MV_TIES.json
Settings compared
columns= ["x", "y"]cut_k= 2linkage= "ward"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights/0 | tolerance | 0 | 0.0 | 0.00E+2 | 15 | passed |
Convention
- Exact duplicate measurements force first Ward.D2 merge height zero.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
34 ord <- order(as.character(seq_len(nrow(d))-1L))
35 hc <- stats::hclust(stats::dist(scale(d[ord,c("x","y")])),method="ward.D2")
36 emit("STAT-MV-HCLUST-TIES-001","tabelz.executor.hierarchical_clustering",
37 "hierarchicalClusteringMenuItem","MV_TIES",
38 list(columns=list("x","y"),linkage="ward",cut_k=2L),
39 list("/merge_heights/0"=tol(hc$height[1],"zero-height duplicate-row merge")),
40 c("Exact duplicate measurements force first Ward.D2 merge height zero."))
Multivariate option STAT-MV-HCLUST-VARIABLES-001
Case STAT-MV-HCLUST-VARIABLES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]cut_k= 2linkage= "average"mode= "variables"standardize= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights/0 | tolerance | 0.021346560296017558 | 0.021346560296017503 | 5.53E-17 | 14 | passed |
/cluster_labels | partition | [1, 2, 1] | [2, 1, 2] | passed |
Convention
- Variable mode distance is 1-r on complete cases; scaling is immaterial to correlation.
- Variable mode requires standardize=true (strict request contract); until 2026-09-25 this case sent false.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
41 var_dist <- as.dist(1-stats::cor(d[c("x","y","z")]))
42 var_hc <- stats::hclust(var_dist,method="average")
43 emit("STAT-MV-HCLUST-VARIABLES-001","tabelz.executor.hierarchical_clustering",
44 "hierarchicalClusteringMenuItem",
45 list(columns=cols,mode="variables",linkage="average",standardize=TRUE,cut_k=2L),
46 list("/merge_heights/0"=tol(var_hc$height[1],"R average linkage on 1-Pearson correlation"),
47 "/cluster_labels"=part(stats::cutree(var_hc,2L),"R variable partition")),
48 c("Variable mode distance is 1-r on complete cases; scaling is immaterial to correlation.",
49 "Variable mode requires standardize=true (strict request contract); until 2026-09-25 this case sent false."))
Variable-mode average linkage
Case STAT-MV-HCLUST-VARIABLES-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::hclust/cutree
- Citation
- R stats::hclust and cutree documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_variables.R · sha256 ab1b4850d11e43e0
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]cut_k= 2linkage= "average"mode= "variables"standardize= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/merge_heights/0 | tolerance | 0.021346560296017558 | 0.021346560296017503 | 5.53E-17 | 14 | passed |
/cluster_labels | partition | [1, 2, 1] | [2, 1, 2] | passed |
Convention
- Variable mode uses 1-Pearson correlation; standardize=true is required by the strict request contract.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
1 source("common.R",local=TRUE)
2 d <- read_dataset("MV_CORE")
3 distance <- as.dist(1-stats::cor(d[c("x","y","z")]))
4 fit <- stats::hclust(distance,method="average")
5 id <- "STAT-MV-HCLUST-VARIABLES-002"
Kendall tau-b tie-corrected normal
Case STAT-MV-KENDALL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::cor.test
- Citation
- R Core Team, stats package help: cor.test (method = 'kendall'); Kendall (1970), Rank Correlation Methods, for S and the tie-corrected variance.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_correlation_extensions.R · sha256 0d15a50f16440286
- Dataset
- reference_data/datasets/MV_CORREXT.json
Settings compared
columns= ["x", "y", "z"]deletion= "pairwise"inference= "asymptotic"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pairs/0/n | exact | 16 | 16 | 0.00E+2 | passed | |
/pairs/0/tau_b | tolerance | 0.83333333333333326 | 0.8333333333333333 | 6.82E-19 | 18 | passed |
/pairs/0/s | exact | 100 | 100 | 0.00E+2 | passed | |
/pairs/0/z | tolerance | 4.5022516889074815 | 4.5022516889074815 | 8.29E-18 | 17 | passed |
/pairs/0/p_value | tail_probability | 6.7237289325878942e-06 | 6.723728932587893e-06 | 7.99E-22 | 15 | passed |
/pairs/1/n | exact | 16 | 16 | 0.00E+2 | passed | |
/pairs/1/tau_b | tolerance | 0.7956783115902859 | 0.7956783115902859 | 2.71E-18 | 17 | passed |
/pairs/1/s | exact | 91 | 91 | 0.00E+2 | passed | |
/pairs/1/z | tolerance | 4.1492428485467343 | 4.149242848546734 | 8.00E-18 | 17 | passed |
/pairs/1/p_value | tail_probability | 3.3357678071950611e-05 | 3.335767807195062e-05 | 7.03E-21 | 15 | passed |
/pairs/2/n | exact | 16 | 16 | 0.00E+2 | passed | |
/pairs/2/tau_b | tolerance | 0.88311548868811962 | 0.8831154886881195 | 1.10E-16 | 15 | passed |
/pairs/2/s | exact | 101 | 101 | 0.00E+2 | passed | |
/pairs/2/z | tolerance | 4.6052036011342876 | 4.605203601134288 | 1.65E-17 | 17 | passed |
/pairs/2/p_value | tail_probability | 4.1206250634638877e-06 | 4.120625063463884e-06 | 3.38E-21 | 15 | passed |
/rows_analysed | exact | 16 | 16 | 0.00E+2 | passed |
Convention
- cor.test(method = 'kendall', exact = FALSE, continuity = FALSE): tau-b with ties and z = S / sqrt(var S) with the tie-corrected variance; S is concordant minus discordant pairs enumerated directly.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:97-101: 'accounts for ties in both variables. Select pairwise or listwise deletion. Exact inference requires no ties; the tie-corrected normal approximation'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
102 outputs <- c(kendall_pair(d$x, d$y, "/pairs/0"), kendall_pair(d$x, d$z, "/pairs/1"),
103 kendall_pair(d$y, d$z, "/pairs/2"))
104 outputs[["/rows_analysed"]] <- exact(nrow(d), "all rows are analysed; deletion is per pair")
105 emit("STAT-MV-KENDALL-001", kendall_entry, kendall_menu, "Kendall tau-b tie-corrected normal",
106 "nominal", list(columns = list("x", "y", "z"), deletion = "pairwise", inference = "asymptotic"),
107 outputs, kendall_notes, kendall_cite, "R 4.6.1 stats::cor.test")Whole script generators/r/multivariate_correlation_extensions.R
Kendall tau-b pairwise deletion
Case STAT-MV-KENDALL-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::cor.test
- Citation
- R Core Team, stats package help: cor.test (method = 'kendall'); Kendall (1970), Rank Correlation Methods, for S and the tie-corrected variance.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_correlation_extensions.R · sha256 0d15a50f16440286
- Dataset
- reference_data/datasets/MV_CORREXT.json
Settings compared
columns= ["x", "y", "w"]deletion= "pairwise"inference= "asymptotic"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pairs/0/n | exact | 16 | 16 | 0.00E+2 | passed | |
/pairs/0/tau_b | tolerance | 0.83333333333333326 | 0.8333333333333333 | 6.82E-19 | 18 | passed |
/pairs/0/s | exact | 100 | 100 | 0.00E+2 | passed | |
/pairs/0/z | tolerance | 4.5022516889074815 | 4.5022516889074815 | 8.29E-18 | 17 | passed |
/pairs/0/p_value | tail_probability | 6.7237289325878942e-06 | 6.723728932587893e-06 | 7.99E-22 | 15 | passed |
/pairs/1/n | exact | 15 | 15 | 0.00E+2 | passed | |
/pairs/1/tau_b | tolerance | 0.69523809523809532 | 0.6952380952380953 | 1.63E-18 | 17 | passed |
/pairs/1/s | exact | 73 | 73 | 0.00E+2 | passed | |
/pairs/1/z | tolerance | 3.6125631129293732 | 3.6125631129293727 | 4.89E-16 | 15 | passed |
/pairs/1/p_value | tail_probability | 0.00030318528169583282 | 0.00030318528169583265 | 1.66E-19 | 15 | passed |
/pairs/2/n | exact | 15 | 15 | 0.00E+2 | passed | |
/pairs/2/tau_b | tolerance | 0.82857142857142874 | 0.8285714285714286 | 1.15E-16 | 15 | passed |
/pairs/2/s | exact | 87 | 87 | 0.00E+2 | passed | |
/pairs/2/z | tolerance | 4.3053834359569239 | 4.305383435956924 | 4.57E-17 | 16 | passed |
/pairs/2/p_value | tail_probability | 1.6669674796231492e-05 | 1.666967479623147e-05 | 2.05E-20 | 14 | passed |
Convention
- cor.test(method = 'kendall', exact = FALSE, continuity = FALSE): tau-b with ties and z = S / sqrt(var S) with the tie-corrected variance; S is concordant minus discordant pairs enumerated directly.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:97-101: 'accounts for ties in both variables. Select pairwise or listwise deletion. Exact inference requires no ties; the tie-corrected normal approximation'
- Pairwise deletion: each pair drops only its own incomplete rows.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
110 outputs <- c(kendall_pair(d$x, d$y, "/pairs/0"), kendall_pair(d$x, d$w, "/pairs/1"),
111 kendall_pair(d$y, d$w, "/pairs/2"))
112 emit("STAT-MV-KENDALL-002", kendall_entry, kendall_menu, "Kendall tau-b pairwise deletion",
113 "missing_excluded", list(columns = list("x", "y", "w"), deletion = "pairwise", inference = "asymptotic"),
114 outputs, c(kendall_notes, "Pairwise deletion: each pair drops only its own incomplete rows."),
115 kendall_cite, "R 4.6.1 stats::cor.test")Whole script generators/r/multivariate_correlation_extensions.R
Kendall tau-b listwise deletion
Case STAT-MV-KENDALL-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::cor.test
- Citation
- R Core Team, stats package help: cor.test (method = 'kendall'); Kendall (1970), Rank Correlation Methods, for S and the tie-corrected variance.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_correlation_extensions.R · sha256 0d15a50f16440286
- Dataset
- reference_data/datasets/MV_CORREXT.json
Settings compared
columns= ["x", "y", "w"]deletion= "listwise"inference= "asymptotic"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pairs/0/n | exact | 15 | 15 | 0.00E+2 | passed | |
/pairs/0/tau_b | tolerance | 0.82857142857142874 | 0.8285714285714286 | 1.15E-16 | 15 | passed |
/pairs/0/s | exact | 87 | 87 | 0.00E+2 | passed | |
/pairs/0/z | tolerance | 4.3053834359569239 | 4.305383435956924 | 4.57E-17 | 16 | passed |
/pairs/0/p_value | tail_probability | 1.6669674796231492e-05 | 1.666967479623147e-05 | 2.05E-20 | 14 | passed |
/pairs/1/n | exact | 15 | 15 | 0.00E+2 | passed | |
/pairs/1/tau_b | tolerance | 0.69523809523809532 | 0.6952380952380953 | 1.63E-18 | 17 | passed |
/pairs/1/s | exact | 73 | 73 | 0.00E+2 | passed | |
/pairs/1/z | tolerance | 3.6125631129293732 | 3.6125631129293727 | 4.89E-16 | 15 | passed |
/pairs/1/p_value | tail_probability | 0.00030318528169583282 | 0.00030318528169583265 | 1.66E-19 | 15 | passed |
/pairs/2/n | exact | 15 | 15 | 0.00E+2 | passed | |
/pairs/2/tau_b | tolerance | 0.82857142857142874 | 0.8285714285714286 | 1.15E-16 | 15 | passed |
/pairs/2/s | exact | 87 | 87 | 0.00E+2 | passed | |
/pairs/2/z | tolerance | 4.3053834359569239 | 4.305383435956924 | 4.57E-17 | 16 | passed |
/pairs/2/p_value | tail_probability | 1.6669674796231492e-05 | 1.666967479623147e-05 | 2.05E-20 | 14 | passed |
Convention
- cor.test(method = 'kendall', exact = FALSE, continuity = FALSE): tau-b with ties and z = S / sqrt(var S) with the tie-corrected variance; S is concordant minus discordant pairs enumerated directly.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:97-101: 'accounts for ties in both variables. Select pairwise or listwise deletion. Exact inference requires no ties; the tie-corrected normal approximation'
- Listwise deletion: rows incomplete on any chosen column are dropped from every pair.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
118 complete <- is.finite(d$x) & is.finite(d$y) & is.finite(d$w)
119 outputs <- c(kendall_pair(d$x[complete], d$y[complete], "/pairs/0"),
120 kendall_pair(d$x[complete], d$w[complete], "/pairs/1"),
121 kendall_pair(d$y[complete], d$w[complete], "/pairs/2"))
122 emit("STAT-MV-KENDALL-003", kendall_entry, kendall_menu, "Kendall tau-b listwise deletion",
123 "axis_coverage", list(columns = list("x", "y", "w"), deletion = "listwise", inference = "asymptotic"),
124 outputs, c(kendall_notes, "Listwise deletion: rows incomplete on any chosen column are dropped from every pair."),
125 kendall_cite, "R 4.6.1 stats::cor.test")Whole script generators/r/multivariate_correlation_extensions.R
Kendall tau-b exact inference
Case STAT-MV-KENDALL-004 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::cor.test
- Citation
- R Core Team, stats package help: cor.test (method = 'kendall'); Kendall (1970), Rank Correlation Methods, for S and the tie-corrected variance.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_correlation_extensions.R · sha256 0d15a50f16440286
- Dataset
- reference_data/datasets/MV_CORREXT.json
Settings compared
columns= ["x", "y", "z"]deletion= "pairwise"inference= "exact"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/pairs/0/n | exact | 16 | 16 | 0.00E+2 | passed | |
/pairs/0/tau_b | tolerance | 0.83333333333333326 | 0.8333333333333333 | 6.82E-19 | 18 | passed |
/pairs/0/s | exact | 100 | 100 | 0.00E+2 | passed | |
/pairs/0/p_value | tail_probability | 2.4419372501860437e-07 | 2.4419372499316283e-07 | 2.54E-17 | 9 | passed |
/pairs/1/n | exact | 16 | 16 | 0.00E+2 | passed | |
/pairs/1/tau_b | tolerance | 0.7956783115902859 | 0.7956783115902859 | 2.71E-18 | 17 | passed |
/pairs/1/s | exact | 91 | 91 | 0.00E+2 | passed | |
/pairs/1/p_value | absent | None | passed |
Convention
- cor.test(method = 'kendall', exact = FALSE, continuity = FALSE): tau-b with ties and z = S / sqrt(var S) with the tie-corrected variance; S is concordant minus discordant pairs enumerated directly.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:97-101: 'accounts for ties in both variables. Select pairwise or listwise deletion. Exact inference requires no ties; the tie-corrected normal approximation'
- cor.test(exact = TRUE) enumerates the permutation distribution of S for n < 50 without ties; with ties the p-value is withheld.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
128 outputs <- c(kendall_pair(d$x, d$y, "/pairs/0", exact_p = TRUE),
129 kendall_pair(d$x, d$z, "/pairs/1", exact_p = TRUE))
130 emit("STAT-MV-KENDALL-004", kendall_entry, kendall_menu, "Kendall tau-b exact inference",
131 "axis_coverage", list(columns = list("x", "y", "z"), deletion = "pairwise", inference = "exact"),
132 outputs, c(kendall_notes, "cor.test(exact = TRUE) enumerates the permutation distribution of S for n < 50 without ties; with ties the p-value is withheld."),
133 kendall_cite, "R 4.6.1 stats::cor.test")Whole script generators/r/multivariate_correlation_extensions.R
Multivariate STAT-MV-KMEANS-001
Case STAT-MV-KMEANS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_core.R · sha256 90e434c114270562
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]k= 3restarts= 50seed= 11
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/inertia | tolerance | 0.11696294271542688 | 0.1169629427154269 | 1.86E-17 | 15 | passed |
/cluster_labels | partition | [2, 2, 1, 1, 2, 2, 3, 3, 3, 3, 1, 1] | [1, 1, 3, 3, 1, 1, 2, 2, 2, 2, 3, 3] | passed |
Convention
- R Hartigan-Wong and Tabelz Lloyd agree on this unique separated optimum.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
70 set.seed(11)
71 km <- stats::kmeans(scaled, centers=3L, nstart=50L, algorithm="Hartigan-Wong")
72 emit("STAT-MV-KMEANS-001", "tabelz.executor.clustering", "kmeansClusteringMenuItem",
73 list(columns=list("x","y","z"), k=3L, seed=11L, restarts=50L),
74 list("/inertia"=tol(km$tot.withinss, "unique three-cluster optimum"),
75 "/cluster_labels"=list(comparison="partition", values=as.list(as.integer(km$cluster)[id_order("STAT-MV-KMEANS-001", nrow(d))]),
76 rationale="Well-separated cluster partition independent of numeric labels")),
77 c("R Hartigan-Wong and Tabelz Lloyd agree on this unique separated optimum.") ,
78 kind="determinism", repeat_count=2L)
Ordered multivariate STAT-MV-KMEANS-002
Case STAT-MV-KMEANS-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::hclust/cutree/kmeans documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_ordered.R · sha256 583c4e9cd0e92e8b
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]k= 3restarts= 50seed= 11
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/inertia | tolerance | 0.11696294271542688 | 0.1169629427154269 | 1.86E-17 | 15 | passed |
/cluster_labels | partition | [2, 2, 3, 3, 2, 2, 1, 1, 1, 1, 3, 3] | [1, 1, 3, 3, 1, 1, 2, 2, 2, 2, 3, 3] | passed |
Convention
- Well-separated optimum is shared by R Hartigan-Wong and scikit-learn Lloyd.
- Engine reports rows sorted lexicographically by stable row ID: ordinal strings 0,1,10,11,2,...
- R re-reads the exported CSV and applies that documented row-ID order before fitting.
Reference code
The lines of the reference script that produce this case's expected values.
37 set.seed(11)
38 km <- stats::kmeans(scaled, centers=3L, nstart=50L, algorithm="Hartigan-Wong")
39 emit("STAT-MV-KMEANS-002", "tabelz.executor.clustering", "kmeansClusteringMenuItem",
40 list(columns=list("x","y","z"), k=3L, seed=11L, restarts=50L),
41 list("/inertia"=tol(km$tot.withinss, "R unique optimum total within-cluster SS"),
42 "/cluster_labels"=part(km$cluster, "R unique optimum partition in retained row-ID order")),
43 c("Well-separated optimum is shared by R Hartigan-Wong and scikit-learn Lloyd."),
44 kind="determinism", repeat_count=2L)
Hard-numeric STAT-MV-KMEANS-HARD-001
Case STAT-MV-KMEANS-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova and chisq.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_hard.R · sha256 06eca51b7d1d3ab6
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
columns= ["x", "y", "z"]k= 3restarts= 50seed= 11
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/inertia | tolerance | 0.11696294317003422 | 0.11696294317003421 | 1.13E-17 | 16 | passed |
Convention
- set.seed(11), nstart=50; unique separated optimum, independent of label names.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
70 set.seed(11)
71 km <- stats::kmeans(scaled,3L,nstart=50L,algorithm="Hartigan-Wong")
72 emit("STAT-MV-KMEANS-HARD-001","tabelz.executor.clustering","kmeansClusteringMenuItem",
73 "MV_HARD",list(columns=xyz,k=3L,seed=11L,restarts=50L),
74 list("/inertia"=tol(km$tot.withinss,"unique separated three-cluster within SS")),
75 c("set.seed(11), nstart=50; unique separated optimum, independent of label names."))
Invalid multivariate request STAT-MV-KMEANS-INVALID-001
Case STAT-MV-KMEANS-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x"]k= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- K-means needs at least two columns.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-KMEANS-INVALID-002
Case STAT-MV-KMEANS-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]k= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- k must be at least two.
- The rejection follows from the declared request schema without statistical computation.
Retained scoring STAT-MV-KMEANS-LABEL-001
Case STAT-MV-KMEANS-LABEL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic
- Citation
- R stats::prcomp, kmeans, hclust and matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring.R · sha256 6aa292c3e1b1894b
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {"kmeans": {"k": 3, "seed": 11, "restarts": 50, "standardize": true, "row_ids": ["STAT-MV-KMEANS-LABEL-001:0", "STAT-MV-KMEANS-LABEL-001:1", "STAT-MV-KMEANS-LABEL-001:10", "STAT-MV-KMEANS-LABEL-001:11", "STAT-MV-KMEANS-LABEL-001:2", "STAT-MV-KMEANS-LABEL-001:3", "STAT-MV-KMEANS-LABEL-001:4", "STAT-MV-KMEANS-LABEL-001:5", "STAT-MV-KMEANS-LABEL-001:6", "STAT-MV-KMEANS-LABEL-001:7", "STAT-MV-KMEANS-LABEL-001:8", "STAT-MV-KMEANS-LABEL-001:9"], "labels": [2, 2, 3, 3, 2, 2, 1, 1, 1, 1, 3, 3]}}name= "kcluster"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/kcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/1/kcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/2/kcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/3/kcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/4/kcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/5/kcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/6/kcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/7/kcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/8/kcluster | exact | 3 | 3 | 0.00E+2 | passed | |
/9/kcluster | exact | 3 | 3 | 0.00E+2 | passed | |
/10/kcluster | exact | 3 | 3 | 0.00E+2 | passed | |
/11/kcluster | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- R cluster labels are retained in engine row-ID order, then joined into source order.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
74 id <- "STAT-MV-KMEANS-LABEL-001"
Invalid multivariate request STAT-MV-KMEANS-LABEL-INVALID-001
Case STAT-MV-KMEANS-LABEL-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {}name= "cluster"unknown_option= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Retained scoring rejects unknown request keys before creating an operation.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-KMEANS-LABEL-INVALID-002
Case STAT-MV-KMEANS-LABEL-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {}name= "cluster"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A retained operation needs a model envelope matching its operation type.
- The rejection follows from the declared request schema without statistical computation.
Retained boundary STAT-MV-KMEANS-LABEL-MIN-001
Case STAT-MV-KMEANS-LABEL-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and retained identity join
- Citation
- R stats::prcomp and base matrix arithmetic documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_boundaries.R · sha256 4cdf60725804542b
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
model= {"kmeans": {"k": 2, "seed": 11, "restarts": 50, "standardize": true, "row_ids": ["STAT-MV-KMEANS-LABEL-MIN-001:0", "STAT-MV-KMEANS-LABEL-MIN-001:1"], "labels": [1, 2]}}name= "kcluster"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/kcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/1/kcluster | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Two-row retained partition; labels are joined by stable row ID.
- R re-reads the exported CSV.
Reference code
Retained correction STAT-MV-KMEANS-LABEL-OMIT-CORRECTED-001
Case STAT-MV-KMEANS-LABEL-OMIT-CORRECTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and analytic row-identity join
- Citation
- R stats::prcomp, scale and base matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_corrections.R · sha256 d22bd7a20d0e25a3
- Dataset
- reference_data/datasets/MV_SCORE_FOUR.json
Settings compared
model= {"kmeans": {"k": 2, "seed": 11, "restarts": 50, "standardize": true, "row_ids": ["STAT-MV-KMEANS-LABEL-OMIT-CORRECTED-001:0", "STAT-MV-KMEANS-LABEL-OMIT-CORRECTED-001:1", "STAT-MV-KMEANS-LABEL-OMIT-CORRECTED-001:2"], "labels": [1, 2, 2]}}name= "kcluster"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/kcluster | exact | 1 | 1 | 0.00E+2 | passed | |
/1/kcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/2/kcluster | exact | 2 | 2 | 0.00E+2 | passed | |
/3/kcluster | absent | None | passed |
Convention
- Three retained labels, one nonmember; the test concerns replay identity, not refitting k-means.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
77 model <- list(hierarchical_clustering=list(mode="rows",linkage="ward",cut_k=2L,
78 row_ids=ids(id,3L),labels=as.list(c(1L,2L,2L))))
79 emit(id,"operation:tabelz.hierarchical_cluster_labels","hierarchicalClusteringMenuItem",
80 "MV_SCORE_FOUR",list(name="hcluster",model=model),c(1L,2L,2L,1L),"hcluster",
81 c("Three retained labels, one nonmember; the test concerns replay identity, not refitting linkage."),
82 omitted=4L,numeric=FALSE)
83 id <- "STAT-MV-KMEANS-LABEL-OMIT-CORRECTED-001"Whole script generators/r/multivariate_scoring_corrections.R
Minimum-sample STAT-MV-KMEANS-MIN-001
Case STAT-MV-KMEANS-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_minimum.R · sha256 bcd4094568b73b37
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
columns= ["x", "y"]k= 2restarts= 50seed= 11
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/inertia | tolerance | 0 | 0.0 | 0.00E+2 | 15 | passed |
Convention
- With k=n=2 every observation forms a singleton, independent of initialization.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
40 emit("STAT-MV-KMEANS-MIN-001","tabelz.executor.clustering","kmeansClusteringMenuItem",
41 "MV_MIN_TWO",list(columns=list("x","y"),k=2L,seed=11L,restarts=50L),
42 list("/inertia"=tol(0,"two singleton clusters have zero within SS")),
43 c("With k=n=2 every observation forms a singleton, independent of initialization."))
Missing and excluded multivariate population STAT-MV-KMEANS-POP-001
Case STAT-MV-KMEANS-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic identities
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_population.R · sha256 8a6d148e9316e21f
- Dataset
- reference_data/datasets/MV_POP.json
Settings compared
columns= ["x", "y", "z"]k= 3restarts= 50seed= 37
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/inertia | tolerance | 0.08704801117912439 | 0.08704801117912436 | 2.73E-17 | 15 | passed |
/cluster_labels | partition | [3, 3, 1, 1, 3, 2, 2, 2, 2, 1] | [1, 1, 3, 3, 1, 2, 2, 2, 2, 3] | passed |
Convention
- Well-separated optimum shared by R Hartigan-Wong and scikit-learn Lloyd.
- R re-reads exported CSV, drops ordinal 9 by stable-row-ID exclusion, then uses complete cases.
Reference code
The lines of the reference script that produce this case's expected values.
55 set.seed(37)
56 km <- stats::kmeans(scaled,3L,nstart=50L,algorithm="Hartigan-Wong")
57 emit("STAT-MV-KMEANS-POP-001","tabelz.executor.clustering","kmeansClusteringMenuItem",
58 list(columns=list("x","y","z"),k=3L,seed=37L,restarts=50L),
59 list("/excluded_count"=exact(1L,"One stable row ID excluded"),
60 "/missing_count"=exact(1L,"One selected-column missing row"),
61 "/inertia"=tol(km$tot.withinss,"R unique optimum complete-case within SS"),
62 "/cluster_labels"=part(km$cluster,"R complete-case partition in sorted row-ID order")),
63 c("Well-separated optimum shared by R Hartigan-Wong and scikit-learn Lloyd."))
Multivariate option STAT-MV-KMEANS-RAW-001
Case STAT-MV-KMEANS-RAW-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]k= 3restarts= 50seed= 29standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/inertia | tolerance | 0.81749999999999901 | 0.8174999999999993 | 3.28E-16 | 15 | passed |
/cluster_labels | partition | [1, 1, 2, 2, 1, 1, 3, 3, 3, 3, 2, 2] | [1, 1, 3, 3, 1, 1, 2, 2, 2, 2, 3, 3] | passed |
Convention
- Well-separated optimum shared by R Hartigan-Wong and scikit-learn Lloyd; no standardization.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
51 set.seed(29)
52 km <- stats::kmeans(d[ord,c("x","y","z")],3L,nstart=50L,algorithm="Hartigan-Wong")
53 emit("STAT-MV-KMEANS-RAW-001","tabelz.executor.clustering","kmeansClusteringMenuItem",
54 list(columns=cols,k=3L,standardize=FALSE,seed=29L,restarts=50L),
55 list("/inertia"=tol(km$tot.withinss,"R unique raw-scale minimum within SS"),
56 "/cluster_labels"=part(km$cluster,"R raw-scale three-way partition")),
57 c("Well-separated optimum shared by R Hartigan-Wong and scikit-learn Lloyd; no standardization."),
58 kind="determinism",repeat_count=2L)
Special boundary STAT-MV-KMEANS-TIES-001
Case STAT-MV-KMEANS-TIES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_boundaries.R · sha256 420706593513ebf0
- Dataset
- reference_data/datasets/MV_TIES.json
Settings compared
columns= ["x", "y"]k= 2restarts= 50seed= 11
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/inertia | tolerance | 2.0143343386251487 | 2.014334338625148 | 4.87E-16 | 15 | passed |
Convention
- set.seed(11), nstart=50; duplicate points remain together in the unique two-way optimum.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
41 set.seed(11)
42 km <- stats::kmeans(scale(d[ord,c("x","y")]),centers=2L,nstart=50L,algorithm="Hartigan-Wong")
43 emit("STAT-MV-KMEANS-TIES-001","tabelz.executor.clustering","kmeansClusteringMenuItem",
44 "MV_TIES",list(columns=list("x","y"),k=2L,seed=11L,restarts=50L),
45 list("/inertia"=tol(km$tot.withinss,"within SS with exact duplicate observations")),
46 c("set.seed(11), nstart=50; duplicate points remain together in the unique two-way optimum."))
One-class latent class fit in closed form
Case STAT-MV-LATENT-ONE-001 · status: passed
Reference
- Evidence type
- R
- Source
- closed-form one-class multinomial maximum likelihood (base R)
- Citation
- Lazarsfeld and Henry (1968) Latent Structure Analysis; McCutcheon (1987) Latent Class Analysis, Sage.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · mclust 6.1.3, cluster 2.1.8.2, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_model_clustering.R · sha256 b03bbb2bfb4448e9
- Dataset
- reference_data/datasets/MV_LATENT.json
Settings compared
k_max= 1k_min= 1kind= "latent_class"variables= ["finish", "defect", "line"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 23 | 23 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/chosen_k | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[k=1]/parameters | exact | 5 | 5 | 0.00E+2 | passed | |
/fits/[k=1]/log_likelihood | tolerance | -60.39735569922253 | -60.39735569922253 | 2.21E-16 | 17 | passed |
/fits/[k=1]/bic | tolerance | 136.47218247809082 | 136.47218247809082 | 4.96E-15 | 16 | passed |
/profiles/0/size | exact | 23 | 23 | 0.00E+2 | passed | |
/profiles/0/probabilities/0/0/0 | exact | gloss | gloss | passed | ||
/profiles/0/probabilities/0/0/1 | tolerance | 0.30434782608695654 | 0.30434782608695654 | 1.05E-18 | 17 | passed |
/profiles/0/probabilities/0/1/1 | tolerance | 0.34782608695652173 | 0.34782608695652173 | 5.24E-19 | 17 | passed |
Convention
- With one class the conditional-independence likelihood factorizes into one multinomial per variable, maximized at the observed category proportions; complete rows only (missing_items complete).
- Categories are listed in code-point order within each variable.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:93-99: a Gaussian mixture uses diagonal covariance by default with a full-covariance option; a latent class model uses conditional independence of categorical variables within each class.
- docs/manual/chapters/90-learning-and-mixtures.tex:101-112: L = prod_i sum_g pi_g f_g(y_i); the default search fits K from 10 seeded starts per K and chooses the smallest BIC = -2 log L + m log n, m the number of free parameters; the selected fit is the best converged start, not a proven global maximum.
Reference code
The lines of the reference script that produce this case's expected values.
182 finish_probs <- table(factor(complete$finish, levels = sort(unique(complete$finish), method = "radix"))) / nl
183 outputs <- list(
184 "/n" = exact(nl, "complete rows"),
185 "/missing_count" = exact(1L, "one row has a missing line"),
186 "/chosen_k" = exact(1L, "the only K in the range"),
187 "/fits/[k=1]/parameters" = exact(as.integer(m), "sum over variables of (categories - 1)"),
188 "/fits/[k=1]/log_likelihood" = tol(loglik, "sum_j sum_c n_jc log(n_jc / n): the multinomial log-likelihood at the observed proportions", rel = "1e-9"),
189 "/fits/[k=1]/bic" = tol(bic_of(loglik, m, nl), "-2 log L + m log n", rel = "1e-9"),
190 "/profiles/0/size" = exact(nl, "every row in the single class"),
191 "/profiles/0/probabilities/0/0/0" = exact(names(finish_probs)[1], "first finish category in code-point order"),
192 "/profiles/0/probabilities/0/0/1" = tol(finish_probs[[1]], "observed proportion of that category", rel = "1e-9"),
193 "/profiles/0/probabilities/0/1/1" = tol(finish_probs[[2]], "observed proportion of the second category", rel = "1e-9")
194 )
195 emit("STAT-MV-LATENT-ONE-001", "One-class latent class fit in closed form", "boundary",
196 "MV_LATENT",
197 list(variables = list("finish", "defect", "line"), kind = "latent_class", k_min = 1L,
198 k_max = 1L),
199 outputs,
200 list("With one class the conditional-independence likelihood factorizes into one multinomial per variable, maximized at the observed category proportions; complete rows only (missing_items complete).",
201 "Categories are listed in code-point order within each variable."),
202 "closed-form one-class multinomial maximum likelihood (base R)",
203 "Lazarsfeld and Henry (1968) Latent Structure Analysis; McCutcheon (1987) Latent Class Analysis, Sage.")
Multivariate STAT-MV-MANOVA-001
Case STAT-MV-MANOVA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_core.R · sha256 90e434c114270562
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
factor_columns= ["group"]response_columns= ["x", "y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/joint_tests/0/value | tolerance | 1.9933593655877515 | 1.9933593655877508 | 6.58E-16 | 15 | passed |
/joint_tests/1/value | tolerance | 9.0403124637035046e-06 | 9.040312463706415e-06 | 2.91E-18 | 12 | passed |
Convention
- R manova one-way factor; Tabelz emits Pillai and Wilks only; no Hotelling-Lawley or Roy.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
107 mv <- stats::manova(cbind(x,y) ~ group, data=d)
108 pillai <- summary(mv, test="Pillai")$stats[1,]
109 wilks <- summary(mv, test="Wilks")$stats[1,]
110 emit("STAT-MV-MANOVA-001", "tabelz.executor.manova", "manovaMenuItem",
111 list(response_columns=list("x","y"), factor_columns=list("group")),
112 list("/joint_tests/0/value"=tol(unname(pillai["Pillai"]), "Pillai trace"),
113 "/joint_tests/1/value"=tol(unname(wilks["Wilks"]), "Wilks lambda")),
114 c("R manova one-way factor; Tabelz emits Pillai and Wilks only; no Hotelling-Lawley or Roy."))
Hard-numeric STAT-MV-MANOVA-HARD-001
Case STAT-MV-MANOVA-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova and chisq.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_hard.R · sha256 06eca51b7d1d3ab6
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
factor_columns= ["group"]response_columns= ["x", "y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/joint_tests/0/value | tolerance | 1.9933593656182462 | 1.9933593655449309 | 7.33E-11 | 10 | passed |
Convention
- One-way MANOVA; Pillai trace computed from R hypothesis/error SSCP.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
76 mv <- stats::manova(cbind(x,y)~group,data=d)
77 pillai <- summary(mv,test="Pillai")$stats[1,"Pillai"]
78 emit("STAT-MV-MANOVA-HARD-001","tabelz.executor.manova","manovaMenuItem",
79 "MV_HARD",list(response_columns=list("x","y"),factor_columns=list("group")),
80 list("/joint_tests/0/value"=tol(pillai,"Pillai trace after cancelling common offset")),
81 c("One-way MANOVA; Pillai trace computed from R hypothesis/error SSCP."))
Multivariate option STAT-MV-MANOVA-II-001
Case STAT-MV-MANOVA-II-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
factor_columns= ["group"]response_columns= ["x", "y"]test_type= "II"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/joint_tests/0/value | tolerance | 1.9933593655877515 | 1.9933593655877508 | 6.58E-16 | 15 | passed |
/joint_tests/1/value | tolerance | 9.0403124637035046e-06 | 9.040312463706415e-06 | 2.91E-18 | 12 | passed |
Convention
- One-factor design has identical Type-II and Type-III hypotheses.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
77 mv <- stats::manova(cbind(x,y)~group,data=d)
78 pillai <- summary(mv,test="Pillai")$stats[1,"Pillai"]
79 wilks <- summary(mv,test="Wilks")$stats[1,"Wilks"]
80 emit("STAT-MV-MANOVA-II-001","tabelz.executor.manova","manovaMenuItem",
81 list(response_columns=list("x","y"),factor_columns=list("group"),test_type="II"),
82 list("/joint_tests/0/value"=tol(pillai,"R one-way Pillai trace; Type II equals Type III"),
83 "/joint_tests/1/value"=tol(wilks,"R one-way Wilks lambda; Type II equals Type III")),
84 c("One-factor design has identical Type-II and Type-III hypotheses."))
Invalid multivariate request STAT-MV-MANOVA-INVALID-001
Case STAT-MV-MANOVA-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
factor_columns= ["group"]response_columns= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- MANOVA needs at least two responses.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-MANOVA-INVALID-002
Case STAT-MV-MANOVA-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
confidence_level= 0.2factor_columns= ["group"]response_columns= ["x", "y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Confidence level below 0.5 is invalid.
- The rejection follows from the declared request schema without statistical computation.
Minimum-sample STAT-MV-MANOVA-MIN-001
Case STAT-MV-MANOVA-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_minimum.R · sha256 bcd4094568b73b37
- Dataset
- reference_data/datasets/MV_MIN_MANOVA.json
Settings compared
factor_columns= ["group"]response_columns= ["x", "y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/joint_tests/0/value | tolerance | 0.99782349022580574 | 0.9978234902258062 | 4.47E-16 | 15 | passed |
Convention
- Each group has three observations for two responses; residual SSCP is estimable.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
66 m <- core[c(1:3,5:7),]
67 export_dataset(m,"MV_MIN_MANOVA","Two groups with three observations each",
68 "R manova minimum-estimable one-way boundary",
69 "Constructed validation data; no third-party license.",types)
70 m <- read_dataset("MV_MIN_MANOVA")
71 mv <- stats::manova(cbind(x,y)~group,data=m)
72 pillai <- summary(mv,test="Pillai")$stats[1,"Pillai"]
73 emit("STAT-MV-MANOVA-MIN-001","tabelz.executor.manova","manovaMenuItem",
74 "MV_MIN_MANOVA",list(response_columns=list("x","y"),factor_columns=list("group")),
75 list("/joint_tests/0/value"=tol(pillai,"two-group Pillai trace")),
76 c("Each group has three observations for two responses; residual SSCP is estimable."))
Missing and excluded multivariate population STAT-MV-MANOVA-POP-001
Case STAT-MV-MANOVA-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic identities
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_population.R · sha256 8a6d148e9316e21f
- Dataset
- reference_data/datasets/MV_POP.json
Settings compared
factor_columns= ["group"]response_columns= ["x", "y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/joint_tests/0/value | tolerance | 1.9955658571756567 | 1.9955658571756567 | 9.90E-18 | 17 | passed |
Convention
- One-way factor Type-III Pillai trace on complete response/factor rows.
- R re-reads exported CSV, drops ordinal 9 by stable-row-ID exclusion, then uses complete cases.
Reference code
The lines of the reference script that produce this case's expected values.
86 md <- eligible[stats::complete.cases(eligible[c("x","y","group")]),,drop=FALSE]
87 mv <- stats::manova(cbind(x,y)~group,data=md)
88 pillai <- summary(mv,test="Pillai")$stats[1,"Pillai"]
89 emit("STAT-MV-MANOVA-POP-001","tabelz.executor.manova","manovaMenuItem",
90 list(response_columns=list("x","y"),factor_columns=list("group")),
91 list("/excluded_count"=exact(1L,"One stable row ID excluded"),
92 "/missing_count"=exact(1L,"One response/factor-missing row"),
93 "/joint_tests/0/value"=tol(pillai,"R complete-case one-way Pillai trace")),
94 c("One-way factor Type-III Pillai trace on complete response/factor rows."))
Special boundary STAT-MV-MANOVA-SMALL-001
Case STAT-MV-MANOVA-SMALL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_boundaries.R · sha256 420706593513ebf0
- Dataset
- reference_data/datasets/MV_MANOVA_FOUR.json
Settings compared
factor_columns= ["group"]response_columns= ["x", "y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/joint_tests/0/value | tolerance | 0.99945235487381423 | 0.9994523548740419 | 2.28E-13 | 12 | passed |
Convention
- Two groups of two observations leave residual df=2 for two responses.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
69 m <- base[c(1L,2L,5L,6L),]
70 export_dataset(m,"MV_MANOVA_FOUR","Two groups with two observations each",
71 "R manova small residual-SSCP boundary",
72 "Constructed validation data; no third-party license.",types)
73 m <- read_dataset("MV_MANOVA_FOUR")
74 mv <- stats::manova(cbind(x,y)~group,data=m)
75 pillai <- summary(mv,test="Pillai")$stats[1,"Pillai"]
76 emit("STAT-MV-MANOVA-SMALL-001","tabelz.executor.manova","manovaMenuItem",
77 "MV_MANOVA_FOUR",list(response_columns=list("x","y"),factor_columns=list("group")),
78 list("/joint_tests/0/value"=tol(pillai,"Pillai trace with two residual degrees of freedom")),
79 c("Two groups of two observations leave residual df=2 for two responses."))
Indicator MCA of three variables, complete rows
Case STAT-MV-MCA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R ca::mjca (lambda = 'indicator' and 'adjusted') with the textbook supplementary projection
- Citation
- Nenadic and Greenacre (2007), Correspondence analysis in R, with two- and three-dimensional graphics: the ca package, Journal of Statistical Software 20(3); Greenacre (2007) Correspondence Analysis in Practice, 2nd ed., chapters 18-19.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · ca 0.72, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_mca.R · sha256 6edebdab7f958ce0
- Dataset
- reference_data/datasets/MV_MCA.json
Settings compared
columns= ["region", "size", "grade"]dimensions= 2missing= "complete"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_analysed | exact | 23 | 23 | 0.00E+2 | passed | |
/variables | exact | 3 | 3 | 0.00E+2 | passed | |
/categories | exact | 8 | 8 | 0.00E+2 | passed | |
/total_inertia | tolerance | 1.6666666666666667 | 1.6666666666666667 | 4.07E-17 | 16 | passed |
/greenacre_denominator | tolerance | 0.35704264870931429 | 0.35704264870931596 | 1.67E-15 | 14 | passed |
/dimensions/0/inertia | tolerance | 0.69147973494866888 | 0.6914797349486692 | 3.31E-16 | 15 | passed |
/dimensions/0/raw_percent | tolerance | 41.488784096920135 | 41.48878409692015 | 1.41E-14 | 15 | passed |
/dimensions/0/cumulative_percent | tolerance | 41.488784096920128 | 41.48878409692015 | 2.11E-14 | 15 | passed |
/dimensions/0/adjusted | tolerance | 0.2886049012275298 | 0.2886049012275303 | 4.97E-16 | 14 | passed |
/dimensions/0/benzecri_percent | tolerance | 92.464433828814563 | 92.46443382881453 | 2.81E-14 | 15 | passed |
/dimensions/0/greenacre_percent | tolerance | 80.83205249311743 | 80.8320524931172 | 2.27E-13 | 14 | passed |
/dimensions/1/inertia | tolerance | 0.43557576703933387 | 0.43557576703933426 | 3.91E-16 | 15 | passed |
/dimensions/1/raw_percent | tolerance | 26.134546022360031 | 26.134546022360055 | 2.44E-14 | 15 | passed |
/dimensions/1/cumulative_percent | tolerance | 67.623330119280155 | 67.62333011928021 | 5.66E-14 | 15 | passed |
/dimensions/1/adjusted | tolerance | 0.023520409312783316 | 0.023520409312783496 | 1.80E-16 | 14 | passed |
/dimensions/1/benzecri_percent | tolerance | 7.5355661711854323 | 7.535566171185475 | 4.26E-14 | 14 | passed |
/dimensions/1/greenacre_percent | tolerance | 6.5875629698043214 | 6.587562969804342 | 2.05E-14 | 14 | passed |
/dimensions/2/inertia | tolerance | 0.30519949016143977 | 0.3051994901614402 | 4.42E-16 | 14 | passed |
/dimensions/2/raw_percent | tolerance | 18.311969409686384 | 18.311969409686412 | 2.83E-14 | 14 | passed |
/dimensions/2/cumulative_percent | tolerance | 85.935299528966553 | 85.93529952896662 | 7.09E-14 | 15 | passed |
/dimensions/2/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/2/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/2/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/inertia | tolerance | 0.16766557359392817 | 0.1676655735939283 | 1.38E-16 | 15 | passed |
/dimensions/3/raw_percent | tolerance | 10.05993441563569 | 10.059934415635698 | 8.46E-15 | 15 | passed |
/dimensions/3/cumulative_percent | tolerance | 95.995233944602234 | 95.99523394460232 | 8.48E-14 | 15 | passed |
/dimensions/3/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/inertia | tolerance | 0.066746100923294915 | 0.06674610092329483 | 8.29E-17 | 14 | passed |
/dimensions/4/raw_percent | tolerance | 4.0047660553976945 | 4.00476605539769 | 4.46E-15 | 14 | passed |
/dimensions/4/cumulative_percent | tolerance | 99.999999999999929 | 100.0 | 7.10E-14 | 15 | passed |
/dimensions/4/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/categories_table/0/variable | exact | region | region | passed | ||
/categories_table/0/category | exact | north | north | passed | ||
/categories_table/0/count | exact | 12 | 12 | 0.00E+2 | passed | |
/categories_table/0/mass | tolerance | 0.17391304347826086 | 0.17391304347826086 | 4.74E-18 | 16 | passed |
/categories_table/0/contributions/0 | tolerance | 0.11360270345761794 | 0.1136027034576179 | 3.88E-17 | 15 | passed |
/categories_table/0/cosine_squared/0 | tolerance | 0.49274761291513569 | 0.4927476129151354 | 2.77E-16 | 15 | passed |
/categories_table/0/contributions/1 | tolerance | 0.0068642474933678548 | 0.0068642474933679355 | 8.07E-17 | 13 | passed |
/categories_table/0/cosine_squared/1 | tolerance | 0.018754826438903246 | 0.018754826438903468 | 2.22E-16 | 13 | passed |
/categories_table/1/variable | exact | region | region | passed | ||
/categories_table/1/category | exact | south | south | passed | ||
/categories_table/1/count | exact | 6 | 6 | 0.00E+2 | passed | |
/categories_table/1/mass | tolerance | 0.086956521739130432 | 0.08695652173913043 | 3.69E-19 | 17 | passed |
/categories_table/1/contributions/0 | tolerance | 0.0098869919490792799 | 0.009886991949079433 | 1.53E-16 | 13 | passed |
/categories_table/1/cosine_squared/0 | tolerance | 0.02774877444087288 | 0.027748774440873213 | 3.33E-16 | 13 | passed |
/categories_table/1/contributions/1 | tolerance | 0.25214281495225588 | 0.2521428149522572 | 1.33E-15 | 14 | passed |
/categories_table/1/cosine_squared/1 | tolerance | 0.44576962951845417 | 0.44576962951845506 | 8.87E-16 | 14 | passed |
/categories_table/2/variable | exact | region | region | passed | ||
/categories_table/2/category | exact | west | west | passed | ||
/categories_table/2/count | exact | 5 | 5 | 0.00E+2 | passed | |
/categories_table/2/mass | tolerance | 0.072463768115942032 | 0.07246376811594203 | 4.00E-19 | 17 | passed |
/categories_table/2/contributions/0 | tolerance | 0.17076054920117464 | 0.17076054920117437 | 2.74E-16 | 14 | passed |
/categories_table/2/cosine_squared/0 | tolerance | 0.45263026065504974 | 0.4526302606550491 | 6.63E-16 | 14 | passed |
/categories_table/2/contributions/1 | tolerance | 0.1778418952854306 | 0.1778418952854306 | 4.34E-18 | 16 | passed |
/categories_table/2/cosine_squared/1 | tolerance | 0.29694387647760778 | 0.29694387647760795 | 1.69E-16 | 15 | passed |
/categories_table/3/variable | exact | size | size | passed | ||
/categories_table/3/category | exact | large | large | passed | ||
/categories_table/3/count | exact | 11 | 11 | 0.00E+2 | passed | |
/categories_table/3/mass | tolerance | 0.15942028985507248 | 0.15942028985507245 | 2.99E-17 | 15 | passed |
/categories_table/3/contributions/0 | tolerance | 0.1477428812746423 | 0.14774288127464227 | 2.63E-17 | 15 | passed |
/categories_table/3/cosine_squared/0 | tolerance | 0.58742694820996799 | 0.587426948209968 | 1.77E-18 | 17 | passed |
/categories_table/3/contributions/1 | tolerance | 0.0089136325189684024 | 0.00891363251896825 | 1.53E-16 | 13 | passed |
/categories_table/3/cosine_squared/1 | tolerance | 0.022324733348949355 | 0.022324733348948984 | 3.71E-16 | 13 | passed |
/categories_table/4/variable | exact | size | size | passed | ||
/categories_table/4/category | exact | small | small | passed | ||
/categories_table/4/count | exact | 12 | 12 | 0.00E+2 | passed | |
/categories_table/4/mass | tolerance | 0.17391304347826086 | 0.17391304347826086 | 4.74E-18 | 16 | passed |
/categories_table/4/contributions/0 | tolerance | 0.13543097450175526 | 0.1354309745017554 | 1.37E-16 | 14 | passed |
/categories_table/4/cosine_squared/0 | tolerance | 0.58742694820996788 | 0.587426948209968 | 1.12E-16 | 15 | passed |
/categories_table/4/contributions/1 | tolerance | 0.0081708298090543904 | 0.008170829809054227 | 1.63E-16 | 13 | passed |
/categories_table/4/cosine_squared/1 | tolerance | 0.022324733348949442 | 0.02232473334894899 | 4.51E-16 | 13 | passed |
/categories_table/5/variable | exact | grade | grade | passed | ||
/categories_table/5/category | exact | A | A | passed | ||
/categories_table/5/count | exact | 9 | 9 | 0.00E+2 | passed | |
/categories_table/5/mass | tolerance | 0.13043478260869565 | 0.13043478260869565 | 1.45E-18 | 16 | passed |
/categories_table/5/contributions/0 | tolerance | 0.23383955139522214 | 0.2338395513952223 | 1.66E-16 | 15 | passed |
/categories_table/5/cosine_squared/0 | tolerance | 0.79692689002361294 | 0.7969268900236134 | 4.48E-16 | 15 | passed |
/categories_table/5/contributions/1 | tolerance | 0.041730351101929172 | 0.04173035110192911 | 6.22E-17 | 14 | passed |
/categories_table/5/cosine_squared/1 | tolerance | 0.089585310615214422 | 0.0895853106152143 | 1.24E-16 | 14 | passed |
/categories_table/6/variable | exact | grade | grade | passed | ||
/categories_table/6/category | exact | B | B | passed | ||
/categories_table/6/count | exact | 4 | 4 | 0.00E+2 | passed | |
/categories_table/6/mass | tolerance | 0.057971014492753624 | 0.057971014492753624 | 1.08E-19 | 17 | passed |
/categories_table/6/contributions/0 | tolerance | 0.0017309614860717463 | 0.001730961486071765 | 1.86E-17 | 13 | passed |
/categories_table/6/cosine_squared/0 | tolerance | 0.0043467268674774739 | 0.004346726867477517 | 4.34E-17 | 14 | passed |
/categories_table/6/contributions/1 | tolerance | 0.4510031355204237 | 0.4510031355204232 | 4.96E-16 | 14 | passed |
/categories_table/6/cosine_squared/1 | tolerance | 0.71340929114264662 | 0.7134092911426455 | 1.11E-15 | 14 | passed |
/categories_table/7/variable | exact | grade | grade | passed | ||
/categories_table/7/category | exact | C | C | passed | ||
/categories_table/7/count | exact | 10 | 10 | 0.00E+2 | passed | |
/categories_table/7/mass | tolerance | 0.14492753623188406 | 0.14492753623188406 | 3.20E-18 | 16 | passed |
/categories_table/7/contributions/0 | tolerance | 0.18700538673443712 | 0.1870053867344372 | 8.12E-17 | 15 | passed |
/categories_table/7/cosine_squared/0 | tolerance | 0.68634000249723404 | 0.6863400024972337 | 3.37E-16 | 15 | passed |
/categories_table/7/contributions/1 | tolerance | 0.053333093318570342 | 0.05333309331857047 | 1.25E-16 | 14 | passed |
/categories_table/7/cosine_squared/1 | tolerance | 0.1233008930097193 | 0.12330089300971951 | 2.12E-16 | 14 | passed |
/incomplete_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- ca::mjca(lambda = 'indicator', nd = NA) on the 23 complete rows: inertias are sv^2, principal coordinates are colpcoord; contributions mass g^2/lambda and squared cosines g^2/d^2 follow Greenacre (2007); d^2 is the chi-square distance of the indicator column profile to the centroid, 1/(Q c_j) - 1 (asserted in the generator).
- Adjusted inertias by the Benzecri formula; Greenacre's denominator equals mjca(lambda = 'adjusted')$inertia.t (asserted in the generator).
- The first three inertias are distinct, so each axis is unique up to sign; with two axes the signs are independent, so the sign-free contributions and squared cosines are compared here and the signed first-axis coordinates in STAT-MV-MCA-DIM1-001.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:100-107: simple CA of the complete indicator matrix; with Q variables and J active categories the raw inertias sum to (J - Q)/Q; contributions and representation quality follow simple CA; supplementary variables are projected after fitting.
- docs/manual/chapters/92-dimensions-and-categories.tex:109-112: missing values are excluded or form a distinct category by the declared option; empty active categories are removed.
- docs/manual/chapters/92-dimensions-and-categories.tex:115-124: Benzecri keeps lambda_s > 1/Q and reports a_s = [Q/(Q-1) (lambda_s - 1/Q)]^2; Greenacre's percentages use a different adjusted total; the map uses the raw principal coordinates.
Reference code
The lines of the reference script that produce this case's expected values.
28 emit <- function(id, title, kind, configuration, outputs, notes) {
29 expected <- list(schema_version = "2.0.0", case_id = id, outputs = outputs,
30 expected_error = NULL, deferred_outputs = list(), generator_run = run)
31 write_expected("multivariate", id, expected)
32 case <- list(
33 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "multivariate",
34 entry_point = "tabelz.analysis.multiple_correspondence_analysis:compute_mca",
35 menu_items = list("multipleCorrespondenceMenuItem"), title = title, case_kind = kind,
36 dataset = list(path = "reference_data/datasets/MV_MCA.json", sha256 = ""),
37 excluded_rows = list(), configuration = configuration, "repeat" = 1L,
38 expected = list(path = paste0("reference_data/expected/multivariate/", id, ".json"),
39 sha256 = ""),
40 oracle = list(oracle_class = "independent_implementation",
41 source = "R ca::mjca (lambda = 'indicator' and 'adjusted') with the textbook supplementary projection",
42 citation = "Nenadic and Greenacre (2007), Correspondence analysis in R, with two- and three-dimensional graphics: the ca package, Journal of Statistical Software 20(3); Greenacre (2007) Correspondence Analysis in Practice, 2nd ed., chapters 18-19.",
43 generator = list(path = "generators/r/multivariate_mca.R", sha256 = ""),
44 independent = TRUE,
45 convention_notes = c(notes, "Expected computed from the exported CSV.", manual)),
46 supported = TRUE, unsupported_reason = NULL,
47 requirement_ids = list("REQ-STAT-MV-MCA-001"), risk_ids = list("RISK-REFERENCE-001"),
48 review_reference = NULL
49 )
50 write_case("multivariate", id, case)
Indicator MCA reporting one dimension
Case STAT-MV-MCA-DIM1-001 · status: passed
Reference
- Evidence type
- R
- Source
- R ca::mjca (lambda = 'indicator' and 'adjusted') with the textbook supplementary projection
- Citation
- Nenadic and Greenacre (2007), Correspondence analysis in R, with two- and three-dimensional graphics: the ca package, Journal of Statistical Software 20(3); Greenacre (2007) Correspondence Analysis in Practice, 2nd ed., chapters 18-19.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · ca 0.72, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_mca.R · sha256 6edebdab7f958ce0
- Dataset
- reference_data/datasets/MV_MCA.json
Settings compared
columns= ["region", "size", "grade"]dimensions= 1missing= "complete"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_analysed | exact | 23 | 23 | 0.00E+2 | passed | |
/variables | exact | 3 | 3 | 0.00E+2 | passed | |
/categories | exact | 8 | 8 | 0.00E+2 | passed | |
/total_inertia | tolerance | 1.6666666666666667 | 1.6666666666666667 | 4.07E-17 | 16 | passed |
/greenacre_denominator | tolerance | 0.35704264870931429 | 0.35704264870931596 | 1.67E-15 | 14 | passed |
/dimensions/0/inertia | tolerance | 0.69147973494866888 | 0.6914797349486692 | 3.31E-16 | 15 | passed |
/dimensions/0/raw_percent | tolerance | 41.488784096920135 | 41.48878409692015 | 1.41E-14 | 15 | passed |
/dimensions/0/cumulative_percent | tolerance | 41.488784096920128 | 41.48878409692015 | 2.11E-14 | 15 | passed |
/dimensions/0/adjusted | tolerance | 0.2886049012275298 | 0.2886049012275303 | 4.97E-16 | 14 | passed |
/dimensions/0/benzecri_percent | tolerance | 92.464433828814563 | 92.46443382881453 | 2.81E-14 | 15 | passed |
/dimensions/0/greenacre_percent | tolerance | 80.83205249311743 | 80.8320524931172 | 2.27E-13 | 14 | passed |
/dimensions/1/inertia | tolerance | 0.43557576703933387 | 0.43557576703933426 | 3.91E-16 | 15 | passed |
/dimensions/1/raw_percent | tolerance | 26.134546022360031 | 26.134546022360055 | 2.44E-14 | 15 | passed |
/dimensions/1/cumulative_percent | tolerance | 67.623330119280155 | 67.62333011928021 | 5.66E-14 | 15 | passed |
/dimensions/1/adjusted | tolerance | 0.023520409312783316 | 0.023520409312783496 | 1.80E-16 | 14 | passed |
/dimensions/1/benzecri_percent | tolerance | 7.5355661711854323 | 7.535566171185475 | 4.26E-14 | 14 | passed |
/dimensions/1/greenacre_percent | tolerance | 6.5875629698043214 | 6.587562969804342 | 2.05E-14 | 14 | passed |
/dimensions/2/inertia | tolerance | 0.30519949016143977 | 0.3051994901614402 | 4.42E-16 | 14 | passed |
/dimensions/2/raw_percent | tolerance | 18.311969409686384 | 18.311969409686412 | 2.83E-14 | 14 | passed |
/dimensions/2/cumulative_percent | tolerance | 85.935299528966553 | 85.93529952896662 | 7.09E-14 | 15 | passed |
/dimensions/2/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/2/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/2/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/inertia | tolerance | 0.16766557359392817 | 0.1676655735939283 | 1.38E-16 | 15 | passed |
/dimensions/3/raw_percent | tolerance | 10.05993441563569 | 10.059934415635698 | 8.46E-15 | 15 | passed |
/dimensions/3/cumulative_percent | tolerance | 95.995233944602234 | 95.99523394460232 | 8.48E-14 | 15 | passed |
/dimensions/3/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/inertia | tolerance | 0.066746100923294915 | 0.06674610092329483 | 8.29E-17 | 14 | passed |
/dimensions/4/raw_percent | tolerance | 4.0047660553976945 | 4.00476605539769 | 4.46E-15 | 14 | passed |
/dimensions/4/cumulative_percent | tolerance | 99.999999999999929 | 100.0 | 7.10E-14 | 15 | passed |
/dimensions/4/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/categories_table/0/variable | exact | region | region | passed | ||
/categories_table/0/category | exact | north | north | passed | ||
/categories_table/0/count | exact | 12 | 12 | 0.00E+2 | passed | |
/categories_table/0/mass | tolerance | 0.17391304347826086 | 0.17391304347826086 | 4.74E-18 | 16 | passed |
/categories_table/0/coordinates | sign_invariant_sequence | ['-0.6720753766050902'] | [-0.6720753766050903] | passed | ||
/categories_table/0/contributions/0 | tolerance | 0.11360270345761794 | 0.1136027034576179 | 3.88E-17 | 15 | passed |
/categories_table/0/cosine_squared/0 | tolerance | 0.49274761291513569 | 0.4927476129151354 | 2.77E-16 | 15 | passed |
/categories_table/1/variable | exact | region | region | passed | ||
/categories_table/1/category | exact | south | south | passed | ||
/categories_table/1/count | exact | 6 | 6 | 0.00E+2 | passed | |
/categories_table/1/mass | tolerance | 0.086956521739130432 | 0.08695652173913043 | 3.69E-19 | 17 | passed |
/categories_table/1/coordinates | sign_invariant_sequence | ['0.2803953059208964'] | [0.2803953059208986] | passed | ||
/categories_table/1/contributions/0 | tolerance | 0.0098869919490792799 | 0.009886991949079433 | 1.53E-16 | 13 | passed |
/categories_table/1/cosine_squared/0 | tolerance | 0.02774877444087288 | 0.027748774440873213 | 3.33E-16 | 13 | passed |
/categories_table/2/variable | exact | region | region | passed | ||
/categories_table/2/category | exact | west | west | passed | ||
/categories_table/2/count | exact | 5 | 5 | 0.00E+2 | passed | |
/categories_table/2/mass | tolerance | 0.072463768115942032 | 0.07246376811594203 | 4.00E-19 | 17 | passed |
/categories_table/2/coordinates | sign_invariant_sequence | ['1.2765065367471409'] | [1.2765065367471402] | passed | ||
/categories_table/2/contributions/0 | tolerance | 0.17076054920117464 | 0.17076054920117437 | 2.74E-16 | 14 | passed |
/categories_table/2/cosine_squared/0 | tolerance | 0.45263026065504974 | 0.4526302606550491 | 6.63E-16 | 14 | passed |
/categories_table/3/variable | exact | size | size | passed | ||
/categories_table/3/category | exact | large | large | passed | ||
/categories_table/3/count | exact | 11 | 11 | 0.00E+2 | passed | |
/categories_table/3/mass | tolerance | 0.15942028985507248 | 0.15942028985507245 | 2.99E-17 | 15 | passed |
/categories_table/3/coordinates | sign_invariant_sequence | ['-0.80051820594364875'] | [-0.800518205943649] | passed | ||
/categories_table/3/contributions/0 | tolerance | 0.1477428812746423 | 0.14774288127464227 | 2.63E-17 | 15 | passed |
/categories_table/3/cosine_squared/0 | tolerance | 0.58742694820996799 | 0.587426948209968 | 1.77E-18 | 17 | passed |
/categories_table/4/variable | exact | size | size | passed | ||
/categories_table/4/category | exact | small | small | passed | ||
/categories_table/4/count | exact | 12 | 12 | 0.00E+2 | passed | |
/categories_table/4/mass | tolerance | 0.17391304347826086 | 0.17391304347826086 | 4.74E-18 | 16 | passed |
/categories_table/4/coordinates | sign_invariant_sequence | ['0.73380835544834422'] | [0.7338083554483448] | passed | ||
/categories_table/4/contributions/0 | tolerance | 0.13543097450175526 | 0.1354309745017554 | 1.37E-16 | 14 | passed |
/categories_table/4/cosine_squared/0 | tolerance | 0.58742694820996788 | 0.587426948209968 | 1.12E-16 | 15 | passed |
/categories_table/5/variable | exact | grade | grade | passed | ||
/categories_table/5/category | exact | A | A | passed | ||
/categories_table/5/count | exact | 9 | 9 | 0.00E+2 | passed | |
/categories_table/5/mass | tolerance | 0.13043478260869565 | 0.13043478260869565 | 1.45E-18 | 16 | passed |
/categories_table/5/coordinates | sign_invariant_sequence | ['-1.1134020168599672'] | [-1.1134020168599679] | passed | ||
/categories_table/5/contributions/0 | tolerance | 0.23383955139522214 | 0.2338395513952223 | 1.66E-16 | 15 | passed |
/categories_table/5/cosine_squared/0 | tolerance | 0.79692689002361294 | 0.7969268900236134 | 4.48E-16 | 15 | passed |
/categories_table/6/variable | exact | grade | grade | passed | ||
/categories_table/6/category | exact | B | B | passed | ||
/categories_table/6/count | exact | 4 | 4 | 0.00E+2 | passed | |
/categories_table/6/mass | tolerance | 0.057971014492753624 | 0.057971014492753624 | 1.08E-19 | 17 | passed |
/categories_table/6/coordinates | sign_invariant_sequence | ['0.14369047505147298'] | [0.14369047505147378] | passed | ||
/categories_table/6/contributions/0 | tolerance | 0.0017309614860717463 | 0.001730961486071765 | 1.86E-17 | 13 | passed |
/categories_table/6/cosine_squared/0 | tolerance | 0.0043467268674774739 | 0.004346726867477517 | 4.34E-17 | 14 | passed |
/categories_table/7/variable | exact | grade | grade | passed | ||
/categories_table/7/category | exact | C | C | passed | ||
/categories_table/7/count | exact | 10 | 10 | 0.00E+2 | passed | |
/categories_table/7/mass | tolerance | 0.14492753623188406 | 0.14492753623188406 | 3.20E-18 | 16 | passed |
/categories_table/7/coordinates | sign_invariant_sequence | ['0.94458562515338074'] | [0.9445856251533812] | passed | ||
/categories_table/7/contributions/0 | tolerance | 0.18700538673443712 | 0.1870053867344372 | 8.12E-17 | 15 | passed |
/categories_table/7/cosine_squared/0 | tolerance | 0.68634000249723404 | 0.6863400024972337 | 3.37E-16 | 15 | passed |
Convention
- Same fit as STAT-MV-MCA-001 with one requested dimension: every inertia is still reported; coordinates (compared up to the axis sign), contributions and cosines are reported for the first axis only.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:100-107: simple CA of the complete indicator matrix; with Q variables and J active categories the raw inertias sum to (J - Q)/Q; contributions and representation quality follow simple CA; supplementary variables are projected after fitting.
- docs/manual/chapters/92-dimensions-and-categories.tex:109-112: missing values are excluded or form a distinct category by the declared option; empty active categories are removed.
- docs/manual/chapters/92-dimensions-and-categories.tex:115-124: Benzecri keeps lambda_s > 1/Q and reports a_s = [Q/(Q-1) (lambda_s - 1/Q)]^2; Greenacre's percentages use a different adjusted total; the map uses the raw principal coordinates.
Reference code
The lines of the reference script that produce this case's expected values.
187 "The first three inertias are distinct, so each axis is unique up to sign; with two axes the signs are independent, so the sign-free contributions and squared cosines are compared here and the signed first-axis coordinates in STAT-MV-MCA-DIM1-001."))
Indicator MCA with missing values as a category
Case STAT-MV-MCA-MISSING-001 · status: passed
Reference
- Evidence type
- R
- Source
- R ca::mjca (lambda = 'indicator' and 'adjusted') with the textbook supplementary projection
- Citation
- Nenadic and Greenacre (2007), Correspondence analysis in R, with two- and three-dimensional graphics: the ca package, Journal of Statistical Software 20(3); Greenacre (2007) Correspondence Analysis in Practice, 2nd ed., chapters 18-19.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · ca 0.72, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_mca.R · sha256 6edebdab7f958ce0
- Dataset
- reference_data/datasets/MV_MCA.json
Settings compared
columns= ["region", "size", "grade"]dimensions= 2missing= "category"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_analysed | exact | 24 | 24 | 0.00E+2 | passed | |
/variables | exact | 3 | 3 | 0.00E+2 | passed | |
/categories | exact | 9 | 9 | 0.00E+2 | passed | |
/total_inertia | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/greenacre_denominator | tolerance | 0.39074074074073861 | 0.3907407407407401 | 1.50E-15 | 14 | passed |
/dimensions/0/inertia | tolerance | 0.71129913678740653 | 0.7112991367874073 | 7.75E-16 | 14 | passed |
/dimensions/0/raw_percent | tolerance | 35.564956839370325 | 35.56495683937037 | 4.24E-14 | 14 | passed |
/dimensions/0/cumulative_percent | tolerance | 35.564956839370325 | 35.56495683937037 | 4.24E-14 | 14 | passed |
/dimensions/0/adjusted | tolerance | 0.32143083430653702 | 0.3214308343065383 | 1.27E-15 | 14 | passed |
/dimensions/0/benzecri_percent | tolerance | 92.045488621002676 | 92.0454886210027 | 2.81E-14 | 15 | passed |
/dimensions/0/greenacre_percent | tolerance | 82.261919680346423 | 82.26191968034644 | 1.46E-14 | 15 | passed |
/dimensions/1/inertia | tolerance | 0.44390943878601746 | 0.44390943878601746 | 2.86E-18 | 17 | passed |
/dimensions/1/raw_percent | tolerance | 22.195471939300873 | 22.195471939300873 | 3.22E-17 | 17 | passed |
/dimensions/1/cumulative_percent | tolerance | 57.760428778671205 | 57.76042877867123 | 2.84E-14 | 15 | passed |
/dimensions/1/adjusted | tolerance | 0.027510918968437031 | 0.02751091896843703 | 2.54E-19 | 17 | passed |
/dimensions/1/benzecri_percent | tolerance | 7.8780742498638938 | 7.8780742498638645 | 2.93E-14 | 14 | passed |
/dimensions/1/greenacre_percent | tolerance | 7.0407091198843972 | 7.04070911988437 | 2.76E-14 | 14 | passed |
/dimensions/2/inertia | tolerance | 0.34422522814707918 | 0.3442252281470789 | 2.81E-16 | 15 | passed |
/dimensions/2/raw_percent | tolerance | 17.211261407353959 | 17.211261407353945 | 1.43E-14 | 15 | passed |
/dimensions/2/cumulative_percent | tolerance | 74.971690186025171 | 74.97169018602519 | 1.42E-14 | 15 | passed |
/dimensions/2/adjusted | tolerance | 0.00026692508842583398 | 0.0002669250884258204 | 1.36E-17 | 13 | passed |
/dimensions/2/benzecri_percent | tolerance | 0.076437129133446552 | 0.07643712913344237 | 4.18E-15 | 13 | passed |
/dimensions/2/greenacre_percent | tolerance | 0.068312581872014763 | 0.068312581872011 | 3.76E-15 | 13 | passed |
/dimensions/3/inertia | tolerance | 0.27368001013187188 | 0.273680010131872 | 1.07E-16 | 15 | passed |
/dimensions/3/raw_percent | tolerance | 13.684000506593593 | 13.6840005065936 | 7.12E-15 | 15 | passed |
/dimensions/3/cumulative_percent | tolerance | 88.655690692618748 | 88.65569069261878 | 2.84E-14 | 15 | passed |
/dimensions/3/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/inertia | tolerance | 0.16358297549457104 | 0.16358297549457104 | 2.36E-18 | 16 | passed |
/dimensions/4/raw_percent | tolerance | 8.179148774728553 | 8.179148774728553 | 4.92E-17 | 17 | passed |
/dimensions/4/cumulative_percent | tolerance | 96.834839467347294 | 96.83483946734734 | 4.25E-14 | 15 | passed |
/dimensions/4/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/5/inertia | tolerance | 0.063303210653052833 | 0.0633032106530528 | 2.81E-17 | 15 | passed |
/dimensions/5/raw_percent | tolerance | 3.1651605326526417 | 3.1651605326526404 | 1.29E-15 | 15 | passed |
/dimensions/5/cumulative_percent | tolerance | 99.999999999999943 | 99.99999999999997 | 2.86E-14 | 15 | passed |
/dimensions/5/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/5/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/5/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/categories_table/0/variable | exact | region | region | passed | ||
/categories_table/0/category | exact | north | north | passed | ||
/categories_table/0/count | exact | 12 | 12 | 0.00E+2 | passed | |
/categories_table/0/mass | tolerance | 0.16666666666666666 | 0.16666666666666666 | 2.59E-18 | 16 | passed |
/categories_table/0/contributions/0 | tolerance | 0.074742262242852825 | 0.07474226224285295 | 1.25E-16 | 14 | passed |
/categories_table/0/cosine_squared/0 | tolerance | 0.31898463968927487 | 0.31898463968927604 | 1.17E-15 | 14 | passed |
/categories_table/0/contributions/1 | tolerance | 0.0011382018453075051 | 0.0011382018453075012 | 3.88E-18 | 14 | passed |
/categories_table/0/cosine_squared/1 | tolerance | 0.0030315512542539828 | 0.003031551254253975 | 7.77E-18 | 14 | passed |
/categories_table/1/variable | exact | region | region | passed | ||
/categories_table/1/category | exact | south | south | passed | ||
/categories_table/1/count | exact | 6 | 6 | 0.00E+2 | passed | |
/categories_table/1/mass | tolerance | 0.083333333333333329 | 0.08333333333333333 | 2.93E-19 | 17 | passed |
/categories_table/1/contributions/0 | tolerance | 0.013814270938747016 | 0.013814270938746964 | 5.21E-17 | 14 | passed |
/categories_table/1/cosine_squared/0 | tolerance | 0.039304315976312447 | 0.03930431597631233 | 1.18E-16 | 14 | passed |
/categories_table/1/contributions/1 | tolerance | 0.20405477836013677 | 0.20405477836013702 | 2.54E-16 | 14 | passed |
/categories_table/1/cosine_squared/1 | tolerance | 0.36232736857381409 | 0.36232736857381437 | 2.78E-16 | 15 | passed |
/categories_table/2/variable | exact | region | region | passed | ||
/categories_table/2/category | exact | west | west | passed | ||
/categories_table/2/count | exact | 5 | 5 | 0.00E+2 | passed | |
/categories_table/2/mass | tolerance | 0.069444444444444448 | 0.06944444444444445 | 4.72E-19 | 17 | passed |
/categories_table/2/contributions/0 | tolerance | 0.15765784357648305 | 0.15765784357648316 | 1.09E-16 | 15 | passed |
/categories_table/2/cosine_squared/0 | tolerance | 0.42495873363934689 | 0.4249587336393469 | 3.84E-18 | 17 | passed |
/categories_table/2/contributions/1 | tolerance | 0.19712565506252139 | 0.19712565506252222 | 8.30E-16 | 14 | passed |
/categories_table/2/cosine_squared/1 | tolerance | 0.3316014527082824 | 0.3316014527082832 | 7.73E-16 | 14 | passed |
/categories_table/3/variable | exact | region | region | passed | ||
/categories_table/3/category | exact | (missing value) | (missing value) | passed | ||
/categories_table/3/count | exact | 1 | 1 | 0.00E+2 | passed | |
/categories_table/3/mass | tolerance | 0.013888888888888888 | 0.013888888888888888 | 1.18E-19 | 17 | passed |
/categories_table/3/contributions/0 | tolerance | 0.052305221976661521 | 0.052305221976661605 | 8.37E-17 | 14 | passed |
/categories_table/3/cosine_squared/0 | tolerance | 0.11646675936461125 | 0.11646675936461161 | 3.58E-16 | 14 | passed |
/categories_table/3/contributions/1 | tolerance | 0.053164823153031456 | 0.05316482315303104 | 4.17E-16 | 14 | passed |
/categories_table/3/cosine_squared/1 | tolerance | 0.073879409141280217 | 0.07387940914127966 | 5.55E-16 | 14 | passed |
/categories_table/4/variable | exact | size | size | passed | ||
/categories_table/4/category | exact | large | large | passed | ||
/categories_table/4/count | exact | 12 | 12 | 0.00E+2 | passed | |
/categories_table/4/mass | tolerance | 0.16666666666666666 | 0.16666666666666666 | 2.59E-18 | 16 | passed |
/categories_table/4/contributions/0 | tolerance | 0.14535253221361205 | 0.145352532213612 | 5.43E-17 | 15 | passed |
/categories_table/4/cosine_squared/0 | tolerance | 0.62033478416043619 | 0.6203347841604362 | 2.30E-18 | 17 | passed |
/categories_table/4/contributions/1 | tolerance | 0.0076360469570681483 | 0.007636046957068293 | 1.45E-16 | 13 | passed |
/categories_table/4/cosine_squared/1 | tolerance | 0.020338279915534805 | 0.020338279915535176 | 3.71E-16 | 13 | passed |
/categories_table/5/variable | exact | size | size | passed | ||
/categories_table/5/category | exact | small | small | passed | ||
/categories_table/5/count | exact | 12 | 12 | 0.00E+2 | passed | |
/categories_table/5/mass | tolerance | 0.16666666666666666 | 0.16666666666666666 | 2.59E-18 | 16 | passed |
/categories_table/5/contributions/0 | tolerance | 0.14535253221361208 | 0.145352532213612 | 8.43E-17 | 15 | passed |
/categories_table/5/cosine_squared/0 | tolerance | 0.6203347841604363 | 0.6203347841604361 | 2.19E-16 | 15 | passed |
/categories_table/5/contributions/1 | tolerance | 0.0076360469570680945 | 0.007636046957068238 | 1.43E-16 | 13 | passed |
/categories_table/5/cosine_squared/1 | tolerance | 0.020338279915534663 | 0.020338279915535024 | 3.61E-16 | 13 | passed |
/categories_table/6/variable | exact | grade | grade | passed | ||
/categories_table/6/category | exact | A | A | passed | ||
/categories_table/6/count | exact | 10 | 10 | 0.00E+2 | passed | |
/categories_table/6/mass | tolerance | 0.1388888888888889 | 0.1388888888888889 | 4.94E-18 | 16 | passed |
/categories_table/6/contributions/0 | tolerance | 0.22281047271724516 | 0.22281047271724527 | 1.13E-16 | 15 | passed |
/categories_table/6/cosine_squared/0 | tolerance | 0.81506518411356321 | 0.8150651841135634 | 2.25E-16 | 15 | passed |
/categories_table/6/contributions/1 | tolerance | 0.026278464985288127 | 0.026278464985288158 | 3.10E-17 | 14 | passed |
/categories_table/6/cosine_squared/1 | tolerance | 0.059992758739425986 | 0.05999275873942598 | 7.02E-18 | 15 | passed |
/categories_table/7/variable | exact | grade | grade | passed | ||
/categories_table/7/category | exact | B | B | passed | ||
/categories_table/7/count | exact | 4 | 4 | 0.00E+2 | passed | |
/categories_table/7/mass | tolerance | 0.055555555555555552 | 0.05555555555555555 | 4.72E-19 | 17 | passed |
/categories_table/7/contributions/0 | tolerance | 0.004868820376099499 | 0.004868820376099462 | 3.73E-17 | 14 | passed |
/categories_table/7/cosine_squared/0 | tolerance | 0.012467475830493024 | 0.012467475830492932 | 9.22E-17 | 14 | passed |
/categories_table/7/contributions/1 | tolerance | 0.43735173392460425 | 0.43735173392460486 | 6.07E-16 | 14 | passed |
/categories_table/7/cosine_squared/1 | tolerance | 0.69892042593082515 | 0.6989204259308256 | 4.45E-16 | 15 | passed |
/categories_table/8/variable | exact | grade | grade | passed | ||
/categories_table/8/category | exact | C | C | passed | ||
/categories_table/8/count | exact | 10 | 10 | 0.00E+2 | passed | |
/categories_table/8/mass | tolerance | 0.1388888888888889 | 0.1388888888888889 | 4.94E-18 | 16 | passed |
/categories_table/8/contributions/0 | tolerance | 0.18309604374468685 | 0.18309604374468688 | 3.16E-17 | 15 | passed |
/categories_table/8/cosine_squared/0 | tolerance | 0.66978544044746635 | 0.6697854404474668 | 4.46E-16 | 15 | passed |
/categories_table/8/contributions/1 | tolerance | 0.065614248754973944 | 0.06561424875497394 | 4.89E-19 | 17 | passed |
/categories_table/8/cosine_squared/1 | tolerance | 0.1497948908975314 | 0.1497948908975313 | 8.69E-17 | 15 | passed |
/incomplete_count | exact | 0 | 0 | 0.00E+2 | passed | |
/categories_table/3/is_missing | exact | True | True | passed |
Convention
- The missing region is recoded as the category '(missing value)' before ca::mjca, so all 24 rows are active and region has four categories (J = 9).
- The product lists the missing category last within its variable; the recoded label sorts after the text categories in R as well (asserted by the index used).
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:100-107: simple CA of the complete indicator matrix; with Q variables and J active categories the raw inertias sum to (J - Q)/Q; contributions and representation quality follow simple CA; supplementary variables are projected after fitting.
- docs/manual/chapters/92-dimensions-and-categories.tex:109-112: missing values are excluded or form a distinct category by the declared option; empty active categories are removed.
- docs/manual/chapters/92-dimensions-and-categories.tex:115-124: Benzecri keeps lambda_s > 1/Q and reports a_s = [Q/(Q-1) (lambda_s - 1/Q)]^2; Greenacre's percentages use a different adjusted total; the map uses the raw principal coordinates.
Reference code
The lines of the reference script that produce this case's expected values.
195 d_missing <- d
196 d_missing$region[is.na(d_missing$region)] <- "(missing value)"
197 ref <- mca_reference(d_missing, active)
198 stopifnot(ref$N == 24, any(grepl("(missing value)", ref$names, fixed = TRUE)))
199 missing_index <- which(ref$names == "region:(missing value)")
200 outputs <- outputs_for(ref, 2L)
201 outputs[["/incomplete_count"]] <- exact(0L, "the missing region is a category, so no row is incomplete")
202 outputs[[sprintf("/categories_table/%d/is_missing", missing_index - 1L)]] <- exact(TRUE, "the typed missing category")
203 emit("STAT-MV-MCA-MISSING-001", "Indicator MCA with missing values as a category", "missing_excluded",
204 list(columns = list("region", "size", "grade"), missing = "category", dimensions = 2L),
205 outputs,
206 list("The missing region is recoded as the category '(missing value)' before ca::mjca, so all 24 rows are active and region has four categories (J = 9).",
207 "The product lists the missing category last within its variable; the recoded label sorts after the text categories in R as well (asserted by the index used)."))
Indicator MCA with a supplementary variable
Case STAT-MV-MCA-SUPP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R ca::mjca (lambda = 'indicator' and 'adjusted') with the textbook supplementary projection
- Citation
- Nenadic and Greenacre (2007), Correspondence analysis in R, with two- and three-dimensional graphics: the ca package, Journal of Statistical Software 20(3); Greenacre (2007) Correspondence Analysis in Practice, 2nd ed., chapters 18-19.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · ca 0.72, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_mca.R · sha256 6edebdab7f958ce0
- Dataset
- reference_data/datasets/MV_MCA.json
Settings compared
columns= ["region", "size", "grade"]dimensions= 1missing= "complete"supplementary= ["sector"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows_analysed | exact | 23 | 23 | 0.00E+2 | passed | |
/variables | exact | 3 | 3 | 0.00E+2 | passed | |
/categories | exact | 8 | 8 | 0.00E+2 | passed | |
/total_inertia | tolerance | 1.6666666666666667 | 1.6666666666666667 | 4.07E-17 | 16 | passed |
/greenacre_denominator | tolerance | 0.35704264870931429 | 0.35704264870931596 | 1.67E-15 | 14 | passed |
/dimensions/0/inertia | tolerance | 0.69147973494866888 | 0.6914797349486692 | 3.31E-16 | 15 | passed |
/dimensions/0/raw_percent | tolerance | 41.488784096920135 | 41.48878409692015 | 1.41E-14 | 15 | passed |
/dimensions/0/cumulative_percent | tolerance | 41.488784096920128 | 41.48878409692015 | 2.11E-14 | 15 | passed |
/dimensions/0/adjusted | tolerance | 0.2886049012275298 | 0.2886049012275303 | 4.97E-16 | 14 | passed |
/dimensions/0/benzecri_percent | tolerance | 92.464433828814563 | 92.46443382881453 | 2.81E-14 | 15 | passed |
/dimensions/0/greenacre_percent | tolerance | 80.83205249311743 | 80.8320524931172 | 2.27E-13 | 14 | passed |
/dimensions/1/inertia | tolerance | 0.43557576703933387 | 0.43557576703933426 | 3.91E-16 | 15 | passed |
/dimensions/1/raw_percent | tolerance | 26.134546022360031 | 26.134546022360055 | 2.44E-14 | 15 | passed |
/dimensions/1/cumulative_percent | tolerance | 67.623330119280155 | 67.62333011928021 | 5.66E-14 | 15 | passed |
/dimensions/1/adjusted | tolerance | 0.023520409312783316 | 0.023520409312783496 | 1.80E-16 | 14 | passed |
/dimensions/1/benzecri_percent | tolerance | 7.5355661711854323 | 7.535566171185475 | 4.26E-14 | 14 | passed |
/dimensions/1/greenacre_percent | tolerance | 6.5875629698043214 | 6.587562969804342 | 2.05E-14 | 14 | passed |
/dimensions/2/inertia | tolerance | 0.30519949016143977 | 0.3051994901614402 | 4.42E-16 | 14 | passed |
/dimensions/2/raw_percent | tolerance | 18.311969409686384 | 18.311969409686412 | 2.83E-14 | 14 | passed |
/dimensions/2/cumulative_percent | tolerance | 85.935299528966553 | 85.93529952896662 | 7.09E-14 | 15 | passed |
/dimensions/2/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/2/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/2/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/inertia | tolerance | 0.16766557359392817 | 0.1676655735939283 | 1.38E-16 | 15 | passed |
/dimensions/3/raw_percent | tolerance | 10.05993441563569 | 10.059934415635698 | 8.46E-15 | 15 | passed |
/dimensions/3/cumulative_percent | tolerance | 95.995233944602234 | 95.99523394460232 | 8.48E-14 | 15 | passed |
/dimensions/3/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/3/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/inertia | tolerance | 0.066746100923294915 | 0.06674610092329483 | 8.29E-17 | 14 | passed |
/dimensions/4/raw_percent | tolerance | 4.0047660553976945 | 4.00476605539769 | 4.46E-15 | 14 | passed |
/dimensions/4/cumulative_percent | tolerance | 99.999999999999929 | 100.0 | 7.10E-14 | 15 | passed |
/dimensions/4/adjusted | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/benzecri_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dimensions/4/greenacre_percent | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/categories_table/0/variable | exact | region | region | passed | ||
/categories_table/0/category | exact | north | north | passed | ||
/categories_table/0/count | exact | 12 | 12 | 0.00E+2 | passed | |
/categories_table/0/mass | tolerance | 0.17391304347826086 | 0.17391304347826086 | 4.74E-18 | 16 | passed |
/categories_table/0/coordinates | sign_invariant_sequence | ['-0.6720753766050902'] | [-0.6720753766050903] | passed | ||
/categories_table/0/contributions/0 | tolerance | 0.11360270345761794 | 0.1136027034576179 | 3.88E-17 | 15 | passed |
/categories_table/0/cosine_squared/0 | tolerance | 0.49274761291513569 | 0.4927476129151354 | 2.77E-16 | 15 | passed |
/categories_table/1/variable | exact | region | region | passed | ||
/categories_table/1/category | exact | south | south | passed | ||
/categories_table/1/count | exact | 6 | 6 | 0.00E+2 | passed | |
/categories_table/1/mass | tolerance | 0.086956521739130432 | 0.08695652173913043 | 3.69E-19 | 17 | passed |
/categories_table/1/coordinates | sign_invariant_sequence | ['0.2803953059208964'] | [0.2803953059208986] | passed | ||
/categories_table/1/contributions/0 | tolerance | 0.0098869919490792799 | 0.009886991949079433 | 1.53E-16 | 13 | passed |
/categories_table/1/cosine_squared/0 | tolerance | 0.02774877444087288 | 0.027748774440873213 | 3.33E-16 | 13 | passed |
/categories_table/2/variable | exact | region | region | passed | ||
/categories_table/2/category | exact | west | west | passed | ||
/categories_table/2/count | exact | 5 | 5 | 0.00E+2 | passed | |
/categories_table/2/mass | tolerance | 0.072463768115942032 | 0.07246376811594203 | 4.00E-19 | 17 | passed |
/categories_table/2/coordinates | sign_invariant_sequence | ['1.2765065367471409'] | [1.2765065367471402] | passed | ||
/categories_table/2/contributions/0 | tolerance | 0.17076054920117464 | 0.17076054920117437 | 2.74E-16 | 14 | passed |
/categories_table/2/cosine_squared/0 | tolerance | 0.45263026065504974 | 0.4526302606550491 | 6.63E-16 | 14 | passed |
/categories_table/8/variable | exact | sector | sector | passed | ||
/categories_table/8/category | exact | mixed | mixed | passed | ||
/categories_table/8/count | exact | 7 | 7 | 0.00E+2 | passed | |
/categories_table/8/supplementary | exact | True | True | passed | ||
/categories_table/8/coordinates | sign_invariant_sequence | ['-0.086904046842107105'] | [-0.08690404684210698] | passed | ||
/categories_table/9/variable | exact | sector | sector | passed | ||
/categories_table/9/category | exact | private | private | passed | ||
/categories_table/9/count | exact | 9 | 9 | 0.00E+2 | passed | |
/categories_table/9/supplementary | exact | True | True | passed | ||
/categories_table/9/coordinates | sign_invariant_sequence | ['-0.14174653089154446'] | [-0.14174653089154457] | passed | ||
/categories_table/10/variable | exact | sector | sector | passed | ||
/categories_table/10/category | exact | public | public | passed | ||
/categories_table/10/count | exact | 7 | 7 | 0.00E+2 | passed | |
/categories_table/10/supplementary | exact | True | True | passed | ||
/categories_table/10/coordinates | sign_invariant_sequence | ['0.26914958655980725'] | [0.269149586559807] | passed |
Convention
- The active fit is that of STAT-MV-MCA-001; each sector category is projected as the average of the standard row coordinates (D_r^-1/2 U) of the complete rows holding it, which is the simple-CA supplementary-column principal coordinate.
- Supplementary categories follow the active ones in the categories table, variable by variable, categories sorted; one dimension is requested so the single coordinate is compared up to the axis sign.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:100-107: simple CA of the complete indicator matrix; with Q variables and J active categories the raw inertias sum to (J - Q)/Q; contributions and representation quality follow simple CA; supplementary variables are projected after fitting.
- docs/manual/chapters/92-dimensions-and-categories.tex:109-112: missing values are excluded or form a distinct category by the declared option; empty active categories are removed.
- docs/manual/chapters/92-dimensions-and-categories.tex:115-124: Benzecri keeps lambda_s > 1/Q and reports a_s = [Q/(Q-1) (lambda_s - 1/Q)]^2; Greenacre's percentages use a different adjusted total; the map uses the raw principal coordinates.
Reference code
The lines of the reference script that produce this case's expected values.
223 emit("STAT-MV-MCA-SUPP-001", "Indicator MCA with a supplementary variable", "axis_coverage",
224 list(columns = list("region", "size", "grade"), supplementary = list("sector"),
225 missing = "complete", dimensions = 1L),
226 outputs,
227 list("The active fit is that of STAT-MV-MCA-001; each sector category is projected as the average of the standard row coordinates (D_r^-1/2 U) of the complete rows holding it, which is the simple-CA supplementary-column principal coordinate.",
228 "Supplementary categories follow the active ones in the categories table, variable by variable, categories sorted; one dimension is requested so the single coordinate is compared up to the axis sign."))
Gaussian mixture with diagonal covariance, K chosen by BIC
Case STAT-MV-MCLUST-001 · status: passed
Reference
- Evidence type
- R
- Source
- R mclust::Mclust (VVI/VVV) with emControl(tol = 1e-12); cluster::silhouette
- Citation
- Scrucca, Fop, Murphy and Raftery (2016) mclust 5: clustering, classification and density estimation using Gaussian finite mixture models, The R Journal 8(1); Rousseeuw (1987) Silhouettes, J. Comput. Appl. Math. 20.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · mclust 6.1.3, cluster 2.1.8.2, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_model_clustering.R · sha256 b03bbb2bfb4448e9
- Dataset
- reference_data/datasets/MV_MIXTURE.json
Settings compared
covariance= "diagonal"k_max= 3k_min= 1kind= "gaussian"variables= ["length", "width"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 29 | 29 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/chosen_k | exact | 2 | 2 | 0.00E+2 | passed | |
/fits/[k=1]/status | exact | fitted | fitted | passed | ||
/fits/[k=1]/parameters | exact | 4 | 4 | 0.00E+2 | passed | |
/fits/[k=1]/log_likelihood | tolerance | -141.10473027092343 | -141.10473027093894 | 1.55E-11 | 12 | passed |
/fits/[k=1]/bic | tolerance | 295.67864386179275 | 295.6786438618238 | 3.10E-11 | 12 | passed |
/fits/[k=2]/status | exact | fitted | fitted | passed | ||
/fits/[k=2]/parameters | exact | 9 | 9 | 0.00E+2 | passed | |
/fits/[k=2]/log_likelihood | tolerance | -85.931249845434138 | -85.93124985076292 | 5.33E-9 | 10 | passed |
/fits/[k=2]/bic | tolerance | 202.16816216074653 | 202.1681621714041 | 1.07E-8 | 10 | passed |
/silhouette | tolerance | 0.79708227153050248 | 0.7970822715305025 | 4.15E-18 | 17 | passed |
Convention
- mclust::Mclust(G = 2, modelNames = 'VVI') on the 29 complete rows; VVI is the per-component diagonal covariance model. K = 1 in closed form. The K = 3 fit is a local optimum question and is not compared; the BIC choice of K = 2 is.
- Cluster numbering is arbitrary, so per-cluster profiles are not addressed by index; the hard partition is checked through its mean silhouette (cluster::silhouette on the mclust classification, which is the two true clusters).
- Log-likelihoods and BIC are compared at 1e-7 relative: both EM runs converge to the same optimum on well-separated clusters (mclust tol 1e-12; the product stops at a 1e-8 change per observation and regularizes each component variance by 1e-6 times the sample variance, a second-order effect at the maximum).
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:93-99: a Gaussian mixture uses diagonal covariance by default with a full-covariance option; a latent class model uses conditional independence of categorical variables within each class.
- docs/manual/chapters/90-learning-and-mixtures.tex:101-112: L = prod_i sum_g pi_g f_g(y_i); the default search fits K from 10 seeded starts per K and chooses the smallest BIC = -2 log L + m log n, m the number of free parameters; the selected fit is the best converged start, not a proven global maximum.
Reference code
The lines of the reference script that produce this case's expected values.
23 emit <- function(id, title, kind, dataset, configuration, outputs, notes, source, citation) {
24 expected <- list(schema_version = "2.0.0", case_id = id, outputs = outputs,
25 expected_error = NULL, deferred_outputs = list(), generator_run = run)
26 write_expected("multivariate", id, expected)
27 case <- list(
28 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "multivariate",
29 entry_point = "tabelz.analysis.model_based_clustering:compute_model_clustering",
30 menu_items = list("modelClusteringMenuItem"), title = title, case_kind = kind,
31 dataset = list(path = paste0("reference_data/datasets/", dataset, ".json"), sha256 = ""),
32 excluded_rows = list(), configuration = configuration, "repeat" = 1L,
33 expected = list(path = paste0("reference_data/expected/multivariate/", id, ".json"),
34 sha256 = ""),
35 oracle = list(oracle_class = "independent_implementation", source = source,
36 citation = citation,
37 generator = list(path = "generators/r/multivariate_model_clustering.R",
38 sha256 = ""),
39 independent = TRUE,
40 convention_notes = c(notes, "Expected computed from the exported CSV.", manual)),
41 supported = TRUE, unsupported_reason = NULL,
42 requirement_ids = list("REQ-STAT-MV-MCLUST-001"), risk_ids = list("RISK-REFERENCE-001"),
43 review_reference = NULL
44 )
45 write_case("multivariate", id, case)
Gaussian mixture with full covariance, two components
Case STAT-MV-MCLUST-FULL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R mclust::Mclust (VVI/VVV) with emControl(tol = 1e-12); cluster::silhouette
- Citation
- Scrucca, Fop, Murphy and Raftery (2016) mclust 5: clustering, classification and density estimation using Gaussian finite mixture models, The R Journal 8(1); Rousseeuw (1987) Silhouettes, J. Comput. Appl. Math. 20.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · mclust 6.1.3, cluster 2.1.8.2, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_model_clustering.R · sha256 b03bbb2bfb4448e9
- Dataset
- reference_data/datasets/MV_MIXTURE.json
Settings compared
covariance= "full"k_max= 2k_min= 2kind= "gaussian"variables= ["length", "width"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 29 | 29 | 0.00E+2 | passed | |
/chosen_k | exact | 2 | 2 | 0.00E+2 | passed | |
/fits/[k=2]/parameters | exact | 11 | 11 | 0.00E+2 | passed | |
/fits/[k=2]/log_likelihood | tolerance | -83.1922537990433 | -83.19225381250631 | 1.35E-8 | 9 | passed |
/fits/[k=2]/bic | tolerance | 203.42476172793781 | 203.42476175486382 | 2.69E-8 | 9 | passed |
Convention
- mclust::Mclust(G = 2, modelNames = 'VVV') on the 29 complete rows; VVV is the unrestricted per-component covariance model.
- Log-likelihoods and BIC are compared at 1e-7 relative: both EM runs converge to the same optimum on well-separated clusters (mclust tol 1e-12; the product stops at a 1e-8 change per observation and regularizes each component variance by 1e-6 times the sample variance, a second-order effect at the maximum).
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:93-99: a Gaussian mixture uses diagonal covariance by default with a full-covariance option; a latent class model uses conditional independence of categorical variables within each class.
- docs/manual/chapters/90-learning-and-mixtures.tex:101-112: L = prod_i sum_g pi_g f_g(y_i); the default search fits K from 10 seeded starts per K and chooses the smallest BIC = -2 log L + m log n, m the number of free parameters; the selected fit is the best converged start, not a proven global maximum.
Reference code
The lines of the reference script that produce this case's expected values.
119 outputs <- list(
120 "/n" = exact(n, "complete rows"),
121 "/chosen_k" = exact(2L, "the only K in the range"),
122 "/fits/[k=2]/parameters" = exact(m2f, "K - 1 + K p means + K p(p+1)/2 covariances"),
123 "/fits/[k=2]/log_likelihood" = tol(fit2_full$loglik, "mclust VVV (full, varying) log-likelihood", rel = "1e-7"),
124 "/fits/[k=2]/bic" = tol(bic_of(fit2_full$loglik, m2f, n), "-2 log L + m log n", rel = "1e-7")
125 )
126 emit("STAT-MV-MCLUST-FULL-001", "Gaussian mixture with full covariance, two components", "axis_coverage",
127 "MV_MIXTURE",
128 list(variables = list("length", "width"), kind = "gaussian", covariance = "full",
129 k_min = 2L, k_max = 2L),
130 outputs,
131 list("mclust::Mclust(G = 2, modelNames = 'VVV') on the 29 complete rows; VVV is the unrestricted per-component covariance model.", em_note),
132 mclust_source, mclust_citation)
One-component Gaussian fit in closed form
Case STAT-MV-MCLUST-ONE-001 · status: passed
Reference
- Evidence type
- R
- Source
- closed-form Gaussian maximum likelihood (base R dnorm)
- Citation
- Scrucca, Fop, Murphy and Raftery (2016) mclust 5: clustering, classification and density estimation using Gaussian finite mixture models, The R Journal 8(1); Rousseeuw (1987) Silhouettes, J. Comput. Appl. Math. 20.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · mclust 6.1.3, cluster 2.1.8.2, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_model_clustering.R · sha256 b03bbb2bfb4448e9
- Dataset
- reference_data/datasets/MV_MIXTURE.json
Settings compared
covariance= "diagonal"k_max= 1k_min= 1kind= "gaussian"variables= ["length", "width"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 29 | 29 | 0.00E+2 | passed | |
/chosen_k | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[k=1]/parameters | exact | 4 | 4 | 0.00E+2 | passed | |
/fits/[k=1]/log_likelihood | tolerance | -141.10473027092343 | -141.10473027093894 | 1.55E-11 | 12 | passed |
/fits/[k=1]/bic | tolerance | 295.67864386179275 | 295.6786438618238 | 3.10E-11 | 12 | passed |
/profiles/0/size | exact | 29 | 29 | 0.00E+2 | passed | |
/profiles/0/weight | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/profiles/0/means | sequence | ['15.077999999999999', '3.4384482758620689'] | [15.078, 3.4384482758620685] | passed | ||
/profiles/0/variances | sequence | ['21.299738620689656', '2.7099001093935793'] | [21.299760681133222, 2.7099029160758374] | passed |
Convention
- With one component EM is the Gaussian MLE: means are the sample means and variances the population (1/n) variances; log L = sum_j sum_i log N(x_ij; mean_j, var_j).
- The product's variance floor (1e-6 times the sample variance) perturbs the variances at 1e-6 relative and the log-likelihood only to second order.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:93-99: a Gaussian mixture uses diagonal covariance by default with a full-covariance option; a latent class model uses conditional independence of categorical variables within each class.
- docs/manual/chapters/90-learning-and-mixtures.tex:101-112: L = prod_i sum_g pi_g f_g(y_i); the default search fits K from 10 seeded starts per K and chooses the smallest BIC = -2 log L + m log n, m the number of free parameters; the selected fit is the best converged start, not a proven global maximum.
Reference code
The lines of the reference script that produce this case's expected values.
134 outputs <- list(
135 "/n" = exact(n, "complete rows"),
136 "/chosen_k" = exact(1L, "the only K in the range"),
137 "/fits/[k=1]/parameters" = exact(m1, "p means and p variances"),
138 "/fits/[k=1]/log_likelihood" = tol(fit1, "closed-form Gaussian log-likelihood with MLE variances", rel = "1e-9"),
139 "/fits/[k=1]/bic" = tol(bic_of(fit1, m1, n), "-2 log L + m log n", rel = "1e-9"),
140 "/profiles/0/size" = exact(n, "every row in the single cluster"),
141 "/profiles/0/weight" = tol(1, "single component weight"),
142 "/profiles/0/means" = list(comparison = "sequence", values = as.list(dec(colMeans(x))),
143 absolute_tolerance = "0", relative_tolerance = "1e-9",
144 rationale = "sample means"),
145 "/profiles/0/variances" = list(comparison = "sequence",
146 values = as.list(dec(apply(x, 2, function(v) mean((v - mean(v))^2)))),
147 absolute_tolerance = "0", relative_tolerance = "1e-5",
148 rationale = "MLE variances; the product adds 1e-6 times the sample variance as a floor, hence 1e-5 relative")
149 )
150 emit("STAT-MV-MCLUST-ONE-001", "One-component Gaussian fit in closed form", "boundary",
151 "MV_MIXTURE",
152 list(variables = list("length", "width"), kind = "gaussian", covariance = "diagonal",
153 k_min = 1L, k_max = 1L),
154 outputs,
155 list("With one component EM is the Gaussian MLE: means are the sample means and variances the population (1/n) variances; log L = sum_j sum_i log N(x_ij; mean_j, var_j).",
156 "The product's variance floor (1e-6 times the sample variance) perturbs the variances at 1e-6 relative and the log-likelihood only to second order."),
157 "closed-form Gaussian maximum likelihood (base R dnorm)", mclust_citation)
Classical scaling of unstandardized city-block distances
Case STAT-MV-MDS-CITYBLOCK-001 · status: passed
Reference
- Evidence type
- R
- Source
- Retained R reference with independently reviewed analytical corrections
- Citation
- R Core Team, stats package help: cmdscale (classical multidimensional scaling, Torgerson 1958; Mardia 1978 goodness-of-fit ratios).
- Reference software
- not recorded
- Reference script
- generators/analytic/reviewed_reference_corrections.py · sha256 49e3645836bb3ac3
- Dataset
- reference_data/datasets/MV_MDS_VARS.json
Settings compared
columns= ["v1", "v2", "v3", "v4"]dimensions= 2distance= "cityblock"labels= "unit"model= "classical"objects= "rows"source= "variables"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/dimensions | exact | 2 | 2 | 0.00E+2 | passed | |
/gof_absolute | tolerance | 0.77648601818926577 | 0.7764860181892658 | 2.16E-19 | 18 | passed |
/gof_positive | tolerance | 0.80622498855062619 | 0.8062249885506262 | 2.94E-18 | 17 | passed |
/eigenvalues/0/eigenvalue | tolerance | 672.92730338881984 | 672.9273033888214 | 1.59E-12 | 14 | passed |
/eigenvalues/0/retained | exact | True | True | passed | ||
/eigenvalues/1/eigenvalue | tolerance | 220.23034351850265 | 220.23034351850256 | 8.52E-14 | 15 | passed |
/eigenvalues/1/retained | exact | True | True | passed | ||
/eigenvalues/2/eigenvalue | tolerance | 103.26657434760966 | 103.26657434760997 | 3.15E-13 | 14 | passed |
/eigenvalues/2/retained | exact | False | False | passed | ||
/eigenvalues/3/eigenvalue | tolerance | 47.978061528996101 | 47.978061528996044 | 5.73E-14 | 14 | passed |
/eigenvalues/3/retained | exact | False | False | passed | ||
/eigenvalues/4/eigenvalue | tolerance | 40.042254352976066 | 40.04225435297619 | 1.21E-13 | 14 | passed |
/eigenvalues/4/retained | exact | False | False | passed | ||
/eigenvalues/5/eigenvalue | tolerance | 11.724877076814344 | 11.724877076814348 | 3.99E-15 | 15 | passed |
/eigenvalues/5/retained | exact | False | False | passed | ||
/eigenvalues/6/eigenvalue | tolerance | 8.5050398118695938 | 8.505039811869537 | 5.69E-14 | 14 | passed |
/eigenvalues/6/retained | exact | False | False | passed | ||
/eigenvalues/7/eigenvalue | tolerance | 3.1523431975760516 | 3.152343197576012 | 3.95E-14 | 13 | passed |
/eigenvalues/7/retained | exact | False | False | passed | ||
/eigenvalues/8/eigenvalue | tolerance | 0 | 4.3955782049271525e-14 | 4.40E-14 | passed | |
/eigenvalues/8/retained | exact | False | False | passed | ||
/eigenvalues/9/eigenvalue | tolerance | -5.6757617106128926 | -5.675761710612848 | 4.44E-14 | 14 | passed |
/eigenvalues/9/retained | exact | False | False | passed | ||
/eigenvalues/10/eigenvalue | tolerance | -36.753370967098888 | -36.75337096709894 | 5.01E-14 | 14 | passed |
/eigenvalues/10/retained | exact | False | False | passed | ||
/objects/0/coordinates | sequence | ['-2.4812798330800709', '0.96146365911720877'] | [-2.481279833080072, 0.9614636591172209] | passed | ||
/objects/1/coordinates | sequence | ['-2.3398777387581386', '3.2911253455489216'] | [-2.339877738758127, 3.2911253455489122] | passed | ||
/objects/2/coordinates | sequence | ['-7.5094623984637865', '-6.6449895970314827'] | [-7.509462398463808, -6.644989597031502] | passed | ||
/objects/3/coordinates | sequence | ['-3.3602813813003882', '6.5050248763842085'] | [-3.3602813813003864, 6.505024876384214] | passed | ||
/objects/4/coordinates | sequence | ['15.65097061757503', '-4.0860336047804982'] | [15.650970617575078, -4.086033604780502] | passed | ||
/objects/5/coordinates | sequence | ['13.681419646746303', '-0.99803533480064366'] | [13.681419646746315, -0.9980353348006439] | passed | ||
/objects/6/coordinates | sequence | ['-5.0457743355063336', '1.7188593431388968'] | [-5.045774335506331, 1.7188593431389114] | passed | ||
/objects/7/coordinates | sequence | ['-5.8608029962304009', '-3.7384024046778119'] | [-5.860802996230433, -3.7384024046778315] | passed | ||
/objects/8/coordinates | sequence | ['5.4844362976911167', '0.25928400704953908'] | [5.484436297691114, 0.25928400704950566] | passed | ||
/objects/9/coordinates | sequence | ['-8.4577282722636529', '-5.0987820796134891'] | [-8.457728272263664, -5.098782079613489] | passed | ||
/objects/10/coordinates | sequence | ['0.238380393590328', '7.8304857896652207'] | [0.2383803935903263, 7.830485789665198] | passed | ||
/rows_used | exact | 11 | 11 | 0.00E+2 | passed |
Convention
- dist(x, method = 'manhattan') on the raw complete rows (standardize off), then stats::cmdscale with k = 2; city-block distances are not Euclidean so negative eigenvalues appear.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:20-24: classical scaling eigendecomposes B = -J D^(2) J / 2; coordinates use eigenvectors times square roots of positive eigenvalues; the goodness-of-fit ratios use the absolute and the positive eigenvalue totals.
- docs/manual/chapters/92-dimensions-and-categories.tex:12-17: computed distances use complete rows, standardization to unit SD by default, Euclidean, city-block or correlation sqrt(2(1 - r)) distance; a supplied matrix is never standardized.
- docs/manual/chapters/92-dimensions-and-categories.tex:45-51: ordinal scaling fits monotone disparities minimizing stress; raw stress, normalized stress and Kruskal stress-1 have different denominators.
- Versioned analytical correction from accuracy_adjudications.json: exact MDS rank/inertia or Turnbull KKT proof. Original R expectations and generator identities are preserved in accuracy_reference_revisions.json and history.
Reference code
Whole script generators/analytic/reviewed_reference_corrections.py
Classical scaling of correlation distances between variables
Case STAT-MV-MDS-CORRELATION-001 · status: passed
Reference
- Evidence type
- R
- Source
- Retained R reference with independently reviewed analytical corrections
- Citation
- R Core Team, stats package help: cmdscale (classical multidimensional scaling, Torgerson 1958; Mardia 1978 goodness-of-fit ratios).
- Reference software
- not recorded
- Reference script
- generators/analytic/reviewed_reference_corrections.py · sha256 49e3645836bb3ac3
- Dataset
- reference_data/datasets/MV_MDS_VARS.json
Settings compared
columns= ["v1", "v2", "v3", "v4"]dimensions= 2distance= "correlation"labels= "unit"model= "classical"objects= "variables"source= "variables"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/dimensions | exact | 2 | 2 | 0.00E+2 | passed | |
/gof_absolute | tolerance | 0.78542648044014529 | 0.7854264804401463 | 1.00E-15 | 14 | passed |
/gof_positive | tolerance | 0.78542648044014529 | 0.7854264804401463 | 1.00E-15 | 14 | passed |
/eigenvalues/0/eigenvalue | tolerance | 1.5404743214924017 | 1.5404743214924022 | 4.54E-16 | 15 | passed |
/eigenvalues/0/retained | exact | True | True | passed | ||
/eigenvalues/1/eigenvalue | tolerance | 0.9934461249659059 | 0.9934461249659065 | 5.52E-16 | 15 | passed |
/eigenvalues/1/retained | exact | True | True | passed | ||
/eigenvalues/2/eigenvalue | tolerance | 0.69225095158052863 | 0.6922509515805264 | 2.22E-15 | 14 | passed |
/eigenvalues/2/retained | exact | False | False | passed | ||
/eigenvalues/3/eigenvalue | tolerance | 0 | 6.705959843412296e-18 | 6.71E-18 | passed | |
/eigenvalues/3/retained | exact | False | False | passed | ||
/objects/0/coordinates | sequence | ['0.79570933992228288', '0.11896890050703234'] | [0.7957093399222828, 0.11896890050703247] | passed | ||
/objects/1/coordinates | sequence | ['0.39360135137049856', '-0.36196788595957713'] | [0.3936013513704991, -0.3619678859595771] | passed | ||
/objects/2/coordinates | sequence | ['-0.44437396982006383', '0.76132271899526494'] | [-0.4443739698200644, 0.7613227189952652] | passed | ||
/objects/3/coordinates | sequence | ['-0.7449367214727175', '-0.51832373354272065'] | [-0.7449367214727174, -0.518323733542721] | passed | ||
/rows_used | exact | 11 | 11 | 0.00E+2 | passed | |
/objects/0/label | exact | v1 | v1 | passed | ||
/objects/3/label | exact | v4 | v4 | passed |
Convention
- d_ij = sqrt(2 (1 - r_ij)) with r the Pearson correlation between variables over the 11 complete rows (cor is scale-invariant, so the standardize-for-correlation option is immaterial here), then stats::cmdscale with k = 2 on the four variables.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:20-24: classical scaling eigendecomposes B = -J D^(2) J / 2; coordinates use eigenvectors times square roots of positive eigenvalues; the goodness-of-fit ratios use the absolute and the positive eigenvalue totals.
- docs/manual/chapters/92-dimensions-and-categories.tex:12-17: computed distances use complete rows, standardization to unit SD by default, Euclidean, city-block or correlation sqrt(2(1 - r)) distance; a supplied matrix is never standardized.
- docs/manual/chapters/92-dimensions-and-categories.tex:45-51: ordinal scaling fits monotone disparities minimizing stress; raw stress, normalized stress and Kruskal stress-1 have different denominators.
- Versioned analytical correction from accuracy_adjudications.json: exact MDS rank/inertia or Turnbull KKT proof. Original R expectations and generator identities are preserved in accuracy_reference_revisions.json and history.
Reference code
Whole script generators/analytic/reviewed_reference_corrections.py
Classical scaling of a one-dimensional supplied matrix
Case STAT-MV-MDS-MATRIX-001 · status: passed
Reference
- Evidence type
- R
- Source
- Retained R reference with independently reviewed analytical corrections
- Citation
- R Core Team, stats package help: cmdscale (classical multidimensional scaling, Torgerson 1958; Mardia 1978 goodness-of-fit ratios).
- Reference software
- not recorded
- Reference script
- generators/analytic/reviewed_reference_corrections.py · sha256 49e3645836bb3ac3
- Dataset
- reference_data/datasets/MV_MDS_CONVEYOR.json
Settings compared
columns= ["A", "B", "C"]dimensions= 1model= "classical"source= "matrix"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/dimensions | exact | 1 | 1 | 0.00E+2 | passed | |
/gof_absolute | tolerance | 0.99999999999999922 | 0.9999999999999998 | 5.58E-16 | 15 | passed |
/gof_positive | tolerance | 0.99999999999999922 | 0.9999999999999998 | 5.58E-16 | 15 | passed |
/eigenvalues/0/eigenvalue | tolerance | 4.6666666666666679 | 4.666666666666668 | 4.91E-17 | 16 | passed |
/eigenvalues/0/retained | exact | True | True | passed | ||
/eigenvalues/1/eigenvalue | tolerance | 0 | 1.2606523053526741e-15 | 1.26E-15 | passed | |
/eigenvalues/1/retained | exact | False | False | passed | ||
/eigenvalues/2/eigenvalue | tolerance | 0 | -3.724738856525493e-16 | 3.72E-16 | passed | |
/eigenvalues/2/retained | exact | False | False | passed | ||
/objects/0/coordinates | sequence | ['-1.333333333333333'] | [-1.3333333333333333] | passed | ||
/objects/1/coordinates | sequence | ['-0.33333333333333365'] | [-0.3333333333333339] | passed | ||
/objects/2/coordinates | sequence | ['1.6666666666666674'] | [1.666666666666667] | passed | ||
/objects/0/label | exact | A | A | passed | ||
/rows_used | exact | 3 | 3 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- stats::cmdscale on the supplied 3 x 3 matrix with k = 1; the distances 1, 2, 3 are exactly collinear so the fit is perfect (coordinates -4/3, -1/3, 5/3 after the sign convention, GOF 1).
- Objects are labelled by the matrix column names in the absence of a label column.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:20-24: classical scaling eigendecomposes B = -J D^(2) J / 2; coordinates use eigenvectors times square roots of positive eigenvalues; the goodness-of-fit ratios use the absolute and the positive eigenvalue totals.
- docs/manual/chapters/92-dimensions-and-categories.tex:12-17: computed distances use complete rows, standardization to unit SD by default, Euclidean, city-block or correlation sqrt(2(1 - r)) distance; a supplied matrix is never standardized.
- docs/manual/chapters/92-dimensions-and-categories.tex:45-51: ordinal scaling fits monotone disparities minimizing stress; raw stress, normalized stress and Kruskal stress-1 have different denominators.
- Versioned analytical correction from accuracy_adjudications.json: exact MDS rank/inertia or Turnbull KKT proof. Original R expectations and generator identities are preserved in accuracy_reference_revisions.json and history.
Reference code
Whole script generators/analytic/reviewed_reference_corrections.py
Classical scaling of a non-Euclidean matrix with labels
Case STAT-MV-MDS-MATRIX-002 · status: passed
Reference
- Evidence type
- R
- Source
- Retained R reference with independently reviewed analytical corrections
- Citation
- R Core Team, stats package help: cmdscale (classical multidimensional scaling, Torgerson 1958; Mardia 1978 goodness-of-fit ratios).
- Reference software
- not recorded
- Reference script
- generators/analytic/reviewed_reference_corrections.py · sha256 49e3645836bb3ac3
- Dataset
- reference_data/datasets/MV_MDS_SITES.json
Settings compared
columns= ["P", "Q", "R", "S", "T"]dimensions= 2labels= "site"model= "classical"source= "matrix"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/dimensions | exact | 2 | 2 | 0.00E+2 | passed | |
/gof_absolute | tolerance | 0.81548867970937911 | 0.8154886797093794 | 3.28E-16 | 15 | passed |
/gof_positive | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/eigenvalues/0/eigenvalue | tolerance | 17.413922108064654 | 17.413922108064682 | 2.80E-14 | 14 | passed |
/eigenvalues/0/retained | exact | True | True | passed | ||
/eigenvalues/1/eigenvalue | tolerance | 7.6590542043269227 | 7.659054204326947 | 2.40E-14 | 14 | passed |
/eigenvalues/1/retained | exact | True | True | passed | ||
/eigenvalues/2/eigenvalue | tolerance | 0 | -1.4140410896003506e-15 | 1.41E-15 | passed | |
/eigenvalues/2/retained | exact | False | False | passed | ||
/eigenvalues/3/eigenvalue | tolerance | -1.5764533572795938 | -1.5764533572795925 | 1.34E-15 | 15 | passed |
/eigenvalues/3/retained | exact | False | False | passed | ||
/eigenvalues/4/eigenvalue | tolerance | -4.0965229551120341 | -4.096522955112036 | 1.80E-15 | 15 | passed |
/eigenvalues/4/retained | exact | False | False | passed | ||
/objects/0/coordinates | sequence | ['-2.3828463202857404', '0.4986714014739243'] | [-2.382846320285741, 0.498671401473925] | passed | ||
/objects/1/coordinates | sequence | ['-1.5513796507817434', '-1.3059822417755038'] | [-1.5513796507817463, -1.3059822417755047] | passed | ||
/objects/2/coordinates | sequence | ['-0.18359339527408747', '1.7264422699623765'] | [-0.18359339527408805, 1.7264422699623794] | passed | ||
/objects/3/coordinates | sequence | ['1.4196671629139705', '-1.5323628107059395'] | [1.4196671629139717, -1.5323628107059435] | passed | ||
/objects/4/coordinates | sequence | ['2.6981522034275995', '0.6132313810451453'] | [2.6981522034276026, 0.6132313810451464] | passed | ||
/objects/0/label | exact | north | north | passed | ||
/objects/4/label | exact | centre | centre | passed |
Convention
- stats::cmdscale with k = 2 on a matrix that violates the triangle inequality: negative eigenvalues are reported and the two goodness-of-fit ratios differ.
- Eigenvalues are distinct, so each axis is unique up to sign; the sign convention (largest absolute coordinate positive) is applied to the R points.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:20-24: classical scaling eigendecomposes B = -J D^(2) J / 2; coordinates use eigenvectors times square roots of positive eigenvalues; the goodness-of-fit ratios use the absolute and the positive eigenvalue totals.
- docs/manual/chapters/92-dimensions-and-categories.tex:12-17: computed distances use complete rows, standardization to unit SD by default, Euclidean, city-block or correlation sqrt(2(1 - r)) distance; a supplied matrix is never standardized.
- docs/manual/chapters/92-dimensions-and-categories.tex:45-51: ordinal scaling fits monotone disparities minimizing stress; raw stress, normalized stress and Kruskal stress-1 have different denominators.
- Versioned analytical correction from accuracy_adjudications.json: exact MDS rank/inertia or Turnbull KKT proof. Original R expectations and generator identities are preserved in accuracy_reference_revisions.json and history.
Reference code
Whole script generators/analytic/reviewed_reference_corrections.py
Ordinal SMACOF on an exactly Euclidean matrix, secondary ties
Case STAT-MV-MDS-ORDINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cmdscale and analytic perfect-fit stress
- Citation
- R Core Team, stats package help: cmdscale (classical multidimensional scaling, Torgerson 1958; Mardia 1978 goodness-of-fit ratios).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_mds.R · sha256 92a560135cfde9af
- Dataset
- reference_data/datasets/MV_MDS_PLANE.json
Settings compared
columns= ["a", "b", "c", "d", "e"]dimensions= 2model= "ordinal"source= "matrix"ties= "secondary"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/dimensions | exact | 2 | 2 | 0.00E+2 | passed | |
/converged | exact | True | True | passed | ||
/iterations | exact | 1 | 1 | 0.00E+2 | passed | |
/raw_stress | tolerance | 0 | 3.944304526105059e-31 | 3.94E-31 | passed | |
/normalized_stress | tolerance | 0 | 3.975119405215255e-32 | 3.98E-32 | passed | |
/smacof_stress | tolerance | 0 | 1.993770148541515e-16 | 1.99E-16 | passed | |
/stress_1 | tolerance | 0 | 1.986027322597818e-16 | 1.99E-16 | passed | |
/starts/0/start | exact | classical | classical | passed | ||
/starts/0/normalized_stress | tolerance | 0 | 3.975119405215255e-32 | 3.98E-32 | passed | |
/eigenvalues/0/eigenvalue | tolerance | 17.208564442887429 | 17.208564442887436 | 7.03E-15 | 15 | passed |
/eigenvalues/1/eigenvalue | tolerance | 6.6914355571125839 | 6.6914355571125705 | 1.34E-14 | 14 | passed |
/objects/0/coordinates | sequence | ['-0.39326786792865198', '-0.4163818642282579'] | [-0.39326786792865204, -0.4163818642282582] | passed | ||
/objects/1/coordinates | sequence | ['0.75924710724200373', '-0.23878156020080102'] | [0.7592471072420044, -0.2387815602008013] | passed | ||
/objects/2/coordinates | sequence | ['0.449448991918459', '0.47586498768943902'] | [0.44944899191845955, 0.475864987689438] | passed | ||
/objects/3/coordinates | sequence | ['-0.70306598325219694', '0.2982646836619815'] | [-0.7030659832521968, 0.298264683661981] | passed | ||
/objects/4/coordinates | sequence | ['-0.1123622479796148', '-0.1189662469223597'] | [-0.11236224797961505, -0.11896624692235955] | passed |
Convention
- The matrix holds the exact Euclidean distances of five plane points: the classical start reproduces every distance, the monotone regression of distances on dissimilarities is the identity, and the raw stress is 0 at the first Guttman transform.
- Disparities are normalized to sum of squares n(n-1)/2, so the final configuration equals the classical solution times sqrt(n(n-1)/2 / sum d_ij^2); no tie is present in the matrix so the tie rule cannot change the result.
- Oracle: stats::cmdscale for the classical solution plus the stated analytic rescaling.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:20-24: classical scaling eigendecomposes B = -J D^(2) J / 2; coordinates use eigenvectors times square roots of positive eigenvalues; the goodness-of-fit ratios use the absolute and the positive eigenvalue totals.
- docs/manual/chapters/92-dimensions-and-categories.tex:12-17: computed distances use complete rows, standardization to unit SD by default, Euclidean, city-block or correlation sqrt(2(1 - r)) distance; a supplied matrix is never standardized.
- docs/manual/chapters/92-dimensions-and-categories.tex:45-51: ordinal scaling fits monotone disparities minimizing stress; raw stress, normalized stress and Kruskal stress-1 have different denominators.
Reference code
Ordinal SMACOF on an exactly Euclidean matrix, primary ties
Case STAT-MV-MDS-ORDINAL-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cmdscale and analytic perfect-fit stress
- Citation
- R Core Team, stats package help: cmdscale (classical multidimensional scaling, Torgerson 1958; Mardia 1978 goodness-of-fit ratios).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_mds.R · sha256 92a560135cfde9af
- Dataset
- reference_data/datasets/MV_MDS_PLANE.json
Settings compared
columns= ["a", "b", "c", "d", "e"]dimensions= 2model= "ordinal"source= "matrix"ties= "primary"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/dimensions | exact | 2 | 2 | 0.00E+2 | passed | |
/converged | exact | True | True | passed | ||
/iterations | exact | 1 | 1 | 0.00E+2 | passed | |
/raw_stress | tolerance | 0 | 5.577493118945435e-31 | 5.58E-31 | passed | |
/normalized_stress | tolerance | 0 | 5.669937756276022e-32 | 5.67E-32 | passed | |
/smacof_stress | tolerance | 0 | 2.3811631099687444e-16 | 2.38E-16 | passed | |
/stress_1 | tolerance | 0 | 2.361671678905735e-16 | 2.36E-16 | passed | |
/starts/0/start | exact | classical | classical | passed | ||
/starts/0/normalized_stress | tolerance | 0 | 5.669937756276022e-32 | 5.67E-32 | passed | |
/eigenvalues/0/eigenvalue | tolerance | 17.208564442887429 | 17.208564442887436 | 7.03E-15 | 15 | passed |
/eigenvalues/1/eigenvalue | tolerance | 6.6914355571125839 | 6.6914355571125705 | 1.34E-14 | 14 | passed |
/objects/0/coordinates | sequence | ['-0.39326786792865198', '-0.4163818642282579'] | [-0.39326786792865204, -0.4163818642282582] | passed | ||
/objects/1/coordinates | sequence | ['0.75924710724200373', '-0.23878156020080102'] | [0.7592471072420044, -0.2387815602008013] | passed | ||
/objects/2/coordinates | sequence | ['0.449448991918459', '0.47586498768943902'] | [0.44944899191845955, 0.475864987689438] | passed | ||
/objects/3/coordinates | sequence | ['-0.70306598325219694', '0.2982646836619815'] | [-0.7030659832521968, 0.298264683661981] | passed | ||
/objects/4/coordinates | sequence | ['-0.1123622479796148', '-0.1189662469223597'] | [-0.11236224797961505, -0.11896624692235955] | passed |
Convention
- The matrix holds the exact Euclidean distances of five plane points: the classical start reproduces every distance, the monotone regression of distances on dissimilarities is the identity, and the raw stress is 0 at the first Guttman transform.
- Disparities are normalized to sum of squares n(n-1)/2, so the final configuration equals the classical solution times sqrt(n(n-1)/2 / sum d_ij^2); no tie is present in the matrix so the tie rule cannot change the result.
- Oracle: stats::cmdscale for the classical solution plus the stated analytic rescaling.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:20-24: classical scaling eigendecomposes B = -J D^(2) J / 2; coordinates use eigenvectors times square roots of positive eigenvalues; the goodness-of-fit ratios use the absolute and the positive eigenvalue totals.
- docs/manual/chapters/92-dimensions-and-categories.tex:12-17: computed distances use complete rows, standardization to unit SD by default, Euclidean, city-block or correlation sqrt(2(1 - r)) distance; a supplied matrix is never standardized.
- docs/manual/chapters/92-dimensions-and-categories.tex:45-51: ordinal scaling fits monotone disparities minimizing stress; raw stress, normalized stress and Kruskal stress-1 have different denominators.
Reference code
Classical scaling of standardized Euclidean distances between rows
Case STAT-MV-MDS-VARIABLES-001 · status: passed
Reference
- Evidence type
- R
- Source
- Retained R reference with independently reviewed analytical corrections
- Citation
- R Core Team, stats package help: cmdscale (classical multidimensional scaling, Torgerson 1958; Mardia 1978 goodness-of-fit ratios).
- Reference software
- not recorded
- Reference script
- generators/analytic/reviewed_reference_corrections.py · sha256 49e3645836bb3ac3
- Dataset
- reference_data/datasets/MV_MDS_VARS.json
Settings compared
columns= ["v1", "v2", "v3", "v4"]dimensions= 2distance= "euclidean"labels= "unit"model= "classical"objects= "rows"source= "variables"standardize= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/dimensions | exact | 2 | 2 | 0.00E+2 | passed | |
/gof_absolute | tolerance | 0.63543631243074139 | 0.635436312430742 | 5.55E-16 | 15 | passed |
/gof_positive | tolerance | 0.6354363124307415 | 0.635436312430742 | 4.45E-16 | 15 | passed |
/eigenvalues/0/eigenvalue | tolerance | 15.468421050215152 | 15.468421050215191 | 3.93E-14 | 14 | passed |
/eigenvalues/0/retained | exact | True | True | passed | ||
/eigenvalues/1/eigenvalue | tolerance | 9.9490314470144749 | 9.949031447014484 | 8.93E-15 | 15 | passed |
/eigenvalues/1/retained | exact | True | True | passed | ||
/eigenvalues/2/eigenvalue | tolerance | 9.2068715454066847 | 9.206871545406683 | 1.74E-15 | 15 | passed |
/eigenvalues/2/retained | exact | False | False | passed | ||
/eigenvalues/3/eigenvalue | tolerance | 5.3756759573636268 | 5.375675957363632 | 5.33E-15 | 15 | passed |
/eigenvalues/3/retained | exact | False | False | passed | ||
/eigenvalues/4/eigenvalue | tolerance | 0 | 2.421380353515736e-15 | 2.42E-15 | passed | |
/eigenvalues/4/retained | exact | False | False | passed | ||
/eigenvalues/5/eigenvalue | tolerance | 0 | 1.60321581260916e-15 | 1.60E-15 | passed | |
/eigenvalues/5/retained | exact | False | False | passed | ||
/eigenvalues/6/eigenvalue | tolerance | 0 | 1.3310908222176163e-15 | 1.33E-15 | passed | |
/eigenvalues/6/retained | exact | False | False | passed | ||
/eigenvalues/7/eigenvalue | tolerance | 0 | 2.0144967829558408e-16 | 2.01E-16 | passed | |
/eigenvalues/7/retained | exact | False | False | passed | ||
/eigenvalues/8/eigenvalue | tolerance | 0 | -2.955351189134437e-16 | 2.96E-16 | passed | |
/eigenvalues/8/retained | exact | False | False | passed | ||
/eigenvalues/9/eigenvalue | tolerance | 0 | -1.344988412040238e-15 | 1.34E-15 | passed | |
/eigenvalues/9/retained | exact | False | False | passed | ||
/eigenvalues/10/eigenvalue | tolerance | 0 | -2.7543484068296546e-15 | 2.75E-15 | passed | |
/eigenvalues/10/retained | exact | False | False | passed | ||
/objects/0/coordinates | sequence | ['-0.61929236698565027', '1.2338419410113577'] | [-0.6192923669856465, 1.2338419410113661] | passed | ||
/objects/1/coordinates | sequence | ['-1.0248572828376896', '-0.57511246726732757'] | [-1.0248572828376927, -0.5751124672673401] | passed | ||
/objects/2/coordinates | sequence | ['0.057899676400370775', '-0.21087958035127785'] | [0.05789967640037349, -0.21087958035126017] | passed | ||
/objects/3/coordinates | sequence | ['-1.3311317304529344', '0.17563355255255569'] | [-1.3311317304529375, 0.1756335525525604] | passed | ||
/objects/4/coordinates | sequence | ['1.4225792689703474', '1.6989763899421912'] | [1.422579268970352, 1.6989763899421808] | passed | ||
/objects/5/coordinates | sequence | ['1.0603123441629405', '0.69753661588814486'] | [1.0603123441629403, 0.6975366158881289] | passed | ||
/objects/6/coordinates | sequence | ['-1.3112234241313061', '0.78775682605887754'] | [-1.3112234241313039, 0.7877568260588819] | passed | ||
/objects/7/coordinates | sequence | ['-0.021012150067988383', '-1.2188486026714596'] | [-0.021012150067989833, -1.2188486026714607] | passed | ||
/objects/8/coordinates | sequence | ['2.4840933496214963', '-1.0981951962197751'] | [2.484093349621497, -1.098195196219777] | passed | ||
/objects/9/coordinates | sequence | ['0.33540949381985807', '-0.41052424669205795'] | [0.33540949381986035, -0.4105242466920375] | passed | ||
/objects/10/coordinates | sequence | ['-1.0527771784994453', '-1.080185232251228'] | [-1.0527771784994528, -1.0801852322512422] | passed | ||
/rows_used | exact | 11 | 11 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/objects/0/label | exact | u01 | u01 | passed | ||
/objects/6/label | exact | u08 | u08 | passed |
Convention
- dist(scale(x)) on the 11 complete rows (scale uses the sample SD, ddof 1, as the product does), then stats::cmdscale with k = 2.
- Roundoff-level eigenvalues (n - 1 - 4 of them) are compared with an absolute tolerance of 1e-9.
- Expected computed from the exported CSV.
- docs/manual/chapters/92-dimensions-and-categories.tex:20-24: classical scaling eigendecomposes B = -J D^(2) J / 2; coordinates use eigenvectors times square roots of positive eigenvalues; the goodness-of-fit ratios use the absolute and the positive eigenvalue totals.
- docs/manual/chapters/92-dimensions-and-categories.tex:12-17: computed distances use complete rows, standardization to unit SD by default, Euclidean, city-block or correlation sqrt(2(1 - r)) distance; a supplied matrix is never standardized.
- docs/manual/chapters/92-dimensions-and-categories.tex:45-51: ordinal scaling fits monotone disparities minimizing stress; raw stress, normalized stress and Kruskal stress-1 have different denominators.
- Versioned analytical correction from accuracy_adjudications.json: exact MDS rank/inertia or Turnbull KKT proof. Original R expectations and generator identities are preserved in accuracy_reference_revisions.json and history.
Reference code
Whole script generators/analytic/reviewed_reference_corrections.py
Partial correlation one control
Case STAT-MV-PARTIAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm, stats::cor, stats::pt
- Citation
- R Core Team, stats package help: lm, residuals, cor, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_correlation_extensions.R · sha256 0d15a50f16440286
- Dataset
- reference_data/datasets/MV_CORREXT.json
Settings compared
controls= ["c1"]x= "x"y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 16 | 16 | 0.00E+2 | passed | |
/incomplete_count | exact | 0 | 0 | 0.00E+2 | passed | |
/control_rank | exact | 1 | 1 | 0.00E+2 | passed | |
/df | exact | 13 | 13 | 0.00E+2 | passed | |
/zero_order_r | tolerance | 0.95682800800692969 | 0.9568280080069298 | 1.08E-16 | 15 | passed |
/partial_r | tolerance | 0.37975383617151115 | 0.37975383617151026 | 8.88E-16 | 14 | passed |
/t_value | tolerance | 1.4800997909583606 | 1.4800997909583566 | 3.96E-15 | 14 | passed |
/p_value | tail_probability | 0.16266981112130274 | 0.1626698111213038 | 1.06E-15 | 14 | passed |
Convention
- Residuals of lm(x ~ controls) and lm(y ~ controls) on the complete cases; r = cor of the residuals; df = n - k - 2 with k the rank of the controls beyond the intercept (lm's rank minus one); t = r sqrt(df / (1 - r^2)); two-sided t tail.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:103-107: 'correlates the residuals after regressing each response on an intercept and the declared controls, using complete cases. If the controls' numerical rank is k, the usual test has n-k-2 degrees of freedom.'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
174 partial_case("STAT-MV-PARTIAL-001", "Partial correlation one control", "nominal", "c1")Whole script generators/r/multivariate_correlation_extensions.R
Partial correlation two controls with a missing control value
Case STAT-MV-PARTIAL-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm, stats::cor, stats::pt
- Citation
- R Core Team, stats package help: lm, residuals, cor, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_correlation_extensions.R · sha256 0d15a50f16440286
- Dataset
- reference_data/datasets/MV_CORREXT.json
Settings compared
controls= ["c1", "c3"]x= "x"y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 15 | 15 | 0.00E+2 | passed | |
/incomplete_count | exact | 1 | 1 | 0.00E+2 | passed | |
/control_rank | exact | 2 | 2 | 0.00E+2 | passed | |
/df | exact | 11 | 11 | 0.00E+2 | passed | |
/zero_order_r | tolerance | 0.95919323227446218 | 0.9591932322744621 | 1.09E-16 | 15 | passed |
/partial_r | tolerance | 0.2770967010332383 | 0.27709670103323647 | 1.83E-15 | 14 | passed |
/t_value | tolerance | 0.95647958090262075 | 0.956479580902614 | 6.77E-15 | 14 | passed |
/p_value | tail_probability | 0.35937917960891463 | 0.3593791796089178 | 3.17E-15 | 14 | passed |
Convention
- Residuals of lm(x ~ controls) and lm(y ~ controls) on the complete cases; r = cor of the residuals; df = n - k - 2 with k the rank of the controls beyond the intercept (lm's rank minus one); t = r sqrt(df / (1 - r^2)); two-sided t tail.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:103-107: 'correlates the residuals after regressing each response on an intercept and the declared controls, using complete cases. If the controls' numerical rank is k, the usual test has n-k-2 degrees of freedom.'
- c3 is missing on one row, so n = 15 complete cases and incomplete_count = 1.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
175 partial_case("STAT-MV-PARTIAL-002", "Partial correlation two controls with a missing control value",
176 "missing_excluded", c("c1", "c3"),
177 "c3 is missing on one row, so n = 15 complete cases and incomplete_count = 1.")Whole script generators/r/multivariate_correlation_extensions.R
Partial correlation redundant control
Case STAT-MV-PARTIAL-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm, stats::cor, stats::pt
- Citation
- R Core Team, stats package help: lm, residuals, cor, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_correlation_extensions.R · sha256 0d15a50f16440286
- Dataset
- reference_data/datasets/MV_CORREXT.json
Settings compared
controls= ["c1", "c2"]x= "x"y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 16 | 16 | 0.00E+2 | passed | |
/incomplete_count | exact | 0 | 0 | 0.00E+2 | passed | |
/control_rank | exact | 1 | 1 | 0.00E+2 | passed | |
/df | exact | 13 | 13 | 0.00E+2 | passed | |
/zero_order_r | tolerance | 0.95682800800692969 | 0.9568280080069298 | 1.08E-16 | 15 | passed |
/partial_r | tolerance | 0.37975383617151115 | 0.37975383617150954 | 1.61E-15 | 14 | passed |
/t_value | tolerance | 1.4800997909583606 | 1.4800997909583535 | 7.07E-15 | 14 | passed |
/p_value | tail_probability | 0.16266981112130274 | 0.16266981112130463 | 1.89E-15 | 13 | passed |
Convention
- Residuals of lm(x ~ controls) and lm(y ~ controls) on the complete cases; r = cor of the residuals; df = n - k - 2 with k the rank of the controls beyond the intercept (lm's rank minus one); t = r sqrt(df / (1 - r^2)); two-sided t tail.
- docs/manual/chapters/82-descriptive-reports-and-association.tex:103-107: 'correlates the residuals after regressing each response on an intercept and the declared controls, using complete cases. If the controls' numerical rank is k, the usual test has n-k-2 degrees of freedom.'
- c2 = 2 c1 + 3 is collinear with c1 and the intercept: the controls have rank 1, df = n - 3 and the residuals equal those on c1 alone.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
178 partial_case("STAT-MV-PARTIAL-003", "Partial correlation redundant control", "axis_coverage",
179 c("c1", "c2"),
180 "c2 = 2 c1 + 3 is collinear with c1 and the intercept: the controls have rank 1, df = n - 3 and the residuals equal those on c1 alone.")Whole script generators/r/multivariate_correlation_extensions.R
Multivariate STAT-MV-PCA-001
Case STAT-MV-PCA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_core.R · sha256 90e434c114270562
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]n_components= 2scaling= "correlation"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/eigenvalues/0 | tolerance | 1.9974590554819609 | 1.9974590554819616 | 6.65E-16 | 15 | passed |
/means | sequence | ['5.0083333333333337', '4.0250000000000004', '5.691666666666 | [5.008333333333333, 4.025, 5.691666666666666] | passed | ||
/loadings/0 | sign_invariant_sequence | ['0.70672573267086569', '-0.0052863510808498241'] | [0.7067257326708654, -0.0052863510808498285] | passed | ||
/source_count | exact | 12 | 12 | 0.00E+2 | passed |
Convention
- prcomp uses sample SD (n-1); each component may flip sign.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
46 pc <- stats::prcomp(d[c("x","y","z")], center=TRUE, scale.=TRUE)
47 emit("STAT-MV-PCA-001", "tabelz.executor.principal_components", "principalComponentsMenuItem",
48 list(columns=list("x","y","z"), scaling="correlation", n_components=2L),
49 list("/eigenvalues/0"=tol(pc$sdev[1]^2, "sample-correlation first eigenvalue"),
50 "/means"=seqtol(pc$center, "column means"),
51 "/loadings/0"=seqtol(pc$rotation[1,1:2], "first variable loadings", TRUE),
52 "/source_count"=exact(nrow(d), "all source rows")),
53 c("prcomp uses sample SD (n-1); each component may flip sign."))
Multivariate option STAT-MV-PCA-COV-001
Case STAT-MV-PCA-COV-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic formulae
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_options.R · sha256 5d6896c30e5e2257
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]n_components= 2scaling= "covariance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/eigenvalues/0 | tolerance | 18.290154867658419 | 18.29015486765842 | 1.36E-16 | 17 | passed |
/scales/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed |
Convention
- prcomp sample covariance divides by n-1 and does not standardize.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
22 cols <- list("x","y","z")
23 pc <- stats::prcomp(d[c("x","y","z")],center=TRUE,scale.=FALSE)
24 emit("STAT-MV-PCA-COV-001","tabelz.executor.principal_components","principalComponentsMenuItem",
25 list(columns=cols,scaling="covariance",n_components=2L),
26 list("/eigenvalues/0"=tol(pc$sdev[1]^2,"R prcomp sample-covariance first eigenvalue"),
27 "/scales/0"=tol(1,"Covariance PCA retains raw measurement scale")),
28 c("prcomp sample covariance divides by n-1 and does not standardize."))
Hard-numeric STAT-MV-PCA-HARD-001
Case STAT-MV-PCA-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova and chisq.test documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_hard.R · sha256 06eca51b7d1d3ab6
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
columns= ["x", "y", "z"]n_components= 2scaling= "correlation"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/eigenvalues/0 | tolerance | 1.9974590556403096 | 1.9974590556403093 | 2.56E-16 | 15 | passed |
Convention
- Large common offset must cancel before computing covariance; prcomp uses n-1.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
49 xyz <- list("x","y","z")
50 pc <- stats::prcomp(d[c("x","y","z")],center=TRUE,scale.=TRUE)
51 emit("STAT-MV-PCA-HARD-001","tabelz.executor.principal_components","principalComponentsMenuItem",
52 "MV_HARD",list(columns=xyz,scaling="correlation",n_components=2L),
53 list("/eigenvalues/0"=tol(pc$sdev[1]^2,"sample-correlation leading eigenvalue")),
54 c("Large common offset must cancel before computing covariance; prcomp uses n-1."))
Invalid multivariate request STAT-MV-PCA-INVALID-001
Case STAT-MV-PCA-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- PCA needs at least two columns.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-PCA-INVALID-002
Case STAT-MV-PCA-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
columns= ["x", "y", "z"]n_components= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Component count must be positive.
- The rejection follows from the declared request schema without statistical computation.
Minimum-sample STAT-MV-PCA-MIN-001
Case STAT-MV-PCA-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, factanal, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_minimum.R · sha256 bcd4094568b73b37
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
columns= ["x", "y"]n_components= 1scaling= "correlation"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/eigenvalues/0 | tolerance | 1.9999999999999996 | 1.9999999999999996 | 4.41E-17 | 16 | passed |
Convention
- Two complete rows are the minimum accepted for PCA.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
24 two <- core[c(1L,5L),]
25 export_dataset(two,"MV_MIN_TWO","Two distinct observations",
26 "R closed-form two-row multivariate boundary",
27 "Constructed validation data; no third-party license.",types)
28 d <- read_dataset("MV_MIN_TWO")
29 pc <- stats::prcomp(d[c("x","y")],center=TRUE,scale.=TRUE)
30 emit("STAT-MV-PCA-MIN-001","tabelz.executor.principal_components","principalComponentsMenuItem",
31 "MV_MIN_TWO",list(columns=list("x","y"),scaling="correlation",n_components=1L),
32 list("/eigenvalues/0"=tol(pc$sdev[1]^2,"two-point sample-correlation eigenvalue")),
33 c("Two complete rows are the minimum accepted for PCA."))
Missing and excluded multivariate population STAT-MV-PCA-POP-001
Case STAT-MV-PCA-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and analytic identities
- Citation
- R stats::prcomp/hclust/kmeans/manova/cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_population.R · sha256 8a6d148e9316e21f
- Dataset
- reference_data/datasets/MV_POP.json
Settings compared
columns= ["x", "y", "z"]n_components= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 12 | 12 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/eigenvalues/0 | tolerance | 1.9811551867503419 | 1.9811551867503416 | 2.65E-16 | 15 | passed |
Convention
- Complete-case standardization divides by n-1.
- R re-reads exported CSV, drops ordinal 9 by stable-row-ID exclusion, then uses complete cases.
Reference code
The lines of the reference script that produce this case's expected values.
33 eligible <- d[-10L,,drop=FALSE]
34 xyzd <- eligible[stats::complete.cases(eligible[c("x","y","z")]),,drop=FALSE]
35 pc <- stats::prcomp(xyzd[c("x","y","z")],center=TRUE,scale.=TRUE)
36 emit("STAT-MV-PCA-POP-001","tabelz.executor.principal_components","principalComponentsMenuItem",
37 list(columns=list("x","y","z"),n_components=2L),
38 list("/source_count"=exact(nrow(d),"CSV source population"),
39 "/excluded_count"=exact(1L,"One stable row ID excluded"),
40 "/missing_count"=exact(1L,"One selected-column missing row"),
41 "/eigenvalues/0"=tol(pc$sdev[1]^2,"R complete-case sample-correlation eigenvalue")),
42 c("Complete-case standardization divides by n-1."))
Retained scoring STAT-MV-PCA-SCORE-001
Case STAT-MV-PCA-SCORE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic
- Citation
- R stats::prcomp, kmeans, hclust and matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring.R · sha256 6aa292c3e1b1894b
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {"principal_components": {"columns": ["x", "y", "z"], "means": [5.00833333333333, 4.025, 5.69166666666667], "scales": [3.41479623599027, 2.2450450491532, 2.59000117000091], "loadings": [[0.706725732670866], [0.136587969630206], [0.694177545973022]], "row_ids": ["STAT-MV-PCA-SCORE-001:0", "STAT-MV-PCA-SCORE-001:1", "STAT-MV-PCA-SCORE-001:3", "STAT-MV-PCA-SCORE-001:4", "STAT-MV-PCA-SCORE-001:5", "STAT-MV-PCA-SCORE-001:6", "STAT-MV-PCA-SCORE-001:7", "STAT-MV-PCA-SCORE-001:8", "STAT-MV-PCA-SCORE-001:9", "STAT-MV-PCA-SCORE-001:10", "STAT-MV-PCA-SCORE-001:11"]}}names= ["pc1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/pc1 | tolerance | -1.647388504772167 | -1.647388504772168 | 9.16E-16 | 15 | passed |
/1/pc1 | tolerance | -1.6803191885164597 | -1.6803191885164601 | 4.16E-16 | 15 | passed |
/2/pc1 | absent | None | passed | |||
/3/pc1 | tolerance | -1.5609201506993629 | -1.5609201506993635 | 6.18E-16 | 15 | passed |
/4/pc1 | tolerance | 0.032884035526104971 | 0.03288403552610487 | 1.04E-16 | 14 | passed |
/5/pc1 | tolerance | 0.023115648755510615 | 0.023115648755510608 | 7.01E-18 | 15 | passed |
/6/pc1 | tolerance | -0.047544843428177191 | -0.047544843428177185 | 6.49E-18 | 15 | passed |
/7/pc1 | tolerance | -0.026782108802030635 | -0.026782108802030753 | 1.18E-16 | 14 | passed |
/8/pc1 | tolerance | 1.6443542287003363 | 1.6443542287003363 | 1.78E-17 | 16 | passed |
/9/pc1 | tolerance | 1.6480386409118577 | 1.6480386409118577 | 4.22E-19 | 18 | passed |
/10/pc1 | tolerance | 1.6321640298619151 | 1.6321640298619156 | 4.55E-16 | 15 | passed |
/11/pc1 | tolerance | 1.710148847028095 | 1.710148847028095 | 1.72E-18 | 17 | passed |
Convention
- One row is absent from the retained population and must receive null; all other scores retain CSV order.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
39 id <- "STAT-MV-PCA-SCORE-001"
Retained correction STAT-MV-PCA-SCORE-HARD-001
Case STAT-MV-PCA-SCORE-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and analytic row-identity join
- Citation
- R stats::prcomp, scale and base matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_corrections.R · sha256 d22bd7a20d0e25a3
- Dataset
- reference_data/datasets/MV_HARD.json
Settings compared
model= {"principal_components": {"columns": ["x", "y"], "means": [100000005.008333, 100000004.025], "scales": [3.4147962360392, 2.24504504951825], "loadings": [[0.707106781186547], [0.707106781186548]], "row_ids": ["STAT-MV-PCA-SCORE-HARD-001:0", "STAT-MV-PCA-SCORE-HARD-001:1", "STAT-MV-PCA-SCORE-HARD-001:2", "STAT-MV-PCA-SCORE-HARD-001:3", "STAT-MV-PCA-SCORE-HARD-001:4", "STAT-MV-PCA-SCORE-HARD-001:5", "STAT-MV-PCA-SCORE-HARD-001:6", "STAT-MV-PCA-SCORE-HARD-001:7", "STAT-MV-PCA-SCORE-HARD-001:8", "STAT-MV-PCA-SCORE-HARD-001:9", "STAT-MV-PCA-SCORE-HARD-001:10", "STAT-MV-PCA-SCORE-HARD-001:11"]}}names= ["pc1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/pc1 | tolerance | -1.4678119640661258 | -1.4678119640661258 | 3.92E-18 | 17 | passed |
/1/pc1 | tolerance | -1.3949013476239474 | -1.3949013476239474 | 4.81E-17 | 16 | passed |
/2/pc1 | tolerance | -1.5722189126001063 | -1.5722189126001063 | 3.35E-17 | 16 | passed |
/3/pc1 | tolerance | -1.3841121615967962 | -1.3841121615967962 | 2.45E-17 | 16 | passed |
/4/pc1 | tolerance | 0.94607945267532567 | 0.9460794526753257 | 1.68E-18 | 17 | passed |
/5/pc1 | tolerance | 0.91371189780929951 | 0.9137118978092995 | 1.41E-18 | 17 | passed |
/6/pc1 | tolerance | 0.99828292774617289 | 0.9982829277461729 | 2.15E-18 | 17 | passed |
/7/pc1 | tolerance | 0.86237965181370968 | 0.8623796518137097 | 4.16E-20 | 19 | passed |
/8/pc1 | tolerance | 0.52443000873401457 | 0.5244300087340146 | 4.40E-18 | 17 | passed |
/9/pc1 | tolerance | 0.52530123620155811 | 0.5253012362015581 | 1.74E-18 | 17 | passed |
/10/pc1 | tolerance | 0.51364082740018224 | 0.5136408274001822 | 2.71E-18 | 17 | passed |
/11/pc1 | tolerance | 0.53521919315345223 | 0.5352191931534522 | 2.89E-18 | 17 | passed |
Convention
- Scoring subtracts 1e8-scale means before applying retained PCA loading.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
102 as_serialized <- function(x) array(as.double(sprintf("%.15g", x)), dim = dim(as.array(x)))
103 id <- "STAT-MV-PCA-SCORE-HARD-001"Whole script generators/r/multivariate_scoring_corrections.R
Retained scoring STAT-MV-PCA-SCORE-HARD-VALID-001
Case STAT-MV-PCA-SCORE-HARD-VALID-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and centered matrix arithmetic
- Citation
- R stats::prcomp and scale documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_final.R · sha256 90940efd66e73ecd
- Dataset
- reference_data/datasets/MV_SCORE_HARD.json
Settings compared
model= {"principal_components": {"columns": ["x", "y"], "means": [100005.008333333, 100004.025], "scales": [3.41479623599022, 2.24504504915284], "loadings": [[0.707106781186548], [0.707106781186547]], "row_ids": ["STAT-MV-PCA-SCORE-HARD-VALID-001:0", "STAT-MV-PCA-SCORE-HARD-VALID-001:1", "STAT-MV-PCA-SCORE-HARD-VALID-001:2", "STAT-MV-PCA-SCORE-HARD-VALID-001:3", "STAT-MV-PCA-SCORE-HARD-VALID-001:4", "STAT-MV-PCA-SCORE-HARD-VALID-001:5", "STAT-MV-PCA-SCORE-HARD-VALID-001:6", "STAT-MV-PCA-SCORE-HARD-VALID-001:7", "STAT-MV-PCA-SCORE-HARD-VALID-001:8", "STAT-MV-PCA-SCORE-HARD-VALID-001:9", "STAT-MV-PCA-SCORE-HARD-VALID-001:10", "STAT-MV-PCA-SCORE-HARD-VALID-001:11"]}}names= ["pc1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/pc1 | tolerance | -1.4678120318312429 | -1.4678120317619379 | 6.93E-11 | 10 | passed |
Convention
- Measurements have a 1e5 offset with O(1) spread; R centers before projecting.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
51 x <- as.matrix(four[c("x","y","z")]); mu <- colMeans(x); sd <- apply(x,2,stats::sd)
52 scores <- as.vector(scale(as.matrix(five[c("x","y","z")]),center=mu,scale=sd)%*%weights)
53 model <- list(factor_analysis=list(columns=list("x","y","z"),means=nums(mu),
54 scales=nums(sd),weights=rows(weights),row_ids=ids(id,4L)))
55 out <- list("/0/factor1"=tol(scores[1],"First retained FA score"),
56 "/3/factor1"=tol(scores[4],"Fourth retained FA score"),
57 "/4/factor1"=absent("Fifth source row is outside retained model population"))
58 emit(id,"operation:tabelz.factor_scores","factorAnalysisMenuItem","MV_SCORE_FIVE",
59 list(names=list("factor1"),model=model),out,"boundary",
60 c("Four retained rows satisfy the model schema; fifth source row must remain missing."))
61 id <- "STAT-MV-PCA-SCORE-HARD-VALID-001"
Invalid multivariate request STAT-MV-PCA-SCORE-INVALID-001
Case STAT-MV-PCA-SCORE-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {}names= ["score"]unknown_option= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Retained scoring rejects unknown request keys before creating an operation.
- The rejection follows from the declared request schema without statistical computation.
Invalid multivariate request STAT-MV-PCA-SCORE-INVALID-002
Case STAT-MV-PCA-SCORE-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict configuration contract
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/MV_CORE.json
Settings compared
model= {}names= ["score"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A retained operation needs a model envelope matching its operation type.
- The rejection follows from the declared request schema without statistical computation.
Retained boundary STAT-MV-PCA-SCORE-MIN-001
Case STAT-MV-PCA-SCORE-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and retained identity join
- Citation
- R stats::prcomp and base matrix arithmetic documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_boundaries.R · sha256 4cdf60725804542b
- Dataset
- reference_data/datasets/MV_MIN_TWO.json
Settings compared
model= {"principal_components": {"columns": ["x", "y"], "means": [2.95, 4.55], "scales": [2.75771644662754, 3.60624458405139], "loadings": [[0.707106781186548], [0.707106781186547]], "row_ids": ["STAT-MV-PCA-SCORE-MIN-001:0", "STAT-MV-PCA-SCORE-MIN-001:1"]}}names= ["pc1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/pc1 | tolerance | -0.99999999999999989 | -0.9999999999999993 | 5.56E-16 | 15 | passed |
/1/pc1 | tolerance | 0.99999999999999989 | 0.9999999999999993 | 5.56E-16 | 15 | passed |
Convention
- Two source rows; R standardized matrix times retained loading.
- R re-reads the exported CSV.
Reference code
Retained correction STAT-MV-PCA-SCORE-OMIT-CORRECTED-001
Case STAT-MV-PCA-SCORE-OMIT-CORRECTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R matrix arithmetic and analytic row-identity join
- Citation
- R stats::prcomp, scale and base matrix multiplication documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_scoring_corrections.R · sha256 d22bd7a20d0e25a3
- Dataset
- reference_data/datasets/MV_SCORE_FOUR.json
Settings compared
model= {"principal_components": {"columns": ["x", "y"], "means": [5, 4.03333333333333], "scales": [4.05092582010582, 2.70246800782791], "loadings": [[0.707106781186547], [0.707106781186548]], "row_ids": ["STAT-MV-PCA-SCORE-OMIT-CORRECTED-001:0", "STAT-MV-PCA-SCORE-OMIT-CORRECTED-001:1", "STAT-MV-PCA-SCORE-OMIT-CORRECTED-001:2"]}}names= ["pc1"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/pc1 | tolerance | -1.2302436583607195 | -1.2302436583607177 | 1.80E-15 | 14 | passed |
/1/pc1 | tolerance | 0.7849447360674624 | 0.7849447360674626 | 2.23E-16 | 15 | passed |
/2/pc1 | tolerance | 0.44529892229325702 | 0.44529892229325774 | 7.17E-16 | 14 | passed |
/3/pc1 | absent | None | passed |
Convention
- Three retained rows and one nonmember; stable row IDs control where null is written.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
57 d <- four 58 ret <- three 59 id <- "STAT-MV-PCA-SCORE-OMIT-CORRECTED-001"
Whole script generators/r/multivariate_scoring_corrections.R
Special boundary STAT-MV-PCA-TIES-001
Case STAT-MV-PCA-TIES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and closed-form formulae
- Citation
- R stats::prcomp, hclust, kmeans, manova, chisq.test and cor documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/multivariate_boundaries.R · sha256 420706593513ebf0
- Dataset
- reference_data/datasets/MV_TIES.json
Settings compared
columns= ["x", "y"]n_components= 2scaling= "correlation"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/eigenvalues/1 | tolerance | 0.65603898193436716 | 0.6560389819343672 | 2.43E-19 | 18 | passed |
Convention
- One exact duplicate row tests covariance computation without assuming a sign for loadings.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
23 d <- base[c(1L,1L,5L,9L),]
24 d$i2 <- c(2L,2L,2L,2L)
25 export_dataset(d,"MV_TIES","Duplicate measurements and a constant item",
26 "R multivariate tie and zero-item-variance references",
27 "Constructed validation data; no third-party license.",types)
28 d <- read_dataset("MV_TIES")
29 pc <- stats::prcomp(d[c("x","y")],center=TRUE,scale.=TRUE)
30 emit("STAT-MV-PCA-TIES-001","tabelz.executor.principal_components","principalComponentsMenuItem",
31 "MV_TIES",list(columns=list("x","y"),scaling="correlation",n_components=2L),
32 list("/eigenvalues/1"=tol(pc$sdev[2]^2,"second eigenvalue with one repeated row")),
33 c("One exact duplicate row tests covariance computation without assuming a sign for loadings."))
NIST AtmWtAg: fit
Case STAT-NIST-ATMWTAG-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/AtmWtAg.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ATMWTAG.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 1.59467335677930E+01 | 15.946733567792975 | 2.46E-14 | 14 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 1 | 1.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 46 | 46.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 48 | 48 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 3.63834187500000E-09 | 3.638341875000001e-09 | 1.08E-24 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.04951729166667E-08 | 1.0495172916666666e-08 | 3.35E-23 | 14 | passed |
Convention
- NIST model: Model: 3 Parameters (mu, tau_1, tau_2) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST AtmWtAg: general linear
Case STAT-NIST-ATMWTAG-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/AtmWtAg.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ATMWTAG.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 1.59467335677930E+01 | 15.946733567792965 | 3.53E-14 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 1 | 1 | 0.00E+2 | passed | |
/residual_df | exact | 46 | 46 | 0.00E+2 | passed | |
/observations | exact | 48 | 48 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 3.63834187500000E-09 | 3.6383418749999986e-09 | 1.40E-24 | 15 | passed |
/term_tests/[term=group]/mean_sq | lre | 3.63834187500000E-09 | 3.6383418749999986e-09 | 1.40E-24 | 15 | passed |
/residual_variance | lre | 2.28155932971014E-10 | 2.281559329710145e-10 | 4.94E-25 | 14 | passed |
Convention
- NIST model: Model: 3 Parameters (mu, tau_1, tau_2) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST AtmWtAg: linear effects
Case STAT-NIST-ATMWTAG-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/AtmWtAg.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ATMWTAG.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 1.59467335677930E+01 | 15.946733567792972 | 2.82E-14 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 1 | 1 | 0.00E+2 | passed | |
/residual_df | exact | 46 | 46 | 0.00E+2 | passed | |
/observations | exact | 48 | 48 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 3.63834187500000E-09 | 3.6383418750000003e-09 | 2.57E-25 | 16 | passed |
/term_tests/[term=group]/mean_sq | lre | 3.63834187500000E-09 | 3.6383418750000003e-09 | 2.57E-25 | 16 | passed |
/residual_variance | lre | 2.28155932971014E-10 | 2.281559329710145e-10 | 4.94E-25 | 14 | passed |
Convention
- NIST model: Model: 3 Parameters (mu, tau_1, tau_2) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST Bennett5: nonlinear regression Start 1
Case STAT-NIST-BENNETT5-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Bennett5.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_BENNETT5.json
Settings compared
curve= "custom"expression= "b1 * (b2+x)**(-1/b3)"max_evaluations= 10000parameters= [{"name": "b1", "start": -2000.0}, {"name": "b2", "start": 50.0}, {"name": "b3", "start": 0.8}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 151 | 151 | 0.00E+2 | passed | |
/sse | lre | 5.2404744073E-04 | 0.0005240474407265671 | 3.43E-15 | 11 | passed |
/artifact/residual_variance | lre | 0.00000347051285265897750784 | 3.470512852493822e-06 | 1.65E-16 | 10 | passed |
/artifact/estimates/0 | lre | -2.5235058043E+03 | -2523.5058043045506 | 4.55E-9 | 11 | passed |
/artifact/covariance/0/0 | lre | 88299.1649706499018921 | 88299.16497005218 | 5.98E-7 | 11 | passed |
/artifact/estimates/1 | lre | 4.6736564644E+01 | 46.73656464357572 | 4.24E-10 | 11 | passed |
/artifact/covariance/1/1 | lre | 1.54974410487108884736 | 1.5497441047498293 | 1.21E-10 | 10 | passed |
/artifact/estimates/2 | lre | 9.3218483193E-01 | 0.9321848319329451 | 2.95E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.000410966122071259186884 | 0.0004109661220794897 | 8.23E-15 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.0e-13 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 3 Parameters (b1 to b3) y = b1 * (b2+x)**(-1/b3) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Bennett5: nonlinear regression Start 2
Case STAT-NIST-BENNETT5-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Bennett5.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_BENNETT5.json
Settings compared
curve= "custom"expression= "b1 * (b2+x)**(-1/b3)"max_evaluations= 10000parameters= [{"name": "b1", "start": -1500.0}, {"name": "b2", "start": 45.0}, {"name": "b3", "start": 0.85}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 151 | 151 | 0.00E+2 | passed | |
/sse | lre | 5.2404744073E-04 | 0.0005240474407262498 | 3.75E-15 | 11 | passed |
/artifact/residual_variance | lre | 0.00000347051285265897750784 | 3.4705128524917205e-06 | 1.67E-16 | 10 | passed |
/artifact/estimates/0 | lre | -2.5235058043E+03 | -2523.5058043046593 | 4.66E-9 | 11 | passed |
/artifact/covariance/0/0 | lre | 88299.1649706499018921 | 88299.16496895936 | 1.69E-6 | 10 | passed |
/artifact/estimates/1 | lre | 4.6736564644E+01 | 46.736564643576195 | 4.24E-10 | 11 | passed |
/artifact/covariance/1/1 | lre | 1.54974410487108884736 | 1.5497441047304132 | 1.41E-10 | 10 | passed |
/artifact/estimates/2 | lre | 9.3218483193E-01 | 0.9321848319329378 | 2.94E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.000410966122071259186884 | 0.0004109661220743723 | 3.11E-15 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within -1.3e-13 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 3 Parameters (b1 to b3) y = b1 * (b2+x)**(-1/b3) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST BoxBOD: nonlinear regression Start 1
Case STAT-NIST-BOXBOD-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/BoxBOD.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_BOXBOD.json
Settings compared
curve= "custom"expression= "b1*(1-exp(-b2*x))"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.0}, {"name": "b2", "start": 1.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 4 | 4 | 0.00E+2 | passed | |
/sse | lre | 1.1680088766E+03 | 1168.0088765555518 | 4.44E-8 | 10 | passed |
/artifact/residual_variance | lre | 292.002219133693090929 | 292.00221913888794 | 5.19E-9 | 10 | passed |
/artifact/estimates/0 | lre | 2.1380940889E+02 | 213.8094088903979 | 3.98E-10 | 11 | passed |
/artifact/covariance/0/0 | lre | 152.634045234014310976 | 152.63404524577564 | 1.18E-8 | 10 | passed |
/artifact/estimates/1 | lre | 5.4723748542E-01 | 0.5472374854191994 | 8.01E-13 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.0109327794572189738169 | 0.010932779457234244 | 1.53E-14 | 11 | passed |
Convention
- NIST model: Model: Exponential Class 2 Parameters (b1 and b2) y = b1*(1-exp[-b2*x]) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST BoxBOD: nonlinear regression Start 2
Case STAT-NIST-BOXBOD-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/BoxBOD.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_BOXBOD.json
Settings compared
curve= "custom"expression= "b1*(1-exp(-b2*x))"max_evaluations= 10000parameters= [{"name": "b1", "start": 100.0}, {"name": "b2", "start": 0.75}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 4 | 4 | 0.00E+2 | passed | |
/sse | lre | 1.1680088766E+03 | 1168.0088765555518 | 4.44E-8 | 10 | passed |
/artifact/residual_variance | lre | 292.002219133693090929 | 292.00221913888794 | 5.19E-9 | 10 | passed |
/artifact/estimates/0 | lre | 2.1380940889E+02 | 213.8094088903979 | 3.98E-10 | 11 | passed |
/artifact/covariance/0/0 | lre | 152.634045234014310976 | 152.63404524577564 | 1.18E-8 | 10 | passed |
/artifact/estimates/1 | lre | 5.4723748542E-01 | 0.5472374854191994 | 8.01E-13 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.0109327794572189738169 | 0.010932779457234244 | 1.53E-14 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.7e-14 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 2 Parameters (b1 and b2) y = b1*(1-exp[-b2*x]) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Chwirut1: nonlinear regression Start 1
Case STAT-NIST-CHWIRUT1-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Chwirut1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_CHWIRUT1.json
Settings compared
curve= "custom"expression= "exp(-b1*x)/(b2+b3*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.1}, {"name": "b2", "start": 0.01}, {"name": "b3", "start": 0.02}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 211 | 211 | 0.00E+2 | passed | |
/sse | lre | 2.3844771393E+03 | 2384.4771393093506 | 9.35E-9 | 11 | passed |
/artifact/residual_variance | lre | 11.30083952306542542400 | 11.300839522793131 | 2.72E-10 | 10 | passed |
/artifact/estimates/0 | lre | 1.9027818370E-01 | 0.19027818369613864 | 3.86E-12 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.000481300284777947991225 | 0.0004813002847665273 | 1.14E-14 | 10 | passed |
/artifact/estimates/1 | lre | 6.1314004477E-03 | 0.006131400447708267 | 8.27E-15 | 11 | passed |
/artifact/covariance/1/1 | lre | 1.190251728519627552601E-7 | 1.1902517284875868e-07 | 3.20E-18 | 10 | passed |
/artifact/estimates/2 | lre | 1.0530908399E-02 | 0.010530908398944706 | 5.53E-14 | 11 | passed |
/artifact/covariance/2/2 | lre | 6.285611382337052671504E-7 | 6.285611382315404e-07 | 2.16E-18 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.1e-15 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = exp[-b1*x]/(b2+b3*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Chwirut1: nonlinear regression Start 2
Case STAT-NIST-CHWIRUT1-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Chwirut1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_CHWIRUT1.json
Settings compared
curve= "custom"expression= "exp(-b1*x)/(b2+b3*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.15}, {"name": "b2", "start": 0.008}, {"name": "b3", "start": 0.01}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 211 | 211 | 0.00E+2 | passed | |
/sse | lre | 2.3844771393E+03 | 2384.4771393093492 | 9.35E-9 | 11 | passed |
/artifact/residual_variance | lre | 11.30083952306542542400 | 11.300839522793124 | 2.72E-10 | 10 | passed |
/artifact/estimates/0 | lre | 1.9027818370E-01 | 0.19027818369635813 | 3.64E-12 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.000481300284777947991225 | 0.0004813002847670335 | 1.09E-14 | 10 | passed |
/artifact/estimates/1 | lre | 6.1314004477E-03 | 0.006131400447711027 | 1.10E-14 | 11 | passed |
/artifact/covariance/1/1 | lre | 1.190251728519627552601E-7 | 1.1902517284871835e-07 | 3.24E-18 | 10 | passed |
/artifact/estimates/2 | lre | 1.0530908399E-02 | 0.010530908398937344 | 6.27E-14 | 11 | passed |
/artifact/covariance/2/2 | lre | 6.285611382337052671504E-7 | 6.2856113823153e-07 | 2.18E-18 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.9e-15 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = exp[-b1*x]/(b2+b3*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Chwirut2: nonlinear regression Start 1
Case STAT-NIST-CHWIRUT2-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Chwirut2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_CHWIRUT2.json
Settings compared
curve= "custom"expression= "exp(-b1*x)/(b2+b3*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.1}, {"name": "b2", "start": 0.01}, {"name": "b3", "start": 0.02}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 51 | 51 | 0.00E+2 | passed | |
/sse | lre | 5.1304802941E+02 | 513.0480294068653 | 3.13E-9 | 11 | passed |
/artifact/residual_variance | lre | 10.05976528277059641600 | 10.059765282487556 | 2.83E-10 | 10 | passed |
/artifact/estimates/0 | lre | 1.6657666537E-01 | 0.16657666536804017 | 1.96E-12 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.001467141780449119976100 | 0.001467141780474518 | 2.54E-14 | 10 | passed |
/artifact/estimates/1 | lre | 5.1653291286E-03 | 0.005165329128572583 | 2.74E-14 | 11 | passed |
/artifact/covariance/1/1 | lre | 4.438438269564669475876E-7 | 4.4384382696228935e-07 | 5.82E-18 | 10 | passed |
/artifact/estimates/2 | lre | 1.2150007096E-02 | 0.01215000709582964 | 1.70E-13 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.00000234219601803451544289 | 2.3421960179905598e-06 | 4.40E-17 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 2.0e-15 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = exp(-b1*x)/(b2+b3*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Chwirut2: nonlinear regression Start 2
Case STAT-NIST-CHWIRUT2-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Chwirut2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_CHWIRUT2.json
Settings compared
curve= "custom"expression= "exp(-b1*x)/(b2+b3*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.15}, {"name": "b2", "start": 0.008}, {"name": "b3", "start": 0.01}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 51 | 51 | 0.00E+2 | passed | |
/sse | lre | 5.1304802941E+02 | 513.0480294068657 | 3.13E-9 | 11 | passed |
/artifact/residual_variance | lre | 10.05976528277059641600 | 10.059765282487563 | 2.83E-10 | 10 | passed |
/artifact/estimates/0 | lre | 1.6657666537E-01 | 0.16657666536803956 | 1.96E-12 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.001467141780449119976100 | 0.0014671417804745122 | 2.54E-14 | 10 | passed |
/artifact/estimates/1 | lre | 5.1653291286E-03 | 0.005165329128572575 | 2.74E-14 | 11 | passed |
/artifact/covariance/1/1 | lre | 4.438438269564669475876E-7 | 4.438438269622887e-07 | 5.82E-18 | 10 | passed |
/artifact/estimates/2 | lre | 1.2150007096E-02 | 0.01215000709582966 | 1.70E-13 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.00000234219601803451544289 | 2.342196017990556e-06 | 4.40E-17 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 2.2e-15 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = exp(-b1*x)/(b2+b3*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST DanWood: nonlinear regression Start 1
Case STAT-NIST-DANWOOD-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/DanWood.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_DANWOOD.json
Settings compared
curve= "custom"expression= "b1*x**b2"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.0}, {"name": "b2", "start": 5.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 4 | 4 | 0.00E+2 | passed | |
/sse | lre | 4.3173084083E-03 | 0.004317308408291094 | 8.91E-15 | 11 | passed |
/artifact/residual_variance | lre | 0.001079327102059538893521 | 0.0010793271020727736 | 1.32E-14 | 10 | passed |
/artifact/estimates/0 | lre | 7.6886226176E-01 | 0.7688622617649826 | 4.98E-12 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.000334230568217723299600 | 0.0003342305682229004 | 5.18E-15 | 10 | passed |
/artifact/estimates/1 | lre | 3.8604055871E+00 | 3.8604055870760576 | 2.39E-11 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.002675642276544890693569 | 0.002675642276531193 | 1.37E-14 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 5.6e-14 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 2 Parameters (b1 and b2) y = b1*x**b2 + e
- HypoNum accuracy policy: minimum 4 digits.
NIST DanWood: nonlinear regression Start 2
Case STAT-NIST-DANWOOD-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/DanWood.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_DANWOOD.json
Settings compared
curve= "custom"expression= "b1*x**b2"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.7}, {"name": "b2", "start": 4.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 4 | 4 | 0.00E+2 | passed | |
/sse | lre | 4.3173084083E-03 | 0.004317308408291083 | 8.92E-15 | 11 | passed |
/artifact/residual_variance | lre | 0.001079327102059538893521 | 0.0010793271020727707 | 1.32E-14 | 10 | passed |
/artifact/estimates/0 | lre | 7.6886226176E-01 | 0.7688622617649825 | 4.98E-12 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.000334230568217723299600 | 0.0003342305682228993 | 5.18E-15 | 10 | passed |
/artifact/estimates/1 | lre | 3.8604055871E+00 | 3.860405587076058 | 2.39E-11 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.002675642276544890693569 | 0.002675642276531186 | 1.37E-14 | 11 | passed |
Convention
- NIST model: Model: Miscellaneous Class 2 Parameters (b1 and b2) y = b1*x**b2 + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Eckerle4: nonlinear regression Start 1
Case STAT-NIST-ECKERLE4-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Eckerle4.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ECKERLE4.json
Settings compared
curve= "custom"expression= "(b1/b2) * exp(-0.5*((x-b3)/b2)**2)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.0}, {"name": "b2", "start": 10.0}, {"name": "b3", "start": 500.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 32 | 32 | 0.00E+2 | passed | |
/sse | lre | 1.4635887487E-03 | 0.0014635887487274716 | 2.75E-14 | 10 | passed |
/artifact/residual_variance | lre | 0.00004573714839730570229809 | 4.5737148397733486e-05 | 4.28E-16 | 11 | passed |
/artifact/estimates/0 | lre | 1.5543827178E+00 | 1.5543827177526135 | 4.74E-11 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.000237408040641625652569 | 0.00023740804065685078 | 1.52E-14 | 10 | passed |
/artifact/estimates/1 | lre | 4.0888321754E+00 | 4.088832175423007 | 2.30E-11 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.002190522751605748687009 | 0.0021905227516353745 | 2.96E-14 | 10 | passed |
/artifact/estimates/2 | lre | 4.5154121844E+02 | 451.54121843614496 | 3.86E-9 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.002190288561446770041856 | 0.002190288561488565 | 4.18E-14 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = (b1/b2) * exp[-0.5*((x-b3)/b2)**2] + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Eckerle4: nonlinear regression Start 2
Case STAT-NIST-ECKERLE4-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Eckerle4.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ECKERLE4.json
Settings compared
curve= "custom"expression= "(b1/b2) * exp(-0.5*((x-b3)/b2)**2)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.5}, {"name": "b2", "start": 5.0}, {"name": "b3", "start": 450.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 32 | 32 | 0.00E+2 | passed | |
/sse | lre | 1.4635887487E-03 | 0.0014635887487274711 | 2.75E-14 | 10 | passed |
/artifact/residual_variance | lre | 0.00004573714839730570229809 | 4.573714839773347e-05 | 4.28E-16 | 11 | passed |
/artifact/estimates/0 | lre | 1.5543827178E+00 | 1.5543827177526137 | 4.74E-11 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.000237408040641625652569 | 0.000237408040656851 | 1.52E-14 | 10 | passed |
/artifact/estimates/1 | lre | 4.0888321754E+00 | 4.088832175423008 | 2.30E-11 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.002190522751605748687009 | 0.0021905227516353775 | 2.96E-14 | 10 | passed |
/artifact/estimates/2 | lre | 4.5154121844E+02 | 451.54121843614496 | 3.86E-9 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.002190288561446770041856 | 0.0021902885614885647 | 4.18E-14 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 2.1e-12 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = (b1/b2) * exp[-0.5*((x-b3)/b2)**2] + e
- HypoNum accuracy policy: minimum 4 digits.
NIST ENSO: nonlinear regression Start 1
Case STAT-NIST-ENSO-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/ENSO.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ENSO.json
Settings compared
curve= "custom"expression= "b1 + b2*cos( 2*3.141592653589793*x/12 ) + b3*sin( 2*3.141592653589793*x/12 ) + b5*cos( 2*3.141592653589793*x/b4 ) + b6*sin( 2*3.141592653589793*x/b4 ) + b8*cos( 2*3.141592653589793*x/b7 ) + b9*sin( 2*3.141592653589793*x/b7 )"max_evaluations= 10000parameters= [{"name": "b1", "start": 11.0}, {"name": "b2", "start": 3.0}, {"name": "b3", "start": 0.5}, {"name": "b4", "start": 40.0}, {"name": "b5", "start": -0.7}, {"name": "b6", "start": -1.3}, {"name": "b7", "start": 25.0}, {"name": "b8", "start": -0.3}, {"name": "b9", "start": 1.4}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 159 | 159 | 0.00E+2 | passed | |
/sse | lre | 7.8853978668E+02 | 788.539786682912 | 2.91E-9 | 11 | passed |
/artifact/residual_variance | lre | 4.95936972757495614409 | 4.959369727565484 | 9.47E-12 | 11 | passed |
/artifact/estimates/0 | lre | 1.0510749193E+01 | 10.510749192771353 | 2.29E-10 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.0305859261058793306089 | 0.030585926106121427 | 2.42E-13 | 11 | passed |
/artifact/estimates/1 | lre | 3.0762128085E+00 | 3.0762128085385 | 3.85E-11 | 10 | passed |
/artifact/covariance/1/1 | lre | 0.0590978635000898475321 | 0.05909786350044775 | 3.58E-13 | 11 | passed |
/artifact/estimates/2 | lre | 5.3280138227E-01 | 0.5328013822659554 | 4.04E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.0593150760260988277924 | 0.059315076026382835 | 2.84E-13 | 11 | passed |
/artifact/estimates/3 | lre | 4.4311088700E+01 | 44.31108870022046 | 2.20E-10 | 11 | passed |
/artifact/covariance/3/3 | lre | 0.8912875368685090752576 | 0.8912875368767411 | 8.23E-12 | 11 | passed |
/artifact/estimates/4 | lre | -1.6231428586E+00 | -1.6231428586266645 | 2.67E-11 | 10 | passed |
/artifact/covariance/4/4 | lre | 0.0788394840011928291321 | 0.07883948399890466 | 2.29E-12 | 10 | passed |
/artifact/estimates/5 | lre | 5.2554493756E-01 | 0.5255449375581798 | 1.82E-12 | 11 | passed |
/artifact/covariance/5/5 | lre | 0.2311080739278941852161 | 0.2311080739251585 | 2.74E-12 | 10 | passed |
/artifact/estimates/6 | lre | 2.6887614440E+01 | 26.887614440024592 | 2.46E-11 | 12 | passed |
/artifact/covariance/6/6 | lre | 0.1731636703037085156900 | 0.17316367029954932 | 4.16E-12 | 10 | passed |
/artifact/estimates/7 | lre | 2.1232288488E-01 | 0.21232288488151732 | 1.52E-12 | 11 | passed |
/artifact/covariance/7/7 | lre | 0.2648133958000644913921 | 0.26481339580125024 | 1.19E-12 | 11 | passed |
/artifact/estimates/8 | lre | 1.4966870418E+00 | 1.4966870418316047 | 3.16E-11 | 10 | passed |
/artifact/covariance/8/8 | lre | 0.0646912207868984645449 | 0.06469122078790132 | 1.00E-12 | 10 | passed |
Convention
- NIST model: Model: Miscellaneous Class 9 Parameters (b1 to b9) y = b1 + b2*cos( 2*pi*x/12 ) + b3*sin( 2*pi*x/12 ) + b5*cos( 2*pi*x/b4 ) + b6*sin( 2*pi*x/b4 ) + b8*cos( 2*pi*x/b7 ) + b9*sin( 2*pi*x/b7 ) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST ENSO: nonlinear regression Start 2
Case STAT-NIST-ENSO-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/ENSO.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ENSO.json
Settings compared
curve= "custom"expression= "b1 + b2*cos( 2*3.141592653589793*x/12 ) + b3*sin( 2*3.141592653589793*x/12 ) + b5*cos( 2*3.141592653589793*x/b4 ) + b6*sin( 2*3.141592653589793*x/b4 ) + b8*cos( 2*3.141592653589793*x/b7 ) + b9*sin( 2*3.141592653589793*x/b7 )"max_evaluations= 10000parameters= [{"name": "b1", "start": 10.0}, {"name": "b2", "start": 3.0}, {"name": "b3", "start": 0.5}, {"name": "b4", "start": 44.0}, {"name": "b5", "start": -1.5}, {"name": "b6", "start": 0.5}, {"name": "b7", "start": 26.0}, {"name": "b8", "start": -0.1}, {"name": "b9", "start": 1.5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 159 | 159 | 0.00E+2 | passed | |
/sse | lre | 7.8853978668E+02 | 788.539786682912 | 2.91E-9 | 11 | passed |
/artifact/residual_variance | lre | 4.95936972757495614409 | 4.959369727565484 | 9.47E-12 | 11 | passed |
/artifact/estimates/0 | lre | 1.0510749193E+01 | 10.510749192771353 | 2.29E-10 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.0305859261058793306089 | 0.030585926106121448 | 2.42E-13 | 11 | passed |
/artifact/estimates/1 | lre | 3.0762128085E+00 | 3.0762128085385 | 3.85E-11 | 10 | passed |
/artifact/covariance/1/1 | lre | 0.0590978635000898475321 | 0.059097863500447705 | 3.58E-13 | 11 | passed |
/artifact/estimates/2 | lre | 5.3280138227E-01 | 0.5328013822659554 | 4.04E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.0593150760260988277924 | 0.05931507602638284 | 2.84E-13 | 11 | passed |
/artifact/estimates/3 | lre | 4.4311088700E+01 | 44.31108870022046 | 2.20E-10 | 11 | passed |
/artifact/covariance/3/3 | lre | 0.8912875368685090752576 | 0.8912875368767393 | 8.23E-12 | 11 | passed |
/artifact/estimates/4 | lre | -1.6231428586E+00 | -1.6231428586266647 | 2.67E-11 | 10 | passed |
/artifact/covariance/4/4 | lre | 0.0788394840011928291321 | 0.07883948399890467 | 2.29E-12 | 10 | passed |
/artifact/estimates/5 | lre | 5.2554493756E-01 | 0.5255449375581797 | 1.82E-12 | 11 | passed |
/artifact/covariance/5/5 | lre | 0.2311080739278941852161 | 0.23110807392515847 | 2.74E-12 | 10 | passed |
/artifact/estimates/6 | lre | 2.6887614440E+01 | 26.887614440024592 | 2.46E-11 | 12 | passed |
/artifact/covariance/6/6 | lre | 0.1731636703037085156900 | 0.17316367029954907 | 4.16E-12 | 10 | passed |
/artifact/estimates/7 | lre | 2.1232288488E-01 | 0.2123228848815172 | 1.52E-12 | 11 | passed |
/artifact/covariance/7/7 | lre | 0.2648133958000644913921 | 0.26481339580125024 | 1.19E-12 | 11 | passed |
/artifact/estimates/8 | lre | 1.4966870418E+00 | 1.496687041831605 | 3.16E-11 | 10 | passed |
/artifact/covariance/8/8 | lre | 0.0646912207868984645449 | 0.06469122078790134 | 1.00E-12 | 10 | passed |
Convention
- NIST model: Model: Miscellaneous Class 9 Parameters (b1 to b9) y = b1 + b2*cos( 2*pi*x/12 ) + b3*sin( 2*pi*x/12 ) + b5*cos( 2*pi*x/b4 ) + b6*sin( 2*pi*x/b4 ) + b8*cos( 2*pi*x/b7 ) + b9*sin( 2*pi*x/b7 ) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Filip: fit
Case STAT-NIST-FILIP-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Filip.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_FILIP.json
Settings compared
algorithm= "ols"degree= 10model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 82 | 82 | 0.00E+2 | passed | |
/responses/0/parameters/[term=Intercept]/estimate | lre | -1467.48961422980 | -1467.4896142297782 | 2.18E-11 | 13 | passed |
/responses/0/parameters/[term=Intercept]/std_error | lre | 298.084530995537 | 298.0845309955336 | 3.39E-12 | 13 | passed |
/responses/0/parameters/[term=x]/estimate | lre | -2772.17959193342 | -2772.1795919333927 | 2.73E-11 | 14 | passed |
/responses/0/parameters/[term=x]/std_error | lre | 559.779865474950 | 559.7798654749438 | 6.21E-12 | 13 | passed |
/responses/0/parameters/[term=x^2]/estimate | lre | -2316.37108160893 | -2316.371081608905 | 2.49E-11 | 13 | passed |
/responses/0/parameters/[term=x^2]/std_error | lre | 466.477572127796 | 466.4775721277913 | 4.71E-12 | 13 | passed |
/responses/0/parameters/[term=x^3]/estimate | lre | -1127.97394098372 | -1127.9739409837034 | 1.66E-11 | 13 | passed |
/responses/0/parameters/[term=x^3]/std_error | lre | 227.204274477751 | 227.2042744777488 | 2.19E-12 | 14 | passed |
/responses/0/parameters/[term=x^4]/estimate | lre | -354.478233703349 | -354.4782337033449 | 4.07E-12 | 13 | passed |
/responses/0/parameters/[term=x^4]/std_error | lre | 71.6478660875927 | 71.64786608759194 | 7.64E-13 | 13 | passed |
/responses/0/parameters/[term=x^5]/estimate | lre | -75.1242017393757 | -75.1242017393749 | 8.03E-13 | 13 | passed |
/responses/0/parameters/[term=x^5]/std_error | lre | 15.2897178747400 | 15.28971787473983 | 1.70E-13 | 13 | passed |
/responses/0/parameters/[term=x^6]/estimate | lre | -10.8753180355343 | -10.875318035534134 | 1.66E-13 | 13 | passed |
/responses/0/parameters/[term=x^6]/std_error | lre | 2.23691159816033 | 2.2369115981603067 | 2.33E-14 | 13 | passed |
/responses/0/parameters/[term=x^7]/estimate | lre | -1.06221498588947 | -1.0622149858894563 | 1.37E-14 | 13 | passed |
/responses/0/parameters/[term=x^7]/std_error | lre | 0.221624321934227 | 0.2216243219342248 | 2.21E-15 | 14 | passed |
/responses/0/parameters/[term=x^8]/estimate | lre | -0.670191154593408E-01 | -0.06701911545934013 | 6.74E-16 | 13 | passed |
/responses/0/parameters/[term=x^8]/std_error | lre | 0.142363763154724E-01 | 0.014236376315472228 | 1.72E-16 | 13 | passed |
/responses/0/parameters/[term=x^9]/estimate | lre | -0.246781078275479E-02 | -0.0024678107827547603 | 2.97E-17 | 13 | passed |
/responses/0/parameters/[term=x^9]/std_error | lre | 0.535617408889821E-03 | 0.0005356174088898144 | 6.57E-18 | 13 | passed |
/responses/0/parameters/[term=x^10]/estimate | lre | -0.402962525080404E-04 | -4.0296252508039944e-05 | 4.56E-19 | 13 | passed |
/responses/0/parameters/[term=x^10]/std_error | lre | 0.896632837373868E-05 | 8.966328373738576e-06 | 1.04E-19 | 13 | passed |
/responses/0/anova/[source=Error]/ss | lre | 0.795851382172941E-03 | 0.0007958513821729283 | 1.27E-17 | 13 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 10 | 10.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 71 | 71.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/ms | lre | 0.00001120917439680199456968168079 | 1.1209174396801807e-05 | 1.88E-19 | 13 | passed |
/responses/0/metrics/r_squared | lre | 0.996727416185620 | 0.9967274161856202 | 2.19E-16 | 15 | passed |
/responses/0/anova/[source=Model]/f_stat | lre | 2162.43954511489 | 2162.439545114922 | 3.21E-11 | 13 | passed |
Convention
- NIST model: Model: Polynomial Class 11 Parameters (B0,B1,...,B10) y = B0 + B1*x + B2*(x**2) + ... + B9*(x**9) + B10*(x**10) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Gauss1: nonlinear regression Start 1
Case STAT-NIST-GAUSS1-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Gauss1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_GAUSS1.json
Settings compared
curve= "custom"expression= "b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 )"max_evaluations= 10000parameters= [{"name": "b1", "start": 97.0}, {"name": "b2", "start": 0.009}, {"name": "b3", "start": 100.0}, {"name": "b4", "start": 65.0}, {"name": "b5", "start": 20.0}, {"name": "b6", "start": 70.0}, {"name": "b7", "start": 178.0}, {"name": "b8", "start": 16.5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 242 | 242 | 0.00E+2 | passed | |
/sse | lre | 1.3158222432E+03 | 1315.8222432033776 | 3.38E-9 | 11 | passed |
/artifact/residual_variance | lre | 5.43728199674872832400 | 5.4372819967081725 | 4.06E-11 | 11 | passed |
/artifact/estimates/0 | lre | 9.8778210871E+01 | 98.77821087103072 | 3.07E-11 | 12 | passed |
/artifact/covariance/0/0 | lre | 0.3309391709935220052900 | 0.3309391709955723 | 2.05E-12 | 11 | passed |
/artifact/estimates/1 | lre | 1.0497276517E-02 | 0.010497276517168547 | 1.69E-13 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.30103429139334826289E-8 | 1.3010342914530905e-08 | 5.97E-19 | 10 | passed |
/artifact/estimates/2 | lre | 1.0048990633E+02 | 100.48990632956493 | 4.35E-10 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.3461177838133615165504 | 0.3461177838151048 | 1.74E-12 | 11 | passed |
/artifact/estimates/3 | lre | 6.7481111276E+01 | 67.48111127631947 | 3.19E-10 | 11 | passed |
/artifact/covariance/3/3 | lre | 0.0109424014531177801744 | 0.010942401453213065 | 9.53E-14 | 11 | passed |
/artifact/estimates/4 | lre | 2.3129773360E+01 | 23.129773359658554 | 3.41E-10 | 10 | passed |
/artifact/covariance/4/4 | lre | 0.0304151895974866713316 | 0.03041518959824542 | 7.59E-13 | 10 | passed |
/artifact/estimates/5 | lre | 7.1994503004E+01 | 71.99450300373363 | 2.66E-10 | 11 | passed |
/artifact/covariance/5/5 | lre | 0.3921614317470069851569 | 0.39216143174686435 | 1.43E-13 | 12 | passed |
/artifact/estimates/6 | lre | 1.7899805021E+02 | 178.99805020726387 | 2.74E-9 | 10 | passed |
/artifact/covariance/6/6 | lre | 0.0154678675909796839089 | 0.015467867591097417 | 1.18E-13 | 11 | passed |
/artifact/estimates/7 | lre | 1.8389389025E+01 | 18.389389025487034 | 4.87E-10 | 10 | passed |
/artifact/covariance/7/7 | lre | 0.0405390553216839860224 | 0.040539055322391736 | 7.08E-13 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 6.9e-16 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 8 Parameters (b1 to b8) y = b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 ) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Gauss1: nonlinear regression Start 2
Case STAT-NIST-GAUSS1-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Gauss1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_GAUSS1.json
Settings compared
curve= "custom"expression= "b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 )"max_evaluations= 10000parameters= [{"name": "b1", "start": 94.0}, {"name": "b2", "start": 0.0105}, {"name": "b3", "start": 99.0}, {"name": "b4", "start": 63.0}, {"name": "b5", "start": 25.0}, {"name": "b6", "start": 71.0}, {"name": "b7", "start": 180.0}, {"name": "b8", "start": 20.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 242 | 242 | 0.00E+2 | passed | |
/sse | lre | 1.3158222432E+03 | 1315.8222432033779 | 3.38E-9 | 11 | passed |
/artifact/residual_variance | lre | 5.43728199674872832400 | 5.437281996708173 | 4.06E-11 | 11 | passed |
/artifact/estimates/0 | lre | 9.8778210871E+01 | 98.77821087103072 | 3.07E-11 | 12 | passed |
/artifact/covariance/0/0 | lre | 0.3309391709935220052900 | 0.330939170995573 | 2.05E-12 | 11 | passed |
/artifact/estimates/1 | lre | 1.0497276517E-02 | 0.010497276517168547 | 1.69E-13 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.30103429139334826289E-8 | 1.3010342914530912e-08 | 5.97E-19 | 10 | passed |
/artifact/estimates/2 | lre | 1.0048990633E+02 | 100.48990632956492 | 4.35E-10 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.3461177838133615165504 | 0.34611778381510516 | 1.74E-12 | 11 | passed |
/artifact/estimates/3 | lre | 6.7481111276E+01 | 67.48111127631947 | 3.19E-10 | 11 | passed |
/artifact/covariance/3/3 | lre | 0.0109424014531177801744 | 0.010942401453213091 | 9.53E-14 | 11 | passed |
/artifact/estimates/4 | lre | 2.3129773360E+01 | 23.129773359658557 | 3.41E-10 | 10 | passed |
/artifact/covariance/4/4 | lre | 0.0304151895974866713316 | 0.030415189598245438 | 7.59E-13 | 10 | passed |
/artifact/estimates/5 | lre | 7.1994503004E+01 | 71.99450300373363 | 2.66E-10 | 11 | passed |
/artifact/covariance/5/5 | lre | 0.3921614317470069851569 | 0.3921614317468642 | 1.43E-13 | 12 | passed |
/artifact/estimates/6 | lre | 1.7899805021E+02 | 178.99805020726387 | 2.74E-9 | 10 | passed |
/artifact/covariance/6/6 | lre | 0.0154678675909796839089 | 0.01546786759109745 | 1.18E-13 | 11 | passed |
/artifact/estimates/7 | lre | 1.8389389025E+01 | 18.389389025487034 | 4.87E-10 | 10 | passed |
/artifact/covariance/7/7 | lre | 0.0405390553216839860224 | 0.04053905532239176 | 7.08E-13 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 8 Parameters (b1 to b8) y = b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 ) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Gauss2: nonlinear regression Start 1
Case STAT-NIST-GAUSS2-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Gauss2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_GAUSS2.json
Settings compared
curve= "custom"expression= "b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 )"max_evaluations= 10000parameters= [{"name": "b1", "start": 96.0}, {"name": "b2", "start": 0.009}, {"name": "b3", "start": 103.0}, {"name": "b4", "start": 106.0}, {"name": "b5", "start": 18.0}, {"name": "b6", "start": 72.0}, {"name": "b7", "start": 151.0}, {"name": "b8", "start": 18.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 242 | 242 | 0.00E+2 | passed | |
/sse | lre | 1.2475282092E+03 | 1247.5282092309983 | 3.10E-8 | 10 | passed |
/artifact/residual_variance | lre | 5.15507524454392171524 | 5.155075244756191 | 2.12E-10 | 10 | passed |
/artifact/estimates/0 | lre | 9.9018328406E+01 | 99.01832840593642 | 6.36E-11 | 12 | passed |
/artifact/covariance/0/0 | lre | 0.2888929941013087400641 | 0.2888929940982791 | 3.03E-12 | 10 | passed |
/artifact/estimates/1 | lre | 1.0994945399E-02 | 0.010994945398639277 | 3.61E-13 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.77830406543325378756E-8 | 1.7783040653063657e-08 | 1.27E-18 | 10 | passed |
/artifact/estimates/2 | lre | 1.0188022528E+02 | 101.88022527525033 | 4.75E-9 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.3506690487240759955984 | 0.35066904872889665 | 4.82E-12 | 10 | passed |
/artifact/estimates/3 | lre | 1.0703095519E+02 | 107.0309551859637 | 4.04E-9 | 10 | passed |
/artifact/covariance/3/3 | lre | 0.0225203995697100435856 | 0.02252039957006401 | 3.54E-13 | 10 | passed |
/artifact/estimates/4 | lre | 2.3578584029E+01 | 23.57858402856899 | 4.31E-10 | 10 | passed |
/artifact/covariance/4/4 | lre | 0.0515090035445234734489 | 0.05150900354408575 | 4.38E-13 | 11 | passed |
/artifact/estimates/5 | lre | 7.2045589471E+01 | 72.04558947063778 | 3.62E-10 | 11 | passed |
/artifact/covariance/5/5 | lre | 0.3809601072585659901456 | 0.38096010725750834 | 1.06E-12 | 11 | passed |
/artifact/estimates/6 | lre | 1.5327010194E+02 | 153.2701019412732 | 1.27E-9 | 11 | passed |
/artifact/covariance/6/6 | lre | 0.0378951409898547784281 | 0.03789514098893975 | 9.15E-13 | 10 | passed |
/artifact/estimates/7 | lre | 1.9525972636E+01 | 19.525972636335617 | 3.36E-10 | 10 | passed |
/artifact/covariance/7/7 | lre | 0.0697834081832808668449 | 0.06978340818400056 | 7.20E-13 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 8 Parameters (b1 to b8) y = b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 ) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Gauss2: nonlinear regression Start 2
Case STAT-NIST-GAUSS2-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Gauss2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_GAUSS2.json
Settings compared
curve= "custom"expression= "b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 )"max_evaluations= 10000parameters= [{"name": "b1", "start": 98.0}, {"name": "b2", "start": 0.0105}, {"name": "b3", "start": 103.0}, {"name": "b4", "start": 105.0}, {"name": "b5", "start": 20.0}, {"name": "b6", "start": 73.0}, {"name": "b7", "start": 150.0}, {"name": "b8", "start": 20.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 242 | 242 | 0.00E+2 | passed | |
/sse | lre | 1.2475282092E+03 | 1247.5282092309985 | 3.10E-8 | 10 | passed |
/artifact/residual_variance | lre | 5.15507524454392171524 | 5.155075244756192 | 2.12E-10 | 10 | passed |
/artifact/estimates/0 | lre | 9.9018328406E+01 | 99.01832840593642 | 6.36E-11 | 12 | passed |
/artifact/covariance/0/0 | lre | 0.2888929941013087400641 | 0.28889299409828195 | 3.03E-12 | 10 | passed |
/artifact/estimates/1 | lre | 1.0994945399E-02 | 0.01099494539863937 | 3.61E-13 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.77830406543325378756E-8 | 1.7783040653064282e-08 | 1.27E-18 | 10 | passed |
/artifact/estimates/2 | lre | 1.0188022528E+02 | 101.88022527524991 | 4.75E-9 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.3506690487240759955984 | 0.3506690487288927 | 4.82E-12 | 10 | passed |
/artifact/estimates/3 | lre | 1.0703095519E+02 | 107.03095518596403 | 4.04E-9 | 10 | passed |
/artifact/covariance/3/3 | lre | 0.0225203995697100435856 | 0.02252039957006427 | 3.54E-13 | 10 | passed |
/artifact/estimates/4 | lre | 2.3578584029E+01 | 23.578584028569768 | 4.30E-10 | 10 | passed |
/artifact/covariance/4/4 | lre | 0.0515090035445234734489 | 0.05150900354408827 | 4.35E-13 | 11 | passed |
/artifact/estimates/5 | lre | 7.2045589471E+01 | 72.04558947063767 | 3.62E-10 | 11 | passed |
/artifact/covariance/5/5 | lre | 0.3809601072585659901456 | 0.38096010725751817 | 1.05E-12 | 11 | passed |
/artifact/estimates/6 | lre | 1.5327010194E+02 | 153.27010194127377 | 1.27E-9 | 11 | passed |
/artifact/covariance/6/6 | lre | 0.0378951409898547784281 | 0.03789514098893781 | 9.17E-13 | 10 | passed |
/artifact/estimates/7 | lre | 1.9525972636E+01 | 19.525972636335073 | 3.35E-10 | 10 | passed |
/artifact/covariance/7/7 | lre | 0.0697834081832808668449 | 0.0697834081839956 | 7.15E-13 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 8 Parameters (b1 to b8) y = b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 ) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Gauss3: nonlinear regression Start 1
Case STAT-NIST-GAUSS3-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Gauss3.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_GAUSS3.json
Settings compared
curve= "custom"expression= "b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 )"max_evaluations= 10000parameters= [{"name": "b1", "start": 94.9}, {"name": "b2", "start": 0.009}, {"name": "b3", "start": 90.1}, {"name": "b4", "start": 113.0}, {"name": "b5", "start": 20.0}, {"name": "b6", "start": 73.8}, {"name": "b7", "start": 140.0}, {"name": "b8", "start": 20.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 242 | 242 | 0.00E+2 | passed | |
/sse | lre | 1.2444846360E+03 | 1244.4846360131571 | 1.32E-8 | 10 | passed |
/artifact/residual_variance | lre | 5.14249849610275640625 | 5.142498495922137 | 1.81E-10 | 10 | passed |
/artifact/estimates/0 | lre | 9.8940368970E+01 | 98.94036896986974 | 1.30E-10 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.2809550467263514565889 | 0.28095504672325367 | 3.10E-12 | 10 | passed |
/artifact/estimates/1 | lre | 1.0945879335E-02 | 0.010945879334886919 | 1.13E-13 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.57604395140858505921E-8 | 1.5760439513043066e-08 | 1.04E-18 | 10 | passed |
/artifact/estimates/2 | lre | 1.0069553078E+02 | 100.69553077815802 | 1.84E-9 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.6602632982405245258489 | 0.6602632982462446 | 5.72E-12 | 11 | passed |
/artifact/estimates/3 | lre | 1.1163619459E+02 | 111.63619458725324 | 2.75E-9 | 10 | passed |
/artifact/covariance/3/3 | lre | 0.1247351217815120099049 | 0.12473512178121048 | 3.02E-13 | 11 | passed |
/artifact/estimates/4 | lre | 2.3300500029E+01 | 23.300500029169655 | 1.70E-10 | 11 | passed |
/artifact/covariance/4/4 | lre | 0.1338446348839989018529 | 0.13384463488609044 | 2.09E-12 | 10 | passed |
/artifact/estimates/5 | lre | 7.3705031418E+01 | 73.70503141760388 | 3.96E-10 | 11 | passed |
/artifact/covariance/5/5 | lre | 1.46198062538084202724 | 1.4619806254406629 | 5.98E-11 | 10 | passed |
/artifact/estimates/6 | lre | 1.4776164251E+02 | 147.76164250510547 | 4.89E-9 | 10 | passed |
/artifact/covariance/6/6 | lre | 0.1639292991064193589201 | 0.16392929910295057 | 3.47E-12 | 10 | passed |
/artifact/estimates/7 | lre | 1.9668221230E+01 | 19.668221229597783 | 4.02E-10 | 10 | passed |
/artifact/covariance/7/7 | lre | 0.1429341599816014160896 | 0.14293415997976577 | 1.84E-12 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 8 Parameters (b1 to b8) y = b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 ) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Gauss3: nonlinear regression Start 2
Case STAT-NIST-GAUSS3-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Gauss3.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_GAUSS3.json
Settings compared
curve= "custom"expression= "b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 )"max_evaluations= 10000parameters= [{"name": "b1", "start": 96.0}, {"name": "b2", "start": 0.0096}, {"name": "b3", "start": 80.0}, {"name": "b4", "start": 110.0}, {"name": "b5", "start": 25.0}, {"name": "b6", "start": 74.0}, {"name": "b7", "start": 139.0}, {"name": "b8", "start": 25.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 242 | 242 | 0.00E+2 | passed | |
/sse | lre | 1.2444846360E+03 | 1244.484636013157 | 1.32E-8 | 10 | passed |
/artifact/residual_variance | lre | 5.14249849610275640625 | 5.142498495922136 | 1.81E-10 | 10 | passed |
/artifact/estimates/0 | lre | 9.8940368970E+01 | 98.94036896986972 | 1.30E-10 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.2809550467263514565889 | 0.28095504672325344 | 3.10E-12 | 10 | passed |
/artifact/estimates/1 | lre | 1.0945879335E-02 | 0.010945879334886902 | 1.13E-13 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.57604395140858505921E-8 | 1.5760439513042984e-08 | 1.04E-18 | 10 | passed |
/artifact/estimates/2 | lre | 1.0069553078E+02 | 100.69553077815794 | 1.84E-9 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.6602632982405245258489 | 0.6602632982462541 | 5.73E-12 | 11 | passed |
/artifact/estimates/3 | lre | 1.1163619459E+02 | 111.63619458725314 | 2.75E-9 | 10 | passed |
/artifact/covariance/3/3 | lre | 0.1247351217815120099049 | 0.1247351217812095 | 3.03E-13 | 11 | passed |
/artifact/estimates/4 | lre | 2.3300500029E+01 | 23.300500029169495 | 1.69E-10 | 11 | passed |
/artifact/covariance/4/4 | lre | 0.1338446348839989018529 | 0.13384463488608858 | 2.09E-12 | 10 | passed |
/artifact/estimates/5 | lre | 7.3705031418E+01 | 73.70503141760429 | 3.96E-10 | 11 | passed |
/artifact/covariance/5/5 | lre | 1.46198062538084202724 | 1.4619806254406185 | 5.98E-11 | 10 | passed |
/artifact/estimates/6 | lre | 1.4776164251E+02 | 147.76164250510536 | 4.89E-9 | 10 | passed |
/artifact/covariance/6/6 | lre | 0.1639292991064193589201 | 0.16392929910295104 | 3.47E-12 | 10 | passed |
/artifact/estimates/7 | lre | 1.9668221230E+01 | 19.66822122959785 | 4.02E-10 | 10 | passed |
/artifact/covariance/7/7 | lre | 0.1429341599816014160896 | 0.1429341599797666 | 1.83E-12 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 5.5e-16 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 8 Parameters (b1 to b8) y = b1*exp( -b2*x ) + b3*exp( -(x-b4)**2 / b5**2 ) + b6*exp( -(x-b7)**2 / b8**2 ) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Hahn1: nonlinear regression Start 1
Case STAT-NIST-HAHN1-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Hahn1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_HAHN1.json
Settings compared
curve= "custom"expression= "(b1+b2*x+b3*x**2+b4*x**3) / (1+b5*x+b6*x**2+b7*x**3)"max_evaluations= 10000parameters= [{"name": "b1", "start": 10.0}, {"name": "b2", "start": -1.0}, {"name": "b3", "start": 0.05}, {"name": "b4", "start": -1e-05}, {"name": "b5", "start": -0.05}, {"name": "b6", "start": 0.001}, {"name": "b7", "start": -1e-06}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 229 | 229 | 0.00E+2 | passed | |
/sse | lre | 1.5324382854E+00 | 1.5324382853606138 | 3.94E-11 | 10 | passed |
/artifact/residual_variance | lre | 0.006691870241794576131049 | 0.006691870241749405 | 4.52E-14 | 11 | passed |
/artifact/estimates/0 | lre | 1.0776351733E+00 | 1.0776351733098901 | 9.89E-12 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.0291390182915825086564 | 0.029139018232172124 | 5.94E-11 | 8 | passed |
/artifact/estimates/1 | lre | -1.2269296921E-01 | -0.12269296921020498 | 2.05E-13 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.000144006940619630277721 | 0.00014400694054967608 | 7.00E-14 | 9 | passed |
/artifact/estimates/2 | lre | 4.0863750610E-03 | 0.004086375061046685 | 4.67E-14 | 10 | passed |
/artifact/covariance/2/2 | lre | 5.06624241303177313969E-8 | 5.0662424122480604e-08 | 7.84E-18 | 9 | passed |
/artifact/estimates/3 | lre | -1.4262662514E-06 | -1.42626625140785e-06 | 7.85E-18 | 11 | passed |
/artifact/covariance/3/3 | lre | 7.60548161507314727556E-14 | 7.605481614902566e-14 | 1.71E-24 | 10 | passed |
/artifact/estimates/4 | lre | -5.7609940901E-03 | -0.005760994090092357 | 7.64E-15 | 11 | passed |
/artifact/covariance/4/4 | lre | 6.10726844124788991961E-8 | 6.107268441530212e-08 | 2.82E-18 | 10 | passed |
/artifact/estimates/5 | lre | 2.4053735503E-04 | 0.00024053735503176533 | 1.77E-15 | 11 | passed |
/artifact/covariance/5/5 | lre | 1.09189412143366517824E-10 | 1.0918941212565823e-10 | 1.77E-20 | 9 | passed |
/artifact/estimates/6 | lre | -1.2314450199E-07 | -1.231445019919573e-07 | 1.96E-18 | 10 | passed |
/artifact/covariance/6/6 | lre | 1.69711465722102196929E-16 | 1.6971146566852321e-16 | 5.36E-26 | 9 | passed |
Convention
- NIST model: Model: Rational Class (cubic/cubic) 7 Parameters (b1 to b7) y = (b1+b2*x+b3*x**2+b4*x**3) / (1+b5*x+b6*x**2+b7*x**3) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Hahn1: nonlinear regression Start 2
Case STAT-NIST-HAHN1-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Hahn1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_HAHN1.json
Settings compared
curve= "custom"expression= "(b1+b2*x+b3*x**2+b4*x**3) / (1+b5*x+b6*x**2+b7*x**3)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.0}, {"name": "b2", "start": -0.1}, {"name": "b3", "start": 0.005}, {"name": "b4", "start": -1e-06}, {"name": "b5", "start": -0.005}, {"name": "b6", "start": 0.0001}, {"name": "b7", "start": -1e-07}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 229 | 229 | 0.00E+2 | passed | |
/sse | lre | 1.5324382854E+00 | 1.5324382853606284 | 3.94E-11 | 10 | passed |
/artifact/residual_variance | lre | 0.006691870241794576131049 | 0.006691870241749469 | 4.51E-14 | 11 | passed |
/artifact/estimates/0 | lre | 1.0776351733E+00 | 1.077635173311552 | 1.16E-11 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.0291390182915825086564 | 0.029139018271224736 | 2.04E-11 | 9 | passed |
/artifact/estimates/1 | lre | -1.2269296921E-01 | -0.12269296921033016 | 3.30E-13 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.000144006940619630277721 | 0.00014400694060278134 | 1.68E-14 | 9 | passed |
/artifact/estimates/2 | lre | 4.0863750610E-03 | 0.004086375061049112 | 4.91E-14 | 10 | passed |
/artifact/covariance/2/2 | lre | 5.06624241303177313969E-8 | 5.0662424119312555e-08 | 1.10E-17 | 9 | passed |
/artifact/estimates/3 | lre | -1.4262662514E-06 | -1.4262662514110709e-06 | 1.11E-17 | 11 | passed |
/artifact/covariance/3/3 | lre | 7.60548161507314727556E-14 | 7.60548161375172e-14 | 1.32E-23 | 9 | passed |
/artifact/estimates/4 | lre | -5.7609940901E-03 | -0.005760994090091838 | 8.16E-15 | 11 | passed |
/artifact/covariance/4/4 | lre | 6.10726844124788991961E-8 | 6.107268441323152e-08 | 7.53E-19 | 10 | passed |
/artifact/estimates/5 | lre | 2.4053735503E-04 | 0.00024053735503187288 | 1.87E-15 | 11 | passed |
/artifact/covariance/5/5 | lre | 1.09189412143366517824E-10 | 1.0918941213019717e-10 | 1.32E-20 | 9 | passed |
/artifact/estimates/6 | lre | -1.2314450199E-07 | -1.2314450199211132e-07 | 2.11E-18 | 10 | passed |
/artifact/covariance/6/6 | lre | 1.69711465722102196929E-16 | 1.6971146573557257e-16 | 1.35E-26 | 10 | passed |
Convention
- NIST model: Model: Rational Class (cubic/cubic) 7 Parameters (b1 to b7) y = (b1+b2*x+b3*x**2+b4*x**3) / (1+b5*x+b6*x**2+b7*x**3) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Kirby2: nonlinear regression Start 1
Case STAT-NIST-KIRBY2-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Kirby2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_KIRBY2.json
Settings compared
curve= "custom"expression= "(b1 + b2*x + b3*x**2) / (1 + b4*x + b5*x**2)"max_evaluations= 10000parameters= [{"name": "b1", "start": 2.0}, {"name": "b2", "start": -0.1}, {"name": "b3", "start": 0.003}, {"name": "b4", "start": -0.001}, {"name": "b5", "start": 1e-05}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 146 | 146 | 0.00E+2 | passed | |
/sse | lre | 3.9050739624E+00 | 3.9050739623908943 | 9.11E-12 | 11 | passed |
/artifact/residual_variance | lre | 0.0267470819351113187161 | 0.026747081934184208 | 9.27E-13 | 10 | passed |
/artifact/estimates/0 | lre | 1.6745063063E+00 | 1.6745063063218064 | 2.18E-11 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.007742175750934948698244 | 0.0077421757507798086 | 1.55E-13 | 10 | passed |
/artifact/estimates/1 | lre | -1.3927397867E-01 | -0.13927397867473756 | 4.74E-12 | 10 | passed |
/artifact/covariance/1/1 | lre | 0.00001695960532718216800996 | 1.6959605327157046e-05 | 2.51E-17 | 11 | passed |
/artifact/estimates/2 | lre | 2.5961181191E-03 | 0.0025961181190934705 | 6.53E-15 | 11 | passed |
/artifact/covariance/2/2 | lre | 1.751968304850972529764E-9 | 1.7519683048531834e-09 | 2.21E-21 | 11 | passed |
/artifact/estimates/3 | lre | -1.7241811870E-03 | -0.0017241811869827196 | 1.73E-14 | 10 | passed |
/artifact/covariance/3/3 | lre | 3.472968525860255996025E-9 | 3.4729685259017387e-09 | 4.15E-20 | 10 | passed |
/artifact/estimates/4 | lre | 2.1664802578E-05 | 2.1664802577673612e-05 | 3.26E-16 | 10 | passed |
/artifact/covariance/4/4 | lre | 4.05207314915622562561E-14 | 4.052073149317941e-14 | 1.62E-24 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 2.1e-10 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Rational Class (quadratic/quadratic) 5 Parameters (b1 to b5) y = (b1 + b2*x + b3*x**2) / (1 + b4*x + b5*x**2) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Kirby2: nonlinear regression Start 2
Case STAT-NIST-KIRBY2-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Kirby2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_KIRBY2.json
Settings compared
curve= "custom"expression= "(b1 + b2*x + b3*x**2) / (1 + b4*x + b5*x**2)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.5}, {"name": "b2", "start": -0.15}, {"name": "b3", "start": 0.0025}, {"name": "b4", "start": -0.0015}, {"name": "b5", "start": 2e-05}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 146 | 146 | 0.00E+2 | passed | |
/sse | lre | 3.9050739624E+00 | 3.9050739623908837 | 9.12E-12 | 11 | passed |
/artifact/residual_variance | lre | 0.0267470819351113187161 | 0.026747081934184135 | 9.27E-13 | 10 | passed |
/artifact/estimates/0 | lre | 1.6745063063E+00 | 1.6745063063223262 | 2.23E-11 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.007742175750934948698244 | 0.007742175751039572 | 1.05E-13 | 10 | passed |
/artifact/estimates/1 | lre | -1.3927397867E-01 | -0.13927397867476804 | 4.77E-12 | 10 | passed |
/artifact/covariance/1/1 | lre | 0.00001695960532718216800996 | 1.695960532726947e-05 | 8.73E-17 | 11 | passed |
/artifact/estimates/2 | lre | 2.5961181191E-03 | 0.0025961181190937953 | 6.20E-15 | 11 | passed |
/artifact/covariance/2/2 | lre | 1.751968304850972529764E-9 | 1.7519683048634274e-09 | 1.25E-20 | 11 | passed |
/artifact/estimates/3 | lre | -1.7241811870E-03 | -0.0017241811869822918 | 1.77E-14 | 10 | passed |
/artifact/covariance/3/3 | lre | 3.472968525860255996025E-9 | 3.4729685259190483e-09 | 5.88E-20 | 10 | passed |
/artifact/estimates/4 | lre | 2.1664802578E-05 | 2.166480257767509e-05 | 3.25E-16 | 10 | passed |
/artifact/covariance/4/4 | lre | 4.05207314915622562561E-14 | 4.052073149325224e-14 | 1.69E-24 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 4.5e-10 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Rational Class (quadratic/quadratic) 5 Parameters (b1 to b5) y = (b1 + b2*x + b3*x**2) / (1 + b4*x + b5*x**2) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lanczos1: nonlinear regression Start 1
Case STAT-NIST-LANCZOS1-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Lanczos1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LANCZOS1.json
Settings compared
curve= "custom"expression= "b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.2}, {"name": "b2", "start": 0.3}, {"name": "b3", "start": 5.6}, {"name": "b4", "start": 5.5}, {"name": "b5", "start": 6.5}, {"name": "b6", "start": 7.6}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 18 | 18 | 0.00E+2 | passed | |
/sse | lre | 1.4307867721E-25 | 1.4307870632247253e-25 | 2.91E-32 | 6 | passed |
/artifact/residual_variance | lre | 7.948815400495619163801E-27 | 7.94881701791514e-27 | 1.62E-33 | 6 | passed |
/artifact/estimates/0 | lre | 9.5100000027E-02 | 0.09510000002743146 | 4.31E-13 | 11 | passed |
/artifact/covariance/0/0 | lre | 2.845934869034954326756E-21 | 2.8459354481681904e-21 | 5.79E-28 | 6 | passed |
/artifact/estimates/1 | lre | 1.0000000001E+00 | 1.000000000127719 | 2.77E-11 | 10 | passed |
/artifact/covariance/1/1 | lre | 7.54767826784791636041E-20 | 7.547679803850871e-20 | 1.54E-26 | 6 | passed |
/artifact/estimates/2 | lre | 8.6070000013E-01 | 0.8607000001344579 | 4.46E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 1.84309465537071950625E-20 | 1.8430950303783614e-20 | 3.75E-27 | 6 | passed |
/artifact/estimates/3 | lre | 3.0000000002E+00 | 3.0000000002346243 | 3.46E-11 | 10 | passed |
/artifact/covariance/3/3 | lre | 1.109439722508547918761E-19 | 1.1094399482683673e-19 | 2.26E-26 | 6 | passed |
/artifact/estimates/4 | lre | 1.5575999998E+00 | 1.5575999998381713 | 3.82E-11 | 10 | passed |
/artifact/covariance/4/4 | lre | 3.54031749923256176704E-20 | 3.540318219491003e-20 | 7.20E-27 | 6 | passed |
/artifact/estimates/5 | lre | 5.0000000001E+00 | 5.000000000111549 | 1.15E-11 | 11 | passed |
/artifact/covariance/5/5 | lre | 1.22268318147870289444E-20 | 1.222683430339539e-20 | 2.49E-27 | 6 | passed |
Convention
- NIST model: Model: Exponential Class 6 Parameters (b1 to b6) y = b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lanczos1: nonlinear regression Start 2
Case STAT-NIST-LANCZOS1-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Lanczos1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LANCZOS1.json
Settings compared
curve= "custom"expression= "b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.5}, {"name": "b2", "start": 0.7}, {"name": "b3", "start": 3.6}, {"name": "b4", "start": 4.2}, {"name": "b5", "start": 4.0}, {"name": "b6", "start": 6.3}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 18 | 18 | 0.00E+2 | passed | |
/sse | lre | 1.4307867721E-25 | 1.4307870632247253e-25 | 2.91E-32 | 6 | passed |
/artifact/residual_variance | lre | 7.948815400495619163801E-27 | 7.94881701791514e-27 | 1.62E-33 | 6 | passed |
/artifact/estimates/0 | lre | 9.5100000027E-02 | 0.09510000002743146 | 4.31E-13 | 11 | passed |
/artifact/covariance/0/0 | lre | 2.845934869034954326756E-21 | 2.8459354481681904e-21 | 5.79E-28 | 6 | passed |
/artifact/estimates/1 | lre | 1.0000000001E+00 | 1.000000000127719 | 2.77E-11 | 10 | passed |
/artifact/covariance/1/1 | lre | 7.54767826784791636041E-20 | 7.547679803850871e-20 | 1.54E-26 | 6 | passed |
/artifact/estimates/2 | lre | 8.6070000013E-01 | 0.8607000001344579 | 4.46E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 1.84309465537071950625E-20 | 1.8430950303783614e-20 | 3.75E-27 | 6 | passed |
/artifact/estimates/3 | lre | 3.0000000002E+00 | 3.0000000002346243 | 3.46E-11 | 10 | passed |
/artifact/covariance/3/3 | lre | 1.109439722508547918761E-19 | 1.1094399482683673e-19 | 2.26E-26 | 6 | passed |
/artifact/estimates/4 | lre | 1.5575999998E+00 | 1.5575999998381713 | 3.82E-11 | 10 | passed |
/artifact/covariance/4/4 | lre | 3.54031749923256176704E-20 | 3.540318219491003e-20 | 7.20E-27 | 6 | passed |
/artifact/estimates/5 | lre | 5.0000000001E+00 | 5.000000000111549 | 1.15E-11 | 11 | passed |
/artifact/covariance/5/5 | lre | 1.22268318147870289444E-20 | 1.222683430339539e-20 | 2.49E-27 | 6 | passed |
Notes
- the fitted SSE is strictly below the certified SSE (Tabelz found the better optimum in a flat valley), so the digit shortfall against the certified parameters is the degenerate objective, not a solver defect.
Convention
- NIST model: Model: Exponential Class 6 Parameters (b1 to b6) y = b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lanczos2: nonlinear regression Start 1
Case STAT-NIST-LANCZOS2-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Lanczos2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LANCZOS2.json
Settings compared
curve= "custom"expression= "b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.2}, {"name": "b2", "start": 0.3}, {"name": "b3", "start": 5.6}, {"name": "b4", "start": 5.5}, {"name": "b5", "start": 6.5}, {"name": "b6", "start": 7.6}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 18 | 18 | 0.00E+2 | passed | |
/sse | lre | 2.2299428125E-11 | 2.2299428122902724e-11 | 2.10E-21 | 10 | passed |
/artifact/residual_variance | lre | 1.23885711799958014201E-12 | 1.2388571179390403e-12 | 6.05E-23 | 10 | passed |
/artifact/estimates/0 | lre | 9.6251029939E-02 | 0.09625103023651423 | 2.98E-10 | 8 | passed |
/artifact/covariance/0/0 | lre | 4.458309749529753777529E-7 | 4.4583097580268464e-07 | 8.50E-16 | 8 | passed |
/artifact/estimates/1 | lre | 1.0057332849E+00 | 1.0057332863729265 | 1.47E-9 | 8 | passed |
/artifact/covariance/1/1 | lre | 0.00001155296047169671422976 | 1.1552960423758281e-05 | 4.79E-14 | 8 | passed |
/artifact/estimates/2 | lre | 8.6424689056E-01 | 0.8642468913069115 | 7.47E-10 | 9 | passed |
/artifact/covariance/2/2 | lre | 0.00000295353326280325489225 | 2.953533282756303e-06 | 2.00E-14 | 8 | passed |
/artifact/estimates/3 | lre | 3.0078283915E+00 | 3.0078283933449335 | 1.84E-9 | 9 | passed |
/artifact/covariance/3/3 | lre | 0.00001739474337472418292736 | 1.7394743409401197e-05 | 3.47E-14 | 8 | passed |
/artifact/estimates/4 | lre | 1.5529016879E+00 | 1.5529016868231198 | 1.08E-9 | 9 | passed |
/artifact/covariance/4/4 | lre | 0.00000563795648875974927889 | 5.63795651925078e-06 | 3.05E-14 | 8 | passed |
/artifact/estimates/5 | lre | 5.0028798100E+00 | 5.002879810596486 | 5.96E-10 | 9 | passed |
/artifact/covariance/5/5 | lre | 0.00000194847742439960096656 | 1.948477435005764e-06 | 1.06E-14 | 8 | passed |
Convention
- NIST model: Model: Exponential Class 6 Parameters (b1 to b6) y = b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lanczos2: nonlinear regression Start 2
Case STAT-NIST-LANCZOS2-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Lanczos2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LANCZOS2.json
Settings compared
curve= "custom"expression= "b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.5}, {"name": "b2", "start": 0.7}, {"name": "b3", "start": 3.6}, {"name": "b4", "start": 4.2}, {"name": "b5", "start": 4.0}, {"name": "b6", "start": 6.3}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 18 | 18 | 0.00E+2 | passed | |
/sse | lre | 2.2299428125E-11 | 2.2299428123953906e-11 | 1.05E-21 | 10 | passed |
/artifact/residual_variance | lre | 1.23885711799958014201E-12 | 1.2388571179974393e-12 | 2.14E-24 | 11 | passed |
/artifact/estimates/0 | lre | 9.6251029939E-02 | 0.09625102988180245 | 5.72E-11 | 9 | passed |
/artifact/covariance/0/0 | lre | 4.458309749529753777529E-7 | 4.4583097476102824e-07 | 1.92E-16 | 9 | passed |
/artifact/estimates/1 | lre | 1.0057332849E+00 | 1.0057332845702573 | 3.30E-10 | 9 | passed |
/artifact/covariance/1/1 | lre | 0.00001155296047169671422976 | 1.1552960480350489e-05 | 8.65E-15 | 9 | passed |
/artifact/estimates/2 | lre | 8.6424689056E-01 | 0.8642468904081949 | 1.52E-10 | 9 | passed |
/artifact/covariance/2/2 | lre | 0.00000295353326280325489225 | 2.953533258737468e-06 | 4.07E-15 | 8 | passed |
/artifact/estimates/3 | lre | 3.0078283915E+00 | 3.00782839113117 | 3.69E-10 | 9 | passed |
/artifact/covariance/3/3 | lre | 0.00001739474337472418292736 | 1.73947433673672e-05 | 7.36E-15 | 9 | passed |
/artifact/estimates/4 | lre | 1.5529016879E+00 | 1.5529016880764082 | 1.76E-10 | 9 | passed |
/artifact/covariance/4/4 | lre | 0.00000563795648875974927889 | 5.637956482362313e-06 | 6.40E-15 | 8 | passed |
/artifact/estimates/5 | lre | 5.0028798100E+00 | 5.002879809864531 | 1.35E-10 | 10 | passed |
/artifact/covariance/5/5 | lre | 0.00000194847742439960096656 | 1.9484774223167206e-06 | 2.08E-15 | 8 | passed |
Convention
- NIST model: Model: Exponential Class 6 Parameters (b1 to b6) y = b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lanczos3: nonlinear regression Start 1
Case STAT-NIST-LANCZOS3-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Lanczos3.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LANCZOS3.json
Settings compared
curve= "custom"expression= "b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1.2}, {"name": "b2", "start": 0.3}, {"name": "b3", "start": 5.6}, {"name": "b4", "start": 5.5}, {"name": "b5", "start": 6.5}, {"name": "b6", "start": 7.6}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 18 | 18 | 0.00E+2 | passed | |
/sse | lre | 1.6117193594E-08 | 1.6117193593564184e-08 | 4.36E-19 | 10 | passed |
/artifact/residual_variance | lre | 8.95399644080031805584E-10 | 8.953996440868991e-10 | 6.87E-21 | 11 | passed |
/artifact/estimates/0 | lre | 8.6816414977E-02 | 0.08681641504661412 | 6.96E-11 | 9 | passed |
/artifact/covariance/0/0 | lre | 0.000295768069122470681881 | 0.00029576806931643385 | 1.94E-13 | 9 | passed |
/artifact/estimates/1 | lre | 9.5498101505E-01 | 0.9549810154366999 | 3.87E-10 | 9 | passed |
/artifact/covariance/1/1 | lre | 0.009417076880746919025625 | 0.009417076871761685 | 8.99E-12 | 9 | passed |
/artifact/estimates/2 | lre | 8.4400777463E-01 | 0.8440077747903022 | 1.60E-10 | 9 | passed |
/artifact/covariance/2/2 | lre | 0.001721309180927175011524 | 0.0017213091837264072 | 2.80E-12 | 8 | passed |
/artifact/estimates/3 | lre | 2.9515951832E+00 | 2.951595183624556 | 4.25E-10 | 9 | passed |
/artifact/covariance/3/3 | lre | 0.0115913484976852000036 | 0.011591348504420219 | 6.74E-12 | 9 | passed |
/artifact/estimates/4 | lre | 1.5825685901E+00 | 1.5825685899152357 | 1.85E-10 | 9 | passed |
/artifact/covariance/4/4 | lre | 0.003407240917528601790961 | 0.0034072409220432245 | 4.51E-12 | 8 | passed |
/artifact/estimates/5 | lre | 4.9863565084E+00 | 4.986356508536565 | 1.37E-10 | 10 | passed |
/artifact/covariance/5/5 | lre | 0.001185865853988957211225 | 0.0011858658555333032 | 1.54E-12 | 8 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.5e-13 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 6 Parameters (b1 to b6) y = b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lanczos3: nonlinear regression Start 2
Case STAT-NIST-LANCZOS3-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Lanczos3.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LANCZOS3.json
Settings compared
curve= "custom"expression= "b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.5}, {"name": "b2", "start": 0.7}, {"name": "b3", "start": 3.6}, {"name": "b4", "start": 4.2}, {"name": "b5", "start": 4.0}, {"name": "b6", "start": 6.3}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 18 | 18 | 0.00E+2 | passed | |
/sse | lre | 1.6117193594E-08 | 1.6117193593562484e-08 | 4.38E-19 | 10 | passed |
/artifact/residual_variance | lre | 8.95399644080031805584E-10 | 8.953996440868046e-10 | 6.77E-21 | 11 | passed |
/artifact/estimates/0 | lre | 8.6816414977E-02 | 0.08681641497745288 | 4.53E-13 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.000295768069122470681881 | 0.00029576806912671305 | 4.24E-15 | 10 | passed |
/artifact/estimates/1 | lre | 9.5498101505E-01 | 0.9549810150472705 | 2.73E-12 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.009417076880746919025625 | 0.009417076880674854 | 7.21E-14 | 11 | passed |
/artifact/estimates/2 | lre | 8.4400777463E-01 | 0.8440077746256947 | 4.31E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.001721309180927175011524 | 0.001721309180945996 | 1.88E-14 | 10 | passed |
/artifact/estimates/3 | lre | 2.9515951832E+00 | 2.9515951831913667 | 8.63E-12 | 11 | passed |
/artifact/covariance/3/3 | lre | 0.0115913484976852000036 | 0.011591348497773083 | 8.79E-14 | 11 | passed |
/artifact/estimates/4 | lre | 1.5825685901E+00 | 1.5825685901489752 | 4.90E-11 | 10 | passed |
/artifact/covariance/4/4 | lre | 0.003407240917528601790961 | 0.0034072409174905833 | 3.80E-14 | 10 | passed |
/artifact/estimates/5 | lre | 4.9863565084E+00 | 4.986356508399509 | 4.91E-13 | 13 | passed |
/artifact/covariance/5/5 | lre | 0.001185865853988957211225 | 0.0011858658539932287 | 4.27E-15 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 2.0e-12 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 6 Parameters (b1 to b6) y = b1*exp(-b2*x) + b3*exp(-b4*x) + b5*exp(-b6*x) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lew: acf
Case STAT-NIST-LEW-ACF-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/Lew.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LEW.json
Settings compared
maximum_lag= 1response_column= "y"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlations/acf/1 | lre | -0.307304800605679 | -0.30730480060567944 | 4.40E-16 | 14 | passed |
/correlations/sample_count | exact | 200 | 200 | 0.00E+2 | passed |
Convention
- NIST model: Model: Lower Level of Difficulty 2 Parameters : mu, sigma 1 Response Variable : y 0 Predictor Variables y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lew: tabulation
Case STAT-NIST-LEW-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/Lew.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LEW.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | -177.435000000000 | -177.435 | 2.27E-15 | 16 | passed |
/numeric_summaries/0/standard_deviation | lre | 277.332168044316 | 277.3321680443161 | 1.20E-13 | 15 | passed |
/numeric_summaries/0/valid_n | exact | 200 | 200 | 0.00E+2 | passed |
Convention
- NIST model: Model: Lower Level of Difficulty 2 Parameters : mu, sigma 1 Response Variable : y 0 Predictor Variables y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Longley: fit
Case STAT-NIST-LONGLEY-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Longley.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LONGLEY.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["x1", "x2", "x3", "x4", "x5", "x6"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 16 | 16 | 0.00E+2 | passed | |
/responses/0/parameters/[term=Intercept]/estimate | lre | -3482258.63459582 | -3482258.634595821 | 1.15E-9 | 15 | passed |
/responses/0/parameters/[term=Intercept]/std_error | lre | 890420.383607373 | 890420.383607372 | 1.06E-9 | 14 | passed |
/responses/0/parameters/[term=x1]/estimate | lre | 15.0618722713733 | 15.061872271373922 | 6.22E-13 | 13 | passed |
/responses/0/parameters/[term=x1]/std_error | lre | 84.9149257747669 | 84.914925774767 | 9.92E-14 | 14 | passed |
/responses/0/parameters/[term=x2]/estimate | lre | -0.358191792925910E-01 | -0.03581917929259122 | 2.22E-16 | 14 | passed |
/responses/0/parameters/[term=x2]/std_error | lre | 0.334910077722432E-01 | 0.033491007772243175 | 2.46E-17 | 15 | passed |
/responses/0/parameters/[term=x3]/estimate | lre | -2.02022980381683 | -2.020229803816828 | 2.18E-15 | 14 | passed |
/responses/0/parameters/[term=x3]/std_error | lre | 0.488399681651699 | 0.4883996816516995 | 5.02E-16 | 14 | passed |
/responses/0/parameters/[term=x4]/estimate | lre | -1.03322686717359 | -1.033226867173593 | 2.91E-15 | 14 | passed |
/responses/0/parameters/[term=x4]/std_error | lre | 0.214274163161675 | 0.21427416316167516 | 1.63E-16 | 15 | passed |
/responses/0/parameters/[term=x5]/estimate | lre | -0.511041056535807E-01 | -0.05110410565357948 | 1.22E-15 | 13 | passed |
/responses/0/parameters/[term=x5]/std_error | lre | 0.226073200069370 | 0.22607320006937048 | 4.84E-16 | 14 | passed |
/responses/0/parameters/[term=x6]/estimate | lre | 1829.15146461355 | 1829.1514646135533 | 3.34E-12 | 14 | passed |
/responses/0/parameters/[term=x6]/std_error | lre | 455.478499142212 | 455.47849914221166 | 3.40E-13 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 836424.055505915 | 836424.0555059145 | 5.03E-10 | 15 | passed |
/responses/0/metrics/r_squared | lre | 0.995479004577296 | 0.9954790045772942 | 1.79E-15 | 14 | passed |
/responses/0/anova/[source=Model]/f_stat | lre | 330.285339234588 | 330.28533923458843 | 4.34E-13 | 14 | passed |
Notes
- an independent SVD lstsq reaches 12.7 of the demanded 13 digits and Tabelz 12.0 on this classic ill-conditioned design; the certified value was computed in extended precision.
Convention
- NIST model: Model: Polynomial Class 7 Parameters (B0,B1,...,B7) y = B0 + B1*x1 + B2*x2 + B3*x3 + B4*x4 + B5*x5 + B6*x6 + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lottery: acf
Case STAT-NIST-LOTTERY-ACF-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/Lottery.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LOTTERY.json
Settings compared
maximum_lag= 1response_column= "y"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlations/acf/1 | lre | -0.120948622967393 | -0.12094862296739288 | 1.20E-16 | 15 | passed |
/correlations/sample_count | exact | 218 | 218 | 0.00E+2 | passed |
Convention
- NIST model: Model: Lower Level of Difficulty 2 Parameters : mu, sigma 1 Response Variable : y 0 Predictor Variables y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Lottery: tabulation
Case STAT-NIST-LOTTERY-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/Lottery.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_LOTTERY.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | 518.958715596330 | 518.9587155963303 | 3.08E-13 | 15 | passed |
/numeric_summaries/0/standard_deviation | lre | 291.699727470969 | 291.69972747096904 | 3.73E-14 | 15 | passed |
/numeric_summaries/0/valid_n | exact | 218 | 218 | 0.00E+2 | passed |
Convention
- NIST model: Model: Lower Level of Difficulty 2 Parameters : mu, sigma 1 Response Variable : y 0 Predictor Variables y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Mavro: acf
Case STAT-NIST-MAVRO-ACF-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/Mavro.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MAVRO.json
Settings compared
maximum_lag= 1response_column= "y"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlations/acf/1 | lre | 0.937989183438248 | 0.9379891834382648 | 1.68E-14 | 13 | passed |
/correlations/sample_count | exact | 50 | 50 | 0.00E+2 | passed |
Convention
- NIST model: Model: Lower Level of Difficulty 2 Parameters : mu, sigma 1 Response Variable : y 0 Predictor Variables y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Mavro: tabulation
Case STAT-NIST-MAVRO-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/Mavro.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MAVRO.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | 2.00185600000000 | 2.001856 | 7.98E-17 | 16 | passed |
/numeric_summaries/0/standard_deviation | lre | 0.000429123454003053 | 0.0004291234540030854 | 3.24E-17 | 13 | passed |
/numeric_summaries/0/valid_n | exact | 50 | 50 | 0.00E+2 | passed |
Convention
- NIST model: Model: Lower Level of Difficulty 2 Parameters : mu, sigma 1 Response Variable : y 0 Predictor Variables y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST MGH09: nonlinear regression Start 1
Case STAT-NIST-MGH09-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/MGH09.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MGH09.json
Settings compared
curve= "custom"expression= "b1*(x**2+x*b2) / (x**2+x*b3+b4)"max_evaluations= 10000parameters= [{"name": "b1", "start": 25.0}, {"name": "b2", "start": 39.0}, {"name": "b3", "start": 41.5}, {"name": "b4", "start": 39.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 7 | 7 | 0.00E+2 | passed | |
/sse | lre | 3.0750560385E-04 | 0.0003075056038492386 | 7.61E-16 | 11 | passed |
/artifact/residual_variance | lre | 0.00004392937197783414375601 | 4.392937197846265e-05 | 6.29E-16 | 10 | passed |
/artifact/estimates/0 | lre | 1.9280693458E-01 | 0.19280693457903736 | 9.63E-13 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.000130766365728975699529 | 0.00013076636571878557 | 1.02E-14 | 10 | passed |
/artifact/estimates/1 | lre | 1.9128232873E-01 | 0.1912823287343783 | 4.38E-12 | 10 | passed |
/artifact/covariance/1/1 | lre | 0.0385463363340127669921 | 0.03854633633408028 | 6.75E-14 | 11 | passed |
/artifact/estimates/2 | lre | 1.2305650693E-01 | 0.12305650692632279 | 3.68E-12 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.006535434013715663437824 | 0.006535434013676034 | 3.96E-14 | 11 | passed |
/artifact/estimates/3 | lre | 1.3606233068E-01 | 0.13606233068380008 | 3.80E-12 | 10 | passed |
/artifact/covariance/3/3 | lre | 0.008104598267849497966864 | 0.008104598267892893 | 4.34E-14 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 2.6e-11 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Rational Class (linear/quadratic) 4 Parameters (b1 to b4) y = b1*(x**2+x*b2) / (x**2+x*b3+b4) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST MGH09: nonlinear regression Start 2
Case STAT-NIST-MGH09-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/MGH09.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MGH09.json
Settings compared
curve= "custom"expression= "b1*(x**2+x*b2) / (x**2+x*b3+b4)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.25}, {"name": "b2", "start": 0.39}, {"name": "b3", "start": 0.415}, {"name": "b4", "start": 0.39}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 7 | 7 | 0.00E+2 | passed | |
/sse | lre | 3.0750560385E-04 | 0.0003075056038492378 | 7.62E-16 | 11 | passed |
/artifact/residual_variance | lre | 0.00004392937197783414375601 | 4.392937197846254e-05 | 6.28E-16 | 10 | passed |
/artifact/estimates/0 | lre | 1.9280693458E-01 | 0.19280693457903803 | 9.62E-13 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.000130766365728975699529 | 0.00013076636571878033 | 1.02E-14 | 10 | passed |
/artifact/estimates/1 | lre | 1.9128232873E-01 | 0.1912823287343639 | 4.36E-12 | 10 | passed |
/artifact/covariance/1/1 | lre | 0.0385463363340127669921 | 0.03854633633407569 | 6.29E-14 | 11 | passed |
/artifact/estimates/2 | lre | 1.2305650693E-01 | 0.12305650692632036 | 3.68E-12 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.006535434013715663437824 | 0.006535434013675471 | 4.02E-14 | 11 | passed |
/artifact/estimates/3 | lre | 1.3606233068E-01 | 0.13606233068379342 | 3.79E-12 | 10 | passed |
/artifact/covariance/3/3 | lre | 0.008104598267849497966864 | 0.008104598267892088 | 4.26E-14 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 4.9e-11 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Rational Class (linear/quadratic) 4 Parameters (b1 to b4) y = b1*(x**2+x*b2) / (x**2+x*b3+b4) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST MGH10: nonlinear regression Start 1
Case STAT-NIST-MGH10-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/MGH10.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MGH10.json
Settings compared
curve= "custom"expression= "b1 * exp(b2/(x+b3))"max_evaluations= 10000parameters= [{"name": "b1", "start": 2.0}, {"name": "b2", "start": 400000.0}, {"name": "b3", "start": 25000.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 13 | 13 | 0.00E+2 | passed | |
/sse | lre | 8.7945855171E+01 | 87.9458551707731 | 2.27E-10 | 11 | passed |
/artifact/residual_variance | lre | 6.76506578248866204225 | 6.765065782367161 | 1.22E-10 | 10 | passed |
/artifact/estimates/0 | lre | 5.6096364710E-03 | 0.005609636471028718 | 2.87E-14 | 11 | passed |
/artifact/covariance/0/0 | lre | 2.46109970181658485841E-8 | 2.4610997017799544e-08 | 3.66E-19 | 10 | passed |
/artifact/estimates/1 | lre | 6.1813463463E+03 | 6181.34634628627 | 1.37E-8 | 11 | passed |
/artifact/covariance/1/1 | lre | 543.310464966571505449 | 543.3104649605068 | 6.06E-9 | 10 | passed |
/artifact/estimates/2 | lre | 3.4522363462E+02 | 345.22363462413296 | 4.13E-9 | 10 | passed |
/artifact/covariance/2/2 | lre | 0.6160068443868489906064 | 0.6160068443808091 | 6.04E-12 | 11 | passed |
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = b1 * exp[b2/(x+b3)] + e
- HypoNum accuracy policy: minimum 4 digits.
NIST MGH10: nonlinear regression Start 2
Case STAT-NIST-MGH10-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/MGH10.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MGH10.json
Settings compared
curve= "custom"expression= "b1 * exp(b2/(x+b3))"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.02}, {"name": "b2", "start": 4000.0}, {"name": "b3", "start": 250.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 13 | 13 | 0.00E+2 | passed | |
/sse | lre | 8.7945855171E+01 | 87.94585517062706 | 3.73E-10 | 11 | passed |
/artifact/residual_variance | lre | 6.76506578248866204225 | 6.7650657823559275 | 1.33E-10 | 10 | passed |
/artifact/estimates/0 | lre | 5.6096364710E-03 | 0.00560963648144691 | 1.04E-11 | 8 | passed |
/artifact/covariance/0/0 | lre | 2.46109970181658485841E-8 | 2.4610997096973467e-08 | 7.88E-17 | 8 | passed |
/artifact/estimates/1 | lre | 6.1813463463E+03 | 6181.346344737892 | 1.56E-6 | 9 | passed |
/artifact/covariance/1/1 | lre | 543.310464966571505449 | 543.3104645540936 | 4.12E-7 | 9 | passed |
/artifact/estimates/2 | lre | 3.4522363462E+02 | 345.22363457200964 | 4.80E-8 | 9 | passed |
/artifact/covariance/2/2 | lre | 0.6160068443868489906064 | 0.6160068440738743 | 3.13E-10 | 9 | passed |
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = b1 * exp[b2/(x+b3)] + e
- HypoNum accuracy policy: minimum 4 digits.
NIST MGH17: nonlinear regression Start 1
Case STAT-NIST-MGH17-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/MGH17.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MGH17.json
Settings compared
curve= "custom"expression= "b1 + b2*exp(-x*b4) + b3*exp(-x*b5)"max_evaluations= 10000parameters= [{"name": "b1", "start": 50.0}, {"name": "b2", "start": 150.0}, {"name": "b3", "start": -100.0}, {"name": "b4", "start": 1.0}, {"name": "b5", "start": 2.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 28 | 28 | 0.00E+2 | passed | |
/sse | lre | 5.4648946975E-05 | 5.4648946974828085e-05 | 1.72E-16 | 11 | passed |
/artifact/residual_variance | lre | 0.00000195174810623910553956 | 1.95174810624386e-06 | 4.75E-18 | 11 | passed |
/artifact/estimates/0 | lre | 3.7541005211E-01 | 0.37541005210695216 | 3.05E-12 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.00000429449093098323909601 | 4.29449093117976e-06 | 1.97E-16 | 10 | passed |
/artifact/estimates/1 | lre | 1.9358469127E+00 | 1.935846912712381 | 1.24E-11 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.0485394448707622085284 | 0.04853944487263093 | 1.87E-12 | 10 | passed |
/artifact/estimates/2 | lre | -1.4646871366E+00 | -1.4646871366134366 | 1.34E-11 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.0491762013725544492121 | 0.04917620137141903 | 1.14E-12 | 10 | passed |
/artifact/estimates/3 | lre | 1.2867534640E-02 | 0.012867534640057314 | 5.73E-14 | 11 | passed |
/artifact/covariance/3/3 | lre | 2.012541451832553636996E-7 | 2.012541451852016e-07 | 1.95E-18 | 11 | passed |
/artifact/estimates/4 | lre | 2.2122699662E-02 | 0.02212269966167255 | 3.27E-13 | 10 | passed |
/artifact/covariance/4/4 | lre | 8.005238171116811730625E-7 | 8.005238171028975e-07 | 8.78E-18 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 5 Parameters (b1 to b5) y = b1 + b2*exp[-x*b4] + b3*exp[-x*b5] + e
- HypoNum accuracy policy: minimum 4 digits.
NIST MGH17: nonlinear regression Start 2
Case STAT-NIST-MGH17-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/MGH17.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MGH17.json
Settings compared
curve= "custom"expression= "b1 + b2*exp(-x*b4) + b3*exp(-x*b5)"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.5}, {"name": "b2", "start": 1.5}, {"name": "b3", "start": -1.0}, {"name": "b4", "start": 0.01}, {"name": "b5", "start": 0.02}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 28 | 28 | 0.00E+2 | passed | |
/sse | lre | 5.4648946975E-05 | 5.464894697482894e-05 | 1.71E-16 | 11 | passed |
/artifact/residual_variance | lre | 0.00000195174810623910553956 | 1.9517481062438905e-06 | 4.78E-18 | 11 | passed |
/artifact/estimates/0 | lre | 3.7541005211E-01 | 0.37541005196194044 | 1.48E-10 | 9 | passed |
/artifact/covariance/0/0 | lre | 0.00000429449093098323909601 | 4.294490933258638e-06 | 2.28E-15 | 9 | passed |
/artifact/estimates/1 | lre | 1.9358469127E+00 | 1.9358468957758423 | 1.69E-8 | 8 | passed |
/artifact/covariance/1/1 | lre | 0.0485394448707622085284 | 0.048539441729225224 | 3.14E-9 | 7 | passed |
/artifact/estimates/2 | lre | -1.4646871366E+00 | -1.4646871195674294 | 1.70E-8 | 7 | passed |
/artifact/covariance/2/2 | lre | 0.0491762013725544492121 | 0.04917619820776114 | 3.16E-9 | 7 | passed |
/artifact/estimates/3 | lre | 1.2867534640E-02 | 0.012867534605724224 | 3.43E-11 | 8 | passed |
/artifact/covariance/3/3 | lre | 2.012541451832553636996E-7 | 2.0125413966144034e-07 | 5.52E-15 | 7 | passed |
/artifact/estimates/4 | lre | 2.2122699662E-02 | 0.022122699730227242 | 6.82E-11 | 8 | passed |
/artifact/covariance/4/4 | lre | 8.005238171116811730625E-7 | 8.005238068507154e-07 | 1.03E-14 | 7 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 3.7e-14 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 5 Parameters (b1 to b5) y = b1 + b2*exp[-x*b4] + b3*exp[-x*b5] + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Michelso: acf
Case STAT-NIST-MICHELSO-ACF-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/Michelso.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MICHELSO.json
Settings compared
maximum_lag= 1response_column= "y"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlations/acf/1 | lre | 0.535199668621283 | 0.5351996686212633 | 1.97E-14 | 13 | passed |
/correlations/sample_count | exact | 100 | 100 | 0.00E+2 | passed |
Convention
- NIST model: y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Michelso: tabulation
Case STAT-NIST-MICHELSO-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/Michelso.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MICHELSO.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | 299.852400000000 | 299.8524 | 1.13E-14 | 16 | passed |
/numeric_summaries/0/standard_deviation | lre | 0.0790105478190518 | 0.07901054781905066 | 1.14E-15 | 13 | passed |
/numeric_summaries/0/valid_n | exact | 100 | 100 | 0.00E+2 | passed |
Convention
- NIST model: y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Misra1a: nonlinear regression Start 1
Case STAT-NIST-MISRA1A-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Misra1a.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MISRA1A.json
Settings compared
curve= "custom"expression= "b1*(1-exp(-b2*x))"max_evaluations= 10000parameters= [{"name": "b1", "start": 500.0}, {"name": "b2", "start": 0.0001}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 12 | 12 | 0.00E+2 | passed | |
/sse | lre | 1.2455138894E-01 | 0.1245513889444131 | 4.41E-12 | 10 | passed |
/artifact/residual_variance | lre | 0.0103792824115374268900 | 0.010379282412034426 | 4.97E-13 | 10 | passed |
/artifact/estimates/0 | lre | 2.3894212918E+02 | 238.94212917886156 | 1.14E-9 | 11 | passed |
/artifact/covariance/0/0 | lre | 7.32788973553401208081 | 7.327889735748008 | 2.14E-10 | 10 | passed |
/artifact/estimates/1 | lre | 5.5015643181E-04 | 0.0005501564318059139 | 4.09E-15 | 11 | passed |
/artifact/covariance/1/1 | lre | 5.280738279008440126096E-11 | 5.280738279036431e-11 | 2.80E-22 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 3.6e-13 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 2 Parameters (b1 and b2) y = b1*(1-exp[-b2*x]) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Misra1a: nonlinear regression Start 2
Case STAT-NIST-MISRA1A-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Misra1a.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MISRA1A.json
Settings compared
curve= "custom"expression= "b1*(1-exp(-b2*x))"max_evaluations= 10000parameters= [{"name": "b1", "start": 250.0}, {"name": "b2", "start": 0.0005}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 12 | 12 | 0.00E+2 | passed | |
/sse | lre | 1.2455138894E-01 | 0.1245513889444021 | 4.40E-12 | 10 | passed |
/artifact/residual_variance | lre | 0.0103792824115374268900 | 0.010379282412033508 | 4.96E-13 | 10 | passed |
/artifact/estimates/0 | lre | 2.3894212918E+02 | 238.9421291788653 | 1.13E-9 | 11 | passed |
/artifact/covariance/0/0 | lre | 7.32788973553401208081 | 7.327889735747851 | 2.14E-10 | 10 | passed |
/artifact/estimates/1 | lre | 5.5015643181E-04 | 0.000550156431805904 | 4.10E-15 | 11 | passed |
/artifact/covariance/1/1 | lre | 5.280738279008440126096E-11 | 5.2807382790359324e-11 | 2.75E-22 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.4e-13 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 2 Parameters (b1 and b2) y = b1*(1-exp[-b2*x]) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Misra1b: nonlinear regression Start 1
Case STAT-NIST-MISRA1B-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Misra1b.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MISRA1B.json
Settings compared
curve= "custom"expression= "b1 * (1-(1+b2*x/2)**(-2))"max_evaluations= 10000parameters= [{"name": "b1", "start": 500.0}, {"name": "b2", "start": 0.0001}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 12 | 12 | 0.00E+2 | passed | |
/sse | lre | 7.5464681533E-02 | 0.07546468153338176 | 3.82E-13 | 11 | passed |
/artifact/residual_variance | lre | 0.006288723461049578112004 | 0.0062887234611151465 | 6.56E-14 | 10 | passed |
/artifact/estimates/0 | lre | 3.3799746163E+02 | 337.9974616336881 | 3.69E-9 | 10 | passed |
/artifact/covariance/0/0 | lre | 10.01339584703095342849 | 10.013395846733776 | 2.97E-10 | 10 | passed |
/artifact/estimates/1 | lre | 3.9039091287E-04 | 0.0003903909128656994 | 4.30E-15 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.810274595245973123556E-11 | 1.810274595251836e-11 | 5.86E-23 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.7e-12 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 2 Parameters (b1 and b2) y = b1 * (1-(1+b2*x/2)**(-2)) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Misra1b: nonlinear regression Start 2
Case STAT-NIST-MISRA1B-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Misra1b.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MISRA1B.json
Settings compared
curve= "custom"expression= "b1 * (1-(1+b2*x/2)**(-2))"max_evaluations= 10000parameters= [{"name": "b1", "start": 300.0}, {"name": "b2", "start": 0.0002}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 12 | 12 | 0.00E+2 | passed | |
/sse | lre | 7.5464681533E-02 | 0.07546468153338176 | 3.82E-13 | 11 | passed |
/artifact/residual_variance | lre | 0.006288723461049578112004 | 0.0062887234611151465 | 6.56E-14 | 10 | passed |
/artifact/estimates/0 | lre | 3.3799746163E+02 | 337.9974616336881 | 3.69E-9 | 10 | passed |
/artifact/covariance/0/0 | lre | 10.01339584703095342849 | 10.013395846733776 | 2.97E-10 | 10 | passed |
/artifact/estimates/1 | lre | 3.9039091287E-04 | 0.0003903909128656994 | 4.30E-15 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.810274595245973123556E-11 | 1.810274595251836e-11 | 5.86E-23 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 2.3e-12 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 2 Parameters (b1 and b2) y = b1 * (1-(1+b2*x/2)**(-2)) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Misra1c: nonlinear regression Start 1
Case STAT-NIST-MISRA1C-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Misra1c.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MISRA1C.json
Settings compared
curve= "custom"expression= "b1 * (1-(1+2*b2*x)**(-.5))"max_evaluations= 10000parameters= [{"name": "b1", "start": 500.0}, {"name": "b2", "start": 0.0001}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 12 | 12 | 0.00E+2 | passed | |
/sse | lre | 4.0966836971E-02 | 0.04096683697067511 | 3.25E-13 | 11 | passed |
/artifact/residual_variance | lre | 0.003413903080850533176049 | 0.0034139030808895926 | 3.91E-14 | 10 | passed |
/artifact/estimates/0 | lre | 6.3642725809E+02 | 636.4272580930073 | 3.01E-9 | 11 | passed |
/artifact/covariance/0/0 | lre | 21.75133505436521271184 | 21.751335054713753 | 3.49E-10 | 10 | passed |
/artifact/estimates/1 | lre | 2.0813627256E-04 | 0.00020813627256328532 | 3.29E-15 | 10 | passed |
/artifact/covariance/1/1 | lre | 3.14296987562740154025E-12 | 3.142969875782169e-12 | 1.55E-22 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 6.7e-12 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 2 Parameters (b1 and b2) y = b1 * (1-(1+2*b2*x)**(-.5)) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Misra1c: nonlinear regression Start 2
Case STAT-NIST-MISRA1C-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Misra1c.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MISRA1C.json
Settings compared
curve= "custom"expression= "b1 * (1-(1+2*b2*x)**(-.5))"max_evaluations= 10000parameters= [{"name": "b1", "start": 600.0}, {"name": "b2", "start": 0.0002}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 12 | 12 | 0.00E+2 | passed | |
/sse | lre | 4.0966836971E-02 | 0.04096683697067817 | 3.22E-13 | 11 | passed |
/artifact/residual_variance | lre | 0.003413903080850533176049 | 0.0034139030808898476 | 3.93E-14 | 10 | passed |
/artifact/estimates/0 | lre | 6.3642725809E+02 | 636.4272580930033 | 3.00E-9 | 11 | passed |
/artifact/covariance/0/0 | lre | 21.75133505436521271184 | 21.751335054715305 | 3.50E-10 | 10 | passed |
/artifact/estimates/1 | lre | 2.0813627256E-04 | 0.00020813627256328681 | 3.29E-15 | 10 | passed |
/artifact/covariance/1/1 | lre | 3.14296987562740154025E-12 | 3.142969875782486e-12 | 1.55E-22 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 6.5e-12 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 2 Parameters (b1 and b2) y = b1 * (1-(1+2*b2*x)**(-.5)) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Misra1d: nonlinear regression Start 1
Case STAT-NIST-MISRA1D-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Misra1d.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MISRA1D.json
Settings compared
curve= "custom"expression= "b1*b2*x*((1+b2*x)**(-1))"max_evaluations= 10000parameters= [{"name": "b1", "start": 500.0}, {"name": "b2", "start": 0.0001}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 12 | 12 | 0.00E+2 | passed | |
/sse | lre | 5.6419295283E-02 | 0.056419295282648926 | 3.51E-13 | 11 | passed |
/artifact/residual_variance | lre | 0.004701607940288140396321 | 0.004701607940220744 | 6.74E-14 | 10 | passed |
/artifact/estimates/0 | lre | 4.3736970754E+02 | 437.3697075398936 | 1.06E-10 | 12 | passed |
/artifact/covariance/0/0 | lre | 13.31459844379806179025 | 13.314598443978236 | 1.80E-10 | 10 | passed |
/artifact/estimates/1 | lre | 3.0227324449E-04 | 0.0003022732444900431 | 4.31E-17 | 12 | passed |
/artifact/covariance/1/1 | lre | 8.60504352699627361441E-12 | 8.605043527146268e-12 | 1.50E-22 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 3.6e-12 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 2 Parameters (b1 and b2) y = b1*b2*x*((1+b2*x)**(-1)) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Misra1d: nonlinear regression Start 2
Case STAT-NIST-MISRA1D-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Misra1d.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_MISRA1D.json
Settings compared
curve= "custom"expression= "b1*b2*x*((1+b2*x)**(-1))"max_evaluations= 10000parameters= [{"name": "b1", "start": 450.0}, {"name": "b2", "start": 0.0003}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 12 | 12 | 0.00E+2 | passed | |
/sse | lre | 5.6419295283E-02 | 0.056419295282646095 | 3.54E-13 | 11 | passed |
/artifact/residual_variance | lre | 0.004701607940288140396321 | 0.004701607940220508 | 6.76E-14 | 10 | passed |
/artifact/estimates/0 | lre | 4.3736970754E+02 | 437.3697075398933 | 1.07E-10 | 12 | passed |
/artifact/covariance/0/0 | lre | 13.31459844379806179025 | 13.314598443977529 | 1.79E-10 | 10 | passed |
/artifact/estimates/1 | lre | 3.0227324449E-04 | 0.0003022732444900434 | 4.34E-17 | 12 | passed |
/artifact/covariance/1/1 | lre | 8.60504352699627361441E-12 | 8.605043527145838e-12 | 1.50E-22 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within -2.5e-14 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Miscellaneous Class 2 Parameters (b1 and b2) y = b1*b2*x*((1+b2*x)**(-1)) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Nelson: nonlinear regression Start 1
Case STAT-NIST-NELSON-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Nelson.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NELSON_LOG_RESPONSE.json
Settings compared
curve= "custom"expression= "b1 - b2*x * exp(-b3*x2)"max_evaluations= 10000parameters= [{"name": "b1", "start": 2.0}, {"name": "b2", "start": 0.0001}, {"name": "b3", "start": -0.01}]response= "log_y"x2_column= "x2"x_column= "x1"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 125 | 125 | 0.00E+2 | passed | |
/sse | lre | 3.7976833176E+00 | 3.797683317645149 | 4.51E-11 | 10 | passed |
/artifact/residual_variance | lre | 0.0303814665410272816900 | 0.03038146654116119 | 1.34E-13 | 11 | passed |
/artifact/estimates/0 | lre | 2.5906836021E+00 | 2.590683602136246 | 3.62E-11 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.000366722362617912866569 | 0.0003667223625994094 | 1.85E-14 | 10 | passed |
/artifact/estimates/1 | lre | 5.6177717026E-09 | 5.6177717026494515e-09 | 4.95E-20 | 11 | passed |
/artifact/covariance/1/1 | lre | 3.736155177831239971600E-17 | 3.7361551778531725e-17 | 2.19E-28 | 11 | passed |
/artifact/estimates/2 | lre | -5.7701013174E-02 | -0.05770101317444775 | 4.48E-13 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.00001565972193813545770849 | 1.565972193848099e-05 | 3.46E-16 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) log[y] = b1 - b2*x1 * exp[-b3*x2] + e
- HypoNum accuracy policy: minimum 4 digits.
- Explicitly prepare log_y = ln(y) from retained original y; fit log_y with x=x1 and second predictor x2. Predictions, residuals, SSE and covariance remain on the selected log-response scale; no back-transformation.
NIST Nelson: nonlinear regression Start 2
Case STAT-NIST-NELSON-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Nelson.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NELSON_LOG_RESPONSE.json
Settings compared
curve= "custom"expression= "b1 - b2*x * exp(-b3*x2)"max_evaluations= 10000parameters= [{"name": "b1", "start": 2.5}, {"name": "b2", "start": 5e-09}, {"name": "b3", "start": -0.05}]response= "log_y"x2_column= "x2"x_column= "x1"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 125 | 125 | 0.00E+2 | passed | |
/sse | lre | 3.7976833176E+00 | 3.7976833176451477 | 4.51E-11 | 10 | passed |
/artifact/residual_variance | lre | 0.0303814665410272816900 | 0.03038146654116118 | 1.34E-13 | 11 | passed |
/artifact/estimates/0 | lre | 2.5906836021E+00 | 2.5906836021362007 | 3.62E-11 | 10 | passed |
/artifact/covariance/0/0 | lre | 0.000366722362617912866569 | 0.00036672236259938416 | 1.85E-14 | 10 | passed |
/artifact/estimates/1 | lre | 5.6177717026E-09 | 5.617771702616804e-09 | 1.68E-20 | 11 | passed |
/artifact/covariance/1/1 | lre | 3.736155177831239971600E-17 | 3.7361551778141565e-17 | 1.71E-28 | 11 | passed |
/artifact/estimates/2 | lre | -5.7701013174E-02 | -0.05770101317446889 | 4.69E-13 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.00001565972193813545770849 | 1.565972193849939e-05 | 3.64E-16 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) log[y] = b1 - b2*x1 * exp[-b3*x2] + e
- HypoNum accuracy policy: minimum 4 digits.
- Explicitly prepare log_y = ln(y) from retained original y; fit log_y with x=x1 and second predictor x2. Predictions, residuals, SSE and covariance remain on the selected log-response scale; no back-transformation.
NIST NoInt1: fit
Case STAT-NIST-NOINT1-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/NoInt1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NOINT1.json
Settings compared
curve= "custom"expression= "b1*x"parameters= [{"name": "b1", "start": 1.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/eligible_count | exact | 11 | 11 | 0.00E+2 | passed | |
/artifact/degrees_of_freedom | exact | 10 | 10 | 0.00E+2 | passed | |
/artifact/estimates/0 | lre | 2.07438016528926 | 2.074380165289256 | 3.83E-15 | 14 | passed |
/validation_standard_errors/0 | lre | 0.165289256198347E-01 | 0.016528925619834704 | 4.26E-18 | 15 | passed |
/sse | lre | 127.272727272727 | 127.27272727272715 | 1.53E-13 | 14 | passed |
Convention
- NIST model: Model: Linear Class 1 Parameter (B1) y = B1*x + e
- HypoNum accuracy policy: minimum 4 digits.
NIST NoInt2: fit
Case STAT-NIST-NOINT2-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/NoInt2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NOINT2.json
Settings compared
curve= "custom"expression= "b1*x"parameters= [{"name": "b1", "start": 1.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/eligible_count | exact | 3 | 3 | 0.00E+2 | passed | |
/artifact/degrees_of_freedom | exact | 2 | 2 | 0.00E+2 | passed | |
/artifact/estimates/0 | lre | 0.727272727272727 | 0.7272727272727273 | 2.93E-16 | 15 | passed |
/validation_standard_errors/0 | lre | 0.420827318078432E-01 | 0.042082731807843214 | 1.42E-17 | 15 | passed |
/sse | lre | 0.272727272727273 | 0.2727272727272722 | 7.93E-16 | 14 | passed |
Convention
- NIST model: Model: Linear Class 1 Parameter (B1) y = B1*x + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Norris: fit
Case STAT-NIST-NORRIS-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Norris.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NORRIS.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/[term=Intercept]/estimate | lre | -0.262323073774029 | -0.26232307377405417 | 2.52E-14 | 13 | passed |
/responses/0/parameters/[term=x]/estimate | lre | 1.00211681802045 | 1.0021168180204545 | 4.49E-15 | 14 | passed |
/responses/0/parameters/[term=Intercept]/std_error | lre | 0.232818234301152 | 0.2328182343011547 | 2.70E-15 | 13 | passed |
/responses/0/parameters/[term=x]/std_error | lre | 0.429796848199937E-03 | 0.0004297968481999409 | 3.92E-18 | 14 | passed |
/responses/0/metrics/r_squared | lre | 0.999993745883712 | 0.9999937458837117 | 2.96E-16 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 26.6173985294224 | 26.617398529422868 | 4.68E-13 | 13 | passed |
/responses/0/observations | exact | 36 | 36 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/f_stat | lre | 5436385.54079785 | 5436385.540797743 | 1.07E-7 | 13 | passed |
Convention
- NIST Norris is an intercept-and-slope OLS model with y response and x predictor.
- HypoNum accuracy policy: minimum 4 digits.
NIST Norris: general linear
Case STAT-NIST-NORRIS-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Norris.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NORRIS.json
Settings compared
covariate_columns= ["x"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/Intercept | lre | -0.262323073774029 | -0.26232307377419284 | 1.64E-13 | 12 | passed |
/coefficients/x | lre | 1.00211681802045 | 1.0021168180204547 | 4.71E-15 | 14 | passed |
/observations | exact | 36 | 36 | 0.00E+2 | passed | |
/residual_df | exact | 34 | 34 | 0.00E+2 | passed | |
/residual_variance | lre | 0.782864662630069 | 0.7828646626300864 | 1.74E-14 | 13 | passed |
/term_tests/[term=x]/f_statistic | lre | 5436385.54079785 | 5436385.540797729 | 1.21E-7 | 13 | passed |
Convention
- NIST Norris is an intercept-and-slope OLS model with y response and x predictor.
- HypoNum accuracy policy: minimum 4 digits.
NIST Norris: linear effects
Case STAT-NIST-NORRIS-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Norris.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NORRIS.json
Settings compared
covariate_columns= ["x"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/Intercept | lre | -0.262323073774029 | -0.2623230737738709 | 1.58E-13 | 12 | passed |
/coefficients/x | lre | 1.00211681802045 | 1.002116818020454 | 4.05E-15 | 14 | passed |
/observations | exact | 36 | 36 | 0.00E+2 | passed | |
/residual_df | exact | 34 | 34 | 0.00E+2 | passed | |
/residual_variance | lre | 0.782864662630069 | 0.782864662630079 | 1.00E-14 | 13 | passed |
/term_tests/[term=x]/f_statistic | lre | 5436385.54079785 | 5436385.540797778 | 7.16E-8 | 13 | passed |
Convention
- NIST Norris is an intercept-and-slope OLS model with y response and x predictor.
- HypoNum accuracy policy: minimum 4 digits.
NIST NumAcc1: tabulation
Case STAT-NIST-NUMACC1-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/NumAcc1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NUMACC1.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | 10000002 | 10000002.0 | 0.00E+2 | passed | |
/numeric_summaries/0/standard_deviation | lre | 1 | 1.0 | 0.00E+2 | passed | |
/numeric_summaries/0/valid_n | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- NIST sample SD uses the n-1 denominator.
- HypoNum accuracy policy: minimum 4 digits.
NIST NumAcc2: acf
Case STAT-NIST-NUMACC2-ACF-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/NumAcc2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NUMACC2.json
Settings compared
maximum_lag= 1response_column= "y"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlations/acf/1 | lre | -0.999 | -0.9989999999999999 | 1.12E-16 | 15 | passed |
/correlations/sample_count | exact | 1001 | 1001 | 0.00E+2 | passed |
Convention
- NIST lag-1 sample autocorrelation uses centered products over the full centered sum of squares.
- HypoNum accuracy policy: minimum 4 digits.
NIST NumAcc2: tabulation
Case STAT-NIST-NUMACC2-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/NumAcc2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NUMACC2.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | 1.2 | 1.2 | 4.44E-17 | 16 | passed |
/numeric_summaries/0/standard_deviation | lre | 0.1 | 0.09999999999999998 | 2.22E-17 | 15 | passed |
/numeric_summaries/0/valid_n | exact | 1001 | 1001 | 0.00E+2 | passed |
Convention
- NIST sample SD uses the n-1 denominator.
- HypoNum accuracy policy: minimum 4 digits.
NIST NumAcc3: acf
Case STAT-NIST-NUMACC3-ACF-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/NumAcc3.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NUMACC3.json
Settings compared
maximum_lag= 1response_column= "y"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlations/acf/1 | lre | -0.999 | -0.999 | 8.88E-19 | 18 | passed |
/correlations/sample_count | exact | 1001 | 1001 | 0.00E+2 | passed |
Convention
- NIST lag-1 sample autocorrelation uses centered products over the full centered sum of squares.
- HypoNum accuracy policy: minimum 4 digits.
NIST NumAcc3: tabulation
Case STAT-NIST-NUMACC3-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/NumAcc3.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NUMACC3.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | 1000000.2 | 1000000.2000000001 | 6.98E-11 | 16 | passed |
/numeric_summaries/0/standard_deviation | lre | 0.1 | 0.1000000000349246 | 3.49E-11 | 9 | passed |
/numeric_summaries/0/valid_n | exact | 1001 | 1001 | 0.00E+2 | passed |
Convention
- NIST sample SD uses the n-1 denominator.
- HypoNum accuracy policy: minimum 4 digits.
NIST NumAcc4: acf
Case STAT-NIST-NUMACC4-ACF-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/NumAcc4.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NUMACC4.json
Settings compared
maximum_lag= 1response_column= "y"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlations/acf/1 | lre | -0.999 | -0.9989999999999998 | 2.23E-16 | 15 | passed |
/correlations/sample_count | exact | 1001 | 1001 | 0.00E+2 | passed |
Convention
- NIST lag-1 sample autocorrelation uses centered products over the full centered sum of squares.
- HypoNum accuracy policy: minimum 4 digits.
NIST NumAcc4: tabulation
Case STAT-NIST-NUMACC4-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/NumAcc4.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_NUMACC4.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | 10000000.2 | 10000000.200000001 | 1.12E-9 | 15 | passed |
/numeric_summaries/0/standard_deviation | lre | 0.1 | 0.10000000055879354 | 5.59E-10 | 8 | passed |
/numeric_summaries/0/valid_n | exact | 1001 | 1001 | 0.00E+2 | passed |
Convention
- NIST sample SD uses the n-1 denominator.
- HypoNum accuracy policy: minimum 4 digits.
NIST PiDigits: acf
Case STAT-NIST-PIDIGITS-ACF-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/PiDigits.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_PIDIGITS.json
Settings compared
maximum_lag= 1response_column= "y"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/correlations/acf/1 | lre | -0.00355099287237972 | -0.0035509928723797216 | 1.62E-18 | 15 | passed |
/correlations/sample_count | exact | 5000 | 5000 | 0.00E+2 | passed |
Convention
- NIST model: Model: Lower Level of Difficulty --> 2 Parameters : mu, sigma --> 1 Response Variable : y --> 0 Predictor Variables y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST PiDigits: tabulation
Case STAT-NIST-PIDIGITS-TABULATION-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/univ/data/PiDigits.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_PIDIGITS.json
Settings compared
kind= "numeric"value_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/numeric_summaries/0/mean | lre | 4.53480000000000 | 4.5348 | 2.80E-16 | 16 | passed |
/numeric_summaries/0/standard_deviation | lre | 2.86733906028871 | 2.867339060288708 | 1.89E-15 | 15 | passed |
/numeric_summaries/0/valid_n | exact | 5000 | 5000 | 0.00E+2 | passed |
Convention
- NIST model: Model: Lower Level of Difficulty --> 2 Parameters : mu, sigma --> 1 Response Variable : y --> 0 Predictor Variables y = mu + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Pontius: fit
Case STAT-NIST-PONTIUS-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Pontius.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_PONTIUS.json
Settings compared
algorithm= "ols"degree= 2model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 40 | 40 | 0.00E+2 | passed | |
/responses/0/parameters/[term=Intercept]/estimate | lre | 0.673565789473684E-03 | 0.0006735657894736408 | 4.32E-17 | 13 | passed |
/responses/0/parameters/[term=Intercept]/std_error | lre | 0.107938612033077E-03 | 0.00010793861203307724 | 2.36E-19 | 14 | passed |
/responses/0/parameters/[term=x]/estimate | lre | 0.732059160401003E-06 | 7.320591604010026e-07 | 4.22E-22 | 15 | passed |
/responses/0/parameters/[term=x]/std_error | lre | 0.157817399981659E-09 | 1.578173999816591e-10 | 1.08E-25 | 15 | passed |
/responses/0/parameters/[term=x^2]/estimate | lre | -0.316081871345029E-14 | -3.160818713450321e-15 | 3.08E-29 | passed | |
/responses/0/parameters/[term=x^2]/std_error | lre | 0.486652849992036E-16 | 4.866528499920374e-17 | 1.39E-31 | 14 | passed |
/responses/0/anova/[source=Error]/ss | lre | 0.155761768796992E-05 | 1.5576176879699351e-06 | 1.51E-20 | 14 | passed |
/responses/0/metrics/r_squared | lre | 0.999999900178537 | 0.9999999001785371 | 1.27E-16 | 15 | passed |
/responses/0/anova/[source=Model]/f_stat | lre | 185330865.995752 | 185330865.99575037 | 1.63E-6 | 14 | passed |
Notes
- the raw-basis coefficients and standard errors of a design with condition above 1e13 - an independent raw-basis double solver collapses to first-digit errors and only extended-precision arithmetic reproduces the certified digits.
Convention
- NIST model: Model: Quadratic Class 3 Parameters (B0,B1,B2) y = B0 + B1*x + B2*(x**2)
- HypoNum accuracy policy: minimum 4 digits.
NIST Rat42: nonlinear regression Start 1
Case STAT-NIST-RAT42-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Rat42.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_RAT42.json
Settings compared
curve= "custom"expression= "b1 / (1+exp(b2-b3*x))"max_evaluations= 10000parameters= [{"name": "b1", "start": 100.0}, {"name": "b2", "start": 1.0}, {"name": "b3", "start": 0.1}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 6 | 6 | 0.00E+2 | passed | |
/sse | lre | 8.0565229338E+00 | 8.056522933811284 | 1.13E-11 | 11 | passed |
/artifact/residual_variance | lre | 1.34275382240174799001 | 1.3427538223018807 | 9.99E-11 | 10 | passed |
/artifact/estimates/0 | lre | 7.2462237576E+01 | 72.46223757556918 | 4.31E-10 | 11 | passed |
/artifact/covariance/0/0 | lre | 3.00685428426996126801 | 3.0068542841112382 | 1.59E-10 | 10 | passed |
/artifact/estimates/1 | lre | 2.6180768402E+00 | 2.618076840208497 | 8.50E-12 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.007796045439729561911296 | 0.0077960454398105904 | 8.10E-14 | 10 | passed |
/artifact/estimates/2 | lre | 6.7359200066E-02 | 0.06735920006610503 | 1.05E-13 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.00001187881952016679044129 | 1.1878819520044612e-05 | 1.22E-16 | 10 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 6.6e-15 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = b1 / (1+exp[b2-b3*x]) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Rat42: nonlinear regression Start 2
Case STAT-NIST-RAT42-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Rat42.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_RAT42.json
Settings compared
curve= "custom"expression= "b1 / (1+exp(b2-b3*x))"max_evaluations= 10000parameters= [{"name": "b1", "start": 75.0}, {"name": "b2", "start": 2.5}, {"name": "b3", "start": 0.07}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 6 | 6 | 0.00E+2 | passed | |
/sse | lre | 8.0565229338E+00 | 8.056522933811294 | 1.13E-11 | 11 | passed |
/artifact/residual_variance | lre | 1.34275382240174799001 | 1.3427538223018824 | 9.99E-11 | 10 | passed |
/artifact/estimates/0 | lre | 7.2462237576E+01 | 72.46223757556919 | 4.31E-10 | 11 | passed |
/artifact/covariance/0/0 | lre | 3.00685428426996126801 | 3.0068542841112516 | 1.59E-10 | 10 | passed |
/artifact/estimates/1 | lre | 2.6180768402E+00 | 2.618076840208497 | 8.50E-12 | 11 | passed |
/artifact/covariance/1/1 | lre | 0.007796045439729561911296 | 0.007796045439810639 | 8.11E-14 | 10 | passed |
/artifact/estimates/2 | lre | 6.7359200066E-02 | 0.06735920006610502 | 1.05E-13 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.00001187881952016679044129 | 1.1878819520044698e-05 | 1.22E-16 | 10 | passed |
Convention
- NIST model: Model: Exponential Class 3 Parameters (b1 to b3) y = b1 / (1+exp[b2-b3*x]) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Rat43: nonlinear regression Start 1
Case STAT-NIST-RAT43-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Rat43.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_RAT43.json
Settings compared
curve= "custom"expression= "b1 / ((1+exp(b2-b3*x))**(1/b4))"max_evaluations= 10000parameters= [{"name": "b1", "start": 100.0}, {"name": "b2", "start": 10.0}, {"name": "b3", "start": 1.0}, {"name": "b4", "start": 1.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 11 | 11 | 0.00E+2 | passed | |
/sse | lre | 8.7864049080E+03 | 8786.404907963151 | 3.68E-8 | 11 | passed |
/artifact/residual_variance | lre | 798.764082526832574244 | 798.7640825421047 | 1.53E-8 | 10 | passed |
/artifact/estimates/0 | lre | 6.9964151270E+02 | 699.6415126964456 | 3.55E-9 | 11 | passed |
/artifact/covariance/0/0 | lre | 265.764914114162965489 | 265.7649141042808 | 9.88E-9 | 10 | passed |
/artifact/estimates/1 | lre | 5.2771253025E+00 | 5.277125302450048 | 5.00E-11 | 11 | passed |
/artifact/covariance/1/1 | lre | 4.33836236234268317241 | 4.3383623625348715 | 1.92E-10 | 10 | passed |
/artifact/estimates/2 | lre | 7.5962938329E-01 | 0.7596293832941349 | 4.13E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.0382833186899772149401 | 0.038283318689537646 | 4.40E-13 | 10 | passed |
/artifact/estimates/3 | lre | 1.2792483859E+00 | 1.2792483859097146 | 9.71E-12 | 11 | passed |
/artifact/covariance/3/3 | lre | 0.4728203895414786868225 | 0.4728203895411055 | 3.73E-13 | 12 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 2.0e-14 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 4 Parameters (b1 to b4) y = b1 / ((1+exp[b2-b3*x])**(1/b4)) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Rat43: nonlinear regression Start 2
Case STAT-NIST-RAT43-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Rat43.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_RAT43.json
Settings compared
curve= "custom"expression= "b1 / ((1+exp(b2-b3*x))**(1/b4))"max_evaluations= 10000parameters= [{"name": "b1", "start": 700.0}, {"name": "b2", "start": 5.0}, {"name": "b3", "start": 0.75}, {"name": "b4", "start": 1.3}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 11 | 11 | 0.00E+2 | passed | |
/sse | lre | 8.7864049080E+03 | 8786.40490796315 | 3.69E-8 | 11 | passed |
/artifact/residual_variance | lre | 798.764082526832574244 | 798.7640825421045 | 1.53E-8 | 10 | passed |
/artifact/estimates/0 | lre | 6.9964151270E+02 | 699.6415126964456 | 3.55E-9 | 11 | passed |
/artifact/covariance/0/0 | lre | 265.764914114162965489 | 265.76491410428116 | 9.88E-9 | 10 | passed |
/artifact/estimates/1 | lre | 5.2771253025E+00 | 5.277125302450035 | 5.00E-11 | 11 | passed |
/artifact/covariance/1/1 | lre | 4.33836236234268317241 | 4.3383623625348555 | 1.92E-10 | 10 | passed |
/artifact/estimates/2 | lre | 7.5962938329E-01 | 0.7596293832941338 | 4.13E-12 | 11 | passed |
/artifact/covariance/2/2 | lre | 0.0382833186899772149401 | 0.0382833186895375 | 4.40E-13 | 10 | passed |
/artifact/estimates/3 | lre | 1.2792483859E+00 | 1.2792483859097101 | 9.71E-12 | 11 | passed |
/artifact/covariance/3/3 | lre | 0.4728203895414786868225 | 0.4728203895411018 | 3.77E-13 | 12 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 9.3e-15 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Exponential Class 4 Parameters (b1 to b4) y = b1 / ((1+exp[b2-b3*x])**(1/b4)) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Roszman1: nonlinear regression Start 1
Case STAT-NIST-ROSZMAN1-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Roszman1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ROSZMAN1.json
Settings compared
curve= "custom"expression= "b1 - b2*x - arctan(b3/(x-b4))/3.141592653589793"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.1}, {"name": "b2", "start": -1e-05}, {"name": "b3", "start": 1000.0}, {"name": "b4", "start": -100.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 21 | 21 | 0.00E+2 | passed | |
/sse | lre | 4.9484847331E-04 | 0.0004948484733096881 | 3.12E-16 | 12 | passed |
/artifact/residual_variance | lre | 0.00002356421301449414083600 | 2.3564213014747053e-05 | 2.53E-16 | 10 | passed |
/artifact/estimates/0 | lre | 2.0196866396E-01 | 0.20196866396029273 | 2.93E-13 | 11 | passed |
/artifact/covariance/0/0 | lre | 0.000367591122429498636529 | 0.000367591122424288 | 5.21E-15 | 10 | passed |
/artifact/estimates/1 | lre | -6.1953516256E-06 | -6.1953516254825735e-06 | 1.17E-16 | 10 | passed |
/artifact/covariance/1/1 | lre | 1.027775101168204119481E-11 | 1.0277751011881212e-11 | 1.99E-22 | 10 | passed |
/artifact/estimates/2 | lre | 1.2044556708E+03 | 1204.4556707861677 | 1.38E-8 | 10 | passed |
/artifact/covariance/2/2 | lre | 5483.548091708101065249 | 5483.5480917033965 | 4.70E-9 | 12 | passed |
/artifact/estimates/3 | lre | -1.8134269537E+02 | -181.34269537038148 | 3.81E-10 | 11 | passed |
/artifact/covariance/3/3 | lre | 2457.533275336994794801 | 2457.5332754035435 | 6.65E-8 | 10 | passed |
Convention
- NIST model: Model: Miscellaneous Class 4 Parameters (b1 to b4) pi = 3.141592653589793238462643383279E0 y = b1 - b2*x - arctan[b3/(x-b4)]/pi + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Roszman1: nonlinear regression Start 2
Case STAT-NIST-ROSZMAN1-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Roszman1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_ROSZMAN1.json
Settings compared
curve= "custom"expression= "b1 - b2*x - arctan(b3/(x-b4))/3.141592653589793"max_evaluations= 10000parameters= [{"name": "b1", "start": 0.2}, {"name": "b2", "start": -5e-06}, {"name": "b3", "start": 1200.0}, {"name": "b4", "start": -150.0}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 21 | 21 | 0.00E+2 | passed | |
/sse | lre | 4.9484847331E-04 | 0.0004948484733096923 | 3.08E-16 | 12 | passed |
/artifact/residual_variance | lre | 0.00002356421301449414083600 | 2.3564213014747253e-05 | 2.53E-16 | 10 | passed |
/artifact/estimates/0 | lre | 2.0196866396E-01 | 0.20196866387777823 | 8.22E-11 | 9 | passed |
/artifact/covariance/0/0 | lre | 0.000367591122429498636529 | 0.00036759112248658106 | 5.71E-14 | 9 | passed |
/artifact/estimates/1 | lre | -6.1953516256E-06 | -6.195351612987561e-06 | 1.26E-14 | 8 | passed |
/artifact/covariance/1/1 | lre | 1.027775101168204119481E-11 | 1.0277751013804922e-11 | 2.12E-21 | 9 | passed |
/artifact/estimates/2 | lre | 1.2044556708E+03 | 1204.4556711287262 | 3.29E-7 | 9 | passed |
/artifact/covariance/2/2 | lre | 5483.548091708101065249 | 5483.548090581426 | 1.13E-6 | 9 | passed |
/artifact/estimates/3 | lre | -1.8134269537E+02 | -181.34269554862834 | 1.79E-7 | 9 | passed |
/artifact/covariance/3/3 | lre | 2457.533275336994794801 | 2457.5332785456135 | 3.21E-6 | 8 | passed |
Convention
- NIST model: Model: Miscellaneous Class 4 Parameters (b1 to b4) pi = 3.141592653589793238462643383279E0 y = b1 - b2*x - arctan[b3/(x-b4)]/pi + e
- HypoNum accuracy policy: minimum 4 digits.
NIST SiRstv: fit
Case STAT-NIST-SIRSTV-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SiRstv.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SIRSTV.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 1.18046237440255E+00 | 1.1804623744024463 | 1.04E-13 | 13 | passed |
/responses/0/observations | exact | 25 | 25 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/df | tolerance | 4 | 4.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 20 | 20.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Model]/ss | lre | 5.11462616000000E-02 | 0.05114626159999949 | 5.07E-16 | 14 | passed |
/responses/0/anova/[source=Error]/ss | lre | 2.16636560000000E-01 | 0.2166365600000165 | 1.65E-14 | 13 | passed |
Convention
- NIST SiRstv is a one-way fixed-effect ANOVA of resistance by instrument.
- HypoNum accuracy policy: minimum 4 digits.
NIST SiRstv: general linear
Case STAT-NIST-SIRSTV-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SiRstv.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SIRSTV.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 1.18046237440255E+00 | 1.1804623744024474 | 1.03E-13 | 13 | passed |
/term_tests/[term=group]/numerator_df | exact | 4 | 4 | 0.00E+2 | passed | |
/residual_df | exact | 20 | 20 | 0.00E+2 | passed | |
/observations | exact | 25 | 25 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 5.11462616000000E-02 | 0.05114626159999955 | 4.52E-16 | 14 | passed |
/term_tests/[term=group]/mean_sq | lre | 1.27865654000000E-02 | 0.012786565399999887 | 1.13E-16 | 14 | passed |
/residual_variance | lre | 1.08318280000000E-02 | 0.010831828000000826 | 8.26E-16 | 13 | passed |
Convention
- NIST SiRstv is a one-way fixed-effect ANOVA of resistance by instrument.
- HypoNum accuracy policy: minimum 4 digits.
NIST SiRstv: linear effects
Case STAT-NIST-SIRSTV-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SiRstv.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SIRSTV.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 1.18046237440255E+00 | 1.1804623744024467 | 1.03E-13 | 13 | passed |
/term_tests/[term=group]/numerator_df | exact | 4 | 4 | 0.00E+2 | passed | |
/residual_df | exact | 20 | 20 | 0.00E+2 | passed | |
/observations | exact | 25 | 25 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 5.11462616000000E-02 | 0.05114626159999952 | 4.79E-16 | 14 | passed |
/term_tests/[term=group]/mean_sq | lre | 1.27865654000000E-02 | 0.01278656539999988 | 1.20E-16 | 14 | passed |
/residual_variance | lre | 1.08318280000000E-02 | 0.010831828000000826 | 8.26E-16 | 13 | passed |
Convention
- NIST SiRstv is a one-way fixed-effect ANOVA of resistance by instrument.
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs01: fit
Case STAT-NIST-SMLS01-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs01.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS01.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.10000000000000E+01 | 21.000000000000004 | 3.55E-15 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 180 | 180.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.68000000000000E+00 | 1.6800000000000013 | 1.27E-15 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+00 | 1.800000000000001 | 9.33E-16 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs01: general linear
Case STAT-NIST-SMLS01-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs01.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS01.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.10000000000000E+01 | 20.999999999999986 | 1.42E-14 | 15 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 180 | 180 | 0.00E+2 | passed | |
/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.68000000000000E+00 | 1.6799999999999995 | 5.06E-16 | 15 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.10000000000000E-01 | 0.20999999999999994 | 6.33E-17 | 15 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000004 | 3.68E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs01: linear effects
Case STAT-NIST-SMLS01-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs01.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS01.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.10000000000000E+01 | 21.0 | 0.00E-11 | passed | |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 180 | 180 | 0.00E+2 | passed | |
/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.68000000000000E+00 | 1.6800000000000006 | 6.04E-16 | 15 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.10000000000000E-01 | 0.21000000000000008 | 7.55E-17 | 15 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000004 | 3.68E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs02: fit
Case STAT-NIST-SMLS02-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs02.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS02.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.01000000000000E+02 | 201.00000000000006 | 5.68E-14 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 1800 | 1800.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.60800000000000E+01 | 16.080000000000013 | 1.25E-14 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+01 | 18.00000000000001 | 1.07E-14 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs02: general linear
Case STAT-NIST-SMLS02-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs02.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS02.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.01000000000000E+02 | 201.00000000000037 | 3.69E-13 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 1800 | 1800 | 0.00E+2 | passed | |
/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60800000000000E+01 | 16.080000000000016 | 1.61E-14 | 15 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.01000000000000E+00 | 2.010000000000002 | 2.01E-15 | 15 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.009999999999999992 | 8.47E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs02: linear effects
Case STAT-NIST-SMLS02-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs02.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS02.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.01000000000000E+02 | 201.00000000000026 | 2.56E-13 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 1800 | 1800 | 0.00E+2 | passed | |
/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60800000000000E+01 | 16.08000000000003 | 3.03E-14 | 14 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.01000000000000E+00 | 2.010000000000004 | 3.78E-15 | 14 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000005 | 5.41E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs03: fit
Case STAT-NIST-SMLS03-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs03.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS03.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.00100000000000E+03 | 2001.000000000001 | 9.09E-13 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 18000 | 18000.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.60080000000000E+02 | 160.08000000000015 | 1.55E-13 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+02 | 180.00000000000009 | 8.53E-14 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs03: general linear
Case STAT-NIST-SMLS03-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs03.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS03.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.00100000000000E+03 | 2001.0000000000261 | 2.61E-11 | 13 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 18000 | 18000 | 0.00E+2 | passed | |
/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60080000000000E+02 | 160.08000000000214 | 2.14E-12 | 13 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.00100000000000E+01 | 20.010000000000268 | 2.68E-13 | 13 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000004 | 3.68E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs03: linear effects
Case STAT-NIST-SMLS03-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs03.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS03.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.00100000000000E+03 | 2000.9999999999795 | 2.05E-11 | 13 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 18000 | 18000 | 0.00E+2 | passed | |
/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60080000000000E+02 | 160.0799999999985 | 1.49E-12 | 14 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.00100000000000E+01 | 20.009999999999813 | 1.87E-13 | 14 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000009 | 8.88E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs04: fit
Case STAT-NIST-SMLS04-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs04.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS04.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.10000000000000E+01 | 20.999999999999996 | 3.55E-15 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 180 | 180.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.68000000000000E+00 | 1.6800000000000002 | 1.60E-16 | 16 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+00 | 1.8000000000000003 | 2.66E-16 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs04: general linear
Case STAT-NIST-SMLS04-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs04.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS04.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.10000000000000E+01 | 20.99999999999997 | 2.84E-14 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 180 | 180 | 0.00E+2 | passed | |
/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.68000000000000E+00 | 1.6799999999999982 | 1.84E-15 | 14 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.10000000000000E-01 | 0.20999999999999977 | 2.30E-16 | 14 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000002 | 1.94E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs04: linear effects
Case STAT-NIST-SMLS04-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs04.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS04.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.10000000000000E+01 | 21.0 | 0.00E-11 | passed | |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 180 | 180 | 0.00E+2 | passed | |
/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.68000000000000E+00 | 1.68 | 6.22E-17 | 16 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.10000000000000E-01 | 0.21 | 7.77E-18 | 16 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.01 | 2.08E-19 | 16 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs05: fit
Case STAT-NIST-SMLS05-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs05.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS05.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.01000000000000E+02 | 200.99999999999994 | 5.68E-14 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 1800 | 1800.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.60800000000000E+01 | 16.08 | 1.71E-15 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+01 | 18.000000000000004 | 3.55E-15 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs05: general linear
Case STAT-NIST-SMLS05-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs05.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS05.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.01000000000000E+02 | 200.99999999999966 | 3.41E-13 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 1800 | 1800 | 0.00E+2 | passed | |
/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60800000000000E+01 | 16.079999999999984 | 1.59E-14 | 15 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.01000000000000E+00 | 2.009999999999998 | 1.99E-15 | 15 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000007 | 7.15E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs05: linear effects
Case STAT-NIST-SMLS05-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs05.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS05.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.01000000000000E+02 | 201.00000000000009 | 8.53E-14 | 15 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 1800 | 1800 | 0.00E+2 | passed | |
/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60800000000000E+01 | 16.080000000000013 | 1.25E-14 | 15 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.01000000000000E+00 | 2.0100000000000016 | 1.56E-15 | 15 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000004 | 3.68E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs06: fit
Case STAT-NIST-SMLS06-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs06.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS06.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.00100000000000E+03 | 2001.0000000000005 | 4.55E-13 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 18000 | 18000.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.60080000000000E+02 | 160.08000000000007 | 6.93E-14 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+02 | 180.00000000000003 | 2.84E-14 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs06: general linear
Case STAT-NIST-SMLS06-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs06.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS06.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.00100000000000E+03 | 2001.0000000000246 | 2.46E-11 | 13 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 18000 | 18000 | 0.00E+2 | passed | |
/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60080000000000E+02 | 160.0800000000021 | 2.09E-12 | 13 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.00100000000000E+01 | 20.01000000000026 | 2.61E-13 | 13 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000007 | 7.15E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs06: linear effects
Case STAT-NIST-SMLS06-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs06.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS06.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.00100000000000E+03 | 2000.9999999999848 | 1.52E-11 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 18000 | 18000 | 0.00E+2 | passed | |
/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60080000000000E+02 | 160.07999999999873 | 1.27E-12 | 14 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.00100000000000E+01 | 20.00999999999984 | 1.58E-13 | 14 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.009999999999999997 | 3.26E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs07: fit
Case STAT-NIST-SMLS07-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs07.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS07.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.10000000000000E+01 | 20.999999999999996 | 3.55E-15 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 180 | 180.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.68000000000000E+00 | 1.6800000000000002 | 1.60E-16 | 16 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+00 | 1.8000000000000003 | 2.66E-16 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs07: general linear
Case STAT-NIST-SMLS07-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs07.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS07.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.10000000000000E+01 | 20.99999999999997 | 2.84E-14 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 180 | 180 | 0.00E+2 | passed | |
/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.68000000000000E+00 | 1.6799999999999982 | 1.84E-15 | 14 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.10000000000000E-01 | 0.20999999999999977 | 2.30E-16 | 14 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000002 | 1.94E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs07: linear effects
Case STAT-NIST-SMLS07-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs07.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS07.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.10000000000000E+01 | 21.0 | 0.00E-11 | passed | |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 180 | 180 | 0.00E+2 | passed | |
/observations | exact | 189 | 189 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.68000000000000E+00 | 1.68 | 6.22E-17 | 16 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.10000000000000E-01 | 0.21 | 7.77E-18 | 16 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.01 | 2.08E-19 | 16 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs08: fit
Case STAT-NIST-SMLS08-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs08.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS08.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.01000000000000E+02 | 200.99999999999994 | 5.68E-14 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 1800 | 1800.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.60800000000000E+01 | 16.08 | 1.71E-15 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+01 | 18.000000000000004 | 3.55E-15 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs08: general linear
Case STAT-NIST-SMLS08-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs08.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS08.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.01000000000000E+02 | 200.99999999999966 | 3.41E-13 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 1800 | 1800 | 0.00E+2 | passed | |
/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60800000000000E+01 | 16.079999999999984 | 1.59E-14 | 15 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.01000000000000E+00 | 2.009999999999998 | 1.99E-15 | 15 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000007 | 7.15E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs08: linear effects
Case STAT-NIST-SMLS08-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs08.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS08.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.01000000000000E+02 | 201.00000000000009 | 8.53E-14 | 15 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 1800 | 1800 | 0.00E+2 | passed | |
/observations | exact | 1809 | 1809 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60800000000000E+01 | 16.080000000000013 | 1.25E-14 | 15 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.01000000000000E+00 | 2.0100000000000016 | 1.56E-15 | 15 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000004 | 3.68E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs09: fit
Case STAT-NIST-SMLS09-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs09.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS09.json
Settings compared
algorithm= "ols"model_type= "linear"x_columns= ["group"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/anova/[source=Model]/f_stat | lre | 2.00100000000000E+03 | 2001.0000000000005 | 4.55E-13 | 15 | passed |
/responses/0/anova/[source=Model]/df | tolerance | 8 | 8.0 | 0.00E+2 | 15 | passed |
/responses/0/anova/[source=Error]/df | tolerance | 18000 | 18000.0 | 0.00E+2 | 15 | passed |
/responses/0/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/responses/0/anova/[source=Model]/ss | lre | 1.60080000000000E+02 | 160.08000000000007 | 6.93E-14 | 15 | passed |
/responses/0/anova/[source=Error]/ss | lre | 1.80000000000000E+02 | 180.00000000000003 | 2.84E-14 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs09: general linear
Case STAT-NIST-SMLS09-GENERAL-LINEAR-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs09.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS09.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.00100000000000E+03 | 2001.0000000000246 | 2.46E-11 | 13 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 18000 | 18000 | 0.00E+2 | passed | |
/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60080000000000E+02 | 160.0800000000021 | 2.09E-12 | 13 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.00100000000000E+01 | 20.01000000000026 | 2.61E-13 | 13 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.010000000000000007 | 7.15E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST SmLs09: linear effects
Case STAT-NIST-SMLS09-LINEAR-EFFECTS-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/anova/SmLs09.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_SMLS09.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/[term=group]/f_statistic | lre | 2.00100000000000E+03 | 2000.9999999999848 | 1.52E-11 | 14 | passed |
/term_tests/[term=group]/numerator_df | exact | 8 | 8 | 0.00E+2 | passed | |
/residual_df | exact | 18000 | 18000 | 0.00E+2 | passed | |
/observations | exact | 18009 | 18009 | 0.00E+2 | passed | |
/term_tests/[term=group]/sum_sq | lre | 1.60080000000000E+02 | 160.07999999999873 | 1.27E-12 | 14 | passed |
/term_tests/[term=group]/mean_sq | lre | 2.00100000000000E+01 | 20.00999999999984 | 1.58E-13 | 14 | passed |
/residual_variance | lre | 1.00000000000000E-02 | 0.009999999999999997 | 3.26E-18 | 15 | passed |
Convention
- NIST model: Model: 10 Parameters (mu,tau_1, ... , tau_9) y_{ij} = mu + tau_i + epsilon_{ij}
- HypoNum accuracy policy: minimum 4 digits.
NIST Thurber: nonlinear regression Start 1
Case STAT-NIST-THURBER-START1-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Thurber.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_THURBER.json
Settings compared
curve= "custom"expression= "(b1 + b2*x + b3*x**2 + b4*x**3) / (1 + b5*x + b6*x**2 + b7*x**3)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1000.0}, {"name": "b2", "start": 1000.0}, {"name": "b3", "start": 400.0}, {"name": "b4", "start": 40.0}, {"name": "b5", "start": 0.7}, {"name": "b6", "start": 0.3}, {"name": "b7", "start": 0.03}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 30 | 30 | 0.00E+2 | passed | |
/sse | lre | 5.6427082397E+03 | 5642.7082396670085 | 3.30E-8 | 11 | passed |
/artifact/residual_variance | lre | 188.090274664493414656 | 188.09027465556696 | 8.93E-9 | 10 | passed |
/artifact/estimates/0 | lre | 1.2881396800E+03 | 1288.1396800910818 | 9.11E-8 | 10 | passed |
/artifact/covariance/0/0 | lre | 21.76032484143167662336 | 21.76032485074853 | 9.32E-9 | 9 | passed |
/artifact/estimates/1 | lre | 1.4910792535E+03 | 1491.0792469868018 | 6.51E-6 | 8 | passed |
/artifact/covariance/1/1 | lre | 1565.876393982574839396 | 1565.8766157531477 | 2.22E-4 | 6 | passed |
/artifact/estimates/2 | lre | 5.8323836877E+02 | 583.2383638935214 | 4.88E-6 | 8 | passed |
/artifact/covariance/2/2 | lre | 823.615157954949994404 | 823.615274830416 | 1.17E-4 | 6 | passed |
/artifact/estimates/3 | lre | 7.5416644291E+01 | 75.41664335613956 | 9.35E-7 | 7 | passed |
/artifact/covariance/3/3 | lre | 30.99746854701599872900 | 30.99747304918288 | 4.50E-6 | 6 | passed |
/artifact/estimates/4 | lre | 9.6629502864E-01 | 0.9662950231270615 | 5.51E-9 | 8 | passed |
/artifact/covariance/4/4 | lre | 0.000981778238607609631969 | 0.0009817783596103686 | 1.21E-10 | 6 | passed |
/artifact/estimates/5 | lre | 3.9797285797E-01 | 0.3979728554185926 | 2.55E-9 | 8 | passed |
/artifact/covariance/5/5 | lre | 0.000224548073099215527204 | 0.000224548101192599 | 2.81E-11 | 6 | passed |
/artifact/estimates/6 | lre | 4.9727297349E-02 | 0.049727296670537616 | 6.78E-10 | 7 | passed |
/artifact/covariance/6/6 | lre | 0.00004335214345453897012129 | 4.335214948657674e-05 | 6.03E-12 | 6 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.1e-10 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Rational Class (cubic/cubic) 7 Parameters (b1 to b7) y = (b1 + b2*x + b3*x**2 + b4*x**3) / (1 + b5*x + b6*x**2 + b7*x**3) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Thurber: nonlinear regression Start 2
Case STAT-NIST-THURBER-START2-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/nls/data/LINKS/DATA/Thurber.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_THURBER.json
Settings compared
curve= "custom"expression= "(b1 + b2*x + b3*x**2 + b4*x**3) / (1 + b5*x + b6*x**2 + b7*x**3)"max_evaluations= 10000parameters= [{"name": "b1", "start": 1300.0}, {"name": "b2", "start": 1500.0}, {"name": "b3", "start": 500.0}, {"name": "b4", "start": 75.0}, {"name": "b5", "start": 1.0}, {"name": "b6", "start": 0.4}, {"name": "b7", "start": 0.05}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/degrees_of_freedom | exact | 30 | 30 | 0.00E+2 | passed | |
/sse | lre | 5.6427082397E+03 | 5642.708239667073 | 3.29E-8 | 11 | passed |
/artifact/residual_variance | lre | 188.090274664493414656 | 188.0902746555691 | 8.92E-9 | 10 | passed |
/artifact/estimates/0 | lre | 1.2881396800E+03 | 1288.139679953759 | 4.62E-8 | 10 | passed |
/artifact/covariance/0/0 | lre | 21.76032484143167662336 | 21.760324841034215 | 3.97E-10 | 10 | passed |
/artifact/estimates/1 | lre | 1.4910792535E+03 | 1491.0792535422156 | 4.22E-8 | 10 | passed |
/artifact/covariance/1/1 | lre | 1565.876393982574839396 | 1565.8763939621053 | 2.05E-8 | 10 | passed |
/artifact/estimates/2 | lre | 5.8323836877E+02 | 583.238368766669 | 3.33E-9 | 11 | passed |
/artifact/covariance/2/2 | lre | 823.615157954949994404 | 823.6151579255238 | 2.94E-8 | 10 | passed |
/artifact/estimates/3 | lre | 7.5416644291E+01 | 75.41664429101121 | 1.12E-11 | 12 | passed |
/artifact/covariance/3/3 | lre | 30.99746854701599872900 | 30.99746854716517 | 1.49E-10 | 11 | passed |
/artifact/estimates/4 | lre | 9.6629502864E-01 | 0.9662950286446166 | 4.62E-12 | 11 | passed |
/artifact/covariance/4/4 | lre | 0.000981778238607609631969 | 0.000981778238607175 | 4.35E-16 | 12 | passed |
/artifact/estimates/5 | lre | 3.9797285797E-01 | 0.3979728579739074 | 3.91E-12 | 11 | passed |
/artifact/covariance/5/5 | lre | 0.000224548073099215527204 | 0.00022454807308993062 | 9.28E-15 | 10 | passed |
/artifact/estimates/6 | lre | 4.9727297349E-02 | 0.04972729734885059 | 1.49E-13 | 11 | passed |
/artifact/covariance/6/6 | lre | 0.00004335214345453897012129 | 4.335214345468464e-05 | 1.46E-16 | 11 | passed |
Notes
- optimum confirmed by independent arithmetic - the fitted SSE matches the certified SSE within 1.3e-10 relative (gradient diagnostics at both points sit at the same finite-difference noise floor), so the coefficient/covariance digit shortfall is the flat, ill-conditioned objective, not a stopping error.
Convention
- NIST model: Model: Rational Class (cubic/cubic) 7 Parameters (b1 to b7) y = (b1 + b2*x + b3*x**2 + b4*x**3) / (1 + b5*x + b6*x**2 + b7*x**3) + e
- HypoNum accuracy policy: minimum 4 digits.
NIST Wampler1: fit
Case STAT-NIST-WAMPLER1-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Wampler1.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_WAMPLER1.json
Settings compared
algorithm= "ols"degree= 5model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 21 | 21 | 0.00E+2 | passed | |
/responses/0/parameters/[term=Intercept]/estimate | lre | 1.00000000000000 | 0.9999999999847685 | 1.52E-11 | 10 | passed |
/responses/0/parameters/[term=x]/estimate | lre | 1.00000000000000 | 1.000000000002785 | 2.79E-12 | 11 | passed |
/responses/0/parameters/[term=x^2]/estimate | lre | 1.00000000000000 | 0.9999999999988504 | 1.15E-12 | 11 | passed |
/responses/0/parameters/[term=x^3]/estimate | lre | 1.00000000000000 | 1.0000000000001352 | 1.35E-13 | 12 | passed |
/responses/0/parameters/[term=x^4]/estimate | lre | 1.00000000000000 | 0.9999999999999939 | 6.11E-15 | 14 | passed |
/responses/0/parameters/[term=x^5]/estimate | lre | 1.00000000000000 | 1.0000000000000002 | 2.22E-16 | 15 | passed |
/responses/0/parameters | zero_residual_standard_errors | [{'term': 'Intercept', 'estimate': 0.9999999999847685, 'std_ | passed | |||
/responses/0/anova/[source=Error]/ss | lre | 0.000000000000000 | 2.4067300062000036e-19 | 2.41E-19 | passed | |
/responses/0/metrics/r_squared | lre | 1.00000000000000 | 1.0 | 0.00E-12 | passed |
Convention
- NIST model: Model: Polynomial Class 6 Parameters (B0,B1,...,B5) y = B0 + B1*x + B2*(x**2) + B3*(x**3)+ B4*(x**4) + B5*(x**5)
- HypoNum accuracy policy: minimum 4 digits.
NIST Wampler2: fit
Case STAT-NIST-WAMPLER2-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Wampler2.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_WAMPLER2.json
Settings compared
algorithm= "ols"degree= 5model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 21 | 21 | 0.00E+2 | passed | |
/responses/0/parameters/[term=Intercept]/estimate | lre | 1.00000000000000 | 0.9999999999999998 | 2.22E-16 | 15 | passed |
/responses/0/parameters/[term=x]/estimate | lre | 0.100000000000000 | 0.10000000000000064 | 6.44E-16 | 14 | passed |
/responses/0/parameters/[term=x^2]/estimate | lre | 0.100000000000000E-01 | 0.009999999999999681 | 3.19E-16 | 13 | passed |
/responses/0/parameters/[term=x^3]/estimate | lre | 0.100000000000000E-02 | 0.0010000000000000542 | 5.42E-17 | 13 | passed |
/responses/0/parameters/[term=x^4]/estimate | lre | 0.100000000000000E-03 | 9.999999999999639e-05 | 3.61E-18 | 13 | passed |
/responses/0/parameters/[term=x^5]/estimate | lre | 0.100000000000000E-04 | 1.000000000000008e-05 | 8.04E-20 | 14 | passed |
/responses/0/parameters | zero_residual_standard_errors | [{'term': 'Intercept', 'estimate': 0.9999999999999998, 'std_ | passed | |||
/responses/0/anova/[source=Error]/ss | lre | 0.000000000000000 | 1.9669194870171214e-29 | 1.97E-29 | passed | |
/responses/0/metrics/r_squared | lre | 1.00000000000000 | 1.0 | 0.00E-12 | passed |
Convention
- NIST model: Model: Polynomial Class 6 Parameters (B0,B1,...,B5) y = B0 + B1*x + B2*(x**2) + B3*(x**3)+ B4*(x**4) + B5*(x**5)
- HypoNum accuracy policy: minimum 4 digits.
NIST Wampler3: fit
Case STAT-NIST-WAMPLER3-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Wampler3.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_WAMPLER3.json
Settings compared
algorithm= "ols"degree= 5model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 21 | 21 | 0.00E+2 | passed | |
/responses/0/parameters/[term=Intercept]/estimate | lre | 1.00000000000000 | 0.999999999995735 | 4.27E-12 | 11 | passed |
/responses/0/parameters/[term=Intercept]/std_error | lre | 2152.32624678170 | 2152.326246781112 | 5.88E-10 | 12 | passed |
/responses/0/parameters/[term=x]/estimate | lre | 1.00000000000000 | 1.0000000000250866 | 2.51E-11 | 10 | passed |
/responses/0/parameters/[term=x]/std_error | lre | 2363.55173469681 | 2363.551734696858 | 4.81E-11 | 13 | passed |
/responses/0/parameters/[term=x^2]/estimate | lre | 1.00000000000000 | 0.9999999999901046 | 9.90E-12 | 11 | passed |
/responses/0/parameters/[term=x^2]/std_error | lre | 779.343524331583 | 779.3435243316006 | 1.76E-11 | 13 | passed |
/responses/0/parameters/[term=x^3]/estimate | lre | 1.00000000000000 | 1.0000000000013964 | 1.40E-12 | 11 | passed |
/responses/0/parameters/[term=x^3]/std_error | lre | 101.475507550350 | 101.47550755035158 | 1.58E-12 | 13 | passed |
/responses/0/parameters/[term=x^4]/estimate | lre | 1.00000000000000 | 0.9999999999999191 | 8.09E-14 | 13 | passed |
/responses/0/parameters/[term=x^4]/std_error | lre | 5.64566512170752 | 5.645665121707608 | 8.77E-14 | 13 | passed |
/responses/0/parameters/[term=x^5]/estimate | lre | 1.00000000000000 | 1.0000000000000016 | 1.55E-15 | 14 | passed |
/responses/0/parameters/[term=x^5]/std_error | lre | 0.112324854679312 | 0.11232485467931357 | 1.57E-15 | 13 | passed |
/responses/0/anova/[source=Error]/ss | lre | 83554268.0000000 | 83554268.00000028 | 2.83E-7 | 14 | passed |
/responses/0/metrics/r_squared | lre | 0.999995559025820 | 0.9999955590258199 | 6.44E-17 | 16 | passed |
/responses/0/anova/[source=Model]/f_stat | lre | 675524.458240122 | 675524.4582401202 | 1.79E-9 | 14 | passed |
Convention
- NIST model: Model: Polynomial Class 6 Parameters (B0,B1,...,B5) y = B0 + B1*x + B2*(x**2) + B3*(x**3)+ B4*(x**4) + B5*(x**5)
- HypoNum accuracy policy: minimum 4 digits.
NIST Wampler4: fit
Case STAT-NIST-WAMPLER4-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Wampler4.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_WAMPLER4.json
Settings compared
algorithm= "ols"degree= 5model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 21 | 21 | 0.00E+2 | passed | |
/responses/0/parameters/[term=Intercept]/estimate | lre | 1.00000000000000 | 0.9999999998848814 | 1.15E-10 | 9 | passed |
/responses/0/parameters/[term=Intercept]/std_error | lre | 215232.624678170 | 215232.62467811082 | 5.92E-8 | 12 | passed |
/responses/0/parameters/[term=x]/estimate | lre | 1.00000000000000 | 0.9999999992269888 | 7.73E-10 | 9 | passed |
/responses/0/parameters/[term=x]/std_error | lre | 236355.173469681 | 236355.17346968543 | 4.43E-9 | 13 | passed |
/responses/0/parameters/[term=x^2]/estimate | lre | 1.00000000000000 | 1.0000000004292138 | 4.29E-10 | 9 | passed |
/responses/0/parameters/[term=x^2]/std_error | lre | 77934.3524331583 | 77934.35243315995 | 1.65E-9 | 13 | passed |
/responses/0/parameters/[term=x^3]/estimate | lre | 1.00000000000000 | 0.9999999999313253 | 6.87E-11 | 10 | passed |
/responses/0/parameters/[term=x^3]/std_error | lre | 10147.5507550350 | 10147.550755035141 | 1.41E-10 | 13 | passed |
/responses/0/parameters/[term=x^4]/estimate | lre | 1.00000000000000 | 1.000000000004233 | 4.23E-12 | 11 | passed |
/responses/0/parameters/[term=x^4]/std_error | lre | 564.566512170752 | 564.5665121707598 | 7.78E-12 | 13 | passed |
/responses/0/parameters/[term=x^5]/estimate | lre | 1.00000000000000 | 0.999999999999911 | 8.90E-14 | 13 | passed |
/responses/0/parameters/[term=x^5]/std_error | lre | 11.2324854679312 | 11.232485467931339 | 1.39E-13 | 13 | passed |
/responses/0/anova/[source=Error]/ss | lre | 835542680000.000 | 835542680000.0001 | 1.22E-4 | 15 | passed |
/responses/0/metrics/r_squared | lre | 0.957478440825662 | 0.9574784408256621 | 1.36E-16 | 15 | passed |
/responses/0/anova/[source=Model]/f_stat | lre | 67.5524458240122 | 67.55244582401222 | 2.43E-14 | 15 | passed |
Convention
- NIST model: Model: Polynomial Class 6 Parameters (B0,B1,...,B5) y = B0 + B1*x + B2*(x**2) + B3*(x**3)+ B4*(x**4) + B5*(x**5)
- HypoNum accuracy policy: minimum 4 digits.
NIST Wampler5: fit
Case STAT-NIST-WAMPLER5-FIT-001 · status: passed
Reference
- Evidence type
- NIST
- Source
- NIST Statistical Reference Datasets
- Citation
- https://itl.nist.gov/div898/strd/lls/data/LINKS/DATA/Wampler5.dat
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/NIST_WAMPLER5.json
Settings compared
algorithm= "ols"degree= 5model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 21 | 21 | 0.00E+2 | passed | |
/responses/0/parameters/[term=Intercept]/estimate | lre | 1.00000000000000 | 0.9999999903134835 | 9.69E-9 | 8 | passed |
/responses/0/parameters/[term=Intercept]/std_error | lre | 21523262.4678170 | 21523262.46781108 | 5.92E-6 | 12 | passed |
/responses/0/parameters/[term=x]/estimate | lre | 1.00000000000000 | 0.9999999243340468 | 7.57E-8 | 7 | passed |
/responses/0/parameters/[term=x]/std_error | lre | 23635517.3469681 | 23635517.346968543 | 4.43E-7 | 13 | passed |
/responses/0/parameters/[term=x^2]/estimate | lre | 1.00000000000000 | 1.0000000421229767 | 4.21E-8 | 7 | passed |
/responses/0/parameters/[term=x^2]/std_error | lre | 7793435.24331583 | 7793435.243315994 | 1.64E-7 | 13 | passed |
/responses/0/parameters/[term=x^3]/estimate | lre | 1.00000000000000 | 0.9999999932602714 | 6.74E-9 | 8 | passed |
/responses/0/parameters/[term=x^3]/std_error | lre | 1014755.07550350 | 1014755.075503514 | 1.40E-8 | 13 | passed |
/responses/0/parameters/[term=x^4]/estimate | lre | 1.00000000000000 | 1.0000000004150376 | 4.15E-10 | 9 | passed |
/responses/0/parameters/[term=x^4]/std_error | lre | 56456.6512170752 | 56456.651217075974 | 7.74E-10 | 13 | passed |
/responses/0/parameters/[term=x^5]/estimate | lre | 1.00000000000000 | 0.999999999991285 | 8.72E-12 | 11 | passed |
/responses/0/parameters/[term=x^5]/std_error | lre | 1123.24854679312 | 1123.2485467931338 | 1.38E-11 | 13 | passed |
/responses/0/anova/[source=Error]/ss | lre | 0.835542680000000E+16 | 8355426800000000.0 | 0.00E+2 | passed | |
/responses/0/metrics/r_squared | lre | 0.224668921574940E-02 | 0.0022466892157495533 | 1.53E-16 | 13 | passed |
/responses/0/anova/[source=Model]/f_stat | lre | 6.7552445824012241E-03 | 0.00675524458240122 | 4.31E-18 | 15 | passed |
Convention
- NIST model: Model: Polynomial Class 6 Parameters (B0,B1,...,B5) y = B0 + B1*x + B2*(x**2) + B3*(x**3)+ B4*(x**4) + B5*(x**5)
- HypoNum accuracy policy: minimum 4 digits.
Fixed approved limits replace the calculated ones
Case STAT-QUAL-APPROVED-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded I-MR charts and rules in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_stages.R · sha256 046de2272a987401
- Dataset
- reference_data/datasets/QUAL_SPC_STAGES.json
Settings compared
approved= [{"chart": "individuals", "center": 21.5, "lower": 18.4, "upper": 24.6}, {"chart": "moving_range", "center": 1, "lower": 0, "upper": 3.3}]x_column= "label"y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/upper_control_limit | tolerance | 24.600000000000001 | 24.6 | 4.21E-16 | 16 | passed |
/primary/lower_control_limit | tolerance | 18.399999999999999 | 18.4 | 4.21E-16 | 16 | passed |
/primary/center_line | tolerance | 21.5 | 21.5 | 0.00E+1 | passed | |
/violation_keys | set | ['primary:rule_1:11', 'primary:rule_1:17', 'primary:rule_1:2 | ['primary:rule_1:11', 'primary:rule_1:17', 'primary:rule_1:2 | passed |
Convention
- Approved values (individuals 18.4/21.5/24.6, moving range 0/1.0/3.3) are hand-chosen round numbers.
- Rules 2-4 need only the approved centre, so the fixed basis needs no process sigma.
- Approved fixed limits are user-supplied; NIST/Nelson support chart factors and rule definitions, not those values.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
96 whole <- stage(d$x)
97 approved <- list(list(chart = "individuals", center = 21.5, lower = 18.4, upper = 24.6),
98 list(chart = "moving_range", center = 1.0, lower = 0, upper = 3.3))
99 keys <- c(rules_for(d$x, rep(21.5, 60), 1, rep(24.6, 60), rep(18.4, 60), 0L),
100 rules_for(whole$mr, rep(1, 59), 1, rep(3.3, 59), rep(0, 59), 0L, "secondary", FALSE))
101 emit("STAT-QUAL-APPROVED-001", approved_entry, "Fixed approved limits replace the calculated ones",
102 list(y_column = "x", x_column = "label", approved = approved),
103 list("/primary/upper_control_limit" = list(comparison = "tolerance", value = dec(24.6), absolute_tolerance = "0",
104 relative_tolerance = "1e-9", rationale = "The approved upper limit applies to every point."),
105 "/primary/lower_control_limit" = list(comparison = "tolerance", value = dec(18.4), absolute_tolerance = "0",
106 relative_tolerance = "1e-9", rationale = "The approved lower limit applies to every point."),
107 "/primary/center_line" = list(comparison = "tolerance", value = dec(21.5), absolute_tolerance = "0",
108 relative_tolerance = "1e-9", rationale = "The approved centre."),
109 "/violation_keys" = set_of(keys, "Rule 1 against the approved limits, rules 2-4 against the approved centre; rule 1 on the MR chart.")),
110 c("Approved values (individuals 18.4/21.5/24.6, moving range 0/1.0/3.3) are hand-chosen round numbers.",
111 "Rules 2-4 need only the approved centre, so the fixed basis needs no process sigma."),
112 kind = "axis_coverage")
Approved limits for the wrong chart are refused
Case STAT-QUAL-APPROVED-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded I-MR charts and rules in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_stages.R · sha256 046de2272a987401
- Dataset
- reference_data/datasets/QUAL_SPC_STAGES.json
Settings compared
approved= [{"chart": "xbar", "center": 21, "lower": 18, "upper": 24}]x_column= "label"y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A variables result needs approvals for the charts it plots.
- Approved fixed limits are user-supplied; NIST/Nelson support chart factors and rule definitions, not those values.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
114 emit("STAT-QUAL-APPROVED-002", approved_entry, "Approved limits for the wrong chart are refused",
115 list(y_column = "x", x_column = "label", approved = list(list(chart = "xbar", center = 21, lower = 18, upper = 24))),
116 list(), c("A variables result needs approvals for the charts it plots."), kind = "invalid_input",
117 error = list(error_class = "ValueError", message_contains = "No approved limits are available"))
p chart with varying inspected counts
Case STAT-QUAL-ATTR-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.3.1-2, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc332.htm; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR.json
Settings compared
chart= "p"count_column= "defectives"sample_size_column= "inspected"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 0.059445178335535004 | 0.059445178335535004 | 1.45E-19 | 17 | passed |
/chart/point_upper_limits | sequence | ['0.1290044393164344', '0.13184475260149978', '0.12834509494 | [0.1290044393164344, 0.13184475260149978, 0.1283450949478652 | passed | ||
/chart/point_lower_limits | sequence | ['0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', | [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, | passed | ||
/chart/points/0/value | tolerance | 0.096153846153846159 | 0.09615384615384616 | 1.84E-19 | 17 | passed |
/chart/points/5/value | tolerance | 0.058823529411764705 | 0.058823529411764705 | 6.60E-20 | 17 | passed |
/violation_keys | set | ['primary:rule_1:16'] | ['primary:rule_1:16'] | passed |
Convention
- Line 139-141; stepped limits for varying n_i (line 160-161).
- NIST published p/c forms; varying-n, clipped-limit and exclusion choices remain explicit in this case.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
121 laney_deferred <- list(list(path = "/dispersion_ratio",
122 reason = "The manual does not define the reported dispersion ratio; sigma_z is checked through the adjusted limits."))
123 emit_chart("STAT-QUAL-ATTR-001", "p chart with varying inspected counts",
124 list(count_column = "defectives", chart = "p", sample_size_column = "inspected"),
125 p_chart(a$defectives, a$inspected), c("Line 139-141; stepped limits for varying n_i (line 160-161)."))
Laney p' chart
Case STAT-QUAL-ATTR-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Laney, Improved Control Charts for Attributes, Quality Engineering 14(4), 2002, pp. 531-537; NIST/SEMATECH e-Handbook 6.3.3
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR.json
Settings compared
chart= "laney_p"count_column= "defectives"sample_size_column= "inspected"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 0.059445178335535004 | 0.059445178335535004 | 1.45E-19 | 17 | passed |
/chart/point_upper_limits | sequence | ['0.15614894767927182', '0.16009765266707113', '0.1552323035 | [0.15614894767927182, 0.16009765266707113, 0.155232303585630 | passed | ||
/chart/point_lower_limits | sequence | ['0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', | [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, | passed | ||
/chart/points/0/value | tolerance | 0.096153846153846159 | 0.09615384615384616 | 1.84E-19 | 17 | passed |
/chart/points/5/value | tolerance | 0.058823529411764705 | 0.058823529411764705 | 6.60E-20 | 17 | passed |
/violation_keys | set | ['primary:rule_1:16'] | ['primary:rule_1:16'] | passed |
Convention
- sigma_z = mean |z_i - z_(i-1)| / d2(2) over standardized p values.
- Laney standardized moving ranges adjust the corresponding p/u limits; sparse or degenerate baselines need separate failure cases.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
126 ch <- p_chart(a$defectives, a$inspected, laney = TRUE)
127 emit_chart("STAT-QUAL-ATTR-002", "Laney p' chart", list(count_column = "defectives", chart = "laney_p", sample_size_column = "inspected"),
128 ch, c("sigma_z = mean |z_i - z_(i-1)| / d2(2) over standardized p values."), kind = "axis_coverage",
129 deferred = laney_deferred)
c chart
Case STAT-QUAL-ATTR-003 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.3.1-2, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc332.htm; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR.json
Settings compared
chart= "c"count_column= "defects"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 7.833333333333333 | 7.833333333333333 | 3.73E-17 | 17 | passed |
/chart/upper_control_limit | tolerance | 16.229761145206666 | 16.229761145206666 | 1.29E-16 | 17 | passed |
/chart/lower_control_limit | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/chart/points/8/value | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/violation_keys | set | ['primary:rule_1:8'] | ['primary:rule_1:8'] | passed |
Convention
- Line 144-145: cbar +/- 3 sqrt(cbar), clipped at 0.
- NIST published p/c forms; varying-n, clipped-limit and exclusion choices remain explicit in this case.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
130 cbar <- mean(a$defects)
131 emit("STAT-QUAL-ATTR-003", attr_entry, "c chart", "QUAL_ATTR", list(count_column = "defects", chart = "c"),
132 list("/chart/center_line" = tol(cbar, "cbar."),
133 "/chart/upper_control_limit" = tol(cbar + 3 * sqrt(cbar), "cbar + 3 sqrt(cbar)."),
134 "/chart/lower_control_limit" = tol(max(0, cbar - 3 * sqrt(cbar)), "Clipped at 0."),
135 "/chart/points/8/value" = tol(a$defects[9], "The ninth count."),
136 "/violation_keys" = set_of(window_keys(a$defects, rep(cbar, k), rep(sqrt(cbar), k), rep(cbar + 3 * sqrt(cbar), k),
137 rep(max(0, cbar - 3 * sqrt(cbar)), k)), "Rules 1-4 in R.")),
138 c("Line 144-145: cbar +/- 3 sqrt(cbar), clipped at 0."), kind = "axis_coverage")
u chart with an area column
Case STAT-QUAL-ATTR-004 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.3.1-2, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc332.htm; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR.json
Settings compared
chart= "u"count_column= "defects"sample_size_column= "area"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 4.2501627721912749 | 4.250162772191277 | 1.79E-15 | 15 | passed |
/chart/point_upper_limits | sequence | ['8.564540080336922', '9.2437352347215551', '8.2608436838305 | [8.564540080336926, 9.243735234721559, 8.260843683830597, 8. | passed | ||
/chart/point_lower_limits | sequence | ['0', '0', '0.23948186055195553', '0', '0', '0.2875157000385 | [0.0, 0.0, 0.23948186055195642, 0.0, 0.0, 0.2875157000385373 | passed | ||
/chart/points/0/value | tolerance | 5.3527980535279802 | 5.35279805352798 | 1.54E-17 | 17 | passed |
/chart/points/5/value | tolerance | 4.9261083743842367 | 4.926108374384237 | 4.55E-17 | 17 | passed |
/violation_keys | set | ['primary:rule_1:8'] | ['primary:rule_1:8'] | passed |
Convention
- Line 146-148.
- np/u formulas are independently derived from binomial/Poisson models with the configured denominator convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
139 emit_chart("STAT-QUAL-ATTR-004", "u chart with an area column", list(count_column = "defects", chart = "u", sample_size_column = "area"),
140 u_chart(a$defects, a$area), c("Line 146-148."), kind = "axis_coverage")
Laney u' chart
Case STAT-QUAL-ATTR-005 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Laney, Improved Control Charts for Attributes, Quality Engineering 14(4), 2002, pp. 531-537; NIST/SEMATECH e-Handbook 6.3.3
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR.json
Settings compared
chart= "laney_u"count_column= "defects"sample_size_column= "area"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 4.2501627721912749 | 4.250162772191277 | 1.79E-15 | 15 | passed |
/chart/point_upper_limits | sequence | ['10.00147955174851', '10.906886336785874', '9.5966345286161 | [10.001479551748513, 10.906886336785877, 9.596634528616164, | passed | ||
/chart/point_lower_limits | sequence | ['0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', | [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, | passed | ||
/chart/points/0/value | tolerance | 5.3527980535279802 | 5.35279805352798 | 1.54E-17 | 17 | passed |
/chart/points/5/value | tolerance | 4.9261083743842367 | 4.926108374384237 | 4.55E-17 | 17 | passed |
/violation_keys | set | ['primary:rule_1:8'] | ['primary:rule_1:8'] | passed |
Convention
- sigma_z from standardized u values.
- Laney standardized moving ranges adjust the corresponding p/u limits; sparse or degenerate baselines need separate failure cases.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
141 ch <- u_chart(a$defects, a$area, laney = TRUE)
142 emit_chart("STAT-QUAL-ATTR-005", "Laney u' chart", list(count_column = "defects", chart = "laney_u", sample_size_column = "area"),
143 ch, c("sigma_z from standardized u values."), kind = "axis_coverage",
144 deferred = laney_deferred)
np chart with a constant size of 100
Case STAT-QUAL-ATTR-006 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.3.1-2, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc332.htm; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR_NP.json
Settings compared
chart= "np"count_column= "defectives"sample_size= 100
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/chart/upper_control_limit | tolerance | 16.13879597975032 | 16.13879597975032 | 1.34E-17 | 18 | passed |
/chart/lower_control_limit | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/violation_keys | set | [] | [] | passed |
Convention
- Line 142-143.
- np/u formulas are independently derived from binomial/Poisson models with the configured denominator convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
147 set.seed(20261007)
148 dn <- rbinom(k, 100, 0.08)
149 export_dataset(data.frame(lot = seq_len(k), defectives = as.integer(dn)), "QUAL_ATTR_NP",
150 "Constructed: rbinom(30, 100, 0.08), seed 20261007", "R stats::rbinom documentation",
151 "Constructed validation data; no third-party license.", c(lot = "Int64", defectives = "Int64"))
152 an <- read_dataset("QUAL_ATTR_NP")
153 pbar <- sum(an$defectives) / (100 * k); s <- sqrt(100 * pbar * (1 - pbar))
154 emit("STAT-QUAL-ATTR-006", attr_entry, "np chart with a constant size of 100", "QUAL_ATTR_NP",
155 list(count_column = "defectives", chart = "np", sample_size = 100),
156 list("/chart/center_line" = tol(100 * pbar, "n pbar."),
157 "/chart/upper_control_limit" = tol(100 * pbar + 3 * s, "n pbar + 3 sqrt(n pbar (1 - pbar))."),
158 "/chart/lower_control_limit" = tol(max(0, 100 * pbar - 3 * s), "Clipped at 0."),
159 "/violation_keys" = set_of(window_keys(an$defectives, rep(100 * pbar, k), rep(s, k), rep(100 * pbar + 3 * s, k),
160 rep(max(0, 100 * pbar - 3 * s), k)), "Rules 1-4 in R.")),
161 c("Line 142-143."), kind = "axis_coverage")
p chart with a Phase I baseline of 20 lots
Case STAT-QUAL-ATTR-007 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.3.1-2, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc332.htm; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR.json
Settings compared
baseline= {"column": "phase", "op": "le", "value": 1}chart= "p"count_column= "defectives"sample_size_column= "inspected"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 0.06646372399797057 | 0.06646372399797057 | 3.76E-19 | 17 | passed |
/chart/point_upper_limits | sequence | ['0.13973985326469524', '0.14273193743148355', '0.1390452771 | [0.13973985326469524, 0.14273193743148355, 0.139045277121975 | passed | ||
/chart/point_lower_limits | sequence | ['0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', | [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, | passed | ||
/chart/points/0/value | tolerance | 0.096153846153846159 | 0.09615384615384616 | 1.84E-19 | 17 | passed |
/chart/points/5/value | tolerance | 0.058823529411764705 | 0.058823529411764705 | 6.60E-20 | 17 | passed |
/violation_keys | set | ['primary:rule_1:16', 'primary:rule_2:25', 'primary:rule_2:2 | ['primary:rule_1:16', 'primary:rule_2:25', 'primary:rule_2:2 | passed | ||
/baseline_count | exact | 20 | 20 | 0.00E+2 | passed |
Convention
- pbar from the first 20 lots; all 30 are evaluated (line 167-168).
- NIST published p/c forms; varying-n, clipped-limit and exclusion choices remain explicit in this case.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
163 bp <- p_chart(a$defectives, a$inspected, base = a$phase <= 1)
164 emit("STAT-QUAL-ATTR-007", attr_entry, "p chart with a Phase I baseline of 20 lots", "QUAL_ATTR",
165 list(count_column = "defectives", chart = "p", sample_size_column = "inspected",
166 baseline = list(column = "phase", op = "le", value = 1)),
167 c(chart_outputs(bp$values, bp$center, bp$ucl, bp$lcl, bp$zone, "From the baseline pbar."),
168 list("/baseline_count" = exact(20L, "Twenty baseline lots."))),
169 c("pbar from the first 20 lots; all 30 are evaluated (line 167-168)."), kind = "axis_coverage")
Missing counts are omitted and excluded lots removed
Case STAT-QUAL-ATTR-008 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.3.1-2, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc332.htm; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR_MISSING.json
Settings compared
chart= "p"count_column= "defectives"sample_size_column= "inspected"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 0.056647398843930635 | 0.056647398843930635 | 2.93E-19 | 17 | passed |
/chart/point_upper_limits | sequence | ['0.12742773976401811', '0.12400635276914609', '0.1207617624 | [0.1274277397640181, 0.12400635276914608, 0.1207617624381226 | passed | ||
/chart/point_lower_limits | sequence | ['0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', | [0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, | passed | ||
/chart/points/0/value | tolerance | 0.03125 | 0.03125 | 0.00E-3 | passed | |
/chart/points/5/value | tolerance | 0.083333333333333329 | 0.08333333333333333 | 2.93E-19 | 17 | passed |
/violation_keys | set | ['primary:rule_1:13'] | ['primary:rule_1:13'] | passed | ||
/subgroup_count | exact | 26 | 26 | 0.00E+2 | passed |
Convention
- Line 164-165: rows with null counts are omitted and counted; excluded lots 0 and 11 (0-based) are removed first.
- NIST published p/c forms; varying-n, clipped-limit and exclusion choices remain explicit in this case.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
171 m <- read_dataset("QUAL_ATTR"); m$defectives[c(5, 23)] <- NA
172 export_dataset(m, "QUAL_ATTR_MISSING", "QUAL_ATTR with defectives missing in rows 5 and 23 (1-based)",
173 "R stats::rbinom documentation", "Constructed validation data; no third-party license.",
174 c(lot = "Int64", defectives = "Int64", inspected = "Int64", defects = "Int64", area = "Float64", phase = "Int64"))
175 mm <- read_dataset("QUAL_ATTR_MISSING")
176 excluded <- c(0L, 11L)
177 keep <- setdiff(which(!is.na(mm$defectives)), excluded + 1L)
178 mp <- p_chart(mm$defectives[keep], mm$inspected[keep])
179 emit("STAT-QUAL-ATTR-008", attr_entry, "Missing counts are omitted and excluded lots removed", "QUAL_ATTR_MISSING",
180 list(count_column = "defectives", chart = "p", sample_size_column = "inspected"),
181 c(chart_outputs(mp$values, mp$center, mp$ucl, mp$lcl, mp$zone, ""),
182 list("/subgroup_count" = exact(length(keep), "Retained lots."))),
183 c("Line 164-165: rows with null counts are omitted and counted; excluded lots 0 and 11 (0-based) are removed first."),
184 kind = "missing_excluded", excluded = excluded)
g chart plots the counts between events
Case STAT-QUAL-ATTR-009 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Benneyan, Number-between g-type statistical quality control charts for monitoring adverse events, Health Care Management Science 4(4), 2001, pp. 305-318; NIST/SEMATECH e-Handbook 6.3.3
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR.json
Settings compared
chart= "g"count_column= "defects"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/points/0/value | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/chart/points/8/value | tolerance | 25 | 25.0 | 0.00E+2 | passed |
Convention
- Line 152-153 say only that g limits are probability based under a geometric model.
- Rare-event geometric support or t-chart fitting conventions must be aligned before comparing published examples.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
186 emit("STAT-QUAL-ATTR-009", attr_entry, "g chart plots the counts between events", "QUAL_ATTR",
187 list(count_column = "defects", chart = "g"),
188 list("/chart/points/0/value" = tol(a$defects[1], "The plotted statistic is the count itself."),
189 "/chart/points/8/value" = tol(a$defects[9], "The plotted statistic is the count itself.")),
190 c("Line 152-153 say only that g limits are probability based under a geometric model."), kind = "axis_coverage",
191 deferred = list(list(path = "/chart/center_line", reason = "The manual does not define the g chart's centre or probability limits."),
192 list(path = "/chart/upper_control_limit", reason = "The manual does not define the g chart's probability limits.")))
Defectives above the sample size are refused
Case STAT-QUAL-ATTR-010 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.3.1-2, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc332.htm; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR_OVER.json
Settings compared
chart= "p"count_column= "defectives"sample_size_column= "inspected"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 166: binomial counts cannot exceed sample size.
- NIST published p/c forms; varying-n, clipped-limit and exclusion choices remain explicit in this case.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
194 big <- read_dataset("QUAL_ATTR"); big$defectives[3] <- big$inspected[3] + 1L
195 export_dataset(big, "QUAL_ATTR_OVER", "QUAL_ATTR with defectives exceeding the inspected count in row 3 (1-based)",
196 "Hand-constructed", "Constructed validation data; no third-party license.",
197 c(lot = "Int64", defectives = "Int64", inspected = "Int64", defects = "Int64", area = "Float64", phase = "Int64"))
198 emit("STAT-QUAL-ATTR-010", attr_entry, "Defectives above the sample size are refused", "QUAL_ATTR_OVER",
199 list(count_column = "defectives", chart = "p", sample_size_column = "inspected"), list(),
200 c("Line 166: binomial counts cannot exceed sample size."), kind = "invalid_input",
201 error = list(error_class = "ValueError", message_contains = "exceed"))
np with a varying size column is refused
Case STAT-QUAL-ATTR-011 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.3.1-2, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc332.htm; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_ATTR.json
Settings compared
chart= "np"count_column= "defectives"sample_size_column= "inspected"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 142 and 167: np requires a constant size.
- np/u formulas are independently derived from binomial/Poisson models with the configured denominator convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
202 emit("STAT-QUAL-ATTR-011", attr_entry, "np with a varying size column is refused", "QUAL_ATTR",
203 list(count_column = "defectives", chart = "np", sample_size_column = "inspected"), list(),
204 c("Line 142 and 167: np requires a constant size."), kind = "invalid_input",
205 error = list(error_class = "ValueError", message_contains = "constant"))
Binomial defectives with a Wilson interval
Case STAT-QUAL-ATTRCAP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_ATTR_CAP.json
Settings compared
denominator_column= "inspected"event_column= "defectives"family= "binomial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rate | tolerance | 0.011956297670583385 | 0.011956297670583385 | 1.07E-19 | 17 | passed |
/ppm | tolerance | 11956.297670583384 | 11956.297670583384 | 3.88E-13 | 16 | passed |
/yield_percent | tolerance | 98.804370232941665 | 98.80437023294166 | 3.47E-16 | 17 | passed |
/ci_lower | tolerance | 0.0092608140017461406 | 0.009260814001746142 | 1.72E-18 | 15 | passed |
/ci_upper | tolerance | 0.015424123670720141 | 0.015424123670720139 | 2.20E-18 | 15 | passed |
/sigma_level | tolerance | 2.258530659387783 | 2.258530659387783 | 3.16E-17 | 16 | passed |
/total_events | exact | 58 | 58 | 0.00E+2 | passed |
Convention
- The sigma level is taken as the normal quantile of the yield without a 1.5 shift; the manual says only 'where defined'.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
76 emit("STAT-QUAL-ATTRCAP-001", attr_entry, "capabilityMenuItem", "Binomial defectives with a Wilson interval", "QUAL_ATTR_CAP",
77 list(family = "binomial", event_column = "defectives", denominator_column = "inspected"),
78 binomial_outputs(a$defectives, a$inspected, 0.95),
79 c("The sigma level is taken as the normal quantile of the yield without a 1.5 shift; the manual says only 'where defined'."))Whole script generators/r/quality_capability_counts_batches.R
Binomial at a 90% confidence level
Case STAT-QUAL-ATTRCAP-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_ATTR_CAP.json
Settings compared
confidence_level= 0.9denominator_column= "inspected"event_column= "defectives"family= "binomial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/ci_lower | tolerance | 0.0096478420109686342 | 0.009647842010968634 | 1.04E-20 | 17 | passed |
/ci_upper | tolerance | 0.014808842143303259 | 0.014808842143303259 | 2.85E-20 | 17 | passed |
Convention
- A non-default confidence level (the engine API accepts it; the dialog fixes 95%).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
80 emit("STAT-QUAL-ATTRCAP-002", attr_entry, "capabilityMenuItem", "Binomial at a 90% confidence level", "QUAL_ATTR_CAP",
81 list(family = "binomial", event_column = "defectives", denominator_column = "inspected", confidence_level = 0.9),
82 binomial_outputs(a$defectives, a$inspected, 0.9)[c("/ci_lower", "/ci_upper")],
83 c("A non-default confidence level (the engine API accepts it; the dialog fixes 95%)."), kind = "axis_coverage")Whole script generators/r/quality_capability_counts_batches.R
Poisson defects with an exposure column
Case STAT-QUAL-ATTRCAP-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_ATTR_CAP.json
Settings compared
denominator_column= "exposure"event_column= "defects"family= "poisson"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rate | tolerance | 2.197802197802198 | 2.197802197802198 | 1.24E-17 | 17 | passed |
/yield_percent | tolerance | 11.104694959162304 | 11.104694959162304 | 3.53E-16 | 16 | passed |
/ci_lower | tolerance | 1.8684659736348206 | 1.8684659736348206 | 1.28E-17 | 17 | passed |
/ci_upper | tolerance | 2.5684700086002494 | 2.5684700086002503 | 9.21E-16 | 15 | passed |
Convention
- Line 173-176.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
92 emit("STAT-QUAL-ATTRCAP-003", attr_entry, "capabilityMenuItem", "Poisson defects with an exposure column", "QUAL_ATTR_CAP",
93 list(family = "poisson", event_column = "defects", denominator_column = "exposure"),
94 poisson_outputs(a$defects, a$exposure, 0.95), c("Line 173-176."), kind = "axis_coverage")Whole script generators/r/quality_capability_counts_batches.R
Poisson defects with unit exposure
Case STAT-QUAL-ATTRCAP-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_ATTR_CAP.json
Settings compared
event_column= "defects"family= "poisson"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rate | tolerance | 6.3200000000000003 | 6.32 | 1.58E-17 | 17 | passed |
/ci_lower | tolerance | 5.3729607537842901 | 5.37296075378429 | 4.45E-17 | 17 | passed |
/ci_upper | tolerance | 7.385892356730877 | 7.38589235673088 | 2.63E-15 | 15 | passed |
Convention
- With the exposure column off, each row has unit exposure (line 161-162).
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
95 emit("STAT-QUAL-ATTRCAP-004", attr_entry, "capabilityMenuItem", "Poisson defects with unit exposure", "QUAL_ATTR_CAP",
96 list(family = "poisson", event_column = "defects"),
97 poisson_outputs(a$defects, rep(1, k), 0.95)[c("/rate", "/ci_lower", "/ci_upper")],
98 c("With the exposure column off, each row has unit exposure (line 161-162)."), kind = "axis_coverage")Whole script generators/r/quality_capability_counts_batches.R
Missing and excluded rows are omitted
Case STAT-QUAL-ATTRCAP-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_ATTR_CAP_MISSING.json
Settings compared
denominator_column= "inspected"event_column= "defectives"family= "binomial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rate | tolerance | 0.012701514411333659 | 0.012701514411333659 | 3.39E-19 | 16 | passed |
/ci_lower | tolerance | 0.0096993826855715209 | 0.009699382685571523 | 1.71E-18 | 15 | passed |
/ci_upper | tolerance | 0.016617267166404326 | 0.016617267166404326 | 1.16E-19 | 17 | passed |
/dropped_rows | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Rows 0 and 10 (0-based) are excluded before the call.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
99 m <- read_dataset("QUAL_ATTR_CAP"); m$defectives[c(4, 19)] <- NA
100 export_dataset(m, "QUAL_ATTR_CAP_MISSING", "QUAL_ATTR_CAP with defectives missing in rows 4 and 19 (1-based)",
101 "R stats::rbinom documentation", "Constructed validation data; no third-party license.",
102 c(defectives = "Int64", inspected = "Int64", defects = "Int64", exposure = "Float64"))
103 mm <- read_dataset("QUAL_ATTR_CAP_MISSING")
104 excluded <- c(0L, 10L)
105 keep <- setdiff(which(!is.na(mm$defectives)), excluded + 1L)
106 emit("STAT-QUAL-ATTRCAP-005", attr_entry, "capabilityMenuItem", "Missing and excluded rows are omitted", "QUAL_ATTR_CAP_MISSING",
107 list(family = "binomial", event_column = "defectives", denominator_column = "inspected"),
108 c(binomial_outputs(mm$defectives[keep], mm$inspected[keep], 0.95)[c("/rate", "/ci_lower", "/ci_upper")],
109 list("/dropped_rows" = exact(2L, "Two rows with a missing count are disclosed and omitted."))),
110 c("Rows 0 and 10 (0-based) are excluded before the call."), kind = "missing_excluded", excluded = excluded)Whole script generators/r/quality_capability_counts_batches.R
Defectives above inspected are refused
Case STAT-QUAL-ATTRCAP-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_ATTR_CAP_OVER.json
Settings compared
denominator_column= "inspected"event_column= "defectives"family= "binomial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 159-160.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
111 over <- read_dataset("QUAL_ATTR_CAP"); over$defectives[2] <- over$inspected[2] + 1L
112 export_dataset(over, "QUAL_ATTR_CAP_OVER", "QUAL_ATTR_CAP with more defectives than inspected in row 2 (1-based)",
113 "Hand-constructed", "Constructed validation data; no third-party license.",
114 c(defectives = "Int64", inspected = "Int64", defects = "Int64", exposure = "Float64"))
115 emit("STAT-QUAL-ATTRCAP-006", attr_entry, "capabilityMenuItem", "Defectives above inspected are refused", "QUAL_ATTR_CAP_OVER",
116 list(family = "binomial", event_column = "defectives", denominator_column = "inspected"), list(),
117 c("Line 159-160."), kind = "invalid_input",
118 error = list(error_class = "ValueError", message_contains = "cannot exceed inspected counts"))Whole script generators/r/quality_capability_counts_batches.R
Binomial without an inspected column is refused
Case STAT-QUAL-ATTRCAP-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_ATTR_CAP.json
Settings compared
event_column= "defectives"family= "binomial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 159: inspected counts are required for Binomial.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
119 emit("STAT-QUAL-ATTRCAP-007", attr_entry, "capabilityMenuItem", "Binomial without an inspected column is refused", "QUAL_ATTR_CAP",
120 list(family = "binomial", event_column = "defectives"), list(),
121 c("Line 159: inspected counts are required for Binomial."), kind = "invalid_input",
122 error = list(error_class = "ValueError", message_contains = "inspected-count column"))Whole script generators/r/quality_capability_counts_batches.R
Within and overall capability of balanced batches
Case STAT-QUAL-BATCH-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_BATCH.json
Settings compared
batch_column= "batch"lower_limit= 46response_column= "y"upper_limit= 54
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/within_capability/sigma | tolerance | 0.84084889149794861 | 0.8408488914979515 | 2.89E-15 | 14 | passed |
/within_capability/cpk | tolerance | 1.5147341132019649 | 1.514734113201968 | 3.15E-15 | 14 | passed |
/within_capability/cpk_interval | interval | [0.68580159139771, 2.01382598571698] | passed | |||
/within_capability/cp | tolerance | 1.5856991033882883 | 1.5856991033882828 | 5.51E-15 | 14 | passed |
/within_capability/cp_interval | interval | [1.1696129051716113, 2.01382598571698] | passed | |||
/overall_capability/sigma | tolerance | 1.0353595234878477 | 1.0353595234878483 | 6.21E-16 | 15 | passed |
/overall_capability/cpk | tolerance | 1.230164470511049 | 1.2301644705110553 | 6.26E-15 | 14 | passed |
/overall_capability/cpk_interval | interval | [0.38505677331520866, 2.01382598571698] | passed | |||
/overall_capability/cp | tolerance | 1.2877974298644512 | 1.2877974298644506 | 6.40E-16 | 15 | passed |
/overall_capability/cp_interval | interval | [0.6567021379686924, 2.01382598571698] | passed | |||
/overall_mean | tolerance | 50.179012499999999 | 50.17901249999998 | 2.14E-14 | 15 | passed |
/total_n | exact | 48 | 48 | 0.00E+2 | passed |
Convention
- Balanced batches: REML equals the ANOVA estimator, s2_e = MSW and s2_b = (MSB - MSW) / n.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
171 set.seed(20261016)
172 G <- 8L; nb <- 6L
173 batch <- rep(sprintf("B%d", seq_len(G)), each = nb)
174 yv <- round(50 + rep(rnorm(G, 0, 0.6), each = nb) + rnorm(G * nb, 0, 0.9), 4)
175 export_dataset(data.frame(batch = batch, y = yv), "QUAL_BATCH", "Constructed: 8 balanced batches of 6, between SD 0.6, within SD 0.9, seed 20261016",
176 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(batch = "String", y = "Float64"))
177 b <- read_dataset("QUAL_BATCH")
178 rb <- batch_ref(b$y, b$batch, 46, 54)
179 if (rb$s2b <= 0) stop("expected a positive between-batch component")
180 emit("STAT-QUAL-BATCH-001", batch_entry, "batchCapabilityMenuItem", "Within and overall capability of balanced batches", "QUAL_BATCH",
181 list(response_column = "y", batch_column = "batch", lower_limit = 46, upper_limit = 54),
182 c(batch_outputs(rb, "within"), batch_outputs(rb, "overall"),
183 list("/overall_mean" = tol(rb$mu, "Analyzed grand mean."), "/total_n" = exact(48L, "48 analyzed rows."))),
184 c("Balanced batches: REML equals the ANOVA estimator, s2_e = MSW and s2_b = (MSB - MSW) / n."))Whole script generators/r/quality_capability_counts_batches.R
Upper limit only at a 90% level
Case STAT-QUAL-BATCH-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_BATCH.json
Settings compared
batch_column= "batch"confidence_level= 0.9response_column= "y"upper_limit= 54
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/within_capability/sigma | tolerance | 0.84084889149794861 | 0.8408488914979515 | 2.89E-15 | 14 | passed |
/within_capability/cpk | tolerance | 1.5147341132019649 | 1.514734113201968 | 3.15E-15 | 14 | passed |
/within_capability/cpk_interval | interval | [0.8029206734865707, 2.4502471616626513] | passed | |||
/within_capability/cp | absent | None | passed |
Convention
- One-sided upper specification; Cpk = CPU.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
185 emit("STAT-QUAL-BATCH-002", batch_entry, "batchCapabilityMenuItem", "Upper limit only at a 90% level", "QUAL_BATCH",
186 list(response_column = "y", batch_column = "batch", upper_limit = 54, confidence_level = 0.9),
187 c(batch_outputs(batch_ref(b$y, b$batch, NULL, 54, 0.9), "within", FALSE),
188 list("/within_capability/cp" = list(comparison = "absent", rationale = "Cp needs both limits."))),
189 c("One-sided upper specification; Cpk = CPU."), kind = "axis_coverage")Whole script generators/r/quality_capability_counts_batches.R
A zero between-batch component makes within and overall coincide
Case STAT-QUAL-BATCH-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_BATCH_FLAT.json
Settings compared
batch_column= "batch"lower_limit= 46response_column= "y"upper_limit= 54
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/within_capability/sigma | tolerance | 0.89979305296870338 | 0.8997930529687033 | 1.14E-16 | 15 | passed |
/overall_capability/sigma | tolerance | 0.89979305296870338 | 0.8997930529687033 | 1.14E-16 | 15 | passed |
Convention
- MSB < MSW, so the constrained REML optimum has zero between-batch variance (issue #2 ruling).
- Until 2026-09-24 this case expected sqrt(MSW), the truncated-ANOVA convention; the statistician ruled for REML.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
190 set.seed(20261017)
191 flat <- round(50 + rnorm(G * nb, 0, 0.9), 4)
192 flat <- flat - ave(flat, batch) + mean(flat) + rep(seq(-0.02, 0.02, length.out = G), each = nb)
193 export_dataset(data.frame(batch = batch, y = round(flat, 6)), "QUAL_BATCH_FLAT",
194 "Constructed: batch means forced nearly equal, seed 20261017", "R stats::rnorm documentation",
195 "Constructed validation data; no third-party license.", c(batch = "String", y = "Float64"))
196 bf <- read_dataset("QUAL_BATCH_FLAT")
197 rf <- batch_ref(bf$y, bf$batch, 46, 54)
198 if (rf$s2b != 0) stop("expected MSB < MSW")
199 emit("STAT-QUAL-BATCH-003", batch_entry, "batchCapabilityMenuItem", "A zero between-batch component makes within and overall coincide", "QUAL_BATCH_FLAT",
200 list(response_column = "y", batch_column = "batch", lower_limit = 46, upper_limit = 54),
201 list("/within_capability/sigma" = tol(rf$within$sigma, "Constrained REML at the zero boundary: sqrt(SST / (N - 1)) = sd(y)."),
202 "/overall_capability/sigma" = tol(rf$overall$sigma, "Chapter 43: at a zero optimum total and within capability coincide.")),
203 c("MSB < MSW, so the constrained REML optimum has zero between-batch variance (issue #2 ruling).",
204 "Until 2026-09-24 this case expected sqrt(MSW), the truncated-ANOVA convention; the statistician ruled for REML."),
205 kind = "boundary")Whole script generators/r/quality_capability_counts_batches.R
No specification limit is refused
Case STAT-QUAL-BATCH-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::prop.test, stats::poisson.test and one-way ANOVA mean squares
- Citation
- R stats::prop.test (correct = FALSE gives the Wilson interval), stats::poisson.test and stats::aov documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_capability_counts_batches.R · sha256 67f13e823884ff37
- Dataset
- reference_data/datasets/QUAL_BATCH.json
Settings compared
batch_column= "batch"response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 6: at least one specification limit.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
206 emit("STAT-QUAL-BATCH-004", batch_entry, "batchCapabilityMenuItem", "No specification limit is refused", "QUAL_BATCH",
207 list(response_column = "y", batch_column = "batch"), list(),
208 c("Line 6: at least one specification limit."), kind = "invalid_input",
209 error = list(error_class = "ValueError", message_contains = "At least one specification limit"))Whole script generators/r/quality_capability_counts_batches.R
Between/within I-MR-R chart by subgroup column
Case STAT-QUAL-BETWEEN-WITHIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas with stats::integrate constants; nlme::lme REML components
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 (I-MR, R and S chart constants); Pinheiro & Bates (2000) nlme; R stats::integrate
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_BW_01.json
Settings compared
dispersion= "range"response= "value"subgroup_column= "batch"subgroup_mode= "column"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stages/0/subgroups | exact | 6 | 6 | 0.00E+2 | passed | |
/stages/0/observations | exact | 30 | 30 | 0.00E+2 | passed | |
/stages/0/grand_mean | tolerance | 10.711 | 10.711 | 2.98E-16 | 16 | passed |
/stages/0/subgroup_mean_center | tolerance | 10.711 | 10.711 | 2.98E-16 | 16 | passed |
/stages/0/mean_moving_range | tolerance | 2.0428000000000002 | 2.0428000000000015 | 1.30E-15 | 15 | passed |
/stages/0/i_chart_scale | tolerance | 1.8103843633148942 | 1.8103843633148955 | 1.30E-15 | 15 | passed |
/stages/0/within_sigma | tolerance | 0.53741968406267238 | 0.537419684062673 | 6.62E-16 | 14 | passed |
/individuals/points/0/center | tolerance | 10.711 | 10.711 | 2.98E-16 | 16 | passed |
/individuals/points/0/upper | tolerance | 16.142153089944685 | 16.142153089944685 | 7.14E-18 | 18 | passed |
/individuals/points/0/lower | tolerance | 5.2798469100553174 | 5.279846910055314 | 3.59E-15 | 15 | passed |
/individuals/points/0/value | tolerance | 10.113999999999999 | 10.113999999999999 | 8.97E-18 | 18 | passed |
/within/points/0/center | tolerance | 1.2500000000000004 | 1.25 | 4.00E-16 | 15 | passed |
/within/points/0/upper | tolerance | 2.6431239313698494 | 2.6431239313698605 | 1.11E-14 | 14 | passed |
/within/points/0/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/stages/0/components/df_between | exact | 5 | 5 | 0.00E+2 | passed | |
/stages/0/components/df_within | exact | 24 | 24 | 0.00E+2 | passed | |
/stages/0/components/ms_between | tolerance | 8.0494780000000006 | 8.049478000000011 | 1.06E-14 | 14 | passed |
/stages/0/components/ms_within | tolerance | 0.27509500000000014 | 0.27509500000000026 | 1.16E-16 | 15 | passed |
/stages/0/components/n0 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/stages/0/components/between_sigma | tolerance | 1.2469469114601472 | 1.2469469114601472 | 4.48E-17 | 16 | passed |
/stages/0/components/within_component_sigma | tolerance | 0.52449499520967802 | 0.5244949952096781 | 1.08E-16 | 15 | passed |
/stages/0/components/total_sigma | tolerance | 1.3527644288640945 | 1.352764428864095 | 4.81E-16 | 15 | passed |
/moving_range/points/0/value | tolerance | 1.7680000000000007 | 1.7680000000000025 | 1.76E-15 | 15 | passed |
/moving_range/points/0/center | tolerance | 2.0428000000000002 | 2.0428000000000015 | 1.30E-15 | 15 | passed |
/moving_range/points/0/upper | tolerance | 6.6728714047227555 | 6.67287140472276 | 4.47E-15 | 15 | passed |
/moving_range/points/0/subgroup | exact | 1 | 1 | 0.00E+2 | passed | |
/subgroups/2/mean | tolerance | 9.4719999999999995 | 9.472 | 3.10E-17 | 17 | passed |
/subgroups/2/range | tolerance | 0.78000000000000114 | 0.7800000000000011 | 3.13E-18 | 17 | passed |
/subgroups/2/standard_deviation | tolerance | 0.3387772129290873 | 0.3387772129290873 | 1.33E-18 | 17 | passed |
/subgroups/2/size | exact | 5 | 5 | 0.00E+2 | passed | |
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/dropped_subgroup_count | exact | 0 | 0 | 0.00E+2 | passed | |
/individuals/points/4/beyond_limits | exact | False | False | passed |
Convention
- docs/manual/chapters/84-subgroup-monitoring.tex:19-26: I chart of subgroup means around their unweighted mean with limits c +/- 3 MR-bar/d2(2); MR upper limit D4(2) MR-bar; R or S chart uses the mean of R_i/d2(n_i) or s_i/c4(n_i) with limits that change with n_i.
- docs/manual/chapters/84-subgroup-monitoring.tex:46-57: between, within and total SDs from the constrained random-intercept REML fit; for balanced groups with a positive between component sigma_u^2 = (MS_B - MS_W)/n and sigma_e^2 = MS_W.
- d2(n), d3(n) by stats::integrate at full precision and c4(n) by lgamma; D4(2) = 1 + 3 d3(2)/d2(2).
- Balanced design with a positive between component: the REML components equal the ANOVA closed form; tolerance 1e-6 on the component SDs because HypoNum's REML optimum is numerical (nlme::lme agrees to that order).
- Expected computed from the re-read QUAL_BW_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
96 set.seed(20261010)
97 batch_means <- c(10.4, 11.9, 9.1, 10.8, 12.6, 9.7)
98 bw_value <- round(rep(batch_means, each = 5) + rnorm(30, 0, 0.5), 2)
99 lot_sizes <- c(4, 5, 6, 5, 4, 6)
100 bw <- data.frame(value = bw_value, batch = rep(1:6, each = 5), stage = rep(c("A", "B"), each = 15),
101 lot = rep(sprintf("L%d", 1:6), times = lot_sizes), stringsAsFactors = FALSE)
102 export_dataset(bw, "QUAL_BW_01",
103 "Simulated (R 4.6.1, set.seed 20261010): six batches of five coating measurements with batch-to-batch shifts; lot gives unequal subgroup sizes 4-6; 30 rows",
104 "Simulated with stats::rnorm", "Constructed validation data; no third-party license.",
105 c(value = "Float64", batch = "Int64", stage = "String", lot = "String"))
106 d <- read_dataset("QUAL_BW_01")
107 bw_ep <- "tabelz.analysis.spc_between_within:compute_between_within"
108 bw_menu <- "betweenWithinChartMenuItem"
109 bw_source <- "Hand-coded chart formulas with stats::integrate constants; nlme::lme REML components"
110 bw_cite <- "Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 (I-MR, R and S chart constants); Pinheiro & Bates (2000) nlme; R stats::integrate"
111 bw_req <- "REQ-STAT-QUAL-BETWEEN-WITHIN-001"
Between/within I-MR-S chart
Case STAT-QUAL-BETWEEN-WITHIN-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas with stats::integrate constants; nlme::lme REML components
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 (I-MR, R and S chart constants); Pinheiro & Bates (2000) nlme; R stats::integrate
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_BW_01.json
Settings compared
dispersion= "stddev"response= "value"subgroup_column= "batch"subgroup_mode= "column"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stages/0/subgroups | exact | 6 | 6 | 0.00E+2 | passed | |
/stages/0/observations | exact | 30 | 30 | 0.00E+2 | passed | |
/stages/0/grand_mean | tolerance | 10.711 | 10.711 | 2.98E-16 | 16 | passed |
/stages/0/subgroup_mean_center | tolerance | 10.711 | 10.711 | 2.98E-16 | 16 | passed |
/stages/0/mean_moving_range | tolerance | 2.0428000000000002 | 2.0428000000000015 | 1.30E-15 | 15 | passed |
/stages/0/i_chart_scale | tolerance | 1.8103843633148942 | 1.8103843633148955 | 1.30E-15 | 15 | passed |
/stages/0/within_sigma | tolerance | 0.53553137364390357 | 0.5355313736439036 | 4.33E-18 | 17 | passed |
/individuals/points/0/center | tolerance | 10.711 | 10.711 | 2.98E-16 | 16 | passed |
/individuals/points/0/upper | tolerance | 16.142153089944685 | 16.142153089944685 | 7.14E-18 | 18 | passed |
/individuals/points/0/lower | tolerance | 5.2798469100553174 | 5.279846910055314 | 3.59E-15 | 15 | passed |
/individuals/points/0/value | tolerance | 10.113999999999999 | 10.113999999999999 | 8.97E-18 | 18 | passed |
/within/points/0/center | tolerance | 0.50339178117292038 | 0.5033917811729205 | 1.14E-16 | 15 | passed |
/within/points/0/upper | tolerance | 1.051584357956233 | 1.0515843579562325 | 4.93E-16 | 15 | passed |
/within/points/0/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/stages/0/components/df_between | exact | 5 | 5 | 0.00E+2 | passed | |
/stages/0/components/df_within | exact | 24 | 24 | 0.00E+2 | passed | |
/stages/0/components/ms_between | tolerance | 8.0494780000000006 | 8.049478000000011 | 1.06E-14 | 14 | passed |
/stages/0/components/ms_within | tolerance | 0.27509500000000014 | 0.27509500000000026 | 1.16E-16 | 15 | passed |
/stages/0/components/n0 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/stages/0/components/between_sigma | tolerance | 1.2469469114601472 | 1.2469469114601472 | 4.48E-17 | 16 | passed |
/stages/0/components/within_component_sigma | tolerance | 0.52449499520967802 | 0.5244949952096781 | 1.08E-16 | 15 | passed |
/stages/0/components/total_sigma | tolerance | 1.3527644288640945 | 1.352764428864095 | 4.81E-16 | 15 | passed |
/within/points/2/value | tolerance | 0.3387772129290873 | 0.3387772129290873 | 1.33E-18 | 17 | passed |
/moving_range/points/0/upper | tolerance | 6.6728714047227555 | 6.67287140472276 | 4.47E-15 | 15 | passed |
Convention
- docs/manual/chapters/84-subgroup-monitoring.tex:19-26: I chart of subgroup means around their unweighted mean with limits c +/- 3 MR-bar/d2(2); MR upper limit D4(2) MR-bar; R or S chart uses the mean of R_i/d2(n_i) or s_i/c4(n_i) with limits that change with n_i.
- docs/manual/chapters/84-subgroup-monitoring.tex:46-57: between, within and total SDs from the constrained random-intercept REML fit; for balanced groups with a positive between component sigma_u^2 = (MS_B - MS_W)/n and sigma_e^2 = MS_W.
- d2(n), d3(n) by stats::integrate at full precision and c4(n) by lgamma; D4(2) = 1 + 3 d3(2)/d2(2).
- S chart: within sigma is the mean of s_i/c4(n_i); limits (c4 +/- 3 sqrt(1 - c4^2)) sigma_w; the I and MR charts are unchanged.
- Expected computed from the re-read QUAL_BW_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
196 s2 <- bw_stage(groups, "stddev")
197 out <- c(stage_outputs(s2, 0L, "stddev", 0L, comp, "1e-6"),
198 list("/within/points/2/value" = num(sd(groups[[3]]), "Sample SD of batch 3 on the S chart."),
199 "/moving_range/points/0/upper" = num(s2$mr_upper, "D4(2) MR-bar.")))
200 emit("STAT-QUAL-BETWEEN-WITHIN-002", bw_ep, bw_menu, "Between/within I-MR-S chart", "QUAL_BW_01",
201 list(response = "value", subgroup_mode = "column", subgroup_column = "batch", dispersion = "stddev"), out,
202 c(bw_notes, "S chart: within sigma is the mean of s_i/c4(n_i); limits (c4 +/- 3 sqrt(1 - c4^2)) sigma_w; the I and MR charts are unchanged."),
203 bw_source, bw_cite, bw_req, kind = "axis_coverage")
Between/within chart with consecutive subgroups of five and two stages
Case STAT-QUAL-BETWEEN-WITHIN-003 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas with stats::integrate constants; nlme::lme REML components
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 (I-MR, R and S chart constants); Pinheiro & Bates (2000) nlme; R stats::integrate
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_BW_01.json
Settings compared
dispersion= "range"response= "value"stage_column= "stage"subgroup_mode= "size"subgroup_size= 5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stages/1/label | exact | B | B | passed | ||
/stages/1/first_subgroup | exact | 3 | 3 | 0.00E+2 | passed | |
/subgroups/3/label | exact | 4 | 4 | passed | ||
/moving_range/points/2/subgroup | exact | 4 | 4 | 0.00E+2 | passed | |
/stages/0/subgroups | exact | 3 | 3 | 0.00E+2 | passed | |
/stages/0/observations | exact | 15 | 15 | 0.00E+2 | passed | |
/stages/0/grand_mean | tolerance | 10.489333333333333 | 10.489333333333331 | 2.04E-15 | 15 | passed |
/stages/0/subgroup_mean_center | tolerance | 10.489333333333333 | 10.489333333333335 | 1.51E-15 | 15 | passed |
/stages/0/mean_moving_range | tolerance | 2.0890000000000004 | 2.089000000000002 | 1.79E-15 | 15 | passed |
/stages/0/i_chart_scale | tolerance | 1.8513280472708118 | 1.8513280472708133 | 1.55E-15 | 15 | passed |
/stages/0/within_sigma | tolerance | 0.56034959058267986 | 0.5603495905826806 | 7.74E-16 | 14 | passed |
/individuals/points/0/center | tolerance | 10.489333333333333 | 10.489333333333335 | 1.51E-15 | 15 | passed |
/individuals/points/0/upper | tolerance | 16.04331747514577 | 16.043317475145777 | 7.00E-15 | 15 | passed |
/individuals/points/0/lower | tolerance | 4.9353491915208973 | 4.935349191520894 | 3.50E-15 | 15 | passed |
/individuals/points/0/value | tolerance | 10.113999999999999 | 10.113999999999999 | 8.97E-18 | 18 | passed |
/within/points/0/center | tolerance | 1.3033333333333341 | 1.303333333333334 | 2.01E-16 | 15 | passed |
/within/points/0/upper | tolerance | 2.7558972191082969 | 2.755897219108309 | 1.20E-14 | 14 | passed |
/within/points/0/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/stages/0/components/df_between | exact | 2 | 2 | 0.00E+2 | passed | |
/stages/0/components/df_within | exact | 12 | 12 | 0.00E+2 | passed | |
/stages/0/components/ms_between | tolerance | 7.7884066666666696 | 7.788406666666682 | 1.24E-14 | 14 | passed |
/stages/0/components/ms_within | tolerance | 0.32582333333333363 | 0.32582333333333363 | 1.23E-18 | 17 | passed |
/stages/0/components/n0 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/stages/0/components/between_sigma | tolerance | 1.2216859934805946 | 1.2216859934805944 | 2.32E-16 | 15 | passed |
/stages/0/components/within_component_sigma | tolerance | 0.57080936689347839 | 0.5708093668934784 | 2.92E-18 | 17 | passed |
/stages/0/components/total_sigma | tolerance | 1.3484583790388196 | 1.3484583790388194 | 2.23E-16 | 15 | passed |
/moving_range/points/0/upper | tolerance | 6.8237851793938891 | 6.823785179393895 | 6.18E-15 | 15 | passed |
/stages/1/subgroups | exact | 3 | 3 | 0.00E+2 | passed | |
/stages/1/observations | exact | 15 | 15 | 0.00E+2 | passed | |
/stages/1/grand_mean | tolerance | 10.932666666666666 | 10.932666666666668 | 1.87E-15 | 15 | passed |
/stages/1/subgroup_mean_center | tolerance | 10.932666666666666 | 10.932666666666668 | 1.87E-15 | 15 | passed |
/stages/1/mean_moving_range | tolerance | 2.2939999999999996 | 2.2940000000000014 | 1.77E-15 | 15 | passed |
/stages/1/i_chart_scale | tolerance | 2.0330045669886267 | 2.033004566988628 | 1.38E-15 | 15 | passed |
/stages/1/within_sigma | tolerance | 0.51448977754266478 | 0.5144897775426652 | 4.48E-16 | 15 | passed |
/individuals/points/3/center | tolerance | 10.932666666666666 | 10.932666666666668 | 1.87E-15 | 15 | passed |
/individuals/points/3/upper | tolerance | 17.031680367632546 | 17.031680367632553 | 7.44E-15 | 15 | passed |
/individuals/points/3/lower | tolerance | 4.8336529657007867 | 4.833652965700783 | 3.52E-15 | 15 | passed |
/individuals/points/3/value | tolerance | 10.92 | 10.92 | 7.11E-17 | 17 | passed |
/within/points/3/center | tolerance | 1.1966666666666665 | 1.1966666666666657 | 8.43E-16 | 15 | passed |
/within/points/3/upper | tolerance | 2.5303506436314014 | 2.5303506436314107 | 9.31E-15 | 14 | passed |
/within/points/3/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/stages/1/components/df_between | exact | 2 | 2 | 0.00E+2 | passed | |
/stages/1/components/df_within | exact | 12 | 12 | 0.00E+2 | passed | |
/stages/1/components/ms_between | tolerance | 11.598246666666663 | 11.598246666666675 | 1.23E-14 | 14 | passed |
/stages/1/components/ms_within | tolerance | 0.22436666666666674 | 0.22436666666666683 | 8.52E-17 | 15 | passed |
/stages/1/components/n0 | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/stages/1/components/between_sigma | tolerance | 1.5082360557949803 | 1.508236055794981 | 6.90E-16 | 15 | passed |
/stages/1/components/within_component_sigma | tolerance | 0.4736735866255018 | 0.47367358662550185 | 5.23E-17 | 15 | passed |
/stages/1/components/total_sigma | tolerance | 1.5808676942320841 | 1.5808676942320845 | 4.08E-16 | 15 | passed |
/moving_range/points/2/upper | tolerance | 7.4934242228480503 | 7.493424222848056 | 5.35E-15 | 15 | passed |
Convention
- docs/manual/chapters/84-subgroup-monitoring.tex:19-26: I chart of subgroup means around their unweighted mean with limits c +/- 3 MR-bar/d2(2); MR upper limit D4(2) MR-bar; R or S chart uses the mean of R_i/d2(n_i) or s_i/c4(n_i) with limits that change with n_i.
- docs/manual/chapters/84-subgroup-monitoring.tex:46-57: between, within and total SDs from the constrained random-intercept REML fit; for balanced groups with a positive between component sigma_u^2 = (MS_B - MS_W)/n and sigma_e^2 = MS_W.
- d2(n), d3(n) by stats::integrate at full precision and c4(n) by lgamma; D4(2) = 1 + 3 d3(2)/d2(2).
- Consecutive rows of five form subgroups 1-6; stage A holds subgroups 1-3 and stage B 4-6; every stage estimates its own centre, scales and components (chapter 84 line 35: stage boundaries restart the calculations).
- Both stages are balanced with positive between components (checked), so the ANOVA closed form is the REML solution.
- Expected computed from the re-read QUAL_BW_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
215 emit("STAT-QUAL-BETWEEN-WITHIN-003", bw_ep, bw_menu, "Between/within chart with consecutive subgroups of five and two stages", "QUAL_BW_01",
216 list(response = "value", subgroup_mode = "size", subgroup_size = 5L, stage_column = "stage", dispersion = "range"), out,
217 c(bw_notes, "Consecutive rows of five form subgroups 1-6; stage A holds subgroups 1-3 and stage B 4-6; every stage estimates its own centre, scales and components (chapter 84 line 35: stage boundaries restart the calculations).",
218 "Both stages are balanced with positive between components (checked), so the ANOVA closed form is the REML solution."),
219 bw_source, bw_cite, bw_req, kind = "axis_coverage")
Between/within chart with unequal lot sizes and an excluded row
Case STAT-QUAL-BETWEEN-WITHIN-004 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas with stats::integrate constants; nlme::lme REML components
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 (I-MR, R and S chart constants); Pinheiro & Bates (2000) nlme; R stats::integrate
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_BW_01.json
Settings compared
dispersion= "range"response= "value"subgroup_column= "lot"subgroup_mode= "column"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stages/0/subgroups | exact | 6 | 6 | 0.00E+2 | passed | |
/stages/0/observations | exact | 29 | 29 | 0.00E+2 | passed | |
/stages/0/grand_mean | tolerance | 10.748275862068965 | 10.748275862068965 | 1.25E-16 | 16 | passed |
/stages/0/subgroup_mean_center | tolerance | 10.821222222222222 | 10.821222222222223 | 1.41E-15 | 15 | passed |
/stages/0/mean_moving_range | tolerance | 1.8062333333333336 | 1.8062333333333342 | 6.46E-16 | 15 | passed |
/stages/0/i_chart_scale | tolerance | 1.6007326136502869 | 1.6007326136502875 | 6.17E-16 | 15 | passed |
/stages/0/within_sigma | tolerance | 0.79443875250755802 | 0.7944387525075592 | 1.22E-15 | 14 | passed |
/individuals/points/0/center | tolerance | 10.821222222222222 | 10.821222222222223 | 1.41E-15 | 15 | passed |
/individuals/points/0/upper | tolerance | 15.623420063173082 | 15.623420063173086 | 3.74E-15 | 15 | passed |
/individuals/points/0/lower | tolerance | 6.0190243812713611 | 6.019024381271361 | 2.06E-17 | 17 | passed |
/individuals/points/0/value | tolerance | 10.122499999999999 | 10.122499999999999 | 2.79E-16 | 16 | passed |
/within/points/0/center | tolerance | 1.6355513743825429 | 1.6355513743825434 | 4.88E-16 | 15 | passed |
/within/points/0/upper | tolerance | 3.7324125676771112 | 3.7324125676771245 | 1.33E-14 | 14 | passed |
/within/points/0/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/stages/0/components/df_between | exact | 5 | 5 | 0.00E+2 | passed | |
/stages/0/components/df_within | exact | 23 | 23 | 0.00E+2 | passed | |
/stages/0/components/ms_between | tolerance | 5.9406420919540244 | 5.940642091954031 | 6.19E-15 | 14 | passed |
/stages/0/components/ms_within | tolerance | 0.69293927536231925 | 0.6929392753623198 | 5.56E-16 | 15 | passed |
/stages/0/components/n0 | tolerance | 4.8137931034482762 | 4.813793103448276 | 4.39E-17 | 17 | passed |
/stages/0/components/between_sigma | tolerance | 1.0679649806992737 | 1.0679649807762444 | 7.70E-11 | 10 | passed |
/stages/0/components/within_component_sigma | tolerance | 0.83301224480796199 | 0.8330122299191233 | 1.49E-8 | 7 | passed |
/stages/0/components/total_sigma | tolerance | 1.3544218692859327 | 1.3544218601895182 | 9.10E-9 | 8 | passed |
/within/points/5/upper | tolerance | 4.0345824515358633 | 4.034582451535878 | 1.51E-14 | 14 | passed |
/within/points/5/center | tolerance | 2.0134356805876403 | 2.0134356805876403 | 3.07E-17 | 16 | passed |
/within/points/5/lower | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/subgroups/2/size | exact | 5 | 5 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/stages/0/subgroup_size_min | exact | 4 | 4 | 0.00E+2 | passed | |
/stages/0/subgroup_size_max | exact | 6 | 6 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/84-subgroup-monitoring.tex:19-26: I chart of subgroup means around their unweighted mean with limits c +/- 3 MR-bar/d2(2); MR upper limit D4(2) MR-bar; R or S chart uses the mean of R_i/d2(n_i) or s_i/c4(n_i) with limits that change with n_i.
- docs/manual/chapters/84-subgroup-monitoring.tex:46-57: between, within and total SDs from the constrained random-intercept REML fit; for balanced groups with a positive between component sigma_u^2 = (MS_B - MS_W)/n and sigma_e^2 = MS_W.
- d2(n), d3(n) by stats::integrate at full precision and c4(n) by lgamma; D4(2) = 1 + 3 d3(2)/d2(2).
- Unequal sizes 4-6: within sigma averages R_i/d2(n_i) and the R-chart limits change with n_i (chapter 84 lines 25-26, 31-33).
- Unbalanced components come from nlme::lme(value ~ 1, random = ~1 | lot, method = 'REML'); tolerance 1e-5 on the component SDs because both programs stop at a numerical REML optimum. MS between/within and n0 are the descriptive ANOVA quantities.
- Row index 10 (0-based) is excluded, so lot L3 has five values; the I chart is centred at the unweighted mean of the six lot means.
- Expected computed from the re-read QUAL_BW_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
223 keep <- rep(TRUE, nrow(d)); keep[11] <- FALSE # 0-based row 10 (lot L3) excluded
224 groups4 <- groups_of(d$value[keep], d$lot[keep])
225 s4 <- bw_stage(groups4, "range")
226 lme4 <- nlme::lme(value ~ 1, random = ~ 1 | lot, data = data.frame(value = d$value[keep], lot = factor(d$lot[keep], levels = unique(d$lot))),
227 method = "REML", control = nlme::lmeControl(tolerance = 1e-10, msTol = 1e-12, niterEM = 100, msMaxIter = 500, opt = "optim"))
228 vc4 <- nlme::VarCorr(lme4)
229 comp4 <- anova_components(groups4)
230 comp4$between <- as.numeric(vc4[1, 1]); comp4$within <- as.numeric(vc4[2, 1])
231 out <- stage_outputs(s4, 0L, "range", 0L, comp4, "1e-5")
232 wl6 <- w_limits(6, s4$within, "range")
233 out <- c(out, list("/within/points/5/upper" = num(wl6[["upper"]], "(d2(6) + 3 d3(6)) sigma_w for the six-value lot."),
234 "/within/points/5/center" = num(wl6[["center"]], "d2(6) sigma_w."),
235 "/within/points/5/lower" = num(wl6[["lower"]], "max(0, d2(6) - 3 d3(6)) sigma_w = 0 for n = 6."),
236 "/subgroups/2/size" = exact(5L, "Lot L3 keeps five values after the exclusion."),
237 "/excluded_count" = exact(1L, "One excluded row."), "/source_count" = exact(30L, "Rows in the table."),
238 "/stages/0/subgroup_size_min" = exact(4L, "Smallest lot."), "/stages/0/subgroup_size_max" = exact(6L, "Largest lot.")))
239 emit("STAT-QUAL-BETWEEN-WITHIN-004", bw_ep, bw_menu, "Between/within chart with unequal lot sizes and an excluded row", "QUAL_BW_01",
240 list(response = "value", subgroup_mode = "column", subgroup_column = "lot", dispersion = "range"), out,
241 c(bw_notes, "Unequal sizes 4-6: within sigma averages R_i/d2(n_i) and the R-chart limits change with n_i (chapter 84 lines 25-26, 31-33).",
242 "Unbalanced components come from nlme::lme(value ~ 1, random = ~1 | lot, method = 'REML'); tolerance 1e-5 on the component SDs because both programs stop at a numerical REML optimum. MS between/within and n0 are the descriptive ANOVA quantities.",
243 "Row index 10 (0-based) is excluded, so lot L3 has five values; the I chart is centred at the unweighted mean of the six lot means."),
244 bw_source, bw_cite, bw_req, kind = "axis_coverage", excluded = 10L)
Bissell Table 3/4 capability: overall sigma
Case STAT-QUAL-BISSELL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R recomputation from Bissell (1990), Table 3
- Citation
- Bissell (1990), How Reliable is Your Capability Index?, Applied Statistics 39(3), 331-340, Tables 3-4, pp. 338-339
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_bissell_capability.R · sha256 6c6439542e744990
- Dataset
- reference_data/datasets/QUAL_BISSELL_TABLE3.json
Settings compared
limits= {"value": [5.49, 5.79]}method= "normal"study= {"subgroup_mode": "individuals", "within_method": "moving_range", "require_stability": false, "require_msa": false}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows/0/n | exact | 75 | 75 | 0.00E+2 | passed | |
/rows/0/mean | tolerance | 5.6135999999999999 | 5.613600000000001 | 9.11E-16 | 15 | passed |
/rows/0/std | tolerance | 0.048313167585681716 | 0.048313167585681716 | 4.57E-19 | 17 | passed |
/rows/0/ppk | tolerance | 0.85276958764778032 | 0.8527695876477864 | 6.11E-15 | 14 | passed |
/rows/0/ppk_ci_lower | tolerance | 0.69603246876381042 | 0.6960324687638156 | 5.22E-15 | 14 | passed |
/rows/0/ppk_ci_upper | tolerance | 1.0095067065317502 | 1.0095067065317571 | 6.91E-15 | 14 | passed |
/rows/0/uncertainty_method | contains | ['Ppk nu=N-1'] | two-sided 0.95 large-sample normal-index approximation, SE = | passed |
Convention
- Table 4 printed effective f 74 Cpk 0.853 and SE 0.08 with +/-2 SE limits 0.693 to 1.013 ; independently computed effective nu 74 and full-precision SE 0.079969387254200761 .
- The paper calls the overall-s index Cpk; Tabelz calls the same estimator Ppk.
- The paper's +/-2 SE limits are not asserted against Tabelz's z=1.95996 intervals.
- The pooled printed SE .086 is discrepant with .0868 from the stated formula and f=60; no rounding equivalence is claimed.
Reference code
Bissell Table 3/4 capability: range sigma
Case STAT-QUAL-BISSELL-002 · status: passed
Reference
- Evidence type
- R
- Source
- R recomputation from Bissell (1990), Table 3
- Citation
- Bissell (1990), How Reliable is Your Capability Index?, Applied Statistics 39(3), 331-340, Tables 3-4, pp. 338-339
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_bissell_capability.R · sha256 6c6439542e744990
- Dataset
- reference_data/datasets/QUAL_BISSELL_TABLE3.json
Settings compared
limits= {"value": [5.49, 5.79]}method= "normal"study= {"subgroup_mode": "constant", "subgroup_size": 5, "within_method": "range", "require_stability": false, "require_msa": false}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows/0/n | exact | 75 | 75 | 0.00E+2 | passed | |
/rows/0/mean | tolerance | 5.6135999999999999 | 5.613600000000001 | 9.11E-16 | 15 | passed |
/rows/0/std | tolerance | 0.048313167585681716 | 0.048313167585681716 | 4.57E-19 | 17 | passed |
/rows/0/ppk | tolerance | 0.85276958764778032 | 0.8527695876477864 | 6.11E-15 | 14 | passed |
/rows/0/ppk_ci_lower | tolerance | 0.69603246876381042 | 0.6960324687638156 | 5.22E-15 | 14 | passed |
/rows/0/ppk_ci_upper | tolerance | 1.0095067065317502 | 1.0095067065317571 | 6.91E-15 | 14 | passed |
/rows/0/uncertainty_method | contains | ['Cpk nu=54.34308553', 'Ppk nu=N-1'] | two-sided 0.95 large-sample normal-index approximation, SE = | passed | ||
/rows/0/within_sigma | tolerance | 0.049585922849515948 | 0.049585922849516004 | 5.57E-17 | 14 | passed |
/rows/0/cpk | tolerance | 0.83088097654316617 | 0.8308809765431712 | 5.00E-15 | 14 | passed |
/rows/0/cpk_ci_lower | tolerance | 0.65741168539798289 | 0.6574116853979868 | 3.89E-15 | 14 | passed |
/rows/0/cpk_ci_upper | tolerance | 1.0043502676883496 | 1.0043502676883556 | 5.96E-15 | 14 | passed |
Convention
- Table 4 printed effective f 54 Cpk 0.831 and SE 0.089 with +/-2 SE limits 0.653 to 1.008 ; independently computed effective nu 54.343085531357779 and full-precision SE 0.088506366705453254 .
- The paper calls the overall-s index Cpk; Tabelz calls the same estimator Ppk.
- The paper's +/-2 SE limits are not asserted against Tabelz's z=1.95996 intervals.
- The pooled printed SE .086 is discrepant with .0868 from the stated formula and f=60; no rounding equivalence is claimed.
Reference code
Bissell Table 3/4 capability: stddev sigma
Case STAT-QUAL-BISSELL-003 · status: passed
Reference
- Evidence type
- R
- Source
- R recomputation from Bissell (1990), Table 3
- Citation
- Bissell (1990), How Reliable is Your Capability Index?, Applied Statistics 39(3), 331-340, Tables 3-4, pp. 338-339
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_bissell_capability.R · sha256 6c6439542e744990
- Dataset
- reference_data/datasets/QUAL_BISSELL_TABLE3.json
Settings compared
limits= {"value": [5.49, 5.79]}method= "normal"study= {"subgroup_mode": "constant", "subgroup_size": 5, "within_method": "stddev", "require_stability": false, "require_msa": false}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows/0/n | exact | 75 | 75 | 0.00E+2 | passed | |
/rows/0/mean | tolerance | 5.6135999999999999 | 5.613600000000001 | 9.11E-16 | 15 | passed |
/rows/0/std | tolerance | 0.048313167585681716 | 0.048313167585681716 | 4.57E-19 | 17 | passed |
/rows/0/ppk | tolerance | 0.85276958764778032 | 0.8527695876477864 | 6.11E-15 | 14 | passed |
/rows/0/ppk_ci_lower | tolerance | 0.69603246876381042 | 0.6960324687638156 | 5.22E-15 | 14 | passed |
/rows/0/ppk_ci_upper | tolerance | 1.0095067065317502 | 1.0095067065317571 | 6.91E-15 | 14 | passed |
/rows/0/uncertainty_method | contains | ['Cpk nu=56.91801074', 'Ppk nu=N-1'] | two-sided 0.95 large-sample normal-index approximation, SE = | passed | ||
/rows/0/within_sigma | tolerance | 0.04955899787629961 | 0.0495589978762996 | 7.21E-18 | 15 | passed |
/rows/0/cpk | tolerance | 0.83133238696303025 | 0.8313323869630365 | 6.21E-15 | 14 | passed |
/rows/0/cpk_ci_lower | tolerance | 0.66100019824176215 | 0.6610001982417675 | 5.33E-15 | 14 | passed |
/rows/0/cpk_ci_upper | tolerance | 1.0016645756842983 | 1.0016645756843054 | 7.15E-15 | 14 | passed |
Convention
- Table 4 printed effective f 57 Cpk 0.831 and SE 0.087 with +/-2 SE limits 0.657 to 1.005 ; independently computed effective nu 56.918010744528516 and full-precision SE 0.086905774833020782 .
- The paper calls the overall-s index Cpk; Tabelz calls the same estimator Ppk.
- The paper's +/-2 SE limits are not asserted against Tabelz's z=1.95996 intervals.
- The pooled printed SE .086 is discrepant with .0868 from the stated formula and f=60; no rounding equivalence is claimed.
Reference code
Bissell Table 3/4 capability: pooled sigma
Case STAT-QUAL-BISSELL-004 · status: passed
Reference
- Evidence type
- R
- Source
- R recomputation from Bissell (1990), Table 3
- Citation
- Bissell (1990), How Reliable is Your Capability Index?, Applied Statistics 39(3), 331-340, Tables 3-4, pp. 338-339
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_bissell_capability.R · sha256 6c6439542e744990
- Dataset
- reference_data/datasets/QUAL_BISSELL_TABLE3.json
Settings compared
limits= {"value": [5.49, 5.79]}method= "normal"study= {"subgroup_mode": "constant", "subgroup_size": 5, "within_method": "pooled", "require_stability": false, "require_msa": false}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows/0/n | exact | 75 | 75 | 0.00E+2 | passed | |
/rows/0/mean | tolerance | 5.6135999999999999 | 5.613600000000001 | 9.11E-16 | 15 | passed |
/rows/0/std | tolerance | 0.048313167585681716 | 0.048313167585681716 | 4.57E-19 | 17 | passed |
/rows/0/ppk | tolerance | 0.85276958764778032 | 0.8527695876477864 | 6.11E-15 | 14 | passed |
/rows/0/ppk_ci_lower | tolerance | 0.69603246876381042 | 0.6960324687638156 | 5.22E-15 | 14 | passed |
/rows/0/ppk_ci_upper | tolerance | 1.0095067065317502 | 1.0095067065317571 | 6.91E-15 | 14 | passed |
/rows/0/uncertainty_method | contains | ['Cpk nu=60', 'Ppk nu=N-1'] | two-sided 0.95 large-sample normal-index approximation, SE = | passed | ||
/rows/0/within_sigma | tolerance | 0.048339080118126682 | 0.04833908011812668 | 4.04E-19 | 17 | passed |
/rows/0/cpk | tolerance | 0.85231245400862121 | 0.8523124540086273 | 6.11E-15 | 14 | passed |
/rows/0/cpk_ci_lower | tolerance | 0.68217765482606652 | 0.6821776548260716 | 5.10E-15 | 14 | passed |
/rows/0/cpk_ci_upper | tolerance | 1.0224472531911759 | 1.022447253191183 | 7.11E-15 | 14 | passed |
Convention
- Table 4 printed effective f 60 Cpk 0.853 and SE 0.086 with +/-2 SE limits 0.679 to 1.027 ; independently computed effective nu 60 and full-precision SE 0.086805064034113047 .
- The paper calls the overall-s index Cpk; Tabelz calls the same estimator Ppk.
- The paper's +/-2 SE limits are not asserted against Tabelz's z=1.95996 intervals.
- The pooled printed SE .086 is discrepant with .0868 from the stated formula and f=60; no rounding equivalence is claimed.
Reference code
Normal capability with individual observations
Case STAT-QUAL-CAPABILITY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats and manual formulas
- Citation
- R stats::mean and stats::sd documentation; Tabelz manual chapter 08, Capability continuous data
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_normal_capability.R · sha256 eb3f29c277d1830a
- Dataset
- reference_data/datasets/QUAL_CAPABILITY_NORMAL_01.json
Settings compared
limits= {"value": [8.7, 11.3]}method= "normal"study= {"subgroup_mode": "individuals", "within_method": "moving_range", "require_stability": false, "require_msa": false}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows/0/n | exact | 30 | 30 | 0.00E+2 | passed | |
/rows/0/mean | tolerance | 9.988812735912834 | 9.988812735912836 | 1.81E-15 | 15 | passed |
/rows/0/std | tolerance | 0.34664816202205612 | 0.3466481620220561 | 3.38E-18 | 17 | passed |
/rows/0/within_sigma | tolerance | 0.20383390869609133 | 0.20383390869609133 | 1.56E-18 | 17 | passed |
/rows/0/cp | tolerance | 2.1259138683319723 | 2.1259138683319723 | 3.26E-17 | 16 | passed |
/rows/0/cpk | tolerance | 2.1076191299692044 | 2.107619129969207 | 2.68E-15 | 14 | passed |
/rows/0/pp | tolerance | 1.2500667270399719 | 1.250066727039972 | 3.32E-18 | 17 | passed |
/rows/0/ppk | tolerance | 1.2393091681153754 | 1.2393091681153772 | 1.77E-15 | 14 | passed |
/rows/0/oos | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Manual chapter 08: individuals use s_w=mean(abs(diff(x)))/d2 with d2=2/sqrt(pi) computed at full precision (about 1.128379167); the manual's 1.128 is a rounded display form. Overall s_o=sample SD.
- LSL=8.7 and USL=11.3 are response units. Cp and Cpk use s_w; Pp and Ppk use s_o.
- Rows are production-ordered as exported; R re-reads the CSV before every calculation.
Reference code
The lines of the reference script that produce this case's expected values.
11 index <- seq_len(30L)
12 raw <- data.frame(value = 10 + 0.41 * sin(index * 0.61) +
13 0.24 * cos(index * 1.19) + 0.07 * sin(index * 2.31))
14 export_dataset(raw, "QUAL_CAPABILITY_NORMAL_01", "Constructed ordered continuous measurements",
15 "R stats::mean and stats::sd documentation; manual chapter 08 capability formulas",
16 "Constructed validation data; no third-party license.", c(value = "Float64"))
17 d <- read_dataset("QUAL_CAPABILITY_NORMAL_01")
18 x <- d$value
19 lsl <- 8.7
20 usl <- 11.3
21 d2 <- 2 / sqrt(pi)
22 mu <- mean(x)
23 overall <- stats::sd(x)
24 mr_bar <- mean(abs(diff(x)))
25 within <- mr_bar / d2
26 cp <- (usl - lsl) / (6 * within)
27 cpk <- min((mu - lsl) / (3 * within), (usl - mu) / (3 * within))
28 pp <- (usl - lsl) / (6 * overall)
29 ppk <- min((mu - lsl) / (3 * overall), (usl - mu) / (3 * overall))
30 id <- "STAT-QUAL-CAPABILITY-001"
Compare capability of two production lines
Case STAT-QUAL-CAPABILITY-COMPARISON-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded manual capability formulas with stats::pnorm, qnorm, shapiro.test and stats::integrate constants
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 8 (Cp, Cpk, Pp, Ppk); NIST Dataplot Cpm; Royston (1995) shapiro.test; R stats documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_SIXPACK_01.json
Settings compared
column= "value"confidence_level= 0.95lsl= 8.8method= "normal"split_column= "line"split_kind= "group"subgroup_mode= "individuals"target= 10usl= 11.2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/populations/0/population | exact | A | A | passed | ||
/populations/0/rows | exact | 20 | 20 | 0.00E+2 | passed | |
/populations/0/excluded | exact | 0 | 0 | 0.00E+2 | passed | |
/populations/0/capability/n | exact | 20 | 20 | 0.00E+2 | passed | |
/populations/0/capability/mean | tolerance | 9.9193499999999997 | 9.919349999999998 | 1.81E-15 | 15 | passed |
/populations/0/capability/std | tolerance | 0.23335229183632006 | 0.23335229183631984 | 2.24E-16 | 15 | passed |
/populations/0/capability/within_sigma | tolerance | 0.24753717333567302 | 0.2475371733356729 | 1.15E-16 | 15 | passed |
/populations/0/capability/cp | tolerance | 1.6159189127427718 | 1.6159189127427724 | 6.40E-16 | 15 | passed |
/populations/0/capability/cpk | tolerance | 1.5073156958155174 | 1.5073156958155158 | 1.57E-15 | 14 | passed |
/populations/0/capability/pp | tolerance | 1.7141464386412417 | 1.7141464386412433 | 1.58E-15 | 15 | passed |
/populations/0/capability/ppk | tolerance | 1.5989415134108944 | 1.5989415134108933 | 1.10E-15 | 15 | passed |
/populations/0/capability/cpm | tolerance | 1.6201142919055069 | 1.6201142919055045 | 2.41E-15 | 14 | passed |
/populations/0/capability/cpk_ci_lower | tolerance | 0.87898856621160859 | 0.8789885662116077 | 8.87E-16 | 14 | passed |
/populations/0/capability/cpk_ci_upper | tolerance | 2.135642825419426 | 2.135642825419424 | 1.82E-15 | 15 | passed |
/populations/0/capability/ppk_ci_lower | tolerance | 1.0699876824640664 | 1.0699876824640657 | 6.74E-16 | 15 | passed |
/populations/0/capability/ppk_ci_upper | tolerance | 2.1278953443577224 | 2.1278953443577207 | 1.75E-15 | 15 | passed |
/populations/0/capability/dpmo | tolerance | 0.82632271251330558 | 0.8263227124216677 | 9.16E-11 | 9 | passed |
/populations/0/capability/within_ppm | tolerance | 3.178502647839462 | 3.178502647839532 | 7.02E-14 | 13 | passed |
/populations/0/capability/normality_p | tail_probability | 0.44146503601837705 | 0.4414650360183859 | 8.83E-15 | 13 | passed |
/populations/0/capability/oos | exact | 0 | 0 | 0.00E+2 | passed | |
/populations/1/population | exact | B | B | passed | ||
/populations/1/rows | exact | 20 | 20 | 0.00E+2 | passed | |
/populations/1/excluded | exact | 0 | 0 | 0.00E+2 | passed | |
/populations/1/capability/n | exact | 20 | 20 | 0.00E+2 | passed | |
/populations/1/capability/mean | tolerance | 10.240600000000001 | 10.2406 | 4.09E-16 | 16 | passed |
/populations/1/capability/std | tolerance | 0.23436485276279459 | 0.23436485276279453 | 5.56E-17 | 15 | passed |
/populations/1/capability/within_sigma | tolerance | 0.27006599465113007 | 0.27006599465113007 | 1.92E-19 | 18 | passed |
/populations/1/capability/cp | tolerance | 1.4811194593999806 | 1.4811194593999806 | 2.42E-17 | 16 | passed |
/populations/1/capability/cpk | tolerance | 1.1841550077902836 | 1.1841550077902836 | 1.99E-18 | 17 | passed |
/populations/1/capability/pp | tolerance | 1.7067405597922478 | 1.706740559792248 | 2.35E-16 | 15 | passed |
/populations/1/capability/ppk | tolerance | 1.364539077553901 | 1.3645390775539012 | 2.47E-16 | 15 | passed |
/populations/1/capability/cpm | tolerance | 1.1909021995984916 | 1.1909021995984919 | 2.62E-16 | 15 | passed |
/populations/1/capability/cpk_ci_lower | tolerance | 0.682330525559669 | 0.682330525559669 | 1.12E-18 | 17 | passed |
/populations/1/capability/cpk_ci_upper | tolerance | 1.6859794900208982 | 1.6859794900208982 | 2.86E-18 | 17 | passed |
/populations/1/capability/ppk_ci_lower | tolerance | 0.90675138286918311 | 0.9067513828691832 | 1.10E-16 | 15 | passed |
/populations/1/capability/ppk_ci_upper | tolerance | 1.8223267722386189 | 1.8223267722386192 | 2.64E-16 | 15 | passed |
/populations/1/capability/dpmo | tolerance | 21.235154872115928 | 21.235154872178974 | 6.30E-11 | 11 | passed |
/populations/1/capability/within_ppm | tolerance | 190.86784552668396 | 190.86784552668368 | 2.79E-13 | 14 | passed |
/populations/1/capability/normality_p | tail_probability | 0.41704896729029367 | 0.4170489672902993 | 5.61E-15 | 13 | passed |
/populations/1/capability/oos | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/08-specifications-and-capability.tex:146-160: within sigma s_w = MR-bar/d2 for ordered individuals (d2 = 2/sqrt(pi) at full precision); with rational subgroups ranges are divided by their own d2(n_i) and averaged; overall s_o is the sample SD.
- docs/manual/chapters/08-specifications-and-capability.tex:268-290: index intervals use SE = sqrt(C^2/(2 nu) + 1/(9 N)) with z_(1 - alpha/2); nu for MR-bar/d2 from A = pi/2 - 1, B = sqrt(3)/2 + pi/12 - 1, v = (mA + 2(m - 1)B)/m^2; for averaged R_i/d2(n_i), v = g^-2 sum (d3/d2)^2; Ppk uses nu = N - 1.
- docs/manual/chapters/85-capability-views.tex:12-17: normal overall spread is mean +/- 3 overall SD and within spread uses within sigma.
- docs/manual/chapters/85-capability-views.tex:19-32: Cpm = (USL - LSL)/(6 sqrt(s^2 + (xbar - T)^2)) with the overall sample SD; normal within PPM is a model projection using within sigma.
- Overall predicted PPM = 1e6 [Phi((LSL - mean)/s_o) + Phi((mean - USL)/s_o)]; within PPM uses s_w; normality check is Shapiro-Wilk (stats::shapiro.test).
- docs/manual/chapters/85-capability-views.tex:34-37: each population gets the identical computation with the same specifications, model and subgrouping; populations are the sorted levels of the grouping column.
- Each line is analysed as ordered individuals within the line: s_w = MR-bar/d2(2) over that line's 20 values.
- Expected computed from the re-read QUAL_SIXPACK_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
495 cmp_ep <- "tabelz.analysis.capability_sixpack:compute_capability_comparison" 496 cmp_req <- "REQ-STAT-QUAL-CAPABILITY-COMPARISON-001"
Compare capability before and after a split point with subgroups of five
Case STAT-QUAL-CAPABILITY-COMPARISON-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded manual capability formulas with stats::pnorm, qnorm, shapiro.test and stats::integrate constants
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 8 (Cp, Cpk, Pp, Ppk); NIST Dataplot Cpm; Royston (1995) shapiro.test; R stats documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_SIXPACK_01.json
Settings compared
column= "value"confidence_level= 0.95lsl= 8.8method= "normal"split_column= "index"split_kind= "point"split_value= 21subgroup_mode= "constant"subgroup_size= 5usl= 11.2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/populations/0/population | exact | before 21 | before 21 | passed | ||
/populations/0/rows | exact | 20 | 20 | 0.00E+2 | passed | |
/populations/0/capability/n | exact | 20 | 20 | 0.00E+2 | passed | |
/populations/0/capability/mean | tolerance | 9.9193499999999997 | 9.919349999999998 | 1.81E-15 | 15 | passed |
/populations/0/capability/std | tolerance | 0.23335229183632006 | 0.23335229183631984 | 2.24E-16 | 15 | passed |
/populations/0/capability/within_sigma | tolerance | 0.23925924334470156 | 0.23925924334470172 | 1.62E-16 | 15 | passed |
/populations/0/capability/cp | tolerance | 1.6718267365901451 | 1.6718267365901438 | 1.30E-15 | 15 | passed |
/populations/0/capability/cpk | tolerance | 1.5594660480018152 | 1.5594660480018117 | 3.54E-15 | 14 | passed |
/populations/0/capability/pp | tolerance | 1.7141464386412417 | 1.7141464386412433 | 1.58E-15 | 15 | passed |
/populations/0/capability/ppk | tolerance | 1.5989415134108944 | 1.5989415134108933 | 1.10E-15 | 15 | passed |
/populations/0/capability/cpm | absent | None | passed | |||
/populations/0/capability/cpk_ci_lower | tolerance | 0.97322837033243825 | 0.9732283703324313 | 6.99E-15 | 14 | passed |
/populations/0/capability/cpk_ci_upper | tolerance | 2.1457037256711922 | 2.145703725671192 | 3.64E-17 | 16 | passed |
/populations/0/capability/ppk_ci_lower | tolerance | 1.0699876824640664 | 1.0699876824640657 | 6.74E-16 | 15 | passed |
/populations/0/capability/ppk_ci_upper | tolerance | 2.1278953443577224 | 2.1278953443577207 | 1.75E-15 | 15 | passed |
/populations/0/capability/dpmo | tolerance | 0.82632271251330558 | 0.8263227124216677 | 9.16E-11 | 9 | passed |
/populations/0/capability/within_ppm | tolerance | 1.4889823738986609 | 1.4889823738987311 | 7.02E-14 | 13 | passed |
/populations/0/capability/normality_p | tail_probability | 0.44146503601837705 | 0.4414650360183859 | 8.83E-15 | 13 | passed |
/populations/0/capability/oos | exact | 0 | 0 | 0.00E+2 | passed | |
/populations/0/capability/subgroup_count | exact | 4 | 4 | 0.00E+2 | passed | |
/populations/1/population | exact | from 21 | from 21 | passed | ||
/populations/1/rows | exact | 20 | 20 | 0.00E+2 | passed | |
/populations/1/capability/n | exact | 20 | 20 | 0.00E+2 | passed | |
/populations/1/capability/mean | tolerance | 10.240600000000001 | 10.2406 | 4.09E-16 | 16 | passed |
/populations/1/capability/std | tolerance | 0.23436485276279459 | 0.23436485276279453 | 5.56E-17 | 15 | passed |
/populations/1/capability/within_sigma | tolerance | 0.23936672728151442 | 0.23936672728151498 | 5.59E-16 | 14 | passed |
/populations/1/capability/cp | tolerance | 1.671076028580897 | 1.671076028580893 | 4.01E-15 | 14 | passed |
/populations/1/capability/cpk | tolerance | 1.3360252848504262 | 1.336025284850423 | 3.16E-15 | 14 | passed |
/populations/1/capability/pp | tolerance | 1.7067405597922478 | 1.706740559792248 | 2.35E-16 | 15 | passed |
/populations/1/capability/ppk | tolerance | 1.364539077553901 | 1.3645390775539012 | 2.47E-16 | 15 | passed |
/populations/1/capability/cpm | absent | None | passed | |||
/populations/1/capability/cpk_ci_lower | tolerance | 0.828163214265073 | 0.828163214265067 | 6.00E-15 | 14 | passed |
/populations/1/capability/cpk_ci_upper | tolerance | 1.8438873554357793 | 1.843887355435779 | 2.15E-16 | 15 | passed |
/populations/1/capability/ppk_ci_lower | tolerance | 0.90675138286918311 | 0.9067513828691832 | 1.10E-16 | 15 | passed |
/populations/1/capability/ppk_ci_upper | tolerance | 1.8223267722386189 | 1.8223267722386192 | 2.64E-16 | 15 | passed |
/populations/1/capability/dpmo | tolerance | 21.235154872115928 | 21.235154872178974 | 6.30E-11 | 11 | passed |
/populations/1/capability/within_ppm | tolerance | 30.608610916307576 | 30.608610916308834 | 1.26E-12 | 13 | passed |
/populations/1/capability/normality_p | tail_probability | 0.41704896729029367 | 0.4170489672902993 | 5.61E-15 | 13 | passed |
/populations/1/capability/oos | exact | 0 | 0 | 0.00E+2 | passed | |
/populations/1/capability/subgroup_count | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/08-specifications-and-capability.tex:146-160: within sigma s_w = MR-bar/d2 for ordered individuals (d2 = 2/sqrt(pi) at full precision); with rational subgroups ranges are divided by their own d2(n_i) and averaged; overall s_o is the sample SD.
- docs/manual/chapters/08-specifications-and-capability.tex:268-290: index intervals use SE = sqrt(C^2/(2 nu) + 1/(9 N)) with z_(1 - alpha/2); nu for MR-bar/d2 from A = pi/2 - 1, B = sqrt(3)/2 + pi/12 - 1, v = (mA + 2(m - 1)B)/m^2; for averaged R_i/d2(n_i), v = g^-2 sum (d3/d2)^2; Ppk uses nu = N - 1.
- docs/manual/chapters/85-capability-views.tex:12-17: normal overall spread is mean +/- 3 overall SD and within spread uses within sigma.
- docs/manual/chapters/85-capability-views.tex:19-32: Cpm = (USL - LSL)/(6 sqrt(s^2 + (xbar - T)^2)) with the overall sample SD; normal within PPM is a model projection using within sigma.
- Overall predicted PPM = 1e6 [Phi((LSL - mean)/s_o) + Phi((mean - USL)/s_o)]; within PPM uses s_w; normality check is Shapiro-Wilk (stats::shapiro.test).
- docs/manual/chapters/85-capability-views.tex:34-37: populations before and from the declared split point 21 on the index column; no target so Cpm is unavailable.
- Within each population consecutive rows of five form subgroups: s_w = mean(R_i/d2(5)).
- Expected computed from the re-read QUAL_SIXPACK_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
524 emit("STAT-QUAL-CAPABILITY-COMPARISON-002", cmp_ep, "capabilityComparisonMenuItem", "Compare capability before and after a split point with subgroups of five", "QUAL_SIXPACK_01",
525 list(column = "value", lsl = lsl, usl = usl, split_kind = "point", split_column = "index", split_value = 21, method = "normal", subgroup_mode = "constant", subgroup_size = 5L, confidence_level = 0.95),
526 out, c(cap_notes, "docs/manual/chapters/85-capability-views.tex:34-37: populations before and from the declared split point 21 on the index column; no target so Cpm is unavailable.",
527 "Within each population consecutive rows of five form subgroups: s_w = mean(R_i/d2(5))."),
528 cap_source, cap_cite, cmp_req, kind = "axis_coverage")
Capability of two characteristics with their own limits
Case STAT-QUAL-CAPABILITY-MULTIPLE-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded manual capability formulas with stats::pnorm, qnorm, shapiro.test and stats::integrate constants
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 8 (Cp, Cpk, Pp, Ppk); NIST Dataplot Cpm; Royston (1995) shapiro.test; R stats documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_SIXPACK_01.json
Settings compared
columns= ["value", "thickness"]confidence_level= 0.95lsls= ["8.8", "1.75"]method= "normal"subgroup_mode= "individuals"targets= ["10", ""]usls= ["11.2", "2.25"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows/0/n | exact | 40 | 40 | 0.00E+2 | passed | |
/rows/0/mean | tolerance | 10.079974999999999 | 10.079975 | 2.41E-16 | 16 | passed |
/rows/0/std | tolerance | 0.28239992441162648 | 0.28239992441162637 | 1.12E-16 | 15 | passed |
/rows/0/within_sigma | tolerance | 0.25627864782708221 | 0.2562786478270822 | 3.41E-18 | 16 | passed |
/rows/0/cp | tolerance | 1.560801117812554 | 1.560801117812554 | 3.97E-17 | 16 | passed |
/rows/0/cpk | tolerance | 1.4567802266483389 | 1.456780226648339 | 4.95E-17 | 16 | passed |
/rows/0/pp | tolerance | 1.4164309740287298 | 1.4164309740287304 | 6.16E-16 | 15 | passed |
/rows/0/ppk | tolerance | 1.3220317514054409 | 1.3220317514054416 | 7.02E-16 | 15 | passed |
/rows/0/cpm | tolerance | 1.3628345778580169 | 1.3628345778580175 | 6.37E-16 | 15 | passed |
/rows/0/cpk_ci_lower | tolerance | 1.0300990292628287 | 1.0300990292628287 | 2.61E-18 | 17 | passed |
/rows/0/cpk_ci_upper | tolerance | 1.8834614240338492 | 1.8834614240338492 | 3.61E-18 | 17 | passed |
/rows/0/ppk_ci_lower | tolerance | 1.0109893622484478 | 1.0109893622484483 | 4.64E-16 | 15 | passed |
/rows/0/ppk_ci_upper | tolerance | 1.6330741405624341 | 1.633074140562435 | 8.39E-16 | 15 | passed |
/rows/0/dpmo | tolerance | 39.444450878714264 | 39.444450878667325 | 4.69E-11 | 11 | passed |
/rows/0/within_ppm | tolerance | 6.4976358253941982 | 6.49763582539419 | 8.04E-15 | 14 | passed |
/rows/0/normality_p | tail_probability | 0.82085801775841405 | 0.820858017758421 | 6.99E-15 | 14 | passed |
/rows/0/oos | exact | 0 | 0 | 0.00E+2 | passed | |
/rows/1/n | exact | 40 | 40 | 0.00E+2 | passed | |
/rows/1/mean | tolerance | 2.0171999999999999 | 2.0172 | 1.80E-17 | 17 | passed |
/rows/1/std | tolerance | 0.082934388648574581 | 0.08293438864857458 | 2.95E-19 | 17 | passed |
/rows/1/within_sigma | tolerance | 0.070398231155196014 | 0.07039823115519601 | 3.75E-19 | 17 | passed |
/rows/1/cp | tolerance | 1.1837418634797983 | 1.1837418634797983 | 3.81E-17 | 16 | passed |
/rows/1/cpk | tolerance | 1.1023004232723888 | 1.1023004232723888 | 4.81E-17 | 16 | passed |
/rows/1/pp | tolerance | 1.0048103650519356 | 1.0048103650519356 | 4.99E-17 | 16 | passed |
/rows/1/ppk | tolerance | 0.93567941193636295 | 0.935679411936363 | 1.95E-18 | 17 | passed |
/rows/1/cpm | absent | None | passed | |||
/rows/1/cpk_ci_lower | tolerance | 0.77245576968486018 | 0.7724557696848602 | 2.88E-18 | 17 | passed |
/rows/1/cpk_ci_upper | tolerance | 1.4321450768599173 | 1.4321450768599173 | 2.09E-17 | 16 | passed |
/rows/1/ppk_ci_lower | tolerance | 0.70375607791878148 | 0.7037560779187815 | 4.77E-18 | 17 | passed |
/rows/1/ppk_ci_upper | tolerance | 1.1676027459539444 | 1.1676027459539444 | 2.09E-17 | 16 | passed |
/rows/1/dpmo | tolerance | 3136.8521973066563 | 3136.852197306583 | 7.32E-11 | 13 | passed |
/rows/1/within_ppm | tolerance | 545.32894552608229 | 545.3289455260816 | 6.79E-13 | 14 | passed |
/rows/1/normality_p | tail_probability | 0.15343483684045106 | 0.15343483684045994 | 8.88E-15 | 13 | passed |
/rows/1/oos | exact | 1 | 1 | 0.00E+2 | passed | |
/rows/0/column | exact | value | value | passed | ||
/rows/1/column | exact | thickness | thickness | passed | ||
/rows/1/cpm_note | exact | Cpm needs both specification limits and a target. | Cpm needs both specification limits and a target. | passed |
Convention
- docs/manual/chapters/08-specifications-and-capability.tex:146-160: within sigma s_w = MR-bar/d2 for ordered individuals (d2 = 2/sqrt(pi) at full precision); with rational subgroups ranges are divided by their own d2(n_i) and averaged; overall s_o is the sample SD.
- docs/manual/chapters/08-specifications-and-capability.tex:268-290: index intervals use SE = sqrt(C^2/(2 nu) + 1/(9 N)) with z_(1 - alpha/2); nu for MR-bar/d2 from A = pi/2 - 1, B = sqrt(3)/2 + pi/12 - 1, v = (mA + 2(m - 1)B)/m^2; for averaged R_i/d2(n_i), v = g^-2 sum (d3/d2)^2; Ppk uses nu = N - 1.
- docs/manual/chapters/85-capability-views.tex:12-17: normal overall spread is mean +/- 3 overall SD and within spread uses within sigma.
- docs/manual/chapters/85-capability-views.tex:19-32: Cpm = (USL - LSL)/(6 sqrt(s^2 + (xbar - T)^2)) with the overall sample SD; normal within PPM is a model projection using within sigma.
- Overall predicted PPM = 1e6 [Phi((LSL - mean)/s_o) + Phi((mean - USL)/s_o)]; within PPM uses s_w; normality check is Shapiro-Wilk (stats::shapiro.test).
- docs/manual/chapters/85-capability-views.tex:39-44: the single-characteristic analysis is applied separately to each column with its own limits and target; nothing is pooled.
- Limits are entered as text; a blank target leaves Cpm unavailable.
- Expected computed from the re-read QUAL_SIXPACK_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
531 mul_ep <- "tabelz.analysis.capability_sixpack:compute_capability_multiple" 532 mul_req <- "REQ-STAT-QUAL-CAPABILITY-MULTIPLE-001"
Capability of two characteristics by lot with one-sided limits at 99% confidence
Case STAT-QUAL-CAPABILITY-MULTIPLE-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded manual capability formulas with stats::pnorm, qnorm, shapiro.test and stats::integrate constants
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 8 (Cp, Cpk, Pp, Ppk); NIST Dataplot Cpm; Royston (1995) shapiro.test; R stats documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_SIXPACK_01.json
Settings compared
columns= ["value", "thickness"]confidence_level= 0.99group_column= "lot"lsls= ["", "1.75"]method= "normal"subgroup_mode= "by_column"usls= ["11.2", ""]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/rows/0/n | exact | 40 | 40 | 0.00E+2 | passed | |
/rows/0/mean | tolerance | 10.079974999999999 | 10.079975 | 2.41E-16 | 16 | passed |
/rows/0/std | tolerance | 0.28239992441162648 | 0.28239992441162637 | 1.12E-16 | 15 | passed |
/rows/0/within_sigma | tolerance | 0.23931298531310799 | 0.23931298531310835 | 3.61E-16 | 14 | passed |
/rows/0/cp | absent | None | passed | |||
/rows/0/cpk | tolerance | 1.5600560336423059 | 1.5600560336423037 | 2.18E-15 | 14 | passed |
/rows/0/pp | absent | None | passed | |||
/rows/0/ppk | tolerance | 1.3220317514054409 | 1.3220317514054416 | 7.02E-16 | 15 | passed |
/rows/0/cpm | absent | None | passed | |||
/rows/0/cpk_ci_lower | tolerance | 1.0150744907254499 | 1.015074490725444 | 5.81E-15 | 14 | passed |
/rows/0/cpk_ci_upper | tolerance | 2.105037576559162 | 2.1050375765591633 | 1.35E-15 | 15 | passed |
/rows/0/ppk_ci_lower | tolerance | 0.9132527600789957 | 0.9132527600789961 | 4.40E-16 | 15 | passed |
/rows/0/ppk_ci_upper | tolerance | 1.7308107427318862 | 1.730810742731887 | 8.64E-16 | 15 | passed |
/rows/0/dpmo | tolerance | 36.529837194337645 | 36.529837194265724 | 7.19E-11 | 11 | passed |
/rows/0/within_ppm | tolerance | 1.4331989734757056 | 1.433198973475746 | 4.04E-14 | 13 | passed |
/rows/0/normality_p | tail_probability | 0.82085801775841405 | 0.820858017758421 | 6.99E-15 | 14 | passed |
/rows/0/oos | exact | 0 | 0 | 0.00E+2 | passed | |
/rows/1/n | exact | 40 | 40 | 0.00E+2 | passed | |
/rows/1/mean | tolerance | 2.0171999999999999 | 2.0172 | 1.80E-17 | 17 | passed |
/rows/1/std | tolerance | 0.082934388648574581 | 0.08293438864857458 | 2.95E-19 | 17 | passed |
/rows/1/within_sigma | tolerance | 0.078785725683587715 | 0.07878572568358784 | 1.25E-16 | 14 | passed |
/rows/1/cp | absent | None | passed | |||
/rows/1/cpk | tolerance | 1.1304924324028991 | 1.130492432402897 | 2.00E-15 | 14 | passed |
/rows/1/pp | absent | None | passed | |||
/rows/1/ppk | tolerance | 1.0739413181675084 | 1.0739413181675084 | 2.58E-17 | 16 | passed |
/rows/1/cpm | absent | None | passed | |||
/rows/1/cpk_ci_lower | tolerance | 0.72464252786816985 | 0.7246425278681654 | 4.44E-15 | 14 | passed |
/rows/1/cpk_ci_upper | tolerance | 1.5363423369376283 | 1.5363423369376288 | 4.83E-16 | 15 | passed |
/rows/1/ppk_ci_lower | tolerance | 0.73256554533587681 | 0.7325655453358768 | 9.95E-19 | 17 | passed |
/rows/1/ppk_ci_upper | tolerance | 1.4153170909991399 | 1.41531709099914 | 3.73E-17 | 16 | passed |
/rows/1/dpmo | tolerance | 636.88686861114172 | 636.8868686111307 | 1.10E-11 | 13 | passed |
/rows/1/within_ppm | tolerance | 347.58461076648001 | 347.58461076648666 | 6.65E-12 | 13 | passed |
/rows/1/normality_p | tail_probability | 0.15343483684045106 | 0.15343483684045994 | 8.88E-15 | 13 | passed |
/rows/1/oos | exact | 0 | 0 | 0.00E+2 | passed | |
/rows/0/subgroup_count | exact | 8 | 8 | 0.00E+2 | passed | |
/rows/1/subgroup_count | exact | 8 | 8 | 0.00E+2 | passed | |
/rows/0/confidence_level | tolerance | 0.98999999999999999 | 0.99 | 1.12E-18 | 17 | passed |
Convention
- docs/manual/chapters/08-specifications-and-capability.tex:146-160: within sigma s_w = MR-bar/d2 for ordered individuals (d2 = 2/sqrt(pi) at full precision); with rational subgroups ranges are divided by their own d2(n_i) and averaged; overall s_o is the sample SD.
- docs/manual/chapters/08-specifications-and-capability.tex:268-290: index intervals use SE = sqrt(C^2/(2 nu) + 1/(9 N)) with z_(1 - alpha/2); nu for MR-bar/d2 from A = pi/2 - 1, B = sqrt(3)/2 + pi/12 - 1, v = (mA + 2(m - 1)B)/m^2; for averaged R_i/d2(n_i), v = g^-2 sum (d3/d2)^2; Ppk uses nu = N - 1.
- docs/manual/chapters/85-capability-views.tex:12-17: normal overall spread is mean +/- 3 overall SD and within spread uses within sigma.
- docs/manual/chapters/85-capability-views.tex:19-32: Cpm = (USL - LSL)/(6 sqrt(s^2 + (xbar - T)^2)) with the overall sample SD; normal within PPM is a model projection using within sigma.
- Overall predicted PPM = 1e6 [Phi((LSL - mean)/s_o) + Phi((mean - USL)/s_o)]; within PPM uses s_w; normality check is Shapiro-Wilk (stats::shapiro.test).
- One-sided limits per column: value has only USL (Cpk = CPU) and thickness only LSL (Cpk = CPL); Cp, Pp and Cpm are unavailable; lots of five give s_w = mean(R_i/d2(5)); 99% intervals with z = qnorm(0.995).
- Expected computed from the re-read QUAL_SIXPACK_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
546 g_value <- groups_of(cp_d$value, cp_d$lot); g_thick <- groups_of(cp_d$thickness, cp_d$lot)
547 r1 <- capability(cp_d$value, NULL, usl, NULL, level = 0.99, groups = g_value)
548 r2 <- capability(cp_d$thickness, 1.75, NULL, NULL, level = 0.99, groups = g_thick)
549 out <- c(cap_outputs(r1, "/rows/0"), cap_outputs(r2, "/rows/1"),
550 list("/rows/0/subgroup_count" = exact(8L, "Eight lots."), "/rows/1/subgroup_count" = exact(8L, "Eight lots."),
551 "/rows/0/confidence_level" = num(0.99, "Configured level.")))
552 emit("STAT-QUAL-CAPABILITY-MULTIPLE-002", mul_ep, "capabilityMultipleMenuItem", "Capability of two characteristics by lot with one-sided limits at 99% confidence", "QUAL_SIXPACK_01",
553 list(columns = list("value", "thickness"), lsls = list("", "1.75"), usls = list("11.2", ""),
554 method = "normal", subgroup_mode = "by_column", group_column = "lot", confidence_level = 0.99),
555 out, c(cap_notes, "One-sided limits per column: value has only USL (Cpk = CPU) and thickness only LSL (Cpk = CPL); Cp, Pp and Cpm are unavailable; lots of five give s_w = mean(R_i/d2(5)); 99% intervals with z = qnorm(0.995)."),
556 cap_source, cap_cite, mul_req, kind = "axis_coverage")
Capability sixpack of ordered individuals with a target
Case STAT-QUAL-CAPABILITY-SIXPACK-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded manual capability formulas with stats::pnorm, qnorm, shapiro.test and stats::integrate constants
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 8 (Cp, Cpk, Pp, Ppk); NIST Dataplot Cpm; Royston (1995) shapiro.test; R stats documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_SIXPACK_01.json
Settings compared
column= "value"confidence_level= 0.95lsl= 8.8method= "normal"subgroup_mode= "individuals"target= 10usl= 11.2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/capability/n | exact | 40 | 40 | 0.00E+2 | passed | |
/capability/mean | tolerance | 10.079974999999999 | 10.079975 | 2.41E-16 | 16 | passed |
/capability/std | tolerance | 0.28239992441162648 | 0.28239992441162637 | 1.12E-16 | 15 | passed |
/capability/within_sigma | tolerance | 0.25627864782708221 | 0.2562786478270822 | 3.41E-18 | 16 | passed |
/capability/cp | tolerance | 1.560801117812554 | 1.560801117812554 | 3.97E-17 | 16 | passed |
/capability/cpk | tolerance | 1.4567802266483389 | 1.456780226648339 | 4.95E-17 | 16 | passed |
/capability/pp | tolerance | 1.4164309740287298 | 1.4164309740287304 | 6.16E-16 | 15 | passed |
/capability/ppk | tolerance | 1.3220317514054409 | 1.3220317514054416 | 7.02E-16 | 15 | passed |
/capability/cpm | tolerance | 1.3628345778580169 | 1.3628345778580175 | 6.37E-16 | 15 | passed |
/capability/cpk_ci_lower | tolerance | 1.0300990292628287 | 1.0300990292628287 | 2.61E-18 | 17 | passed |
/capability/cpk_ci_upper | tolerance | 1.8834614240338492 | 1.8834614240338492 | 3.61E-18 | 17 | passed |
/capability/ppk_ci_lower | tolerance | 1.0109893622484478 | 1.0109893622484483 | 4.64E-16 | 15 | passed |
/capability/ppk_ci_upper | tolerance | 1.6330741405624341 | 1.633074140562435 | 8.39E-16 | 15 | passed |
/capability/dpmo | tolerance | 39.444450878714264 | 39.444450878667325 | 4.69E-11 | 11 | passed |
/capability/within_ppm | tolerance | 6.4976358253941982 | 6.49763582539419 | 8.04E-15 | 14 | passed |
/capability/normality_p | tail_probability | 0.82085801775841405 | 0.820858017758421 | 6.99E-15 | 14 | passed |
/capability/oos | exact | 0 | 0 | 0.00E+2 | passed | |
/within_spread/0 | tolerance | 9.3111390565187531 | 9.311139056518753 | 3.45E-17 | 17 | passed |
/within_spread/1 | tolerance | 10.848810943481245 | 10.848810943481245 | 4.17E-16 | 16 | passed |
/overall_spread/0 | tolerance | 9.2327752267651206 | 9.23277522676512 | 3.53E-17 | 17 | passed |
/overall_spread/1 | tolerance | 10.927174773234878 | 10.927174773234878 | 1.53E-16 | 16 | passed |
/overall_spread_label | exact | mean +/- 3 overall SD | mean +/- 3 overall SD | passed | ||
/chart_family | exact | I-MR | I-MR | passed | ||
/primary/0/center | tolerance | 10.079974999999999 | 10.079975 | 2.41E-16 | 16 | passed |
/primary/0/upper | tolerance | 10.848810943481245 | 10.848810943481245 | 4.17E-16 | 16 | passed |
/primary/0/lower | tolerance | 9.3111390565187531 | 9.311139056518753 | 3.45E-17 | 17 | passed |
/secondary/0/center | tolerance | 0.28917948717948722 | 0.2891794871794872 | 4.29E-18 | 16 | passed |
/secondary/0/upper | tolerance | 0.9446140252753038 | 0.9446140252753038 | 3.57E-18 | 17 | passed |
/run_plot_subgroups | exact | 25 | 25 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/08-specifications-and-capability.tex:146-160: within sigma s_w = MR-bar/d2 for ordered individuals (d2 = 2/sqrt(pi) at full precision); with rational subgroups ranges are divided by their own d2(n_i) and averaged; overall s_o is the sample SD.
- docs/manual/chapters/08-specifications-and-capability.tex:268-290: index intervals use SE = sqrt(C^2/(2 nu) + 1/(9 N)) with z_(1 - alpha/2); nu for MR-bar/d2 from A = pi/2 - 1, B = sqrt(3)/2 + pi/12 - 1, v = (mA + 2(m - 1)B)/m^2; for averaged R_i/d2(n_i), v = g^-2 sum (d3/d2)^2; Ppk uses nu = N - 1.
- docs/manual/chapters/85-capability-views.tex:12-17: normal overall spread is mean +/- 3 overall SD and within spread uses within sigma.
- docs/manual/chapters/85-capability-views.tex:19-32: Cpm = (USL - LSL)/(6 sqrt(s^2 + (xbar - T)^2)) with the overall sample SD; normal within PPM is a model projection using within sigma.
- Overall predicted PPM = 1e6 [Phi((LSL - mean)/s_o) + Phi((mean - USL)/s_o)]; within PPM uses s_w; normality check is Shapiro-Wilk (stats::shapiro.test).
- Individuals: s_w = MR-bar/d2(2) over the 40 ordered values; the I chart uses the same MR-bar; 95% intervals with z = qnorm(0.975).
- Expected computed from the re-read QUAL_SIXPACK_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
432 six_ep <- "tabelz.analysis.capability_sixpack:compute_capability_sixpack" 433 six_req <- "REQ-STAT-QUAL-CAPABILITY-SIXPACK-001"
Capability sixpack with consecutive subgroups of five at 90% confidence
Case STAT-QUAL-CAPABILITY-SIXPACK-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded manual capability formulas with stats::pnorm, qnorm, shapiro.test and stats::integrate constants
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 8 (Cp, Cpk, Pp, Ppk); NIST Dataplot Cpm; Royston (1995) shapiro.test; R stats documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_SIXPACK_01.json
Settings compared
column= "value"confidence_level= 0.9lsl= 8.8method= "normal"subgroup_mode= "constant"subgroup_size= 5target= 10usl= 11.2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/capability/n | exact | 40 | 40 | 0.00E+2 | passed | |
/capability/mean | tolerance | 10.079974999999999 | 10.079975 | 2.41E-16 | 16 | passed |
/capability/std | tolerance | 0.28239992441162648 | 0.28239992441162637 | 1.12E-16 | 15 | passed |
/capability/within_sigma | tolerance | 0.23931298531310799 | 0.23931298531310835 | 3.61E-16 | 14 | passed |
/capability/cp | tolerance | 1.6714512982931327 | 1.6714512982931304 | 2.26E-15 | 14 | passed |
/capability/cpk | tolerance | 1.5600560336423059 | 1.5600560336423037 | 2.18E-15 | 14 | passed |
/capability/pp | tolerance | 1.4164309740287298 | 1.4164309740287304 | 6.16E-16 | 15 | passed |
/capability/ppk | tolerance | 1.3220317514054409 | 1.3220317514054416 | 7.02E-16 | 15 | passed |
/capability/cpm | tolerance | 1.3628345778580169 | 1.3628345778580175 | 6.37E-16 | 15 | passed |
/capability/cpk_ci_lower | tolerance | 1.2120458350420547 | 1.21204583504205 | 4.71E-15 | 14 | passed |
/capability/cpk_ci_upper | tolerance | 1.9080662322425572 | 1.9080662322425574 | 2.47E-16 | 15 | passed |
/capability/ppk_ci_lower | tolerance | 1.0609967497543298 | 1.0609967497543304 | 6.48E-16 | 15 | passed |
/capability/ppk_ci_upper | tolerance | 1.5830667530565521 | 1.5830667530565528 | 6.56E-16 | 15 | passed |
/capability/dpmo | tolerance | 39.444450878714264 | 39.444450878667325 | 4.69E-11 | 11 | passed |
/capability/within_ppm | tolerance | 1.4775323403539575 | 1.4775323403539997 | 4.22E-14 | 13 | passed |
/capability/normality_p | tail_probability | 0.82085801775841405 | 0.820858017758421 | 6.99E-15 | 14 | passed |
/capability/oos | exact | 0 | 0 | 0.00E+2 | passed | |
/primary/0/center | tolerance | 10.079975000000001 | 10.079975000000001 | 1.75E-17 | 17 | passed |
/primary/0/upper | tolerance | 10.401047061835111 | 10.401047061835113 | 2.18E-15 | 15 | passed |
/primary/0/lower | tolerance | 9.7589029381648906 | 9.758902938164889 | 1.75E-15 | 15 | passed |
/primary/0/y | tolerance | 10.0816 | 10.081599999999998 | 1.88E-15 | 15 | passed |
/secondary/0/center | tolerance | 0.55662500000000015 | 0.5566250000000001 | 2.56E-18 | 17 | passed |
/secondary/0/upper | tolerance | 1.1769830866389939 | 1.176983086638999 | 5.08E-15 | 14 | passed |
/secondary/0/y | tolerance | 0.33000000000000007 | 0.3299999999999983 | 1.78E-15 | 14 | passed |
/run_plot_subgroups | exact | 8 | 8 | 0.00E+2 | passed | |
/capability/subgroup_count | exact | 8 | 8 | 0.00E+2 | passed | |
/capability/confidence_level | tolerance | 0.90000000000000002 | 0.9 | 2.20E-18 | 17 | passed |
Convention
- docs/manual/chapters/08-specifications-and-capability.tex:146-160: within sigma s_w = MR-bar/d2 for ordered individuals (d2 = 2/sqrt(pi) at full precision); with rational subgroups ranges are divided by their own d2(n_i) and averaged; overall s_o is the sample SD.
- docs/manual/chapters/08-specifications-and-capability.tex:268-290: index intervals use SE = sqrt(C^2/(2 nu) + 1/(9 N)) with z_(1 - alpha/2); nu for MR-bar/d2 from A = pi/2 - 1, B = sqrt(3)/2 + pi/12 - 1, v = (mA + 2(m - 1)B)/m^2; for averaged R_i/d2(n_i), v = g^-2 sum (d3/d2)^2; Ppk uses nu = N - 1.
- docs/manual/chapters/85-capability-views.tex:12-17: normal overall spread is mean +/- 3 overall SD and within spread uses within sigma.
- docs/manual/chapters/85-capability-views.tex:19-32: Cpm = (USL - LSL)/(6 sqrt(s^2 + (xbar - T)^2)) with the overall sample SD; normal within PPM is a model projection using within sigma.
- Overall predicted PPM = 1e6 [Phi((LSL - mean)/s_o) + Phi((mean - USL)/s_o)]; within PPM uses s_w; normality check is Shapiro-Wilk (stats::shapiro.test).
- Subgroups of five: s_w = mean(R_i/d2(5)) (the default range estimator for sizes up to ten); Cpk nu = 1/(2 v) with v = g^-2 sum (d3(5)/d2(5))^2; 90% intervals with z = qnorm(0.95).
- Expected computed from the re-read QUAL_SIXPACK_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
455 groups5 <- split(x, rep(1:8, each = 5))
456 r <- capability(x, lsl, usl, target, level = 0.90, groups = groups5)
457 means5 <- vapply(groups5, mean, 0); ranges5 <- vapply(groups5, function(g) max(g) - min(g), 0)
458 out <- c(cap_outputs(r, "/capability"),
459 list("/primary/0/center" = num(mean(means5), "X-bar centre: mean of the eight subgroup means."),
460 "/primary/0/upper" = num(mean(means5) + 3 * r$within / sqrt(5), "centre + 3 s_w/sqrt(5)."),
461 "/primary/0/lower" = num(mean(means5) - 3 * r$within / sqrt(5), "centre - 3 s_w/sqrt(5)."),
462 "/primary/0/y" = num(means5[1], "First subgroup mean."),
463 "/secondary/0/center" = num(d2(5) * r$within, "R chart centre d2(5) s_w."),
464 "/secondary/0/upper" = num((d2(5) + 3 * d3(5)) * r$within, "(d2(5) + 3 d3(5)) s_w."),
465 "/secondary/0/y" = num(ranges5[1], "First subgroup range."),
466 "/run_plot_subgroups" = exact(8L, "Eight subgroups, fewer than 25."),
467 "/capability/subgroup_count" = exact(8L, "Eight complete subgroups."),
468 "/capability/confidence_level" = num(0.90, "Configured level.")))
469 emit("STAT-QUAL-CAPABILITY-SIXPACK-002", six_ep, "capabilitySixpackMenuItem", "Capability sixpack with consecutive subgroups of five at 90% confidence", "QUAL_SIXPACK_01",
470 list(column = "value", lsl = lsl, usl = usl, target = target, method = "normal", subgroup_mode = "constant", subgroup_size = 5L, confidence_level = 0.90),
471 out, c(cap_notes, "Subgroups of five: s_w = mean(R_i/d2(5)) (the default range estimator for sizes up to ten); Cpk nu = 1/(2 v) with v = g^-2 sum (d3(5)/d2(5))^2; 90% intervals with z = qnorm(0.95)."),
472 cap_source, cap_cite, six_req, kind = "axis_coverage")
Capability sixpack by lot column with an upper limit only and excluded rows
Case STAT-QUAL-CAPABILITY-SIXPACK-003 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded manual capability formulas with stats::pnorm, qnorm, shapiro.test and stats::integrate constants
- Citation
- Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 8 (Cp, Cpk, Pp, Ppk); NIST Dataplot Cpm; Royston (1995) shapiro.test; R stats documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_SIXPACK_01.json
Settings compared
column= "thickness"confidence_level= 0.95group_column= "lot"method= "normal"subgroup_mode= "by_column"usl= 2.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/capability/n | exact | 38 | 38 | 0.00E+2 | passed | |
/capability/mean | tolerance | 2.0174473684210525 | 2.017447368421052 | 3.99E-16 | 15 | passed |
/capability/std | tolerance | 0.085138265087308471 | 0.08513826508730847 | 3.53E-19 | 17 | passed |
/capability/within_sigma | tolerance | 0.081122171040382038 | 0.08112217104038215 | 1.11E-16 | 14 | passed |
/capability/cp | absent | None | passed | |||
/capability/cpk | tolerance | 0.95556544980855451 | 0.9555654498085551 | 5.57E-16 | 15 | passed |
/capability/pp | absent | None | passed | |||
/capability/ppk | tolerance | 0.91049005732211785 | 0.9104900573221196 | 1.78E-15 | 14 | passed |
/capability/cpm | absent | None | passed | |||
/capability/cpk_ci_lower | tolerance | 0.67873466015653428 | 0.6787346601565329 | 1.34E-15 | 14 | passed |
/capability/cpk_ci_upper | tolerance | 1.2323962394605747 | 1.2323962394605772 | 2.49E-15 | 14 | passed |
/capability/ppk_ci_lower | tolerance | 0.67753802566451549 | 0.6775380256645169 | 1.44E-15 | 14 | passed |
/capability/ppk_ci_upper | tolerance | 1.1434420889797203 | 1.1434420889797223 | 2.03E-15 | 14 | passed |
/capability/dpmo | tolerance | 3152.6224115979167 | 3152.6224115978607 | 5.60E-11 | 13 | passed |
/capability/within_ppm | tolerance | 2073.9038597972631 | 2073.90385979725 | 1.32E-11 | 14 | passed |
/capability/normality_p | tail_probability | 0.20683934860473979 | 0.20683934860473502 | 4.77E-15 | 13 | passed |
/capability/oos | exact | 1 | 1 | 0.00E+2 | passed | |
/capability/cpm_note | exact | Cpm needs both specification limits and a target. | Cpm needs both specification limits and a target. | passed | ||
/within_spread/1 | tolerance | 2.2608138815421985 | 2.2608138815421985 | 3.35E-17 | 16 | passed |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed | |
/capability/subgroup_count | exact | 8 | 8 | 0.00E+2 | passed | |
/primary/0/center | tolerance | 2.0174473684210525 | 2.0174473684210525 | 4.48E-17 | 16 | passed |
/primary/0/upper | tolerance | 2.1391306249816258 | 2.1391306249816258 | 3.88E-17 | 16 | passed |
/primary/1/upper | tolerance | 2.1262841817782481 | 2.126284181778248 | 2.76E-17 | 16 | passed |
Convention
- docs/manual/chapters/08-specifications-and-capability.tex:146-160: within sigma s_w = MR-bar/d2 for ordered individuals (d2 = 2/sqrt(pi) at full precision); with rational subgroups ranges are divided by their own d2(n_i) and averaged; overall s_o is the sample SD.
- docs/manual/chapters/08-specifications-and-capability.tex:268-290: index intervals use SE = sqrt(C^2/(2 nu) + 1/(9 N)) with z_(1 - alpha/2); nu for MR-bar/d2 from A = pi/2 - 1, B = sqrt(3)/2 + pi/12 - 1, v = (mA + 2(m - 1)B)/m^2; for averaged R_i/d2(n_i), v = g^-2 sum (d3/d2)^2; Ppk uses nu = N - 1.
- docs/manual/chapters/85-capability-views.tex:12-17: normal overall spread is mean +/- 3 overall SD and within spread uses within sigma.
- docs/manual/chapters/85-capability-views.tex:19-32: Cpm = (USL - LSL)/(6 sqrt(s^2 + (xbar - T)^2)) with the overall sample SD; normal within PPM is a model projection using within sigma.
- Overall predicted PPM = 1e6 [Phi((LSL - mean)/s_o) + Phi((mean - USL)/s_o)]; within PPM uses s_w; normality check is Shapiro-Wilk (stats::shapiro.test).
- Only USL: Cp, Pp and Cpm are unavailable; Cpk = CPU and Ppk = PPU. Lots L01 and L05 lose one row each to the exclusions, so s_w averages R_i/d2(n_i) over sizes 4 and 5 and the X-bar limits change with n_i.
- The X-bar centre is the size-weighted mean of all retained observations.
- Expected computed from the re-read QUAL_SIXPACK_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
485 out[["/primary/0/center"]] <- num(mean(xk), "X-bar centre: size-weighted mean of the 38 retained observations.")
486 out[["/primary/0/upper"]] <- num(mean(xk) + 3 * r$within / sqrt(4), "Size-weighted centre + 3 s_w/sqrt(4): lot L01 has four values after the exclusion.")
487 out[["/primary/1/upper"]] <- num(mean(xk) + 3 * r$within / sqrt(5), "Size-weighted centre + 3 s_w/sqrt(5) for the complete lot L02.")
488 emit("STAT-QUAL-CAPABILITY-SIXPACK-003", six_ep, "capabilitySixpackMenuItem", "Capability sixpack by lot column with an upper limit only and excluded rows", "QUAL_SIXPACK_01",
489 list(column = "thickness", usl = 2.25, method = "normal", subgroup_mode = "by_column", group_column = "lot", confidence_level = 0.95),
490 out, c(cap_notes, "Only USL: Cp, Pp and Cpm are unavailable; Cpk = CPU and Ppk = PPU. Lots L01 and L05 lose one row each to the exclusions, so s_w averages R_i/d2(n_i) over sizes 4 and 5 and the X-bar limits change with n_i.",
491 "The X-bar centre is the size-weighted mean of all retained observations."),
492 cap_source, cap_cite, six_req, kind = "axis_coverage", excluded = c(2L, 21L))
Slifker-Shapiro supplied-parameter Johnson SU transform
Case STAT-QUAL-JOHNSON-PARAM-001 · status: passed
Reference
- Evidence type
- R
- Source
- R recomputation from Slifker and Shapiro (1980), p. 243
- Citation
- Slifker and Shapiro (1980), The Johnson System: Selection and Parameter Estimation, Technometrics 22(2), 239-246, p. 243
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_johnson_supplied_parameters.R · sha256 7eda3f986a1a3fa6
- Dataset
- reference_data/datasets/QUAL_JOHNSON_SU_PUBLISHED.json
Settings compared
a= 1.402b= 2.333family= "SU"loc= 15.516measurement_column= "value"scale= 1.585
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/scores/0 | tolerance | 3.0005218812430074 | 3.0005218812430074 | 4.93E-17 | 16 | passed |
/scores/1 | tolerance | 1.0006749587203319 | 1.0006749587203316 | 2.69E-16 | 15 | passed |
/scores/2 | tolerance | -0.99920282692934959 | -0.9992028269293496 | 4.32E-18 | 17 | passed |
/scores/3 | tolerance | -2.9990399696617649 | -2.999039969661765 | 7.19E-18 | 17 | passed |
Convention
- The paper prints rounded parameters and percentile coordinates; expected scores apply the formula to exactly those rounded values.
- This exercises only supplied-parameter transformation; it does not qualify Tabelz Johnson MLE or automatic family selection.
- The retained binding sends each supplied value through the public scalar helper in the analysis worker; no parameter fitting is performed.
Reference code
The lines of the reference script that produce this case's expected values.
6 run <- generator_run(c("stats", "jsonlite"))
7 examples <- list(
8 list(id = "STAT-QUAL-JOHNSON-PARAM-001", dataset = "QUAL_JOHNSON_SU_PUBLISHED",
9 family = "SU", x = c(16.689, 15.242, 13.581, 10.409),
10 a = 1.402, b = 2.333, loc = 15.516, scale = 1.585,
11 printed = c(3, 1, -1, -3)),
12 list(id = "STAT-QUAL-JOHNSON-PARAM-002", dataset = "QUAL_JOHNSON_SB_PUBLISHED",
13 family = "SB", x = c(0.786, 0.635, 0.516, 0.432),
14 a = 2.373, b = 1.959, loc = 0.295, scale = 1.203,
15 printed = c(1.645, 0.5483, -0.5483, -1.645)))Whole script generators/r/quality_johnson_supplied_parameters.R
Slifker-Shapiro supplied-parameter Johnson SB transform
Case STAT-QUAL-JOHNSON-PARAM-002 · status: passed
Reference
- Evidence type
- R
- Source
- R recomputation from Slifker and Shapiro (1980), p. 243
- Citation
- Slifker and Shapiro (1980), The Johnson System: Selection and Parameter Estimation, Technometrics 22(2), 239-246, p. 243
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_johnson_supplied_parameters.R · sha256 7eda3f986a1a3fa6
- Dataset
- reference_data/datasets/QUAL_JOHNSON_SB_PUBLISHED.json
Settings compared
a= 2.373b= 1.959family= "SB"loc= 0.295measurement_column= "value"scale= 1.203
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/scores/0 | tolerance | 1.6449694178934058 | 1.6449694178934058 | 1.69E-17 | 16 | passed |
/scores/1 | tolerance | 0.54825208506596068 | 0.5482520850659607 | 1.48E-18 | 17 | passed |
/scores/2 | tolerance | -0.54870864079312076 | -0.5487086407931208 | 1.00E-18 | 17 | passed |
/scores/3 | tolerance | -1.6462561629605261 | -1.6462561629605261 | 2.60E-17 | 16 | passed |
Convention
- The paper prints rounded parameters and percentile coordinates; expected scores apply the formula to exactly those rounded values.
- This exercises only supplied-parameter transformation; it does not qualify Tabelz Johnson MLE or automatic family selection.
- The retained binding sends each supplied value through the public scalar helper in the analysis worker; no parameter fitting is performed.
Reference code
The lines of the reference script that produce this case's expected values.
12 list(id = "STAT-QUAL-JOHNSON-PARAM-002", dataset = "QUAL_JOHNSON_SB_PUBLISHED", 13 family = "SB", x = c(0.786, 0.635, 0.516, 0.432), 14 a = 2.373, b = 1.959, loc = 0.295, scale = 1.203, 15 printed = c(1.645, 0.5483, -0.5483, -1.645)))
Whole script generators/r/quality_johnson_supplied_parameters.R
Width 3 with a Phase I marker and the moving-range sigma
Case STAT-QUAL-MA-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 9.3, pp. 428-429; NIST/SEMATECH e-Handbook 6.3.2.1 for d2 moving-range factor
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_MA.json
Settings compared
baseline_column= "phase1"value_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/0/moving_average | tolerance | 11.9085 | 11.9085 | 8.53E-17 | 17 | passed |
/points/0/window_size | exact | 1 | 1 | 0.00E+2 | passed | |
/points/0/ucl | tolerance | 14.608462472838699 | 14.6084624728387 | 1.42E-16 | 17 | passed |
/points/0/lcl | tolerance | 9.2651375271613006 | 9.2651375271613 | 3.20E-17 | 17 | passed |
/points/1/moving_average | tolerance | 11.8278 | 11.8278 | 1.31E-16 | 16 | passed |
/points/1/window_size | exact | 2 | 2 | 0.00E+2 | passed | |
/points/1/ucl | tolerance | 13.825950651585863 | 13.825950651585863 | 2.27E-16 | 16 | passed |
/points/1/lcl | tolerance | 10.047649348414136 | 10.047649348414136 | 4.83E-16 | 16 | passed |
/points/2/moving_average | tolerance | 11.333933333333333 | 11.333933333333334 | 1.30E-15 | 15 | passed |
/points/2/window_size | exact | 3 | 3 | 0.00E+2 | passed | |
/points/2/ucl | tolerance | 13.479285047877244 | 13.479285047877244 | 3.52E-16 | 16 | passed |
/points/2/lcl | tolerance | 10.394314952122755 | 10.394314952122755 | 3.58E-16 | 16 | passed |
/points/10/moving_average | tolerance | 12.5619 | 12.5619 | 3.78E-16 | 16 | passed |
/points/10/window_size | exact | 3 | 3 | 0.00E+2 | passed | |
/points/10/ucl | tolerance | 13.479285047877244 | 13.479285047877244 | 3.52E-16 | 16 | passed |
/points/10/lcl | tolerance | 10.394314952122755 | 10.394314952122755 | 3.58E-16 | 16 | passed |
/points/29/moving_average | tolerance | 11.950666666666667 | 11.950666666666669 | 1.55E-15 | 15 | passed |
/points/29/window_size | exact | 3 | 3 | 0.00E+2 | passed | |
/points/29/ucl | tolerance | 13.479285047877244 | 13.479285047877244 | 3.52E-16 | 16 | passed |
/points/29/lcl | tolerance | 10.394314952122755 | 10.394314952122755 | 3.58E-16 | 16 | passed |
/baseline_mean | tolerance | 11.9368 | 11.9368 | 1.45E-16 | 16 | passed |
/baseline_sigma | tolerance | 0.89055415761289958 | 0.8905541576128996 | 2.68E-18 | 17 | passed |
/baseline_count | exact | 30 | 30 | 0.00E+2 | passed |
Convention
- Expanding startup: k = 1, 2, 3 (line 28-29).
- Montgomery's Example 9.3 uses known mean and sigma; estimated-baseline and full-window cases here are independent Tabelz-convention calculations.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
82 set.seed(20261010)
83 x <- round(c(rnorm(30, 12, 0.8), rnorm(20, 12.9, 0.8)), 4)
84 export_dataset(data.frame(x = x, phase1 = c(rep(TRUE, 30), rep(FALSE, 20)),
85 stage = c(rep("S1", 25), rep("S2", 25))),
86 "QUAL_MA", "Constructed: 30 points N(12, 0.8^2) then 20 points N(12.9, 0.8^2), seed 20261010",
87 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
88 c(x = "Float64", phase1 = "Boolean", stage = "String"))
89 d <- read_dataset("QUAL_MA")
90 base <- d$x[d$phase1]
91 s_mr <- mean(abs(diff(base))) / d2
92 r <- moving(d$x, 3, mean(base), s_mr)
93 emit("STAT-QUAL-MA-001", ma_entry, ma_menu, "Width 3 with a Phase I marker and the moving-range sigma", "QUAL_MA",
94 list(value_column = "x", baseline_column = "phase1"),
95 c(ma_outputs(r), list("/baseline_mean" = tol(mean(base), "Mean of the 30 Phase I rows."),
96 "/baseline_sigma" = tol(s_mr, "MR-bar / d2 over the Phase I rows."),
97 "/baseline_count" = exact(30L, "Thirty Phase I rows."))),
98 c("Expanding startup: k = 1, 2, 3 (line 28-29)."))
Width 5 with the sample standard deviation
Case STAT-QUAL-MA-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 9.3, pp. 428-429; NIST/SEMATECH e-Handbook 6.3.2.1 for d2 moving-range factor
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_MA.json
Settings compared
baseline_column= "phase1"sigma_estimator= "stddev"value_column= "x"window_width= 5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/0/moving_average | tolerance | 11.9085 | 11.9085 | 8.53E-17 | 17 | passed |
/points/0/window_size | exact | 1 | 1 | 0.00E+2 | passed | |
/points/0/ucl | tolerance | 14.492387861381678 | 14.492387861381678 | 1.06E-16 | 17 | passed |
/points/0/lcl | tolerance | 9.3812121386183218 | 9.381212138618322 | 1.64E-17 | 17 | passed |
/points/1/moving_average | tolerance | 11.8278 | 11.8278 | 1.31E-16 | 16 | passed |
/points/1/window_size | exact | 2 | 2 | 0.00E+2 | passed | |
/points/1/ucl | tolerance | 13.743873506701011 | 13.74387350670101 | 2.88E-16 | 16 | passed |
/points/1/lcl | tolerance | 10.129726493298989 | 10.129726493298989 | 1.50E-18 | 18 | passed |
/points/2/moving_average | tolerance | 11.333933333333333 | 11.333933333333334 | 1.30E-15 | 15 | passed |
/points/2/window_size | exact | 3 | 3 | 0.00E+2 | passed | |
/points/2/ucl | tolerance | 13.412269339706452 | 13.412269339706452 | 3.68E-16 | 16 | passed |
/points/2/lcl | tolerance | 10.461330660293548 | 10.461330660293548 | 7.82E-17 | 17 | passed |
/points/10/moving_average | tolerance | 12.389419999999999 | 12.389419999999998 | 1.34E-15 | 15 | passed |
/points/10/window_size | exact | 5 | 5 | 0.00E+2 | passed | |
/points/10/ucl | tolerance | 13.079693636104547 | 13.079693636104547 | 4.94E-16 | 16 | passed |
/points/10/lcl | tolerance | 10.793906363895452 | 10.793906363895452 | 2.16E-16 | 16 | passed |
/points/29/moving_average | tolerance | 11.545160000000001 | 11.54516 | 1.80E-15 | 15 | passed |
/points/29/window_size | exact | 5 | 5 | 0.00E+2 | passed | |
/points/29/ucl | tolerance | 13.079693636104547 | 13.079693636104547 | 4.94E-16 | 16 | passed |
/points/29/lcl | tolerance | 10.793906363895452 | 10.793906363895452 | 2.16E-16 | 16 | passed |
/baseline_sigma | tolerance | 0.85186262046055927 | 0.8518626204605593 | 2.22E-18 | 17 | passed |
Convention
- sigma_estimator = stddev (line 29-31).
- Montgomery's Example 9.3 uses known mean and sigma; estimated-baseline and full-window cases here are independent Tabelz-convention calculations.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
99 s_sd <- sd(base)
100 r <- moving(d$x, 5, mean(base), s_sd)
101 emit("STAT-QUAL-MA-002", ma_entry, ma_menu, "Width 5 with the sample standard deviation", "QUAL_MA",
102 list(value_column = "x", baseline_column = "phase1", window_width = 5L, sigma_estimator = "stddev"),
103 c(ma_outputs(r), list("/baseline_sigma" = tol(s_sd, "Sample standard deviation of the Phase I rows."))),
104 c("sigma_estimator = stddev (line 29-31)."), kind = "axis_coverage")
Full-window startup with historical parameters
Case STAT-QUAL-MA-003 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 9.3, pp. 428-429; NIST/SEMATECH e-Handbook 6.3.2.1 for d2 moving-range factor
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_MA.json
Settings compared
historical_mean= 12historical_sigma= 0.8partial_window_policy= "full_window"value_column= "x"window_width= 4
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/0/limits_available | exact | False | False | passed | ||
/points/2/limits_available | exact | False | False | passed | ||
/points/3/limits_available | exact | True | True | passed | ||
/points/3/ucl | tolerance | 13.199999999999999 | 13.2 | 2.89E-16 | 16 | passed |
/points/0/moving_average | tolerance | 11.9085 | 11.9085 | 8.53E-17 | 17 | passed |
Convention
- Historical mean 12 and sigma 0.8 are used exactly (line 12-13).
- Montgomery's Example 9.3 uses known mean and sigma; estimated-baseline and full-window cases here are independent Tabelz-convention calculations.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
105 r <- moving(d$x, 4, 12, 0.8, full = TRUE)
106 emit("STAT-QUAL-MA-003", ma_entry, ma_menu, "Full-window startup with historical parameters", "QUAL_MA",
107 list(value_column = "x", window_width = 4L, partial_window_policy = "full_window", historical_mean = 12, historical_sigma = 0.8),
108 list("/points/0/limits_available" = exact(FALSE, "The first w - 1 rows have no limits (line 34-36)."),
109 "/points/2/limits_available" = exact(FALSE, "Still a partial window."),
110 "/points/3/limits_available" = exact(TRUE, "The first complete window starts monitoring."),
111 "/points/3/ucl" = tol(12 + 3 * 0.8 / 2, "Historical centre + 3 sigma / sqrt(4)."),
112 "/points/0/moving_average" = tol(r$m[1], "The expanding partial statistic is still reported.")),
113 c("Historical mean 12 and sigma 0.8 are used exactly (line 12-13)."), kind = "axis_coverage")
A stage column resets the window
Case STAT-QUAL-MA-004 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 9.3, pp. 428-429; NIST/SEMATECH e-Handbook 6.3.2.1 for d2 moving-range factor
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_MA.json
Settings compared
historical_mean= 12historical_sigma= 0.8stage_column= "stage"value_column= "x"window_width= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/25/window_size | exact | 1 | 1 | 0.00E+2 | passed | |
/points/26/moving_average | tolerance | 10.936900000000001 | 10.936900000000001 | 3.98E-16 | 16 | passed |
/points/24/window_size | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- Stages S1 (rows 1-25) and S2 (rows 26-50).
- Montgomery's Example 9.3 uses known mean and sigma; estimated-baseline and full-window cases here are independent Tabelz-convention calculations.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
114 r <- moving(d$x, 3, 12, 0.8, stage = d$stage)
115 emit("STAT-QUAL-MA-004", ma_entry, ma_menu, "A stage column resets the window", "QUAL_MA",
116 list(value_column = "x", window_width = 3L, stage_column = "stage", historical_mean = 12, historical_sigma = 0.8),
117 list("/points/25/window_size" = exact(1L, "The first row of stage S2 starts a new window (line 39-47)."),
118 "/points/26/moving_average" = tol(r$m[27], "Mean of the first two S2 rows."),
119 "/points/24/window_size" = exact(3L, "A full window at the end of S1.")),
120 c("Stages S1 (rows 1-25) and S2 (rows 26-50)."), kind = "axis_coverage")
Width one is the individuals specification
Case STAT-QUAL-MA-005 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 9.3, pp. 428-429; NIST/SEMATECH e-Handbook 6.3.2.1 for d2 moving-range factor
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_MA.json
Settings compared
baseline_column= "phase1"value_column= "x"window_width= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/40/moving_average | tolerance | 11.9267 | 11.9267 | 3.01E-16 | 16 | passed |
/points/40/ucl | tolerance | 14.608462472838699 | 14.6084624728387 | 1.42E-16 | 17 | passed |
Convention
- Width 1.
- Montgomery's Example 9.3 uses known mean and sigma; estimated-baseline and full-window cases here are independent Tabelz-convention calculations.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
121 r <- moving(d$x, 1, mean(base), s_mr)
122 emit("STAT-QUAL-MA-005", ma_entry, ma_menu, "Width one is the individuals specification", "QUAL_MA",
123 list(value_column = "x", window_width = 1L, baseline_column = "phase1"),
124 list("/points/40/moving_average" = tol(d$x[41], "Each average is the observation itself (line 6-8)."),
125 "/points/40/ucl" = tol(mean(base) + 3 * s_mr, "Centre + 3 sigma.")),
126 c("Width 1."), kind = "boundary")
Missing and excluded rows are omitted before the windows
Case STAT-QUAL-MA-006 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 9.3, pp. 428-429; NIST/SEMATECH e-Handbook 6.3.2.1 for d2 moving-range factor
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_MA_MISSING.json
Settings compared
baseline_column= "phase1"value_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/0/moving_average | tolerance | 11.9085 | 11.9085 | 8.53E-17 | 17 | passed |
/points/0/window_size | exact | 1 | 1 | 0.00E+2 | passed | |
/points/0/ucl | tolerance | 14.363619415785202 | 14.363619415785202 | 2.62E-16 | 16 | passed |
/points/0/lcl | tolerance | 9.6650805842147989 | 9.665080584214802 | 3.53E-15 | 15 | passed |
/points/5/moving_average | tolerance | 11.783366666666666 | 11.783366666666666 | 1.22E-16 | 16 | passed |
/points/5/window_size | exact | 3 | 3 | 0.00E+2 | passed | |
/points/5/ucl | tolerance | 13.370701329602541 | 13.370701329602543 | 1.98E-15 | 15 | passed |
/points/5/lcl | tolerance | 10.657998670397459 | 10.657998670397461 | 2.18E-15 | 15 | passed |
/points/10/moving_average | tolerance | 12.303133333333333 | 12.303133333333335 | 2.03E-15 | 15 | passed |
/points/10/window_size | exact | 3 | 3 | 0.00E+2 | passed | |
/points/10/ucl | tolerance | 13.370701329602541 | 13.370701329602543 | 1.98E-15 | 15 | passed |
/points/10/lcl | tolerance | 10.657998670397459 | 10.657998670397461 | 2.18E-15 | 15 | passed |
/points/30/moving_average | tolerance | 12.9129 | 12.9129 | 4.89E-16 | 16 | passed |
/points/30/window_size | exact | 3 | 3 | 0.00E+2 | passed | |
/points/30/ucl | tolerance | 13.370701329602541 | 13.370701329602543 | 1.98E-15 | 15 | passed |
/points/30/lcl | tolerance | 10.657998670397459 | 10.657998670397461 | 2.18E-15 | 15 | passed |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Line 41-43: the retained rows become adjacent; excluded rows 9 and 40 (0-based) and two missing values are omitted.
- Montgomery's Example 9.3 uses known mean and sigma; estimated-baseline and full-window cases here are independent Tabelz-convention calculations.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
128 m <- read_dataset("QUAL_MA"); m$x[c(6, 33)] <- NA
129 export_dataset(m, "QUAL_MA_MISSING", "QUAL_MA with x missing in rows 6 and 33 (1-based)", "R stats::rnorm documentation",
130 "Constructed validation data; no third-party license.", c(x = "Float64", phase1 = "Boolean", stage = "String"))
131 mm <- read_dataset("QUAL_MA_MISSING")
132 excluded <- c(9L, 40L)
133 keep <- setdiff(which(!is.na(mm$x)), excluded + 1L)
134 xk <- mm$x[keep]; bk <- mm$phase1[keep]
135 r <- moving(xk, 3, mean(xk[bk]), mean(abs(diff(xk[bk]))) / d2)
136 emit("STAT-QUAL-MA-006", ma_entry, ma_menu, "Missing and excluded rows are omitted before the windows", "QUAL_MA_MISSING",
137 list(value_column = "x", baseline_column = "phase1"),
138 c(ma_outputs(r, c(0L, 5L, 10L, 30L)), list("/excluded_count" = exact(2L, "Two excluded rows."))),
139 c("Line 41-43: the retained rows become adjacent; excluded rows 9 and 40 (0-based) and two missing values are omitted."),
140 kind = "missing_excluded", excluded = excluded)
A constant baseline is rejected
Case STAT-QUAL-MA-007 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 9.3, pp. 428-429; NIST/SEMATECH e-Handbook 6.3.2.1 for d2 moving-range factor
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_MA_CONSTANT.json
Settings compared
baseline_column= "phase1"value_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 32: constant estimated baseline data are rejected; the fragment is the product's wording.
- Montgomery's Example 9.3 uses known mean and sigma; estimated-baseline and full-window cases here are independent Tabelz-convention calculations.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
141 export_dataset(data.frame(x = rep(5, 8), phase1 = rep(TRUE, 8)), "QUAL_MA_CONSTANT", "Constructed: eight equal values",
142 "Hand-constructed", "Constructed validation data; no third-party license.", c(x = "Float64", phase1 = "Boolean"))
143 emit("STAT-QUAL-MA-007", ma_entry, ma_menu, "A constant baseline is rejected", "QUAL_MA_CONSTANT",
144 list(value_column = "x", baseline_column = "phase1"), list(),
145 c("Line 32: constant estimated baseline data are rejected; the fragment is the product's wording."), kind = "invalid_input",
146 error = list(error_class = "SpcMovingAverageExecutionError", message_contains = "no varying measurements"))
A historical mean without a sigma is refused
Case STAT-QUAL-MA-008 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 9.3, pp. 428-429; NIST/SEMATECH e-Handbook 6.3.2.1 for d2 moving-range factor
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_MA.json
Settings compared
historical_mean= 12value_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 12-13: the two historical values must be supplied together.
- Montgomery's Example 9.3 uses known mean and sigma; estimated-baseline and full-window cases here are independent Tabelz-convention calculations.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
147 emit("STAT-QUAL-MA-008", ma_entry, ma_menu, "A historical mean without a sigma is refused", "QUAL_MA",
148 list(value_column = "x", historical_mean = 12), list(),
149 c("Line 12-13: the two historical values must be supplied together."), kind = "invalid_input",
150 error = list(error_class = "ValueError", message_contains = "supplied together"))
MEWMA with lambda 0.2 and a trial limit of 11
Case STAT-QUAL-MEWMA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2.json
Settings compared
decision_limit= 11reference_column= "role"reference_value= "ref"variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/0/statistic | tolerance | 2.3156526425892312 | 2.3156526425892463 | 1.51E-14 | 14 | passed |
/points/9/statistic | tolerance | 6.3199097007134366 | 6.319909700713337 | 9.95E-14 | 13 | passed |
/points/19/statistic | tolerance | 113.85192367474005 | 113.8519236747394 | 6.54E-13 | 14 | passed |
/signal_count | exact | 10 | 10 | 0.00E+2 | passed | |
/asymptotic_factor | tolerance | 0.11111111111111112 | 0.11111111111111112 | 1.18E-18 | 16 | passed |
Convention
- Z_0 = xbar; no reset after a signal (line 77-78).
- Lowry finite-time MEWMA covariance is used; user-set h is not an independently calibrated ARL claim.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
131 mw <- mewma(M0, 0.2, xbar, S)
132 emit("STAT-QUAL-MEWMA-001", mewma_entry, "mewmaMenuItem", "MEWMA with lambda 0.2 and a trial limit of 11", "QUAL_T2",
133 list(variables = as.list(vars), reference_column = "role", reference_value = "ref", decision_limit = 11),
134 list("/points/0/statistic" = tol(mw[1], "Exact finite-time covariance at step 1."),
135 "/points/9/statistic" = tol(mw[10], "Step 10."),
136 "/points/19/statistic" = tol(mw[20], "Step 20."),
137 "/signal_count" = exact(sum(mw > 11), "Points with T^2 > h."),
138 "/asymptotic_factor" = tol(0.2 / 1.8, "Steady-state lambda / (2 - lambda).")),
139 c("Z_0 = xbar; no reset after a signal (line 77-78)."))
Lambda 1 reproduces the individual Hotelling statistic
Case STAT-QUAL-MEWMA-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2.json
Settings compared
decision_limit= 11reference_column= "role"reference_value= "ref"smoothing= 1variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/0/statistic | tolerance | 2.3156526425892534 | 2.315652642589245 | 8.43E-15 | 14 | passed |
/points/15/statistic | tolerance | 34.550817762706906 | 34.55081776270681 | 9.95E-14 | 14 | passed |
Convention
- R check: max |MEWMA(lambda = 1) - T^2| = 0.
- Lowry finite-time MEWMA covariance is used; user-set h is not an independently calibrated ARL claim.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
140 m1 <- mewma(M0, 1, xbar, S)
141 emit("STAT-QUAL-MEWMA-002", mewma_entry, "mewmaMenuItem", "Lambda 1 reproduces the individual Hotelling statistic", "QUAL_T2",
142 list(variables = as.list(vars), reference_column = "role", reference_value = "ref", smoothing = 1, decision_limit = 11),
143 list("/points/0/statistic" = tol(t2[1], "Line 63-65: with lambda = 1 the statistic equals the individual T^2."),
144 "/points/15/statistic" = tol(t2[16], "Same identity at a shifted row.")),
145 c(sprintf("R check: max |MEWMA(lambda = 1) - T^2| = %.3g.", max(abs(m1 - t2)))), kind = "boundary")
A stage column restarts the recursion
Case STAT-QUAL-MEWMA-003 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2.json
Settings compared
decision_limit= 12reference_column= "role"reference_value= "ref"smoothing= 0.3stage_column= "stage"variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/10/step | exact | 1 | 1 | 0.00E+2 | passed | |
/points/10/statistic | tolerance | 14.919454268345625 | 14.91945426834554 | 8.54E-14 | 14 | passed |
/segment_count | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Monitoring stages S1 (rows 41-50) and S2 (rows 51-60), 1-based.
- Lowry finite-time MEWMA covariance is used; user-set h is not an independently calibrated ARL claim.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
146 ms <- mewma(M0, 0.3, xbar, S, stage = d$stage[d$role == "mon"])
147 emit("STAT-QUAL-MEWMA-003", mewma_entry, "mewmaMenuItem", "A stage column restarts the recursion", "QUAL_T2",
148 list(variables = as.list(vars), reference_column = "role", reference_value = "ref", smoothing = 0.3,
149 decision_limit = 12, stage_column = "stage"),
150 list("/points/10/step" = exact(1L, "The first S2 row restarts at step 1 (line 69-71)."),
151 "/points/10/statistic" = tol(ms[11], "Restarted from Z = xbar."),
152 "/segment_count" = exact(2L, "Two stages.")),
153 c("Monitoring stages S1 (rows 41-50) and S2 (rows 51-60), 1-based."), kind = "axis_coverage")
A user-calibrated limit needs a source note
Case STAT-QUAL-MEWMA-004 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2.json
Settings compared
decision_limit= 11limit_provenance= "user_calibrated"reference_column= "role"reference_value= "ref"variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 25-28: a user-calibrated limit requires a source note.
- Lowry finite-time MEWMA covariance is used; user-set h is not an independently calibrated ARL claim.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
154 emit("STAT-QUAL-MEWMA-004", mewma_entry, "mewmaMenuItem", "A user-calibrated limit needs a source note", "QUAL_T2",
155 list(variables = as.list(vars), reference_column = "role", reference_value = "ref", decision_limit = 11,
156 limit_provenance = "user_calibrated"), list(),
157 c("Line 25-28: a user-calibrated limit requires a source note."), kind = "invalid_input",
158 error = list(error_class = "ValueError", message_contains = "source"))
A smoothing weight above 1 is refused
Case STAT-QUAL-MEWMA-005 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2.json
Settings compared
decision_limit= 11reference_column= "role"reference_value= "ref"smoothing= 1.2variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 19: 0 < lambda <= 1.
- Lowry finite-time MEWMA covariance is used; user-set h is not an independently calibrated ARL claim.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
159 emit("STAT-QUAL-MEWMA-005", mewma_entry, "mewmaMenuItem", "A smoothing weight above 1 is refused", "QUAL_T2",
160 list(variables = as.list(vars), reference_column = "role", reference_value = "ref", smoothing = 1.2, decision_limit = 11), list(),
161 c("Line 19: 0 < lambda <= 1."), kind = "invalid_input",
162 error = list(error_class = "ValueError", message_contains = "less than or equal to 1"))
NIST R-chart D4(5): printed table versus full precision
Case STAT-QUAL-PUBCHART-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_NIST_R5.json
Settings compared
run_rules= []subgroup_mode= "constant"subgroup_size= 5y_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/secondary/center_line | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/secondary/upper_control_limit | tolerance | 8.4579965803835542 | 8.457996580383552 | 1.80E-15 | 15 | passed |
Convention
- NIST's printed D4(5)=2.115 is retained as source evidence, not rounded into the full-precision expected output.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
NIST wafer c chart with strict on-limit decision
Case STAT-QUAL-PUBCHART-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc331.htm
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_NIST_WAFERS.json
Settings compared
chart= "c"count_column= "defects"run_rules= []
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/chart/lower_control_limit | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/chart/upper_control_limit | tolerance | 28 | 28.0 | 0.00E+2 | passed | |
/chart/points/2/value | tolerance | 28 | 28.0 | 0.00E+2 | passed | |
/chart/points/23/value | tolerance | 31 | 31.0 | 0.00E+2 | passed | |
/violation_keys | set | ['primary:rule_1:23'] | ['primary:rule_1:23'] | passed |
Convention
- All 25 source counts are transcribed; NIST's stated center and limits have integer precision.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
NIST tabular CUSUM strict H boundary
Case STAT-QUAL-PUBCHART-003 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc323.htm
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_NIST_CUSUM_DERIVED.json
Settings compared
cusum_h= 1cusum_k= 0.5method= "cusum"sigma= 1target= 0y_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/points/0/value | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/primary/points/1/value | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/primary/points/2/value | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/primary/points/3/value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/violation_keys | set | ['primary:rule_1:2'] | ['primary:rule_1:2'] | passed |
Convention
- The four inputs and exact outputs are derived from NIST's formula, not transcribed from a NIST example.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
Montgomery Example 9.2 finite-time EWMA
Case STAT-QUAL-PUBCHART-004 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Examples 9.2-9.3 and Tables 9.10/9.14, pp. 421-429
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_MONTGOMERY_9_2_9_3.json
Settings compared
ewma_l= 2.7ewma_lambda= 0.1method= "ewma"sigma= 1target= 10y_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/points/0/value | tolerance | 9.9450000000000003 | 9.945 | 1.58E-17 | 17 | passed |
/primary/points/1/value | tolerance | 9.7494999999999994 | 9.7495 | 1.11E-17 | 17 | passed |
/primary/points/2/value | tolerance | 9.7035499999999999 | 9.70355 | 2.32E-18 | 18 | passed |
/primary/points/3/value | tolerance | 9.8991950000000006 | 9.899195 | 3.27E-17 | 17 | passed |
/primary/points/4/value | tolerance | 10.125275500000001 | 10.1252755 | 2.39E-16 | 16 | passed |
/primary/points/5/value | tolerance | 10.130747950000002 | 10.130747950000002 | 2.77E-16 | 16 | passed |
/primary/points/6/value | tolerance | 9.9216731550000024 | 9.921673155000002 | 4.68E-17 | 17 | passed |
/primary/points/7/value | tolerance | 10.075505839500003 | 10.075505839500003 | 4.47E-16 | 16 | passed |
/primary/points/8/value | tolerance | 9.9879552555500037 | 9.987955255550004 | 4.14E-17 | 17 | passed |
/primary/points/9/value | tolerance | 10.023159729995005 | 10.023159729995005 | 4.03E-16 | 16 | passed |
/primary/points/10/value | tolerance | 9.9238437569955043 | 9.923843756995504 | 4.95E-17 | 17 | passed |
/primary/points/11/value | tolerance | 10.078459381295954 | 10.078459381295954 | 4.66E-16 | 16 | passed |
/primary/points/12/value | tolerance | 10.121613443166359 | 10.121613443166359 | 3.08E-16 | 16 | passed |
/primary/points/13/value | tolerance | 10.049452098849722 | 10.049452098849722 | 2.07E-16 | 16 | passed |
/primary/points/14/value | tolerance | 10.05250688896475 | 10.05250688896475 | 2.41E-17 | 17 | passed |
/primary/points/15/value | tolerance | 9.9842562000682751 | 9.984256200068275 | 2.22E-17 | 17 | passed |
/primary/points/16/value | tolerance | 10.047830580061447 | 10.047830580061447 | 1.37E-16 | 16 | passed |
/primary/points/17/value | tolerance | 10.074047522055304 | 10.074047522055304 | 7.14E-17 | 17 | passed |
/primary/points/18/value | tolerance | 9.9186427698497734 | 9.918642769849773 | 4.40E-17 | 17 | passed |
/primary/points/19/value | tolerance | 10.010778492864796 | 10.010778492864796 | 2.63E-16 | 16 | passed |
/primary/points/20/value | tolerance | 10.099700643578316 | 10.099700643578316 | 3.17E-16 | 16 | passed |
/primary/points/21/value | tolerance | 10.022730579220484 | 10.022730579220484 | 1.59E-16 | 16 | passed |
/primary/points/22/value | tolerance | 10.249457521298435 | 10.249457521298435 | 1.25E-16 | 16 | passed |
/primary/points/23/value | tolerance | 10.374511769168592 | 10.374511769168592 | 3.19E-17 | 17 | passed |
/primary/points/24/value | tolerance | 10.397060592251734 | 10.397060592251734 | 3.76E-16 | 16 | passed |
/primary/points/25/value | tolerance | 10.465354533026561 | 10.465354533026561 | 1.57E-16 | 16 | passed |
/primary/points/26/value | tolerance | 10.456819079723905 | 10.456819079723905 | 1.19E-16 | 16 | passed |
/primary/points/27/value | tolerance | 10.573137171751515 | 10.573137171751515 | 2.40E-16 | 16 | passed |
/primary/points/28/value | tolerance | 10.646823454576364 | 10.646823454576364 | 4.12E-16 | 16 | passed |
/primary/points/29/value | tolerance | 10.634141109118728 | 10.634141109118728 | 1.03E-16 | 17 | passed |
/primary/point_upper_limits | sequence | ['10.27', '10.363247849270991', '10.424003172157946', '10.46 | [10.27, 10.36324784927099, 10.424003172157946, 10.4674620186 | passed | ||
/primary/point_lower_limits | sequence | ['9.7300000000000004', '9.6367521507290093', '9.575996827842 | [9.73, 9.63675215072901, 9.575996827842054, 9.53253798132896 | passed | ||
/violation_keys | set | ['primary:rule_1:28', 'primary:rule_1:29'] | ['primary:rule_1:28', 'primary:rule_1:29'] | passed |
Convention
- All 30 printed EWMA values are retained at source precision in reference_data/published/quality/PUB_MONTGOMERY_EWMA_SEQUENCE.json sha256=89c860d1dabe981cfed4e566dd0fd7976dc6189c6945d22ecb5a563685b4db09
- Expected values are independently recursed from the printed input series; the source's rounded output is not treated as full precision.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
Montgomery Example 9.3 all 30 moving averages
Case STAT-QUAL-PUBCHART-005 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Examples 9.2-9.3 and Tables 9.10/9.14, pp. 421-429
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_MONTGOMERY_9_2_9_3.json
Settings compared
historical_mean= 10historical_sigma= 1value_column= "value"window_width= 5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/points/0/moving_average | tolerance | 9.4499999999999993 | 9.45 | 1.05E-17 | 17 | passed |
/points/1/moving_average | tolerance | 8.7200000000000006 | 8.719999999999999 | 1.74E-15 | 15 | passed |
/points/2/moving_average | tolerance | 8.9100000000000001 | 8.909999999999998 | 1.73E-15 | 15 | passed |
/points/3/moving_average | tolerance | 9.5975000000000001 | 9.5975 | 4.21E-17 | 17 | passed |
/points/4/moving_average | tolerance | 10.109999999999999 | 10.11 | 4.32E-16 | 16 | passed |
/points/5/moving_average | tolerance | 10.256 | 10.256 | 2.27E-16 | 16 | passed |
/points/6/moving_average | tolerance | 10.266 | 10.266 | 1.42E-17 | 17 | passed |
/points/7/moving_average | tolerance | 10.699999999999999 | 10.7 | 2.89E-16 | 16 | passed |
/points/8/moving_average | tolerance | 10.208 | 10.208000000000002 | 1.96E-15 | 15 | passed |
/points/9/moving_average | tolerance | 9.8439999999999994 | 9.844 | 1.74E-17 | 17 | passed |
/points/10/moving_average | tolerance | 9.6140000000000008 | 9.614 | 3.26E-17 | 17 | passed |
/points/11/moving_average | tolerance | 10.300000000000001 | 10.3 | 2.89E-16 | 16 | passed |
/points/12/moving_average | tolerance | 10.109999999999999 | 10.11 | 4.32E-16 | 16 | passed |
/points/13/moving_average | tolerance | 10.15 | 10.149999999999999 | 1.42E-15 | 15 | passed |
/points/14/moving_average | tolerance | 10.098000000000001 | 10.097999999999999 | 2.02E-15 | 15 | passed |
/points/15/moving_average | tolerance | 10.166 | 10.166 | 3.69E-16 | 16 | passed |
/points/16/moving_average | tolerance | 9.9960000000000004 | 9.995999999999999 | 1.74E-15 | 15 | passed |
/points/17/moving_average | tolerance | 9.9559999999999995 | 9.956 | 1.68E-17 | 17 | passed |
/points/18/moving_average | tolerance | 9.7799999999999994 | 9.780000000000001 | 1.74E-15 | 15 | passed |
/points/19/moving_average | tolerance | 9.9320000000000004 | 9.931999999999999 | 1.79E-15 | 15 | passed |
/points/20/moving_average | tolerance | 10.238 | 10.238 | 4.55E-16 | 16 | passed |
/points/21/moving_average | tolerance | 9.9800000000000004 | 9.98 | 2.63E-17 | 17 | passed |
/points/22/moving_average | tolerance | 10.375999999999999 | 10.376 | 4.46E-16 | 16 | passed |
/points/23/moving_average | tolerance | 10.972 | 10.972 | 4.69E-16 | 16 | passed |
/points/24/moving_average | tolerance | 10.923999999999999 | 10.924 | 4.88E-16 | 16 | passed |
/points/25/moving_average | tolerance | 10.960000000000001 | 10.959999999999999 | 1.92E-15 | 15 | passed |
/points/26/moving_average | tolerance | 11.17 | 11.17 | 7.11E-17 | 17 | passed |
/points/27/moving_average | tolerance | 11.036 | 11.036 | 4.12E-16 | 16 | passed |
/points/28/moving_average | tolerance | 10.997999999999999 | 10.998000000000001 | 2.11E-15 | 15 | passed |
/points/29/moving_average | tolerance | 10.981999999999999 | 10.982 | 3.18E-16 | 16 | passed |
/points/0/window_size | exact | 1 | 1 | 0.00E+2 | passed | |
/points/4/window_size | exact | 5 | 5 | 0.00E+2 | passed | |
/points/4/ucl | tolerance | 11.341640786499873 | 11.341640786499873 | 1.72E-16 | 16 | passed |
Convention
- Published averages are transcribed at their printed decimals; steady-state printed limits 8.66/11.34 remain distinct from full-precision products.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
Lucas-Saccucci Table 1 EWMA finite-time decisions
Case STAT-QUAL-PUBCHART-006 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- Lucas and Saccucci, Technometrics 32(1), 1990, Table 1
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_LUCAS_EWMA.json
Settings compared
ewma_l= 3ewma_lambda= 0.25method= "ewma"sigma= 1target= 0y_column= "value"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/points/0/value | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/primary/points/1/value | tolerance | 0.0625 | 0.0625 | 0.00E-2 | passed | |
/primary/points/2/value | tolerance | 0.046875 | 0.046875 | 0.00E-4 | passed | |
/primary/points/3/value | tolerance | -0.16484375000000001 | -0.16484375 | 1.10E-18 | 17 | passed |
/primary/points/4/value | tolerance | -0.32363281250000003 | -0.32363281250000003 | 3.31E-18 | 16 | passed |
/primary/points/5/value | tolerance | -0.542724609375 | -0.542724609375 | 0.00E-10 | passed | |
/primary/points/6/value | tolerance | -0.03204345703125 | -0.03204345703125 | 0.00E-12 | passed | |
/primary/points/7/value | tolerance | -0.17403259277343749 | -0.1740325927734375 | 4.45E-18 | 16 | passed |
/primary/points/8/value | tolerance | 0.11947555541992189 | 0.11947555541992189 | 3.90E-18 | 16 | passed |
/primary/points/9/value | tolerance | -0.1353933334350586 | -0.1353933334350586 | 4.85E-18 | 16 | passed |
/primary/points/10/value | tolerance | 0.19845499992370602 | 0.19845499992370602 | 1.38E-18 | 17 | passed |
/primary/points/11/value | tolerance | 0.27384124994277953 | 0.27384124994277953 | 8.66E-20 | 18 | passed |
/primary/points/12/value | tolerance | 0.85538093745708466 | 0.8553809374570847 | 4.24E-18 | 17 | passed |
/primary/points/13/value | tolerance | 0.81653570309281354 | 0.8165357030928135 | 3.77E-18 | 17 | passed |
/primary/points/14/value | tolerance | 0.88740177731961023 | 0.8874017773196102 | 1.12E-19 | 18 | passed |
/primary/points/15/value | tolerance | 1.1655513329897076 | 1.1655513329897076 | 1.09E-17 | 17 | passed |
/primary/points/16/value | tolerance | 1.2241634997422808 | 1.2241634997422808 | 1.93E-17 | 16 | passed |
/primary/points/17/value | tolerance | 1.3931226248067106 | 1.3931226248067106 | 3.67E-17 | 16 | passed |
/primary/points/18/value | tolerance | 1.2448419686050329 | 1.244841968605033 | 3.36E-17 | 16 | passed |
/violation_keys | set | ['primary:rule_1:15', 'primary:rule_1:16', 'primary:rule_1:1 | ['primary:rule_1:15', 'primary:rule_1:16', 'primary:rule_1:1 | passed |
Convention
- All 19 printed and independently derived EWMA values are retained in reference_data/published/quality/PUB_LUCAS_EWMA_SEQUENCE.json sha256=522097b845c386807fb62013c290111e76329f7f0865d9fd4bfbe565f7f54f0d
- Table displays asymptotic limits +/-1.134; product comparisons use finite-time limits from the printed lambda/L inputs.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
Minitab Z-MR printed factors versus full precision
Case STAT-QUAL-PUBCHART-007 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- https://support.minitab.com/en-us/minitab/help-and-how-to/quality-and-process-improvement/control-charts/how-to/variables-charts-for-individuals/z-mr-chart/methods-and-formulas/methods-and-formulas/
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_ZMR_DERIVED.json
Settings compared
measurement_column= "value"product_column= "product"products= [{"product": "A", "center": 0, "sigma": 1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/mr_chart/upper_control_limit | tolerance | 3.6858865663777776 | 3.6858865663777776 | 3.77E-17 | 16 | passed |
Convention
- Minitab's factor display is rounded. The product uses d2=2/sqrt(pi), d3=sqrt(2-4/pi), with D4=3.2665319192886013 derived.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
Benneyan geometric support translated to Tabelz g chart
Case STAT-QUAL-PUBCHART-008 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- Benneyan, Health Care Management Science 4(4), 2001, Example 1, p. 311
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_BENNEYAN_G_TRANSLATED.json
Settings compared
baseline= {"column": "phase", "op": "eq", "value": "reference"}chart= "g"count_column= "between"run_rules= []
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/chart/center_line | tolerance | 42.200000000000003 | 42.2 | 1.58E-16 | 17 | passed |
/chart/lower_control_limit | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/chart/upper_control_limit | tolerance | 276 | 276.0 | 0.00E+2 | passed | |
/violation_keys | set | ['primary:rule_1:6'] | ['primary:rule_1:6'] | passed |
Convention
- The source reports a zero-based mean, not these constructed rows or quantile limits. One-based center 42.2 is a support translation.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
Lowry Table 4 MEWMA from printed inputs
Case STAT-QUAL-PUBCHART-009 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- Lowry, Woodall, Champ and Rigdon, Technometrics 34(1), 1992, Table 4
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_LOWRY_TABLE4.json
Settings compared
decision_limit= 8.79reference_column= "phase"reference_value= "reference"smoothing= 0.1variables= ["x", "y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/baseline/mean/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/baseline/covariance/0/1 | tolerance | 0.5 | 0.49999999999999994 | 5.55E-17 | 15 | passed |
/points/0/statistic | tolerance | 3.2884000000000002 | 3.2884000000000015 | 1.34E-15 | 15 | passed |
/points/1/statistic | tolerance | 3.1771955801104972 | 3.1771955801104985 | 1.32E-15 | 15 | passed |
/points/2/statistic | tolerance | 7.3680914966951878 | 7.3680914966951905 | 2.68E-15 | 15 | passed |
/points/3/statistic | tolerance | 5.2590722161042454 | 5.259072216104246 | 8.45E-16 | 15 | passed |
/points/4/statistic | tolerance | 1.0920333271364406 | 1.0920333271364404 | 1.87E-16 | 15 | passed |
/points/5/statistic | tolerance | 1.2799549639089192 | 1.2799549639089187 | 4.81E-16 | 15 | passed |
/points/6/statistic | tolerance | 5.6610515109062725 | 5.661051510906273 | 8.43E-16 | 15 | passed |
/points/7/statistic | tolerance | 8.3244233089597941 | 8.324423308959794 | 1.12E-18 | 18 | passed |
/points/8/statistic | tolerance | 9.6449826904905347 | 9.644982690490535 | 6.41E-18 | 18 | passed |
/points/9/statistic | tolerance | 17.207444727815862 | 17.207444727815872 | 1.02E-14 | 15 | passed |
/signal_count | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- All ten printed Z vectors/T-squared values and independently derived sequences are retained in reference_data/published/quality/PUB_LOWRY_MEWMA_SEQUENCE.json sha256=fd32e4c159d9db8e462456d7fccb364c3c803d4b92375e2b1ac83968424b3cab
- MewmaPoint's public contract exposes T-squared, signal, and row identity, but not the internal Z vector; no public Z output is claimed.
- Published T-squared 3.17/9.65 differ from calculations using the paper's rounded inputs; both are retained without widening precision silently.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
Montgomery Example 11.1 subgroup Hotelling full-precision limit
Case STAT-QUAL-PUBCHART-010 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Published inputs and independent analytic calculation
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., Example 11.1
- Reference software
- not recorded
- Reference script
- generators/chart_published_reference.py · sha256 18ce58af14ce93a9
- Dataset
- reference_data/datasets/PUB_MONTGOMERY_11_1_DERIVED.json
Settings compared
alpha= 0.001reference_column= "phase"reference_value= "reference"subgroup_column= "subgroup"subgroup_size= 10variables= ["x", "y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/baseline/t_squared_ucl | tolerance | 15.165030183000001 | 15.16503018300991 | 9.91E-12 | 12 | passed |
/baseline/reference_mean_generalized_variance | tolerance | 1 | 0.9999999999999997 | 3.33E-16 | 15 | passed |
/baseline/sigma_determinant | tolerance | 1.125 | 1.1249999999999998 | 2.22E-16 | 15 | passed |
Convention
- Montgomery's 15.16 is approximate; a full-precision evaluation is 15.1650301830. Rows are constructed, not presented by Montgomery.
- Printed sequence transcription: generators/chart_published_sequences.py sha256=84346e2b1f2d88470793ff776da6b7386f4edc7e1a9d4ade779d8e15ce8806c5
Reference code
Standardized Z-MR across three products
Case STAT-QUAL-SHORTRUN-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Minitab Z-MR Chart Methods and Formulas, https://support.minitab.com/en-us/minitab/help-and-how-to/quality-and-process-improvement/control-charts/how-to/variables-charts-for-individuals/z-mr-chart/methods-and-formulas/methods-and-formulas/
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_SHORTRUN.json
Settings compared
measurement_column= "x"product_column= "product"products= [{"product": "A", "center": 10, "sigma": 0.5}, {"product": "B", "center": 25, "sigma": 1.2}, {"product": "C", "center": 3, "sigma": 0.1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations/0/z | tolerance | 0.063800000000000523 | 0.06380000000000052 | 4.05E-20 | 18 | passed |
/observations/0/moving_range | absent | None | passed | |||
/observations/1/z | tolerance | -0.20499999999999829 | -0.2049999999999983 | 4.70E-18 | 16 | passed |
/observations/1/moving_range | tolerance | 0.26879999999999882 | 0.2687999999999988 | 2.34E-18 | 17 | passed |
/observations/2/z | tolerance | -1.0705000000000009 | -1.070500000000001 | 4.72E-18 | 17 | passed |
/observations/2/moving_range | tolerance | 0.8655000000000026 | 0.8655000000000026 | 5.86E-19 | 18 | passed |
/observations/13/z | tolerance | 3.3999999999999986 | 3.399999999999995 | 3.57E-15 | 14 | passed |
/observations/13/moving_range | tolerance | 4.0107999999999997 | 4.010799999999996 | 3.55E-15 | 15 | passed |
/observations/14/z | tolerance | 0.98383333333333201 | 0.983833333333332 | 4.79E-18 | 17 | passed |
/observations/14/moving_range | tolerance | 2.4161666666666664 | 2.416166666666663 | 3.60E-15 | 14 | passed |
/observations/35/z | tolerance | 1.4670000000000005 | 1.4670000000000005 | 2.58E-17 | 16 | passed |
/observations/35/moving_range | tolerance | 0.86833333333333462 | 0.8683333333333346 | 2.67E-18 | 17 | passed |
/observations/13/signal_reasons | contains | ['Z'] | ['Z above UCL', 'MR above UCL'] | passed |
Convention
- Reset at product change is off, so cross-product pairs contribute moving ranges (line 28-31).
- MR upper limit d2 + 3 d3 = 3.68588656637778.
- Minitab prints rounded Z-MR factors; the generator uses d2=2/sqrt(pi), d3=sqrt(2-4/pi), with full-precision MR UCL d2+3d3.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
186 all_valid <- rep(TRUE, 36)
187 r <- short_run(s$x, s$product, all_valid)
188 emit("STAT-QUAL-SHORTRUN-001", sr_entry, sr_menu, "Standardized Z-MR across three products", "QUAL_SHORTRUN",
189 list(measurement_column = "x", product_column = "product", products = products),
190 c(sr_outputs(r, c(0L, 1L, 2L, 13L, 14L, 35L)),
191 list("/observations/13/signal_reasons" = list(comparison = "contains", values = list("Z"),
192 rationale = "Row 14 (1-based) lies 3.4 sigma above its product centre: z > 3."))),
193 c("Reset at product change is off, so cross-product pairs contribute moving ranges (line 28-31).",
194 sprintf("MR upper limit d2 + 3 d3 = %.15g.", d2 + 3 * d3)))
Reset the moving range at each product change
Case STAT-QUAL-SHORTRUN-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Minitab Z-MR Chart Methods and Formulas, https://support.minitab.com/en-us/minitab/help-and-how-to/quality-and-process-improvement/control-charts/how-to/variables-charts-for-individuals/z-mr-chart/methods-and-formulas/methods-and-formulas/
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_SHORTRUN.json
Settings compared
measurement_column= "x"product_column= "product"products= [{"product": "A", "center": 10, "sigma": 0.5}, {"product": "B", "center": 25, "sigma": 1.2}, {"product": "C", "center": 3, "sigma": 0.1}]reset_on_product_change= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations/1/z | tolerance | -0.20499999999999829 | -0.2049999999999983 | 4.70E-18 | 16 | passed |
/observations/1/moving_range | tolerance | 0.26879999999999882 | 0.2687999999999988 | 2.34E-18 | 17 | passed |
/observations/2/z | tolerance | -1.0705000000000009 | -1.070500000000001 | 4.72E-18 | 17 | passed |
/observations/2/moving_range | absent | None | passed | |||
/observations/3/z | tolerance | -1.9280000000000008 | -1.9280000000000008 | 2.42E-17 | 16 | passed |
/observations/3/moving_range | tolerance | 0.85749999999999993 | 0.8574999999999999 | 1.05E-18 | 17 | passed |
/observations/5/z | tolerance | 1.1560000000000015 | 1.1560000000000015 | 2.92E-17 | 16 | passed |
/observations/5/moving_range | absent | None | passed | |||
/observations/6/z | tolerance | -0.56360000000000099 | -0.563600000000001 | 9.25E-19 | 17 | passed |
/observations/6/moving_range | absent | None | passed |
Convention
- A product transition starts a new moving-range sequence (line 30-31).
- Minitab prints rounded Z-MR factors; the generator uses d2=2/sqrt(pi), d3=sqrt(2-4/pi), with full-precision MR UCL d2+3d3.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
195 r <- short_run(s$x, s$product, all_valid, reset = TRUE)
196 emit("STAT-QUAL-SHORTRUN-002", sr_entry, sr_menu, "Reset the moving range at each product change", "QUAL_SHORTRUN",
197 list(measurement_column = "x", product_column = "product", products = products, reset_on_product_change = TRUE),
198 sr_outputs(r, c(1L, 2L, 3L, 5L, 6L)), c("A product transition starts a new moving-range sequence (line 30-31)."),
199 kind = "axis_coverage")
A stage column breaks adjacency
Case STAT-QUAL-SHORTRUN-003 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Minitab Z-MR Chart Methods and Formulas, https://support.minitab.com/en-us/minitab/help-and-how-to/quality-and-process-improvement/control-charts/how-to/variables-charts-for-individuals/z-mr-chart/methods-and-formulas/methods-and-formulas/
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_SHORTRUN.json
Settings compared
measurement_column= "x"product_column= "product"products= [{"product": "A", "center": 10, "sigma": 0.5}, {"product": "B", "center": 25, "sigma": 1.2}, {"product": "C", "center": 3, "sigma": 0.1}]stage_column= "stage"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations/19/z | tolerance | 0.25740000000000052 | 0.2574000000000005 | 2.72E-18 | 16 | passed |
/observations/19/moving_range | tolerance | 2.2378 | 2.2378 | 1.14E-17 | 17 | passed |
/observations/20/z | tolerance | -0.85183333333333466 | -0.8518333333333347 | 3.53E-18 | 17 | passed |
/observations/20/moving_range | absent | None | passed | |||
/observations/21/z | tolerance | 0.90608333333333257 | 0.9060833333333326 | 4.53E-18 | 17 | passed |
/observations/21/moving_range | tolerance | 1.7579166666666672 | 1.7579166666666672 | 3.81E-17 | 16 | passed |
Convention
- Stage I is rows 1-20 and stage II rows 21-36 (1-based).
- Minitab prints rounded Z-MR factors; the generator uses d2=2/sqrt(pi), d3=sqrt(2-4/pi), with full-precision MR UCL d2+3d3.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
200 r <- short_run(s$x, s$product, all_valid, stage = s$stage)
201 emit("STAT-QUAL-SHORTRUN-003", sr_entry, sr_menu, "A stage column breaks adjacency", "QUAL_SHORTRUN",
202 list(measurement_column = "x", product_column = "product", stage_column = "stage", products = products),
203 sr_outputs(r, c(19L, 20L, 21L)), c("Stage I is rows 1-20 and stage II rows 21-36 (1-based)."), kind = "axis_coverage")
Missing and excluded rows break adjacency but stay in the table
Case STAT-QUAL-SHORTRUN-004 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Minitab Z-MR Chart Methods and Formulas, https://support.minitab.com/en-us/minitab/help-and-how-to/quality-and-process-improvement/control-charts/how-to/variables-charts-for-individuals/z-mr-chart/methods-and-formulas/methods-and-formulas/
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_SHORTRUN_MISSING.json
Settings compared
measurement_column= "x"product_column= "product"products= [{"product": "A", "center": 10, "sigma": 0.5}, {"product": "B", "center": 25, "sigma": 1.2}, {"product": "C", "center": 3, "sigma": 0.1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations/3/z | absent | None | passed | |||
/observations/3/moving_range | absent | None | passed | |||
/observations/4/z | tolerance | -0.83158333333333445 | -0.8315833333333345 | 1.25E-18 | 17 | passed |
/observations/4/moving_range | absent | None | passed | |||
/observations/7/z | absent | None | passed | |||
/observations/7/moving_range | absent | None | passed | |||
/observations/8/z | tolerance | -0.75916666666666788 | -0.7591666666666679 | 2.45E-18 | 17 | passed |
/observations/8/moving_range | absent | None | passed | |||
/observations/25/z | absent | None | passed | |||
/observations/25/moving_range | absent | None | passed | |||
/observations/26/z | tolerance | 0.28358333333333263 | 0.28358333333333263 | 2.26E-18 | 17 | passed |
/observations/26/moving_range | absent | None | passed | |||
/observations/3/status | exact | excluded | excluded | passed | ||
/observations/7/status | exact | missing | missing | passed |
Convention
- Rows 3 and 25 (0-based) are excluded; row 7 (0-based) is missing.
- Minitab prints rounded Z-MR factors; the generator uses d2=2/sqrt(pi), d3=sqrt(2-4/pi), with full-precision MR UCL d2+3d3.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
204 m <- read_dataset("QUAL_SHORTRUN"); m$x[8] <- NA
205 export_dataset(m, "QUAL_SHORTRUN_MISSING", "QUAL_SHORTRUN with x missing in row 8 (1-based)", "R stats::rnorm documentation",
206 "Constructed validation data; no third-party license.", c(x = "Float64", product = "String", stage = "String"))
207 mm <- read_dataset("QUAL_SHORTRUN_MISSING")
208 valid <- !is.na(mm$x); valid[c(3, 25) + 1] <- FALSE
209 r <- short_run(mm$x, mm$product, valid)
210 emit("STAT-QUAL-SHORTRUN-004", sr_entry, sr_menu, "Missing and excluded rows break adjacency but stay in the table", "QUAL_SHORTRUN_MISSING",
211 list(measurement_column = "x", product_column = "product", products = products),
212 c(sr_outputs(r, c(3L, 4L, 7L, 8L, 25L, 26L)),
213 list("/observations/3/status" = exact("excluded", "Excluded rows are retained in the detail table (line 47-48)."),
214 "/observations/7/status" = exact("missing", "A missing measurement."))),
215 c("Rows 3 and 25 (0-based) are excluded; row 7 (0-based) is missing."), kind = "missing_excluded", excluded = c(3L, 25L))
A product without parameters is an input error
Case STAT-QUAL-SHORTRUN-005 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Minitab Z-MR Chart Methods and Formulas, https://support.minitab.com/en-us/minitab/help-and-how-to/quality-and-process-improvement/control-charts/how-to/variables-charts-for-individuals/z-mr-chart/methods-and-formulas/methods-and-formulas/
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_SHORTRUN.json
Settings compared
measurement_column= "x"product_column= "product"products= [{"product": "A", "center": 10, "sigma": 0.5}, {"product": "B", "center": 25, "sigma": 1.2}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 13-14: every active product must have a record.
- Minitab prints rounded Z-MR factors; the generator uses d2=2/sqrt(pi), d3=sqrt(2-4/pi), with full-precision MR UCL d2+3d3.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
216 emit("STAT-QUAL-SHORTRUN-005", sr_entry, sr_menu, "A product without parameters is an input error", "QUAL_SHORTRUN",
217 list(measurement_column = "x", product_column = "product", products = products[1:2]), list(),
218 c("Line 13-14: every active product must have a record."), kind = "invalid_input",
219 error = list(error_class = "ShortRunExecutionError", message_contains = "parameters were supplied for product"))
A zero sigma is refused
Case STAT-QUAL-SHORTRUN-006 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- Minitab Z-MR Chart Methods and Formulas, https://support.minitab.com/en-us/minitab/help-and-how-to/quality-and-process-improvement/control-charts/how-to/variables-charts-for-individuals/z-mr-chart/methods-and-formulas/methods-and-formulas/
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_ma_shortrun.R · sha256 ad9724ed63c7b629
- Dataset
- reference_data/datasets/QUAL_SHORTRUN.json
Settings compared
measurement_column= "x"product_column= "product"products= [{"product": "A", "center": 10, "sigma": 0}, {"product": "B", "center": 25, "sigma": 1.2}, {"product": "C", "center": 3, "sigma": 0.1}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 14: sigma must be strictly positive.
- Minitab prints rounded Z-MR factors; the generator uses d2=2/sqrt(pi), d3=sqrt(2-4/pi), with full-precision MR UCL d2+3d3.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
220 emit("STAT-QUAL-SHORTRUN-006", sr_entry, sr_menu, "A zero sigma is refused", "QUAL_SHORTRUN",
221 list(measurement_column = "x", product_column = "product",
222 products = list(list(product = "A", center = 10, sigma = 0), products[[2]], products[[3]])), list(),
223 c("Line 14: sigma must be strictly positive."), kind = "invalid_input",
224 error = list(error_class = "ValueError", message_contains = "must be finite and positive"))
Individuals and moving range with the default rules
Case STAT-QUAL-SPC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_IMR.json
Settings compared
y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 50.630482857142859 | 50.63048285714286 | 3.23E-16 | 17 | passed |
/primary/upper_control_limit | tolerance | 57.42612871892279 | 57.42612871892279 | 2.85E-17 | 18 | passed |
/primary/lower_control_limit | tolerance | 43.834836995362927 | 43.83483699536293 | 3.25E-16 | 17 | passed |
/within_sigma | tolerance | 2.2652152872599767 | 2.265215287259977 | 4.17E-16 | 15 | passed |
/secondary/center_line | tolerance | 2.5560217391304345 | 2.556021739130435 | 4.55E-16 | 15 | passed |
/secondary/upper_control_limit | tolerance | 8.3493265972651276 | 8.349326597265128 | 3.01E-18 | 18 | passed |
/secondary/lower_control_limit | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/primary/points/0/value | tolerance | 48.633299999999998 | 48.6333 | 4.20E-16 | 17 | passed |
/secondary/points/0/value | tolerance | 2.3980999999999995 | 2.3980999999999995 | 4.57E-17 | 16 | passed |
/violation_keys | set | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | passed |
Convention
- Rules 2-4 are on by default (line 216-217).
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
114 set.seed(20261001)
115 x <- round(rnorm(70, 50, 2), 4)
116 x[20] <- 62 # beyond the limits
117 x[30:38] <- round(51 + abs(rnorm(9, 1.2, 0.3)), 4) # nine above the centre
118 x[45:50] <- round(seq(46, 52, length.out = 6), 4) # six rising
119 x[55:57] <- c(55.5, 49.8, 55.9) # two of three beyond 2 sigma
120 export_dataset(data.frame(t = seq_along(x), x = x, phase = ifelse(seq_along(x) <= 40, 1L, 2L)),
121 "QUAL_SPC_IMR", "Constructed individuals series, seed 20261001, with an outlier, a shift, a trend and a two-of-three pattern",
122 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
123 c(t = "Int64", x = "Float64", phase = "Int64"))
124 d <- read_dataset("QUAL_SPC_IMR")
125 default_rules <- c("rule_2", "rule_3", "rule_4")
126 all_rules <- c(default_rules, "rule_5", "rule_6", "rule_7", "rule_8")
127 r <- imr(d$x, default_rules)
128 emit("STAT-QUAL-SPC-001", "Individuals and moving range with the default rules", "QUAL_SPC_IMR",
129 list(y_column = "x"), imr_outputs(r, d$x, "Rules 1-4 on the I chart and rule 1 on the MR chart."),
130 c("Rules 2-4 are on by default (line 216-217)."))
Individuals chart with all eight rules
Case STAT-QUAL-SPC-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_IMR.json
Settings compared
run_rules= ["rule_2", "rule_3", "rule_4", "rule_5", "rule_6", "rule_7", "rule_8"]y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/violation_keys | set | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | passed |
Convention
- Zones use the I chart's sigma = MR-bar/d2 (line 238-240).
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
131 r <- imr(d$x, all_rules)
132 emit("STAT-QUAL-SPC-002", "Individuals chart with all eight rules", "QUAL_SPC_IMR",
133 list(y_column = "x", run_rules = as.list(all_rules)), list("/violation_keys" = set_of(r$keys, "Rules 1-8 evaluated independently in R.")),
134 c("Zones use the I chart's sigma = MR-bar/d2 (line 238-240)."), kind = "axis_coverage")
Phase I baseline freezes the limits from the first 40 points
Case STAT-QUAL-SPC-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_IMR.json
Settings compared
baseline= {"column": "phase", "op": "le", "value": 1}y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 50.892407499999997 | 50.8924075 | 3.56E-16 | 17 | passed |
/primary/upper_control_limit | tolerance | 57.189090708123018 | 57.18909070812302 | 2.03E-16 | 17 | passed |
/primary/lower_control_limit | tolerance | 44.595724291876977 | 44.59572429187698 | 4.92E-16 | 16 | passed |
/within_sigma | tolerance | 2.098894402707673 | 2.098894402707673 | 2.37E-17 | 16 | passed |
/secondary/center_line | tolerance | 2.3683487179487175 | 2.3683487179487175 | 1.44E-17 | 17 | passed |
/secondary/upper_control_limit | tolerance | 7.736286683185722 | 7.736286683185722 | 9.30E-18 | 17 | passed |
/secondary/lower_control_limit | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/primary/points/0/value | tolerance | 48.633299999999998 | 48.6333 | 4.20E-16 | 17 | passed |
/secondary/points/0/value | tolerance | 2.3980999999999995 | 2.3980999999999995 | 4.57E-17 | 16 | passed |
/violation_keys | set | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | passed | ||
/baseline_count | exact | 40 | 40 | 0.00E+2 | passed |
Convention
- Line 25-27: the baseline estimates the limits and every point is still plotted and evaluated.
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
135 rb <- imr(d$x, default_rules, baseline = d$phase <= 1)
136 emit("STAT-QUAL-SPC-003", "Phase I baseline freezes the limits from the first 40 points", "QUAL_SPC_IMR",
137 list(y_column = "x", baseline = list(column = "phase", op = "le", value = 1)),
138 c(imr_outputs(rb, d$x, "All 70 points are evaluated against the baseline limits."),
139 list("/baseline_count" = exact(40L, "Forty baseline points."))),
140 c("Line 25-27: the baseline estimates the limits and every point is still plotted and evaluated."), kind = "axis_coverage")
Missing and excluded rows are omitted before the moving ranges
Case STAT-QUAL-SPC-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_IMR_MISSING.json
Settings compared
y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 50.582260606060608 | 50.5822606060606 | 7.41E-15 | 15 | passed |
/primary/upper_control_limit | tolerance | 57.603717918357404 | 57.6037179183574 | 7.15E-15 | 15 | passed |
/primary/lower_control_limit | tolerance | 43.560803293763811 | 43.560803293763804 | 6.67E-15 | 15 | passed |
/within_sigma | tolerance | 2.3404857707655977 | 2.340485770765598 | 4.61E-16 | 15 | passed |
/secondary/center_line | tolerance | 2.6409553846153839 | 2.6409553846153844 | 4.71E-16 | 15 | passed |
/secondary/upper_control_limit | tolerance | 8.6267650612632565 | 8.626765061263258 | 1.76E-15 | 15 | passed |
/secondary/lower_control_limit | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/primary/points/0/value | tolerance | 48.633299999999998 | 48.6333 | 4.20E-16 | 17 | passed |
/secondary/points/0/value | tolerance | 2.3980999999999995 | 2.3980999999999995 | 4.57E-17 | 16 | passed |
/violation_keys | set | ['primary:rule_1:17', 'primary:rule_2:35', 'primary:rule_3:4 | ['primary:rule_1:17', 'primary:rule_2:35', 'primary:rule_3:4 | passed |
Convention
- Line 75-77: missing observations are omitted and the adjacent retained values become successive.
- Excluded rows (0-based 2 and 40) are removed from the plotted source.
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
143 m <- read_dataset("QUAL_SPC_IMR")
144 m$x[c(8, 61)] <- NA
145 export_dataset(m, "QUAL_SPC_IMR_MISSING", "QUAL_SPC_IMR with x missing in rows 8 and 61 (1-based)",
146 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
147 c(t = "Int64", x = "Float64", phase = "Int64"))
148 mm <- read_dataset("QUAL_SPC_IMR_MISSING")
149 excluded <- c(2L, 40L)
150 xm <- mm$x[-(excluded + 1L)]; xm <- xm[!is.na(xm)]
151 emit("STAT-QUAL-SPC-004", "Missing and excluded rows are omitted before the moving ranges", "QUAL_SPC_IMR_MISSING",
152 list(y_column = "x"), imr_outputs(imr(xm, default_rules), xm, "Rules on the retained sequence."),
153 c("Line 75-77: missing observations are omitted and the adjacent retained values become successive.",
154 "Excluded rows (0-based 2 and 40) are removed from the plotted source."),
155 kind = "missing_excluded", excluded = excluded)
Individuals chart at a 1e7 offset
Case STAT-QUAL-SPC-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_IMR_OFFSET.json
Settings compared
y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 10000050.630482858 | 10000050.630482858 | 4.69E-11 | 17 | passed |
/primary/upper_control_limit | tolerance | 10000057.426128719 | 10000057.426128719 | 2.01E-12 | 18 | passed |
/primary/lower_control_limit | tolerance | 10000043.834836997 | 10000043.834836995 | 1.77E-9 | 15 | passed |
/within_sigma | tolerance | 2.2652152872758617 | 2.2652152872599767 | 1.59E-11 | 11 | passed |
/secondary/center_line | tolerance | 2.5560217391483593 | 2.5560217391304345 | 1.79E-11 | 11 | passed |
/secondary/upper_control_limit | tolerance | 8.3493265973236781 | 8.349326597265128 | 5.86E-11 | 11 | passed |
/secondary/lower_control_limit | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/primary/points/0/value | tolerance | 10000048.633300001 | 10000048.6333 | 1.98E-10 | 16 | passed |
/secondary/points/0/value | tolerance | 2.3980999998748302 | 2.3981 | 1.25E-10 | 10 | passed |
/violation_keys | set | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | passed |
Convention
- A 1e7 shift moves the centre and limits only.
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
157 h <- read_dataset("QUAL_SPC_IMR"); h$x <- h$x + 1e7
158 export_dataset(h, "QUAL_SPC_IMR_OFFSET", "QUAL_SPC_IMR shifted by 1e7", "R stats::rnorm documentation",
159 "Constructed validation data; no third-party license.", c(t = "Int64", x = "Float64", phase = "Int64"))
160 ho <- read_dataset("QUAL_SPC_IMR_OFFSET")
161 ro <- imr(ho$x, default_rules)
162 emit("STAT-QUAL-SPC-005", "Individuals chart at a 1e7 offset", "QUAL_SPC_IMR_OFFSET", list(y_column = "x"),
163 imr_outputs(ro, ho$x, "The offset changes no signal."), c("A 1e7 shift moves the centre and limits only."), kind = "hard_numeric")
X-bar and R with constant subgroups of 5
Case STAT-QUAL-SPC-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_SUB5.json
Settings compared
subgroup_mode= "constant"subgroup_size= 5y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 19.972519999999999 | 19.97252 | 3.85E-16 | 16 | passed |
/within_sigma | tolerance | 1.430520434761525 | 1.430520434761527 | 2.02E-15 | 14 | passed |
/primary/points/0/value | tolerance | 19.87978 | 19.87978 | 2.29E-16 | 16 | passed |
/secondary/points/0/value | tolerance | 2.014800000000001 | 2.014800000000001 | 3.46E-17 | 16 | passed |
/violation_keys | set | [] | [] | passed | ||
/subgroup_count | exact | 9 | 9 | 0.00E+2 | passed | |
/primary/upper_control_limit | tolerance | 21.891764561197594 | 21.891764561197597 | 3.06E-15 | 15 | passed |
/primary/lower_control_limit | tolerance | 18.053275438802405 | 18.0532754388024 | 3.29E-15 | 15 | passed |
/secondary/center_line | tolerance | 3.327288888888889 | 3.3272888888888885 | 4.82E-16 | 15 | passed |
/secondary/upper_control_limit | tolerance | 7.0355495110425723 | 7.035549511042602 | 2.93E-14 | 14 | passed |
/secondary/lower_control_limit | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/dropped_subgroups | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Line 44-48: subgroups are formed from consecutive row positions before missing values are assessed; incomplete ones are dropped and counted.
- A2(5) = 0.576819334085086, D4(5) = 2.11449914509588 from the integrals.
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
225 set.seed(20261002)
226 xs <- round(rnorm(52, 20, 1.5), 4)
227 xs[13] <- NA # makes subgroup 3 incomplete
228 export_dataset(data.frame(row = seq_along(xs), x = xs), "QUAL_SPC_SUB5",
229 "Constructed: 52 rows, seed 20261002, x missing at row 13 (1-based)", "R stats::rnorm documentation",
230 "Constructed validation data; no third-party license.", c(row = "Int64", x = "Float64"))
231 s5 <- read_dataset("QUAL_SPC_SUB5")$x
232 blocks <- split(s5[1:50], rep(1:10, each = 5))
233 kept <- Filter(function(g) !anyNA(g), blocks)
234 ch <- xbar_chart(unname(kept), "R", default_rules)
235 emit("STAT-QUAL-SPC-006", "X-bar and R with constant subgroups of 5", "QUAL_SPC_SUB5",
236 list(y_column = "x", subgroup_mode = "constant", subgroup_size = 5L),
237 c(xbar_outputs(ch), list("/dropped_subgroups" = exact(2L, "Subgroup 3 has a missing value and rows 51-52 are an incomplete final subgroup."))),
238 c("Line 44-48: subgroups are formed from consecutive row positions before missing values are assessed; incomplete ones are dropped and counted.",
239 sprintf("A2(5) = %.15g, D4(5) = %.15g from the integrals.", 3 / (d2(5) * sqrt(5)), 1 + 3 * d3(5) / d2(5))))
X-bar and S with constant subgroups of 12
Case STAT-QUAL-SPC-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_SUB12.json
Settings compared
subgroup_mode= "constant"subgroup_size= 12y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 7.0016183333333331 | 7.001618333333333 | 4.48E-17 | 17 | passed |
/within_sigma | tolerance | 0.37119355658770742 | 0.3711935565877072 | 2.24E-16 | 15 | passed |
/primary/points/0/value | tolerance | 6.9087216666666666 | 6.908721666666666 | 8.38E-16 | 15 | passed |
/secondary/points/0/value | tolerance | 0.41259714051433499 | 0.41259714051433494 | 5.31E-17 | 15 | passed |
/violation_keys | set | [] | [] | passed | ||
/subgroup_count | exact | 8 | 8 | 0.00E+2 | passed | |
/primary/upper_control_limit | tolerance | 7.3230813830593844 | 7.323081383059384 | 1.39E-17 | 17 | passed |
/primary/lower_control_limit | tolerance | 6.6801552836072817 | 6.680155283607282 | 2.43E-17 | 17 | passed |
/secondary/center_line | tolerance | 0.36286373259054677 | 0.3628637325905467 | 5.30E-17 | 15 | passed |
/secondary/upper_control_limit | tolerance | 0.59745084264604253 | 0.59745084264604 | 2.55E-15 | 14 | passed |
/secondary/lower_control_limit | tolerance | 0.12827662253505101 | 0.12827662253505343 | 2.42E-15 | 13 | passed |
Convention
- Sizes 11-25 use X-bar/S (line 46).
- c4(12) = 0.977559351854772.
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
241 set.seed(20261003)
242 x12 <- round(rnorm(96, 7, 0.4), 5)
243 export_dataset(data.frame(x = x12, row = seq_along(x12)), "QUAL_SPC_SUB12", "Constructed: 96 rows, seed 20261003",
244 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(x = "Float64", row = "Int64"))
245 s12 <- read_dataset("QUAL_SPC_SUB12")$x
246 ch <- xbar_chart(unname(split(s12, rep(1:8, each = 12))), "S", default_rules)
247 emit("STAT-QUAL-SPC-007", "X-bar and S with constant subgroups of 12", "QUAL_SPC_SUB12",
248 list(y_column = "x", subgroup_mode = "constant", subgroup_size = 12L), xbar_outputs(ch),
249 c("Sizes 11-25 use X-bar/S (line 46).", sprintf("c4(12) = %.15g.", c4(12))), kind = "axis_coverage")
X-bar and R with the smallest subgroups of 2
Case STAT-QUAL-SPC-008 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_SUB12.json
Settings compared
subgroup_mode= "constant"subgroup_size= 2y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 7.0016183333333331 | 7.001618333333333 | 4.48E-17 | 17 | passed |
/within_sigma | tolerance | 0.3557492124152461 | 0.3557492124152461 | 3.39E-18 | 17 | passed |
/primary/upper_control_limit | tolerance | 7.7562763748351156 | 7.756276374835116 | 3.87E-17 | 17 | passed |
/secondary/upper_control_limit | tolerance | 1.3112512430408301 | 1.31125124304083 | 2.77E-17 | 16 | passed |
Convention
- All 96 rows form 48 subgroups of 2, the smallest subgroup size (line 44).
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
251 x2 <- read_dataset("QUAL_SPC_SUB12")$x
252 ch <- xbar_chart(unname(split(x2, rep(1:48, each = 2))), "R", default_rules)
253 emit("STAT-QUAL-SPC-008", "X-bar and R with the smallest subgroups of 2", "QUAL_SPC_SUB12",
254 list(y_column = "x", subgroup_mode = "constant", subgroup_size = 2L),
255 c(xbar_outputs(ch)[c("/primary/center_line", "/within_sigma")],
256 list("/primary/upper_control_limit" = tol(ch$ucl[1], "Grand mean + A2(2) R-bar."),
257 "/secondary/upper_control_limit" = tol(ch$s_ucl[1], "D4(2) R-bar."))),
258 c("All 96 rows form 48 subgroups of 2, the smallest subgroup size (line 44)."),
259 kind = "boundary")
Grouping column with varying sizes (X-bar/R, point-specific limits)
Case STAT-QUAL-SPC-009 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_BYLOT.json
Settings compared
group_column= "lot"subgroup_mode= "by_column"y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 100.43124600000002 | 100.43124599999999 | 3.26E-14 | 15 | passed |
/within_sigma | tolerance | 2.3354214225837509 | 2.3354214225837557 | 4.84E-15 | 14 | passed |
/primary/points/0/value | tolerance | 100.6999 | 100.6999 | 4.77E-16 | 17 | passed |
/secondary/points/0/value | tolerance | 6.203000000000003 | 6.203000000000003 | 4.41E-17 | 17 | passed |
/violation_keys | set | [] | [] | passed | ||
/subgroup_count | exact | 10 | 10 | 0.00E+2 | passed | |
/primary/point_upper_limits | sequence | ['103.93437813387564', '103.29154140984751', '103.5645426342 | [103.93437813387563, 103.2915414098475, 103.56454263420392, | passed | ||
/primary/point_lower_limits | sequence | ['96.928113866124392', '97.57095059015252', '97.297949365796 | [96.92811386612435, 97.57095059015248, 97.29794936579606, 96 | passed | ||
/secondary/point_upper_limits | sequence | ['10.97221936991426', '11.860511913292751', '11.486010719222 | [10.972219369914306, 11.8605119132928, 11.486010719222381, 1 | passed | ||
/secondary/point_center_lines | sequence | ['4.8080505959871935', '5.9189217628128414', '5.432024290887 | [4.808050595987198, 5.918921762812844, 5.4320242908878145, 3 | passed | ||
/dropped_subgroups | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Line 49-52 and 93-97: first-appearance order; sigma averages R_i/d2(n_i); the median size is 5, so X-bar/R.
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
262 set.seed(20261004)
263 sizes <- c(4, 6, 5, 3, 7, 5, 4, 6, 5, 1, 5)
264 lot <- rep(sprintf("L%02d", seq_along(sizes)), sizes)
265 vals <- round(rnorm(length(lot), 100, 3), 4)
266 export_dataset(data.frame(lot = lot, x = vals), "QUAL_SPC_BYLOT", "Constructed: lots of sizes 4,6,5,3,7,5,4,6,5,1,5, seed 20261004",
267 "R stats::rnorm documentation", "Constructed validation data; no third-party license.", c(lot = "String", x = "Float64"))
268 bl <- read_dataset("QUAL_SPC_BYLOT")
269 groups <- split(bl$x, factor(bl$lot, levels = unique(bl$lot)))
270 groups <- groups[vapply(groups, length, 1L) >= 2]
271 ch <- xbar_chart(unname(groups), "R", default_rules)
272 emit("STAT-QUAL-SPC-009", "Grouping column with varying sizes (X-bar/R, point-specific limits)", "QUAL_SPC_BYLOT",
273 list(y_column = "x", subgroup_mode = "by_column", group_column = "lot"),
274 c(xbar_outputs(ch, varying = TRUE), list("/dropped_subgroups" = exact(1L, "Lot L10 has one measurement."))),
275 c("Line 49-52 and 93-97: first-appearance order; sigma averages R_i/d2(n_i); the median size is 5, so X-bar/R."),
276 kind = "axis_coverage")
Grouping column with a median size above 10 uses X-bar/S
Case STAT-QUAL-SPC-010 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_BYLOT_S.json
Settings compared
group_column= "lot"subgroup_mode= "by_column"y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/center_line | tolerance | 3.0043718181818182 | 3.004371818181818 | 1.08E-18 | 18 | passed |
/within_sigma | tolerance | 0.19251143076359814 | 0.1925114307635981 | 2.74E-17 | 15 | passed |
/primary/points/0/value | tolerance | 3.0372391666666667 | 3.0372391666666663 | 4.32E-16 | 15 | passed |
/secondary/points/0/value | tolerance | 0.16416286283933423 | 0.16416286283933432 | 8.70E-17 | 15 | passed |
/violation_keys | set | [] | [] | passed | ||
/subgroup_count | exact | 6 | 6 | 0.00E+2 | passed | |
/primary/point_upper_limits | sequence | ['3.1710916077419835', '3.158724350386469', '3.1785049591901 | [3.171091607741983, 3.158724350386469, 3.1785049591901826, 3 | passed | ||
/primary/point_lower_limits | sequence | ['2.8376520286216529', '2.8500192859771674', '2.830238677173 | [2.8376520286216533, 2.8500192859771674, 2.830238677173454, | passed | ||
/secondary/point_upper_limits | sequence | ['0.30985483041791551', '0.30097771397180728', '0.3152065766 | [0.3098548304179143, 0.30097771397180784, 0.3152065766456035 | passed | ||
/secondary/point_center_lines | sequence | ['0.18819134948189775', '0.18884821482802699', '0.1877660388 | [0.1881913494818978, 0.18884821482802694, 0.1877660388466138 | passed |
Convention
- Median usable size 12.5 > 10 selects X-bar/S; sigma averages s_i/c4(n_i) (line 119-120).
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
279 set.seed(20261005)
280 sizes <- c(12, 14, 11, 13, 12, 15)
281 lot <- rep(sprintf("B%d", seq_along(sizes)), sizes)
282 export_dataset(data.frame(lot = lot, x = round(rnorm(length(lot), 3, 0.2), 5)), "QUAL_SPC_BYLOT_S",
283 "Constructed: batches of sizes 12,14,11,13,12,15, seed 20261005", "R stats::rnorm documentation",
284 "Constructed validation data; no third-party license.", c(lot = "String", x = "Float64"))
285 bs <- read_dataset("QUAL_SPC_BYLOT_S")
286 ch <- xbar_chart(unname(split(bs$x, factor(bs$lot, levels = unique(bs$lot)))), "S", default_rules)
287 emit("STAT-QUAL-SPC-010", "Grouping column with a median size above 10 uses X-bar/S", "QUAL_SPC_BYLOT_S",
288 list(y_column = "x", subgroup_mode = "by_column", group_column = "lot"), xbar_outputs(ch, varying = TRUE),
289 c("Median usable size 12.5 > 10 selects X-bar/S; sigma averages s_i/c4(n_i) (line 119-120)."), kind = "axis_coverage")
Spec limits are overlays only
Case STAT-QUAL-SPC-011 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_IMR.json
Settings compared
lower_spec= 40upper_spec= 60y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/lower_spec_limit | tolerance | 40 | 40 | 0.00E+2 | passed | |
/upper_spec_limit | tolerance | 60 | 60 | 0.00E+2 | passed | |
/violation_keys | set | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | ['primary:rule_1:19', 'primary:rule_2:37', 'primary:rule_3:4 | passed |
Convention
- Line 30-31: applied specifications never replace limits or create signals.
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
291 emit("STAT-QUAL-SPC-011", "Spec limits are overlays only", "QUAL_SPC_IMR",
292 list(y_column = "x", lower_spec = 40, upper_spec = 60),
293 list("/lower_spec_limit" = tol(40, "Passed through as an overlay."), "/upper_spec_limit" = tol(60, "Passed through as an overlay."),
294 "/violation_keys" = set_of(imr(d$x, default_rules)$keys, "Spec limits never create signals (line 30-31).")),
295 c("Line 30-31: applied specifications never replace limits or create signals."), kind = "axis_coverage")
A subgroup size of 26 is refused
Case STAT-QUAL-SPC-012 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_SUB12.json
Settings compared
subgroup_mode= "constant"subgroup_size= 26y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 44: sizes 2-25.
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
297 emit("STAT-QUAL-SPC-012", "A subgroup size of 26 is refused", "QUAL_SPC_SUB12",
298 list(y_column = "x", subgroup_mode = "constant", subgroup_size = 26L), list(),
299 c("Line 44: sizes 2-25."), kind = "invalid_input", error = list(error_class = "ValueError", message_contains = "25"))
An unknown run rule is refused
Case STAT-QUAL-SPC-013 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::integrate constants and hand-coded chart formulas and rules
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R stats::integrate and base::lgamma
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc.R · sha256 933d3416ca032dbb
- Dataset
- reference_data/datasets/QUAL_SPC_IMR.json
Settings compared
run_rules= ["rule_9"]y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Only rules 2-8 are optional (line 219-236).
- NIST tabulates rounded factors; the generator integrates d2/d3 at full precision.
- Phase-I selection, varying subgroup sizes and row adjacency are Tabelz conventions independently implemented here.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
300 emit("STAT-QUAL-SPC-013", "An unknown run rule is refused", "QUAL_SPC_IMR",
301 list(y_column = "x", run_rules = list("rule_9")), list(),
302 c("Only rules 2-8 are optional (line 219-236)."), kind = "invalid_input",
303 error = list(error_class = "ValueError", message_contains = "Unknown run rules"))
Default normalization matches through whitespace and case
Case STAT-QUAL-SPECMATCH-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation from the constructed spec sheet
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/quality_spec_import.R · sha256 3e2833e638a2586d
- Dataset
- reference_data/datasets/QUAL_SPEC_SHEET.json
Settings compared
lsl_column= "LSL"name_column= "variable"target_column= "Target"target_columns= ["DiameterA", "Length", "Width", "Height", "Mass", "Other"]units_column= "Units"usl_column= "USL"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/matches/0/variable | exact | Diameter A | Diameter A | passed | ||
/matches/0/column | exact | DiameterA | DiameterA | passed | ||
/matches/0/lower | tolerance | 9.9000000000000004 | 9.9 | 4.47E-17 | 17 | passed |
/matches/0/upper | tolerance | 10.1 | 10.1 | 3.55E-16 | 16 | passed |
/matches/0/target | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/matches/0/units | exact | mm | mm | passed | ||
/matches/1/column | exact | Length | Length | passed | ||
/matches/1/lower | absent | None | passed | |||
/matches/1/upper | tolerance | 50.5 | 50.5 | 0.00E+1 | passed | |
/matches/2 | absent | None | passed |
Convention
- Width has LSL 3 > USL 2 (inverted); Height has the malformed LSL 'abc' and is unresolved even though USL 7 parses (line 48-50);
- Mass has neither limit; Unknown names no target column. None of these cancels the two valid rows (line 51-52).
Reference code
The lines of the reference script that produce this case's expected values.
44 sheet <- data.frame(
45 variable = c(" Diameter A", "length", "Width", "Height", "Mass", "Unknown"),
46 LSL = c("9.9", "", "3", "abc", "", "1"),
47 USL = c("10.1", "50.5", "2", "7", "", "2"),
48 Target = c("10", "", "", "", "", ""),
49 Units = c("mm", "mm", "mm", "mm", "g", "mm"),
50 stringsAsFactors = FALSE)
51 export_dataset(sheet, "QUAL_SPEC_SHEET", "Constructed specification sheet with whitespace, case, one-sided, inverted, malformed, empty and unmatched rows",
52 "Hand-constructed", "Constructed validation data; no third-party license.",
53 c(variable = "String", LSL = "String", USL = "String", Target = "String", Units = "String"))
54 targets <- list("DiameterA", "Length", "Width", "Height", "Mass", "Other")
55 base <- list(target_columns = targets, name_column = "variable", lsl_column = "LSL", usl_column = "USL",
56 target_column = "Target", units_column = "Units")
57 emit("STAT-QUAL-SPECMATCH-001", match_entry, "Default normalization matches through whitespace and case", "QUAL_SPEC_SHEET", base,
58 list("/matches/0/variable" = exact(" Diameter A", "The first resolved row."),
59 "/matches/0/column" = exact("DiameterA", "' Diameter A' without whitespace and case equals 'DiameterA'."),
60 "/matches/0/lower" = num(9.9, "LSL 9.9."), "/matches/0/upper" = num(10.1, "USL 10.1."),
61 "/matches/0/target" = num(10, "Target 10."), "/matches/0/units" = exact("mm", "Units retained."),
62 "/matches/1/column" = exact("Length", "'length' matches 'Length' case-insensitively."),
63 "/matches/1/lower" = absent("A blank LSL is an absent side (line 47-48)."),
64 "/matches/1/upper" = num(50.5, "USL 50.5, a one-sided specification."),
65 "/matches/2" = absent("Only two rows resolve.")),
66 c("Width has LSL 3 > USL 2 (inverted); Height has the malformed LSL 'abc' and is unresolved even though USL 7 parses (line 48-50);",
67 "Mass has neither limit; Unknown names no target column. None of these cancels the two valid rows (line 51-52)."))
Case-sensitive matching leaves 'length' unmatched
Case STAT-QUAL-SPECMATCH-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation from the constructed spec sheet
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/quality_spec_import.R · sha256 3e2833e638a2586d
- Dataset
- reference_data/datasets/QUAL_SPEC_SHEET.json
Settings compared
case_insensitive= falselsl_column= "LSL"name_column= "variable"target_column= "Target"target_columns= ["DiameterA", "Length", "Width", "Height", "Mass", "Other"]units_column= "Units"usl_column= "USL"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/matches/0/column | exact | DiameterA | DiameterA | passed | ||
/matches/1 | absent | None | passed |
Convention
- case_insensitive = false (line 26).
Reference code
The lines of the reference script that produce this case's expected values.
68 emit("STAT-QUAL-SPECMATCH-002", match_entry, "Case-sensitive matching leaves 'length' unmatched", "QUAL_SPEC_SHEET",
69 modifyList(base, list(case_insensitive = FALSE)),
70 list("/matches/0/column" = exact("DiameterA", "Whitespace is still removed and the letters match exactly."),
71 "/matches/1" = absent("'length' does not match 'Length' when case matters.")),
72 c("case_insensitive = false (line 26)."), kind = "axis_coverage")
Keeping whitespace leaves ' Diameter A' unmatched
Case STAT-QUAL-SPECMATCH-003 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation from the constructed spec sheet
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/quality_spec_import.R · sha256 3e2833e638a2586d
- Dataset
- reference_data/datasets/QUAL_SPEC_SHEET.json
Settings compared
ignore_whitespace= falselsl_column= "LSL"name_column= "variable"target_column= "Target"target_columns= ["DiameterA", "Length", "Width", "Height", "Mass", "Other"]units_column= "Units"usl_column= "USL"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/matches/0/column | exact | Length | Length | passed | ||
/matches/1 | absent | None | passed |
Convention
- ignore_whitespace = false (line 24-25).
Reference code
The lines of the reference script that produce this case's expected values.
73 emit("STAT-QUAL-SPECMATCH-003", match_entry, "Keeping whitespace leaves ' Diameter A' unmatched", "QUAL_SPEC_SHEET",
74 modifyList(base, list(ignore_whitespace = FALSE)),
75 list("/matches/0/column" = exact("Length", "Only 'length' still matches."),
76 "/matches/1" = absent("' Diameter A' keeps its spaces and matches nothing.")),
77 c("ignore_whitespace = false (line 24-25)."), kind = "axis_coverage")
Neither limit role assigned is refused
Case STAT-QUAL-SPECMATCH-004 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation from the constructed spec sheet
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/quality_spec_import.R · sha256 3e2833e638a2586d
- Dataset
- reference_data/datasets/QUAL_SPEC_SHEET.json
Settings compared
name_column= "variable"target_columns= ["DiameterA", "Length", "Width", "Height", "Mass", "Other"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 32-33: at least one of LSL or USL must be assigned.
Reference code
The lines of the reference script that produce this case's expected values.
78 emit("STAT-QUAL-SPECMATCH-004", match_entry, "Neither limit role assigned is refused", "QUAL_SPEC_SHEET",
79 list(target_columns = targets, name_column = "variable"), list(),
80 c("Line 32-33: at least one of LSL or USL must be assigned."), kind = "invalid_input",
81 error = list(error_class = "ValueError", message_contains = "lsl_column or usl_column"))
Matching a transposed sheet
Case STAT-QUAL-SPECMATCH-005 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation from the constructed spec sheet
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/quality_spec_import.R · sha256 3e2833e638a2586d
- Dataset
- reference_data/datasets/QUAL_SPEC_WIDE.json
Settings compared
lsl_column= "LSL"name_column= "variable"target_columns= ["alpha", "beta"]transposed= trueusl_column= "USL"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/matches/0/column | exact | alpha | alpha | passed | ||
/matches/0/lower | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/matches/1/lower | absent | None | passed | |||
/matches/1/upper | tolerance | 9 | 9.0 | 0.00E+2 | passed |
Convention
- Prepare then match, as the desktop does.
Reference code
The lines of the reference script that produce this case's expected values.
97 emit("STAT-QUAL-SPECMATCH-005", match_entry, "Matching a transposed sheet", "QUAL_SPEC_WIDE",
98 list(transposed = TRUE, target_columns = list("alpha", "beta"), name_column = "variable", lsl_column = "LSL", usl_column = "USL"),
99 list("/matches/0/column" = exact("alpha", "'Alpha' matches 'alpha' case-insensitively."),
100 "/matches/0/lower" = num(1, "LSL 1."), "/matches/1/lower" = absent("Beta has a blank LSL."),
101 "/matches/1/upper" = num(9, "USL 9.")),
102 c("Prepare then match, as the desktop does."), kind = "axis_coverage")
Transposing a sheet laid out across columns
Case STAT-QUAL-SPECPREP-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation from the constructed spec sheet
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/quality_spec_import.R · sha256 3e2833e638a2586d
- Dataset
- reference_data/datasets/QUAL_SPEC_WIDE.json
Settings compared
transposed= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/variable | exact | Alpha | Alpha | passed | ||
/0/LSL | exact | 1 | 1 | passed | ||
/1/variable | exact | Beta | Beta | passed | ||
/1/USL | exact | 9 | 9 | passed | ||
/2 | absent | None | passed |
Convention
- The first source column (variable, LSL, USL) supplies the new headings (line 20-22).
Reference code
The lines of the reference script that produce this case's expected values.
83 wide <- data.frame(field = c("variable", "LSL", "USL"), c1 = c("Alpha", "1", "2"), c2 = c("Beta", "", "9"),
84 stringsAsFactors = FALSE)
85 export_dataset(wide, "QUAL_SPEC_WIDE", "Constructed specification sheet laid out across columns", "Hand-constructed",
86 "Constructed validation data; no third-party license.", c(field = "String", c1 = "String", c2 = "String"))
87 emit("STAT-QUAL-SPECPREP-001", prep_entry, "Transposing a sheet laid out across columns", "QUAL_SPEC_WIDE",
88 list(transposed = TRUE),
89 list("/0/variable" = exact("Alpha", "The first characteristic becomes the first row."),
90 "/0/LSL" = exact("1", "Its LSL."), "/1/variable" = exact("Beta", "The second characteristic."),
91 "/1/USL" = exact("9", "Its USL."), "/2" = absent("Two characteristics become two rows.")),
92 c("The first source column (variable, LSL, USL) supplies the new headings (line 20-22)."))
Without transposing the sheet is unchanged
Case STAT-QUAL-SPECPREP-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand derivation from the constructed spec sheet
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- generators/r/quality_spec_import.R · sha256 3e2833e638a2586d
- Dataset
- reference_data/datasets/QUAL_SPEC_WIDE.json
Settings compared
transposed= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/field | exact | variable | variable | passed | ||
/2/c2 | exact | 9 | 9 | passed |
Convention
- transposed = false is the default (line 20).
Reference code
The lines of the reference script that produce this case's expected values.
93 emit("STAT-QUAL-SPECPREP-002", prep_entry, "Without transposing the sheet is unchanged", "QUAL_SPEC_WIDE",
94 list(transposed = FALSE),
95 list("/0/field" = exact("variable", "The original first row."), "/2/c2" = exact("9", "The original cell.")),
96 c("transposed = false is the default (line 20)."), kind = "axis_coverage")
Two process stages recalculated independently
Case STAT-QUAL-STAGES-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded I-MR charts and rules in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.1, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc321.htm; Nelson, Journal of Quality Technology 16(4), 1984, pp. 237-239; R base arithmetic
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_stages.R · sha256 046de2272a987401
- Dataset
- reference_data/datasets/QUAL_SPC_STAGES.json
Settings compared
stages= [{"name": "Before", "start_label": "P01", "end_label": "P30"}, {"name": "After", "start_label": "P31"}]x_column= "label"y_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/point_center_lines | sequence | ['19.869526666666665', '19.869526666666665', '19.86952666666 | [19.86952666666667, 19.86952666666667, 19.86952666666667, 19 | passed | ||
/primary/point_upper_limits | sequence | ['23.599142395471546', '23.599142395471546', '23.59914239547 | [23.599142395471546, 23.599142395471546, 23.599142395471546, | passed | ||
/primary/point_lower_limits | sequence | ['16.139910937861785', '16.139910937861785', '16.13991093786 | [16.139910937861792, 16.139910937861792, 16.139910937861792, | passed | ||
/violation_keys | set | ['primary:rule_1:11', 'primary:rule_1:46', 'secondary:rule_1 | ['primary:rule_1:11', 'primary:rule_1:46', 'secondary:rule_1 | passed | ||
/stage_count | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Stage 'After' starts at label P31 with no end label, so it runs to the last point.
- Moving ranges are formed within each stage: 29 + 29 points on the MR chart.
- Independent Phase-I estimates and restarted rule windows at stage boundaries are explicit Tabelz conventions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
79 a <- stage(d$x[1:30]); b <- stage(d$x[31:60])
80 keys <- c(rules_for(a$values, a$center, a$sigma, a$ucl, a$lcl, 0L),
81 rules_for(b$values, b$center, b$sigma, b$ucl, b$lcl, 30L),
82 rules_for(a$mr, rep(0, 29), 1, a$mr_ucl, rep(0, 29), 0L, "secondary", FALSE),
83 rules_for(b$mr, rep(0, 29), 1, b$mr_ucl, rep(0, 29), 29L, "secondary", FALSE))
84 emit("STAT-QUAL-STAGES-001", stage_entry, "Two process stages recalculated independently",
85 list(y_column = "x", x_column = "label",
86 stages = list(list(name = "Before", start_label = "P01", end_label = "P30"),
87 list(name = "After", start_label = "P31"))),
88 list("/primary/point_center_lines" = seqtol(c(a$center, b$center), "Each stage's own mean."),
89 "/primary/point_upper_limits" = seqtol(c(a$ucl, b$ucl), "Each stage's mean + 3 MR-bar/d2."),
90 "/primary/point_lower_limits" = seqtol(c(a$lcl, b$lcl), "Each stage's mean - 3 MR-bar/d2."),
91 "/violation_keys" = set_of(keys, "Rules restart at the stage boundary; moving ranges stay within a stage."),
92 "/stage_count" = exact(2L, "Two calculated stages.")),
93 c("Stage 'After' starts at label P31 with no end label, so it runs to the last point.",
94 "Moving ranges are formed within each stage: 29 + 29 points on the MR chart."))
Individual Phase II T-squared at alpha 0.0027
Case STAT-QUAL-T2-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2.json
Settings compared
alpha= 0.0027reference_column= "role"reference_value= "ref"variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/baseline/mean | sequence | ['9.8712924999999991', '20.095361749999999', '4.778065749999 | [9.871292500000004, 20.095361750000002, 4.778065749999999] | passed | ||
/baseline/covariance/0 | sequence | ['0.44568973674743589', '0.24653224772884599', '0.2109089705 | [0.4456897367474356, 0.24653224772884605, 0.2109089705878206 | passed | ||
/baseline/upper_control_limit | tolerance | 18.34636266923107 | 18.346362669231052 | 1.80E-14 | 15 | passed |
/monitoring_points/0/t_squared | tolerance | 2.3156526425892534 | 2.3156526425892454 | 7.99E-15 | 14 | passed |
/monitoring_points/15/t_squared | tolerance | 34.550817762706906 | 34.55081776270681 | 9.95E-14 | 14 | passed |
/breach_count | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- The standard Phase-II individual-observation limit is used (Montgomery, 6th ed., section 11.3).
- Montgomery's Phase-II individual T-squared F limit applies to a future observation against the estimated baseline.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
63 set.seed(20261012)
64 L <- matrix(c(1, 0, 0, 0.6, 0.8, 0, 0.3, -0.2, 0.9), 3, byrow = TRUE)
65 ref <- matrix(rnorm(40 * 3), 40) %*% t(L)
66 mon <- matrix(rnorm(20 * 3), 20) %*% t(L); mon[11:20, 1] <- mon[11:20, 1] + 2.2
67 X <- round(rbind(ref, mon) + matrix(rep(c(10, 20, 5), each = 60), 60), 5)
68 export_dataset(data.frame(a = X[, 1], b = X[, 2], c = X[, 3], role = c(rep("ref", 40), rep("mon", 20)),
69 stage = c(rep("ref", 40), rep("S1", 10), rep("S2", 10))),
70 "QUAL_T2", "Constructed: 40 reference and 20 monitoring rows of three correlated variables, seed 20261012; a +2.2 shift in a from monitoring row 11",
71 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
72 c(a = "Float64", b = "Float64", c = "Float64", role = "String", stage = "String"))
73 d <- read_dataset("QUAL_T2")
74 vars <- c("a", "b", "c")
75 R0 <- as.matrix(d[d$role == "ref", vars]); M0 <- as.matrix(d[d$role == "mon", vars])
76 m <- nrow(R0); p <- 3L; xbar <- colMeans(R0); S <- cov(R0); Si <- solve(S)
77 t2 <- apply(M0, 1, function(x) quad(x - xbar, Si))
78 ucl_ind <- function(alpha) p * (m + 1) * (m - 1) / (m * (m - p)) * qf(1 - alpha, p, m - p)
79 for (alpha in c(0.0027, 0.01)) {
80 id <- if (alpha == 0.0027) "STAT-QUAL-T2-001" else "STAT-QUAL-T2-002"
81 emit(id, t2_entry, "hotellingMenuItem", sprintf("Individual Phase II T-squared at alpha %g", alpha), "QUAL_T2",
82 list(variables = as.list(vars), reference_column = "role", reference_value = "ref", alpha = alpha),
83 list("/baseline/mean" = seqtol(xbar, "Reference mean vector."),
84 "/baseline/covariance/0" = seqtol(S[1, ], "First row of S, denominator m - 1."),
85 "/baseline/upper_control_limit" = tol(ucl_ind(alpha), "p(m+1)(m-1)/(m(m-p)) F_(1-alpha)(p, m-p)."),
86 "/monitoring_points/0/t_squared" = tol(t2[1], "First monitoring T^2."),
87 "/monitoring_points/15/t_squared" = tol(t2[16], "A shifted monitoring row."),
88 "/breach_count" = exact(sum(t2 > ucl_ind(alpha)), "Rows with T^2 above the limit.")),
89 c("The standard Phase-II individual-observation limit is used (Montgomery, 6th ed., section 11.3)."),
90 kind = if (alpha == 0.0027) "nominal" else "threshold")
Individual Phase II T-squared at alpha 0.01
Case STAT-QUAL-T2-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2.json
Settings compared
alpha= 0.01reference_column= "role"reference_value= "ref"variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/baseline/mean | sequence | ['9.8712924999999991', '20.095361749999999', '4.778065749999 | [9.871292500000004, 20.095361750000002, 4.778065749999999] | passed | ||
/baseline/covariance/0 | sequence | ['0.44568973674743589', '0.24653224772884599', '0.2109089705 | [0.4456897367474356, 0.24653224772884605, 0.2109089705878206 | passed | ||
/baseline/upper_control_limit | tolerance | 14.130211049133246 | 14.13021104913324 | 5.34E-15 | 15 | passed |
/monitoring_points/0/t_squared | tolerance | 2.3156526425892534 | 2.3156526425892454 | 7.99E-15 | 14 | passed |
/monitoring_points/15/t_squared | tolerance | 34.550817762706906 | 34.55081776270681 | 9.95E-14 | 14 | passed |
/breach_count | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- The standard Phase-II individual-observation limit is used (Montgomery, 6th ed., section 11.3).
- Montgomery's Phase-II individual T-squared F limit applies to a future observation against the estimated baseline.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
63 set.seed(20261012)
64 L <- matrix(c(1, 0, 0, 0.6, 0.8, 0, 0.3, -0.2, 0.9), 3, byrow = TRUE)
65 ref <- matrix(rnorm(40 * 3), 40) %*% t(L)
66 mon <- matrix(rnorm(20 * 3), 20) %*% t(L); mon[11:20, 1] <- mon[11:20, 1] + 2.2
67 X <- round(rbind(ref, mon) + matrix(rep(c(10, 20, 5), each = 60), 60), 5)
68 export_dataset(data.frame(a = X[, 1], b = X[, 2], c = X[, 3], role = c(rep("ref", 40), rep("mon", 20)),
69 stage = c(rep("ref", 40), rep("S1", 10), rep("S2", 10))),
70 "QUAL_T2", "Constructed: 40 reference and 20 monitoring rows of three correlated variables, seed 20261012; a +2.2 shift in a from monitoring row 11",
71 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
72 c(a = "Float64", b = "Float64", c = "Float64", role = "String", stage = "String"))
73 d <- read_dataset("QUAL_T2")
74 vars <- c("a", "b", "c")
75 R0 <- as.matrix(d[d$role == "ref", vars]); M0 <- as.matrix(d[d$role == "mon", vars])
76 m <- nrow(R0); p <- 3L; xbar <- colMeans(R0); S <- cov(R0); Si <- solve(S)
77 t2 <- apply(M0, 1, function(x) quad(x - xbar, Si))
78 ucl_ind <- function(alpha) p * (m + 1) * (m - 1) / (m * (m - p)) * qf(1 - alpha, p, m - p)
79 for (alpha in c(0.0027, 0.01)) {
80 id <- if (alpha == 0.0027) "STAT-QUAL-T2-001" else "STAT-QUAL-T2-002"
81 emit(id, t2_entry, "hotellingMenuItem", sprintf("Individual Phase II T-squared at alpha %g", alpha), "QUAL_T2",
82 list(variables = as.list(vars), reference_column = "role", reference_value = "ref", alpha = alpha),
83 list("/baseline/mean" = seqtol(xbar, "Reference mean vector."),
84 "/baseline/covariance/0" = seqtol(S[1, ], "First row of S, denominator m - 1."),
85 "/baseline/upper_control_limit" = tol(ucl_ind(alpha), "p(m+1)(m-1)/(m(m-p)) F_(1-alpha)(p, m-p)."),
86 "/monitoring_points/0/t_squared" = tol(t2[1], "First monitoring T^2."),
87 "/monitoring_points/15/t_squared" = tol(t2[16], "A shifted monitoring row."),
88 "/breach_count" = exact(sum(t2 > ucl_ind(alpha)), "Rows with T^2 above the limit.")),
89 c("The standard Phase-II individual-observation limit is used (Montgomery, 6th ed., section 11.3)."),
90 kind = if (alpha == 0.0027) "nominal" else "threshold")
Excluded and incomplete rows leave the baseline and the monitoring
Case STAT-QUAL-T2-003 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2_MISSING.json
Settings compared
alpha= 0.0027reference_column= "role"reference_value= "ref"variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/baseline/mean | sequence | ['9.8533569230769231', '20.062712564102565', '4.766203076923 | [9.853356923076927, 20.062712564102565, 4.766203076923077] | passed | ||
/baseline/upper_control_limit | tolerance | 18.479300870530007 | 18.479300870530007 | 4.72E-16 | 16 | passed |
/monitoring_points/0/t_squared | tolerance | 2.2323355465236521 | 2.232335546523639 | 1.29E-14 | 14 | passed |
/incomplete_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Reference row 3 and monitoring row 52 (0-based) are excluded; monitoring row 44 (0-based) is incomplete.
- Montgomery's Phase-II individual T-squared F limit applies to a future observation against the estimated baseline.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
92 mm <- read_dataset("QUAL_T2"); mm$b[45] <- NA
93 export_dataset(mm, "QUAL_T2_MISSING", "QUAL_T2 with b missing in row 45 (1-based)", "R stats::rnorm documentation",
94 "Constructed validation data; no third-party license.",
95 c(a = "Float64", b = "Float64", c = "Float64", role = "String", stage = "String"))
96 dm <- read_dataset("QUAL_T2_MISSING")
97 excluded <- c(3L, 52L)
98 keep <- setdiff(which(stats::complete.cases(dm[vars])), excluded + 1L)
99 Rk <- as.matrix(dm[intersect(keep, which(dm$role == "ref")), vars]); Mk <- as.matrix(dm[intersect(keep, which(dm$role == "mon")), vars])
100 xk <- colMeans(Rk); Sk <- solve(cov(Rk)); mk <- nrow(Rk)
101 emit("STAT-QUAL-T2-003", t2_entry, "hotellingMenuItem", "Excluded and incomplete rows leave the baseline and the monitoring", "QUAL_T2_MISSING",
102 list(variables = as.list(vars), reference_column = "role", reference_value = "ref", alpha = 0.0027),
103 list("/baseline/mean" = seqtol(xk, "Mean of the 39 remaining reference rows."),
104 "/baseline/upper_control_limit" = tol(p * (mk + 1) * (mk - 1) / (mk * (mk - p)) * qf(1 - 0.0027, p, mk - p), "Limit at m = 39."),
105 "/monitoring_points/0/t_squared" = tol(quad(Mk[1, ] - xk, Sk), "First remaining monitoring row."),
106 "/incomplete_count" = exact(1L, "Row 45 (1-based) has a missing value."),
107 "/excluded_count" = exact(2L, "Two excluded rows.")),
108 c("Reference row 3 and monitoring row 52 (0-based) are excluded; monitoring row 44 (0-based) is incomplete."),
109 kind = "missing_excluded", excluded = excluded)
Three reference rows for three variables are too few
Case STAT-QUAL-T2-004 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2_FEWREF.json
Settings compared
reference_column= "role"reference_value= "ref"variables= ["a", "b", "c"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The baseline needs more reference rows than variables (m > p).
- Montgomery's Phase-II individual T-squared F limit applies to a future observation against the estimated baseline.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
110 small <- read_dataset("QUAL_T2"); small$role[4:40] <- "mon"
111 export_dataset(small, "QUAL_T2_FEWREF", "QUAL_T2 with only three reference rows", "Hand-constructed",
112 "Constructed validation data; no third-party license.",
113 c(a = "Float64", b = "Float64", c = "Float64", role = "String", stage = "String"))
114 emit("STAT-QUAL-T2-004", t2_entry, "hotellingMenuItem", "Three reference rows for three variables are too few", "QUAL_T2_FEWREF",
115 list(variables = as.list(vars), reference_column = "role", reference_value = "ref"), list(),
116 c("The baseline needs more reference rows than variables (m > p)."), kind = "invalid_input",
117 error = list(error_class = "ValueError", message_contains = "reference rows"))
Subgroup T-squared and generalized variance
Case STAT-QUAL-T2SUB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2_SUB.json
Settings compared
reference_column= "role"reference_value= "ref"subgroup_column= "lot"subgroup_size= 5variables= ["v1", "v2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/baseline/grand_mean | sequence | ['5.0256395999999999', '5.2890446666666664'] | [5.0256396, 5.289044666666668] | passed | ||
/baseline/pooled_covariance/0 | sequence | ['1.0006864177346666', '0.25431099362000004'] | [1.0006864177346666, 0.25431099362000004] | passed | ||
/baseline/t_squared_ucl | tolerance | 14.208217693899925 | 14.208217693899913 | 1.20E-14 | 15 | passed |
/baseline/f_denominator_df | exact | 59 | 59 | 0.00E+2 | passed | |
/monitoring_points/0/t_squared | tolerance | 4.9819184149101954 | 4.9819184149102105 | 1.51E-14 | 14 | passed |
/monitoring_points/7/t_squared | tolerance | 10.573075959252808 | 10.573075959252815 | 7.18E-15 | 15 | passed |
/monitoring_points/0/generalized_variance | tolerance | 0.61692719125543705 | 0.616927191255437 | 3.72E-18 | 17 | passed |
/baseline/generalized_variance_center | tolerance | 1.0310244271532751 | 1.0310244271532751 | 3.59E-17 | 16 | passed |
/baseline/generalized_variance_ucl | tolerance | 4.8192500654595491 | 4.819250065459549 | 4.83E-17 | 16 | passed |
/t_squared_breach_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- alpha defaults to 0.0027 (line 24-25).
- Alt's b1 and b2 for n = 5, p = 2 (line 70-73).
- Montgomery's Phase-II subgroup T-squared F limit and Alt's b1/b2 determinant formulas use the configured m, n and p.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
207 export_dataset(subgroup_data(20261013, 2, 5, 15, 8, 1.6), "QUAL_T2_SUB", "Constructed: p = 2, n = 5, 15 reference and 8 monitoring subgroups, seed 20261013; +1.6 shift in v1 in the last four",
208 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
209 c(v1 = "Float64", v2 = "Float64", lot = "String", role = "String"))
210 ds <- read_dataset("QUAL_T2_SUB")
211 sc <- sub_chart(ds, c("v1", "v2"), 5)
212 sub_config <- list(variables = list("v1", "v2"), subgroup_column = "lot", subgroup_size = 5L,
213 reference_column = "role", reference_value = "ref")
214 emit("STAT-QUAL-T2SUB-001", sub_entry, "hotellingSubgroupsMenuItem", "Subgroup T-squared and generalized variance", "QUAL_T2_SUB",
215 sub_config,
216 list("/baseline/grand_mean" = seqtol(sc$gm, "Mean of the reference subgroup means."),
217 "/baseline/pooled_covariance/0" = seqtol(sc$Sbar[1, ], "Mean of the reference subgroup covariances."),
218 "/baseline/t_squared_ucl" = tol(sc$ucl, "p(m+1)(n-1)/(mn-m-p+1) F_(1-alpha)(p, mn-m-p+1)."),
219 "/baseline/f_denominator_df" = exact(as.integer(sc$df2), "mn - m - p + 1."),
220 "/monitoring_points/0/t_squared" = tol(sc$t2[[1]], "n (xbar_j - xbarbar)' Sbar^-1 (xbar_j - xbarbar)."),
221 "/monitoring_points/7/t_squared" = tol(sc$t2[[8]], "A shifted subgroup."),
222 "/monitoring_points/0/generalized_variance" = tol(sc$gv[[1]], "|S_j|."),
223 "/baseline/generalized_variance_center" = tol(sc$center, "Mean reference |S_i|."),
224 "/baseline/generalized_variance_ucl" = tol(sc$gv_ucl, "|Sigma| (b1 + 3 sqrt(b2))."),
225 "/t_squared_breach_count" = exact(sum(sc$t2 > sc$ucl), "Subgroups above the limit.")),
226 c("alpha defaults to 0.0027 (line 24-25).", "Alt's b1 and b2 for n = 5, p = 2 (line 70-73)."))
n <= p keeps the location chart and withholds the spread chart
Case STAT-QUAL-T2SUB-002 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2_SUB_SMALLN.json
Settings compared
reference_column= "role"reference_value= "ref"subgroup_column= "lot"subgroup_size= 3variables= ["v1", "v2", "v3"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/baseline/t_squared_ucl | tolerance | 22.825538801854478 | 22.825538801854485 | 6.92E-15 | 15 | passed |
/monitoring_points/0/t_squared | tolerance | 1.2357411989584708 | 1.2357411989584706 | 2.34E-16 | 15 | passed |
/baseline/generalized_variance_available | exact | False | False | passed |
Convention
- m(n - 1) = 24 >= p = 3, so the location chart is defined.
- Montgomery's Phase-II subgroup T-squared F limit and Alt's b1/b2 determinant formulas use the configured m, n and p.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
227 export_dataset(subgroup_data(20261014, 3, 3, 12, 6, 0), "QUAL_T2_SUB_SMALLN", "Constructed: p = 3, n = 3, seed 20261014",
228 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
229 c(v1 = "Float64", v2 = "Float64", v3 = "Float64", lot = "String", role = "String"))
230 dn <- read_dataset("QUAL_T2_SUB_SMALLN")
231 sn <- sub_chart(dn, c("v1", "v2", "v3"), 3)
232 emit("STAT-QUAL-T2SUB-002", sub_entry, "hotellingSubgroupsMenuItem", "n <= p keeps the location chart and withholds the spread chart", "QUAL_T2_SUB_SMALLN",
233 list(variables = list("v1", "v2", "v3"), subgroup_column = "lot", subgroup_size = 3L, reference_column = "role", reference_value = "ref"),
234 list("/baseline/t_squared_ucl" = tol(sn$ucl, "Location limit still computed."),
235 "/monitoring_points/0/t_squared" = tol(sn$t2[[1]], "Location statistic."),
236 "/baseline/generalized_variance_available" = exact(FALSE, "Every subgroup covariance is singular when n <= p (line 83-85).")),
237 c("m(n - 1) = 24 >= p = 3, so the location chart is defined."), kind = "boundary")
A subgroup size of 1 is refused
Case STAT-QUAL-T2SUB-003 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2_SUB.json
Settings compared
reference_column= "role"reference_value= "ref"subgroup_column= "lot"subgroup_size= 1variables= ["v1", "v2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 22-24: a size of 1 points to the individual-observation chart.
- Montgomery's Phase-II subgroup T-squared F limit and Alt's b1/b2 determinant formulas use the configured m, n and p.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
238 emit("STAT-QUAL-T2SUB-003", sub_entry, "hotellingSubgroupsMenuItem", "A subgroup size of 1 is refused", "QUAL_T2_SUB",
239 modifyList(sub_config, list(subgroup_size = 1L)), list(),
240 c("Line 22-24: a size of 1 points to the individual-observation chart."), kind = "invalid_input",
241 error = list(error_class = "ValueError", message_contains = "individual"))
Subgroups larger than n stop the run
Case STAT-QUAL-T2SUB-004 · status: passed
Reference
- Evidence type
- R
- Source
- R base linear algebra (solve, det, cov) and stats::qf
- Citation
- Montgomery, Introduction to Statistical Quality Control, 6th ed., sec. 11.3 and Example 11.1; Alt, Multivariate Quality Control, Encyclopedia of Statistical Sciences 6, 1985, pp. 110-122; Lowry et al., Technometrics 34(1), 1992, pp. 46-53; R base::solve, base::det, stats::cov and stats::qf
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_multivariate_spc.R · sha256 07605e0a04ab57ce
- Dataset
- reference_data/datasets/QUAL_T2_SUB.json
Settings compared
reference_column= "role"reference_value= "ref"subgroup_column= "lot"subgroup_size= 4variables= ["v1", "v2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 36-38: a subgroup with more than n rows stops the run.
- Montgomery's Phase-II subgroup T-squared F limit and Alt's b1/b2 determinant formulas use the configured m, n and p.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
242 emit("STAT-QUAL-T2SUB-004", sub_entry, "hotellingSubgroupsMenuItem", "Subgroups larger than n stop the run", "QUAL_T2_SUB",
243 modifyList(sub_config, list(subgroup_size = 4L)), list(),
244 c("Line 36-38: a subgroup with more than n rows stops the run."), kind = "invalid_input",
245 error = list(error_class = "ValueError", message_contains = "G01"))
CUSUM with target and sigma from the data
Case STAT-QUAL-TW-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.3-4, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc323.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc324.htm; Montgomery, Introduction to Statistical Quality Control, 6th ed., ch. 9
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_TW.json
Settings compared
y_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/target | tolerance | 10.285364 | 10.285364 | 4.93E-16 | 16 | passed |
/sigma | tolerance | 0.77083837113243059 | 0.7708383711324305 | 1.12E-16 | 15 | passed |
/primary/points/49/value | tolerance | 3.831084958771636 | 3.8310849587716334 | 2.65E-15 | 15 | passed |
/secondary/points/49/value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/primary/upper_control_limit | tolerance | 3.8541918556621528 | 3.8541918556621524 | 4.12E-16 | 15 | passed |
/violation_keys | set | [] | [] | passed |
Convention
- Defaults k = 0.5 and h = 5 (line 180-182); accumulators start at zero.
- CUSUM/EWMA targets and sigma are known when supplied, otherwise estimated from the selected Phase-I baseline by the stated Tabelz convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
226 t0 <- mean(tw); s0 <- mean(abs(diff(tw))) / d2_2
227 cu <- cusum(tw, t0, s0, 0.5, 5)
228 emit("STAT-QUAL-TW-001", tw_entry, "CUSUM with target and sigma from the data", "QUAL_TW", list(y_column = "y"),
229 list("/target" = tol(t0, "Baseline mean."), "/sigma" = tol(s0, "MR-bar / d2(2)."),
230 "/primary/points/49/value" = tol(cu$up[50], "Final upper accumulator C+."),
231 "/secondary/points/49/value" = tol(cu$lo[50], "Final lower accumulator C-."),
232 "/primary/upper_control_limit" = tol(cu$H, "Decision interval H = h sigma."),
233 "/violation_keys" = set_of(cu$keys, "Points where an accumulator exceeds H.")),
234 c("Defaults k = 0.5 and h = 5 (line 180-182); accumulators start at zero."))
CUSUM with a supplied target and sigma
Case STAT-QUAL-TW-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.3-4, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc323.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc324.htm; Montgomery, Introduction to Statistical Quality Control, 6th ed., ch. 9
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_TW.json
Settings compared
cusum_h= 4cusum_k= 0.25sigma= 1.1target= 10y_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/points/30/value | tolerance | 2.7247000000000012 | 2.724700000000002 | 9.20E-16 | 15 | passed |
/violation_keys | set | ['primary:rule_1:39', 'primary:rule_1:40', 'primary:rule_1:4 | ['primary:rule_1:39', 'primary:rule_1:40', 'primary:rule_1:4 | passed |
Convention
- Supplied target 10 and sigma 1.1 override the baseline estimates (line 173-176).
- CUSUM/EWMA targets and sigma are known when supplied, otherwise estimated from the selected Phase-I baseline by the stated Tabelz convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
235 cu2 <- cusum(tw, 10, 1.1, 0.25, 4)
236 emit("STAT-QUAL-TW-002", tw_entry, "CUSUM with a supplied target and sigma", "QUAL_TW",
237 list(y_column = "y", target = 10, sigma = 1.1, cusum_k = 0.25, cusum_h = 4),
238 list("/primary/points/30/value" = tol(cu2$up[31], "C+ at point 31."),
239 "/violation_keys" = set_of(cu2$keys, "Points where an accumulator exceeds H.")),
240 c("Supplied target 10 and sigma 1.1 override the baseline estimates (line 173-176)."), kind = "axis_coverage")
EWMA with finite-time limits
Case STAT-QUAL-TW-003 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.3-4, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc323.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc324.htm; Montgomery, Introduction to Statistical Quality Control, 6th ed., ch. 9
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_TW.json
Settings compared
method= "ewma"y_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/points/0/value | tolerance | 9.9837512000000004 | 9.9837512 | 1.91E-17 | 17 | passed |
/primary/points/49/value | tolerance | 11.00812005771667 | 11.00812005771667 | 4.59E-16 | 16 | passed |
/primary/point_upper_limits | sequence | ['10.747867022679458', '10.877656862880958', '10.94750294361 | [10.747867022679458, 10.877656862880958, 10.947502943618526, | passed | ||
/primary/point_lower_limits | sequence | ['9.8228609773205413', '9.6930711371190412', '9.623225056381 | [9.822860977320541, 9.693071137119041, 9.623225056381473, 9. | passed | ||
/violation_keys | set | ['primary:rule_1:48'] | ['primary:rule_1:48'] | passed |
Convention
- Defaults lambda = 0.2 and L = 3 (line 195-196).
- CUSUM/EWMA targets and sigma are known when supplied, otherwise estimated from the selected Phase-I baseline by the stated Tabelz convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
241 ew <- ewma(tw, t0, s0, 0.2, 3)
242 emit("STAT-QUAL-TW-003", tw_entry, "EWMA with finite-time limits", "QUAL_TW", list(y_column = "y", method = "ewma"),
243 list("/primary/points/0/value" = tol(ew$z[1], "z_1 = lambda x_1 + (1 - lambda) T."),
244 "/primary/points/49/value" = tol(ew$z[50], "z_50."),
245 "/primary/point_upper_limits" = seqtol(ew$ucl, "T + L sigma sqrt(lambda/(2-lambda) (1 - (1-lambda)^(2i)))."),
246 "/primary/point_lower_limits" = seqtol(ew$lcl, "Mirror of the upper limits."),
247 "/violation_keys" = set_of(ew$keys, "Points beyond their limits.")),
248 c("Defaults lambda = 0.2 and L = 3 (line 195-196)."), kind = "axis_coverage")
EWMA with lambda 0.1, L 2.7 and a supplied target
Case STAT-QUAL-TW-004 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.3-4, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc323.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc324.htm; Montgomery, Introduction to Statistical Quality Control, 6th ed., ch. 9
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_TW.json
Settings compared
ewma_l= 2.7ewma_lambda= 0.1method= "ewma"target= 10y_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/primary/points/49/value | tolerance | 10.779236532523244 | 10.779236532523244 | 2.07E-16 | 16 | passed |
/primary/point_upper_limits | sequence | ['10.208126360205757', '10.280005380449408', '10.32683791458 | [10.208126360205757, 10.280005380449408, 10.326837914581214, | passed | ||
/violation_keys | set | ['primary:rule_1:40', 'primary:rule_1:41', 'primary:rule_1:4 | ['primary:rule_1:40', 'primary:rule_1:41', 'primary:rule_1:4 | passed |
Convention
- Sigma still comes from the data (MR-bar / d2).
- CUSUM/EWMA targets and sigma are known when supplied, otherwise estimated from the selected Phase-I baseline by the stated Tabelz convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
249 ew2 <- ewma(tw, 10, s0, 0.1, 2.7)
250 emit("STAT-QUAL-TW-004", tw_entry, "EWMA with lambda 0.1, L 2.7 and a supplied target", "QUAL_TW",
251 list(y_column = "y", method = "ewma", target = 10, ewma_lambda = 0.1, ewma_l = 2.7),
252 list("/primary/points/49/value" = tol(ew2$z[50], "z_50."),
253 "/primary/point_upper_limits" = seqtol(ew2$ucl, "Finite-time limits."),
254 "/violation_keys" = set_of(ew2$keys, "Points beyond their limits.")),
255 c("Sigma still comes from the data (MR-bar / d2)."), kind = "axis_coverage")
A non-positive sigma is refused
Case STAT-QUAL-TW-005 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.3-4, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc323.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc324.htm; Montgomery, Introduction to Statistical Quality Control, 6th ed., ch. 9
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_TW.json
Settings compared
sigma= 0y_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 176: a supplied sigma must be positive.
- CUSUM/EWMA targets and sigma are known when supplied, otherwise estimated from the selected Phase-I baseline by the stated Tabelz convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
256 emit("STAT-QUAL-TW-005", tw_entry, "A non-positive sigma is refused", "QUAL_TW",
257 list(y_column = "y", sigma = 0), list(), c("Line 176: a supplied sigma must be positive."), kind = "invalid_input",
258 error = list(error_class = "ValueError", message_contains = "igma must be positive"))
An EWMA lambda above 1 is refused
Case STAT-QUAL-TW-006 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded chart formulas in R
- Citation
- NIST/SEMATECH e-Handbook 6.3.2.3-4, https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc323.htm and https://www.itl.nist.gov/div898/handbook/pmc/section3/pmc324.htm; Montgomery, Introduction to Statistical Quality Control, 6th ed., ch. 9
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_spc_attributes.R · sha256 6e47cf20f469f98b
- Dataset
- reference_data/datasets/QUAL_TW.json
Settings compared
ewma_lambda= 1.5method= "ewma"y_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 195: 0 < lambda <= 1.
- CUSUM/EWMA targets and sigma are known when supplied, otherwise estimated from the selected Phase-I baseline by the stated Tabelz convention.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
259 emit("STAT-QUAL-TW-006", tw_entry, "An EWMA lambda above 1 is refused", "QUAL_TW",
260 list(y_column = "y", method = "ewma", ewma_lambda = 1.5), list(), c("Line 195: 0 < lambda <= 1."), kind = "invalid_input",
261 error = list(error_class = "ValueError", message_contains = "ambda"))
known sigma one-sided variables plan
Case STAT-QUAL-VARACC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats analytic normal/noncentral-t formulas
- Citation
- R stats::pnorm, stats::qnorm, stats::pt and stats::uniroot documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_variables_acceptance.R · sha256 a00adcb842fc579c
- Dataset
- None
Settings compared
aql= 0.02consumer_risk= 0.1ltpd= 0.1max_sample_size= 500oc_points= 11producer_risk= 0.05sigma= 2.25sigma_status= "known"spec_limit= 87.5spec_side= "upper"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sample_size | exact | 15 | 15 | 0.00E+2 | passed | |
/acceptance_constant | tolerance | 1.6207 | 1.6207 | 2.95E-17 | 16 | passed |
/probability_accept_aql | tolerance | 0.95324745220222451 | 0.9532474522022247 | 2.22E-16 | 15 | passed |
/probability_accept_ltpd | tolerance | 0.09450452637064613 | 0.09450452637064594 | 1.94E-16 | 14 | passed |
Convention
- Manual chapter 64: Pa(p)=Phi(sqrt(n)*(z_p-k)) for known sigma, with z_p=qnorm(1-p).
- For unknown sigma Pa(p)=P(T>=sqrt(n)*k), T noncentral-t(df=n-1,ncp=sqrt(n)*z_p).
- R scans n from 2 to 500, solves the two k bounds, takes their midpoint and quantizes down to four decimals.
- Upper and lower specification sides share the same one-sided OC probability by symmetry.
Reference code
The lines of the reference script that produce this case's expected values.
71 for (status in c("known", "unknown")) {
72 config <- list(spec_side = if (status == "known") "upper" else "lower",
73 spec_limit = if (status == "known") 87.5 else 12.5,
74 sigma_status = status, aql = 0.02, ltpd = 0.10,
75 producer_risk = 0.05, consumer_risk = 0.10,
76 max_sample_size = 500L, oc_points = 11L)
77 if (status == "known") config$sigma <- 2.25
78 result <- plan(config)
79 id <- if (status == "known") "STAT-QUAL-VARACC-001" else "STAT-QUAL-VARACC-002"
80 outputs <- list("/sample_size" = exact(result$n,
81 "First n with a feasible k interval; one fewer n fails a risk constraint."))
82 deferred <- list()
83 if (status == "known") {
84 outputs[["/acceptance_constant"]] <- tol(result$k,
85 "Midpoint k quantized down to four decimals; owner 1e-9 tier.")
86 outputs[["/probability_accept_aql"]] <- tol(result$aql,
87 "Normal AQL acceptance probability; owner 1e-9 tier.")
88 outputs[["/probability_accept_ltpd"]] <- tol(result$ltpd,
89 "Normal LTPD acceptance probability; owner 1e-9 tier.")
90 } else {
91 deferred <- lapply(c("/acceptance_constant", "/probability_accept_aql",
92 "/probability_accept_ltpd"), function(path)
93 list(path = path, reason = "reference precision below tier"))
94 }
95 emit(id, paste(status, "sigma one-sided variables plan"), config,
96 outputs,
97 c("Manual chapter 64: Pa(p)=Phi(sqrt(n)*(z_p-k)) for known sigma, with z_p=qnorm(1-p).",
98 "For unknown sigma Pa(p)=P(T>=sqrt(n)*k), T noncentral-t(df=n-1,ncp=sqrt(n)*z_p).",
99 "R scans n from 2 to 500, solves the two k bounds, takes their midpoint and quantizes down to four decimals.",
unknown sigma one-sided variables plan
Case STAT-QUAL-VARACC-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats analytic normal/noncentral-t formulas
- Citation
- R stats::pnorm, stats::qnorm, stats::pt and stats::uniroot documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/quality_variables_acceptance.R · sha256 a00adcb842fc579c
- Dataset
- None
Settings compared
aql= 0.02consumer_risk= 0.1ltpd= 0.1max_sample_size= 500oc_points= 11producer_risk= 0.05sigma_status= "unknown"spec_limit= 12.5spec_side= "lower"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sample_size | exact | 35 | 35 | 0.00E+2 | passed |
Convention
- Manual chapter 64: Pa(p)=Phi(sqrt(n)*(z_p-k)) for known sigma, with z_p=qnorm(1-p).
- For unknown sigma Pa(p)=P(T>=sqrt(n)*k), T noncentral-t(df=n-1,ncp=sqrt(n)*z_p).
- R scans n from 2 to 500, solves the two k bounds, takes their midpoint and quantizes down to four decimals.
- Upper and lower specification sides share the same one-sided OC probability by symmetry.
- R pt warned that full precision may not be achieved; continuous outputs are deferred at the owner 1e-9 tier.
Reference code
The lines of the reference script that produce this case's expected values.
71 for (status in c("known", "unknown")) {
72 config <- list(spec_side = if (status == "known") "upper" else "lower",
73 spec_limit = if (status == "known") 87.5 else 12.5,
74 sigma_status = status, aql = 0.02, ltpd = 0.10,
75 producer_risk = 0.05, consumer_risk = 0.10,
76 max_sample_size = 500L, oc_points = 11L)
77 if (status == "known") config$sigma <- 2.25
78 result <- plan(config)
79 id <- if (status == "known") "STAT-QUAL-VARACC-001" else "STAT-QUAL-VARACC-002"
80 outputs <- list("/sample_size" = exact(result$n,
81 "First n with a feasible k interval; one fewer n fails a risk constraint."))
82 deferred <- list()
83 if (status == "known") {
84 outputs[["/acceptance_constant"]] <- tol(result$k,
85 "Midpoint k quantized down to four decimals; owner 1e-9 tier.")
86 outputs[["/probability_accept_aql"]] <- tol(result$aql,
87 "Normal AQL acceptance probability; owner 1e-9 tier.")
88 outputs[["/probability_accept_ltpd"]] <- tol(result$ltpd,
89 "Normal LTPD acceptance probability; owner 1e-9 tier.")
90 } else {
91 deferred <- lapply(c("/acceptance_constant", "/probability_accept_aql",
92 "/probability_accept_ltpd"), function(path)
93 list(path = path, reason = "reference precision below tier"))
94 }
95 emit(id, paste(status, "sigma one-sided variables plan"), config,
96 outputs,
97 c("Manual chapter 64: Pa(p)=Phi(sqrt(n)*(z_p-k)) for known sigma, with z_p=qnorm(1-p).",
98 "For unknown sigma Pa(p)=P(T>=sqrt(n)*k), T noncentral-t(df=n-1,ncp=sqrt(n)*z_p).",
99 "R scans n from 2 to 500, solves the two k bounds, takes their midpoint and quantizes down to four decimals.",
Zone chart of subgroup means with R-bar within sigma
Case STAT-QUAL-ZONE-001 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded zone scoring rule (Jaehn 1987) with stats::integrate chart constants
- Citation
- Jaehn, A. H. (1987) Zone control charts: SPC made easy, Quality 26(10), 51-53; Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 constants
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_ZONE_01.json
Settings compared
response= "value"statistic= "subgroup_mean"subgroup_column= "sample"subgroup_mode= "column"within_sigma= "rbar"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stages/0/center | tolerance | 50.957250000000002 | 50.95725 | 6.73E-17 | 17 | passed |
/stages/0/sigma | tolerance | 2.0716446652272769 | 2.0716446652272795 | 2.62E-15 | 14 | passed |
/points/0/scale | tolerance | 1.0358223326136384 | 1.0358223326136398 | 1.36E-15 | 14 | passed |
/stages/0/signals | exact | 6 | 6 | 0.00E+2 | passed | |
/signal_count | exact | 6 | 6 | 0.00E+2 | passed | |
/customized_signal | exact | False | False | passed | ||
/source_count | exact | 40 | 40 | 0.00E+2 | passed | |
/dropped_subgroup_count | exact | 0 | 0 | 0.00E+2 | passed | |
/points/0/z | tolerance | -2.4398489204448017 | -2.4398489204448057 | 4.02E-15 | 14 | passed |
/points/0/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/0/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/0/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/0/signal | exact | False | False | passed | ||
/points/1/z | tolerance | -2.2419385322001895 | -2.2419385322001864 | 3.15E-15 | 14 | passed |
/points/1/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/1/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/1/score | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/points/1/signal | exact | True | True | passed | ||
/points/2/z | tolerance | -0.834843942607436 | -0.8348439426074349 | 1.11E-15 | 14 | passed |
/points/2/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/2/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/2/score | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/points/2/signal | exact | True | True | passed | ||
/points/3/z | tolerance | -1.3223792892587882 | -1.3223792892587865 | 1.75E-15 | 14 | passed |
/points/3/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/3/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/3/score | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/points/3/signal | exact | True | True | passed | ||
/points/4/z | tolerance | -1.6602750740666559 | -1.6602750740666468 | 9.14E-15 | 14 | passed |
/points/4/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/4/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/4/score | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/points/4/signal | exact | True | True | passed | ||
/points/5/z | tolerance | 0.64224334526695182 | 0.6422433452669509 | 8.93E-16 | 14 | passed |
/points/5/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/5/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/5/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/5/signal | exact | False | False | passed | ||
/points/6/z | tolerance | 0.35261838686020519 | 0.35261838686020475 | 4.43E-16 | 14 | passed |
/points/6/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/6/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/6/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/6/signal | exact | False | False | passed | ||
/points/7/z | tolerance | 2.6406555582734681 | 2.640655558273465 | 3.11E-15 | 14 | passed |
/points/7/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/7/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/7/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/7/signal | exact | False | False | passed | ||
/points/8/z | tolerance | 3.3840262848507772 | 3.3840262848507656 | 1.16E-14 | 14 | passed |
/points/8/zone | exact | 4 | 4 | 0.00E+2 | passed | |
/points/8/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/8/score | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/points/8/signal | exact | True | True | passed | ||
/points/9/z | tolerance | 1.4797421833264486 | 1.4797421833264466 | 2.02E-15 | 14 | passed |
/points/9/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/9/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/9/score | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/points/9/signal | exact | True | True | passed |
Convention
- docs/manual/chapters/84-subgroup-monitoring.tex:103-107: z_i = (xbar_i - c)/(sigma_w/sqrt(n_i)); the centre is the size-weighted mean of the baseline observations; the I chart of subgroup means uses its MR scale.
- docs/manual/chapters/84-subgroup-monitoring.tex:112-120: zones at 1, 2, 3 with boundary points in the inner zone; weights 0, 2, 4, 8 and signal score 8; scores accumulate on one side, a strict side change starts a new score with that point's weight; a centre-line point adds zero; reset after signal restarts the next point from zero.
- Expected computed from the re-read QUAL_ZONE_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
249 set.seed(20261011)
250 zone_means <- c(50.0, 49.5, 50.4, 49.8, 50.2, 51.6, 52.0, 51.8, 52.4, 52.1)
251 zone_value <- round(rep(zone_means, each = 4) + rnorm(40, 0, 2), 2)
252 zone_gap <- zone_value; zone_gap[15] <- NA
253 zd <- data.frame(value = zone_value, sample = rep(1:10, each = 4), stage = rep(c("P", "Q"), each = 20),
254 value_gap = zone_gap, stringsAsFactors = FALSE)
255 export_dataset(zd, "QUAL_ZONE_01",
256 "Simulated (R 4.6.1, set.seed 20261011): ten samples of four fill weights whose mean shifts upward in the second half; value_gap is value with row 15 missing; 40 rows",
257 "Simulated with stats::rnorm", "Constructed validation data; no third-party license.",
258 c(value = "Float64", sample = "Int64", stage = "String", value_gap = "Float64"))
259 z <- read_dataset("QUAL_ZONE_01")
260 zone_ep <- "tabelz.analysis.spc_zone:compute_zone_chart"
261 zone_menu <- "zoneChartMenuItem"
262 zone_source <- "Hand-coded zone scoring rule (Jaehn 1987) with stats::integrate chart constants"
263 zone_cite <- "Jaehn, A. H. (1987) Zone control charts: SPC made easy, Quality 26(10), 51-53; Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 constants"
264 zone_req <- "REQ-STAT-QUAL-ZONE-001"
Zone chart of subgroup means with S-bar within sigma
Case STAT-QUAL-ZONE-002 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded zone scoring rule (Jaehn 1987) with stats::integrate chart constants
- Citation
- Jaehn, A. H. (1987) Zone control charts: SPC made easy, Quality 26(10), 51-53; Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 constants
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_ZONE_01.json
Settings compared
response= "value"statistic= "subgroup_mean"subgroup_column= "sample"subgroup_mode= "column"within_sigma= "sbar"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stages/0/sigma | tolerance | 2.0832099546656182 | 2.0832099546656186 | 4.46E-16 | 15 | passed |
/signal_count | exact | 6 | 6 | 0.00E+2 | passed | |
/points/0/z | tolerance | -2.426303689976038 | -2.426303689976044 | 6.18E-15 | 14 | passed |
/points/0/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/0/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/0/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/0/signal | exact | False | False | passed | ||
/points/1/z | tolerance | -2.2294920344433047 | -2.2294920344433042 | 4.62E-16 | 15 | passed |
/points/1/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/1/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/1/score | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/points/1/signal | exact | True | True | passed | ||
/points/2/z | tolerance | -0.8302091664484238 | -0.8302091664484236 | 2.26E-16 | 15 | passed |
/points/2/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/2/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/2/score | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/points/2/signal | exact | True | True | passed | ||
/points/3/z | tolerance | -1.3150378788583177 | -1.3150378788583175 | 2.34E-16 | 15 | passed |
/points/3/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/3/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/3/score | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/points/3/signal | exact | True | True | passed | ||
/points/4/z | tolerance | -1.6510577785483429 | -1.6510577785483356 | 7.32E-15 | 14 | passed |
/points/4/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/4/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/4/score | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/points/4/signal | exact | True | True | passed | ||
/points/5/z | tolerance | 0.63867782362510983 | 0.6386778236251096 | 2.21E-16 | 15 | passed |
/points/5/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/5/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/5/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/5/signal | exact | False | False | passed | ||
/points/6/z | tolerance | 0.3506607667479425 | 0.3506607667479424 | 1.13E-16 | 15 | passed |
/points/6/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/6/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/6/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/6/signal | exact | False | False | passed | ||
/points/7/z | tolerance | 2.6259955160775297 | 2.625995516077529 | 9.09E-16 | 15 | passed |
/points/7/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/7/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/7/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/7/signal | exact | False | False | passed | ||
/points/8/z | tolerance | 3.3652392953955848 | 3.365239295395577 | 7.60E-15 | 14 | passed |
/points/8/zone | exact | 4 | 4 | 0.00E+2 | passed | |
/points/8/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/8/score | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/points/8/signal | exact | True | True | passed | ||
/points/9/z | tolerance | 1.4715271464282398 | 1.4715271464282396 | 2.37E-16 | 15 | passed |
/points/9/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/9/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/9/score | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/points/9/signal | exact | True | True | passed |
Convention
- docs/manual/chapters/84-subgroup-monitoring.tex:103-107: z_i = (xbar_i - c)/(sigma_w/sqrt(n_i)); the centre is the size-weighted mean of the baseline observations; the I chart of subgroup means uses its MR scale.
- docs/manual/chapters/84-subgroup-monitoring.tex:112-120: zones at 1, 2, 3 with boundary points in the inner zone; weights 0, 2, 4, 8 and signal score 8; scores accumulate on one side, a strict side change starts a new score with that point's weight; a centre-line point adds zero; reset after signal restarts the next point from zero.
- within_sigma = sbar: the scale is S-bar/c4(n) divided by sqrt(n_i).
- Expected computed from the re-read QUAL_ZONE_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
292 zz <- (zmeans - zcenter) / (sigma_s / sqrt(zsizes))
293 steps <- zone_scores(zz)
294 out <- c(list("/stages/0/sigma" = num(sigma_s, "Mean of s_i/c4(4)."), "/signal_count" = exact(as.integer(sum(steps$signal)), "Signalling points.")),
295 zone_outputs(steps, zz))
296 emit("STAT-QUAL-ZONE-002", zone_ep, zone_menu, "Zone chart of subgroup means with S-bar within sigma", "QUAL_ZONE_01",
297 list(response = "value", statistic = "subgroup_mean", subgroup_mode = "column", subgroup_column = "sample", within_sigma = "sbar"),
298 out, c(zone_notes, "within_sigma = sbar: the scale is S-bar/c4(n) divided by sqrt(n_i)."), zone_source, zone_cite, zone_req, kind = "axis_coverage")
Zone chart as an individuals chart of subgroup means
Case STAT-QUAL-ZONE-003 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded zone scoring rule (Jaehn 1987) with stats::integrate chart constants
- Citation
- Jaehn, A. H. (1987) Zone control charts: SPC made easy, Quality 26(10), 51-53; Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 constants
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_ZONE_01.json
Settings compared
response= "value"statistic= "individuals_of_means"subgroup_mode= "size"subgroup_size= 4
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stages/0/sigma | tolerance | 1.0157145262272456 | 1.0157145262272433 | 2.26E-15 | 14 | passed |
/points/0/scale | tolerance | 1.0157145262272456 | 1.0157145262272433 | 2.26E-15 | 14 | passed |
/signal_count | exact | 6 | 6 | 0.00E+2 | passed | |
/points/0/z | tolerance | -2.4881499030905672 | -2.4881499030905796 | 1.24E-14 | 14 | passed |
/points/0/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/0/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/0/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/0/signal | exact | False | False | passed | ||
/points/1/z | tolerance | -2.2863215401927217 | -2.2863215401927266 | 4.90E-15 | 14 | passed |
/points/1/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/1/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/1/score | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/points/1/signal | exact | True | True | passed | ||
/points/2/z | tolerance | -0.85137110641905944 | -0.8513711064190613 | 1.89E-15 | 14 | passed |
/points/2/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/2/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/2/score | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/points/2/signal | exact | True | True | passed | ||
/points/3/z | tolerance | -1.3485580491673992 | -1.348558049167402 | 2.87E-15 | 14 | passed |
/points/3/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/3/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/3/score | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/points/3/signal | exact | True | True | passed | ||
/points/4/z | tolerance | -1.6931430589929808 | -1.6931430589929775 | 3.34E-15 | 14 | passed |
/points/4/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/4/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/4/score | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/points/4/signal | exact | True | True | passed | ||
/points/5/z | tolerance | 0.65495765081847823 | 0.6549576508184797 | 1.45E-15 | 14 | passed |
/points/5/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/5/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/5/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/5/signal | exact | False | False | passed | ||
/points/6/z | tolerance | 0.35959907096797666 | 0.35959907096797744 | 7.81E-16 | 14 | passed |
/points/6/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/6/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/6/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/6/signal | exact | False | False | passed | ||
/points/7/z | tolerance | 2.6929318517869034 | 2.692931851786909 | 5.79E-15 | 14 | passed |
/points/7/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/7/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/7/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/7/signal | exact | False | False | passed | ||
/points/8/z | tolerance | 3.451018873403183 | 3.4510188734031835 | 4.73E-16 | 15 | passed |
/points/8/zone | exact | 4 | 4 | 0.00E+2 | passed | |
/points/8/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/8/score | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/points/8/signal | exact | True | True | passed | ||
/points/9/z | tolerance | 1.5090362108861661 | 1.5090362108861695 | 3.36E-15 | 14 | passed |
/points/9/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/9/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/9/score | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/points/9/signal | exact | True | True | passed |
Convention
- docs/manual/chapters/84-subgroup-monitoring.tex:103-107: z_i = (xbar_i - c)/(sigma_w/sqrt(n_i)); the centre is the size-weighted mean of the baseline observations; the I chart of subgroup means uses its MR scale.
- docs/manual/chapters/84-subgroup-monitoring.tex:112-120: zones at 1, 2, 3 with boundary points in the inner zone; weights 0, 2, 4, 8 and signal score 8; scores accumulate on one side, a strict side change starts a new score with that point's weight; a centre-line point adds zero; reset after signal restarts the next point from zero.
- statistic = individuals_of_means: the scale is MR-bar/d2(2) of the consecutive subgroup means (chapter 84 line 106); the centre stays the size-weighted mean, which equals the mean of the means for equal sizes.
- Expected computed from the re-read QUAL_ZONE_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
301 sigma_i <- mean(abs(diff(zmeans))) / d2_2
302 zz <- (zmeans - zcenter) / sigma_i
303 steps <- zone_scores(zz)
304 out <- c(list("/stages/0/sigma" = num(sigma_i, "MR-bar of the subgroup means / d2(2)."),
305 "/points/0/scale" = num(sigma_i, "The MR scale is not divided by sqrt(n)."),
306 "/signal_count" = exact(as.integer(sum(steps$signal)), "Signalling points.")),
307 zone_outputs(steps, zz))
308 emit("STAT-QUAL-ZONE-003", zone_ep, zone_menu, "Zone chart as an individuals chart of subgroup means", "QUAL_ZONE_01",
309 list(response = "value", statistic = "individuals_of_means", subgroup_mode = "size", subgroup_size = 4L),
310 out, c(zone_notes, "statistic = individuals_of_means: the scale is MR-bar/d2(2) of the consecutive subgroup means (chapter 84 line 106); the centre stays the size-weighted mean, which equals the mean of the means for equal sizes."),
311 zone_source, zone_cite, zone_req, kind = "axis_coverage")
Zone chart with custom weights, reset after signal and two stages
Case STAT-QUAL-ZONE-004 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded zone scoring rule (Jaehn 1987) with stats::integrate chart constants
- Citation
- Jaehn, A. H. (1987) Zone control charts: SPC made easy, Quality 26(10), 51-53; Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 constants
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_ZONE_01.json
Settings compared
reset_after_signal= trueresponse= "value"signal_score= 6stage_column= "stage"statistic= "subgroup_mean"subgroup_column= "sample"subgroup_mode= "column"weights= [0, 1, 3, 6]within_sigma= "rbar"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/customized_signal | exact | False | False | passed | ||
/weights/1 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/reset_after_signal | exact | True | True | passed | ||
/stages/0/center | tolerance | 49.1965 | 49.1965 | 3.41E-16 | 17 | passed |
/stages/0/sigma | tolerance | 2.122646468239906 | 2.122646468239908 | 2.21E-15 | 14 | passed |
/stages/0/signals | exact | 0 | 0 | 0.00E+2 | passed | |
/points/0/z | tolerance | -0.72221164613962385 | -0.7222116461396297 | 5.89E-15 | 14 | passed |
/points/0/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/0/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/0/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/0/signal | exact | False | False | passed | ||
/points/1/z | tolerance | -0.52905654182308548 | -0.5290565418230849 | 5.55E-16 | 14 | passed |
/points/1/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/1/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/1/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/1/signal | exact | False | False | passed | ||
/points/2/z | tolerance | 0.8442291388664096 | 0.8442291388664087 | 8.87E-16 | 14 | passed |
/points/2/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/2/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/2/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/2/signal | exact | False | False | passed | ||
/points/3/z | tolerance | 0.36840802823299595 | 0.36840802823299557 | 3.84E-16 | 14 | passed |
/points/3/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/3/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/3/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/3/signal | exact | False | False | passed | ||
/points/4/z | tolerance | 0.03863102086330366 | 0.038631020863310314 | 6.65E-15 | 12 | passed |
/points/4/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/4/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/4/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/4/signal | exact | False | False | passed | ||
/stages/1/center | tolerance | 52.717999999999996 | 52.717999999999996 | 4.19E-16 | 17 | passed |
/stages/1/sigma | tolerance | 2.0206428622146477 | 2.02064286221465 | 2.25E-15 | 14 | passed |
/stages/1/signals | exact | 0 | 0 | 0.00E+2 | passed | |
/points/5/z | tolerance | -1.0843083856979194 | -1.0843083856979183 | 1.08E-15 | 15 | passed |
/points/5/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/5/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/5/score | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/points/5/signal | exact | False | False | passed | ||
/points/6/z | tolerance | -1.3812435894490671 | -1.3812435894490656 | 1.54E-15 | 14 | passed |
/points/6/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/6/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/6/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/6/signal | exact | False | False | passed | ||
/points/7/z | tolerance | 0.96454452018496317 | 0.9645445201849622 | 9.97E-16 | 14 | passed |
/points/7/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/7/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/7/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/7/signal | exact | False | False | passed | ||
/points/8/z | tolerance | 1.726678209812901 | 1.726678209812892 | 8.89E-15 | 14 | passed |
/points/8/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/8/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/8/score | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/points/8/signal | exact | False | False | passed | ||
/points/9/z | tolerance | -0.22567075485086346 | -0.22567075485086321 | 2.46E-16 | 14 | passed |
/points/9/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/9/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/9/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/9/signal | exact | False | False | passed | ||
/signal_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/84-subgroup-monitoring.tex:103-107: z_i = (xbar_i - c)/(sigma_w/sqrt(n_i)); the centre is the size-weighted mean of the baseline observations; the I chart of subgroup means uses its MR scale.
- docs/manual/chapters/84-subgroup-monitoring.tex:112-120: zones at 1, 2, 3 with boundary points in the inner zone; weights 0, 2, 4, 8 and signal score 8; scores accumulate on one side, a strict side change starts a new score with that point's weight; a centre-line point adds zero; reset after signal restarts the next point from zero.
- Weights 0, 1, 3, 6 with signal 6: a signalling point keeps its score and the next point starts from zero (chapter 84 lines 118-120); each stage (P: samples 1-5, Q: samples 6-10) estimates its own centre and sigma and starts a new accumulation.
- Expected computed from the re-read QUAL_ZONE_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
328 out[["/signal_count"]] <- exact(as.integer(total_signals), "Signals over both stages.")
329 emit("STAT-QUAL-ZONE-004", zone_ep, zone_menu, "Zone chart with custom weights, reset after signal and two stages", "QUAL_ZONE_01",
330 list(response = "value", statistic = "subgroup_mean", subgroup_mode = "column", subgroup_column = "sample", stage_column = "stage",
331 within_sigma = "rbar", weights = list(0, 1, 3, 6), signal_score = 6, reset_after_signal = TRUE),
332 out, c(zone_notes, "Weights 0, 1, 3, 6 with signal 6: a signalling point keeps its score and the next point starts from zero (chapter 84 lines 118-120); each stage (P: samples 1-5, Q: samples 6-10) estimates its own centre and sigma and starts a new accumulation."),
333 zone_source, zone_cite, zone_req, kind = "axis_coverage")
Raw-individual zone chart with a missing observation
Case STAT-QUAL-ZONE-005 · status: passed
Reference
- Evidence type
- R
- Source
- Hand-coded zone scoring rule (Jaehn 1987) with stats::integrate chart constants
- Citation
- Jaehn, A. H. (1987) Zone control charts: SPC made easy, Quality 26(10), 51-53; Montgomery, Introduction to Statistical Quality Control, 7th ed., ch. 6 constants
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, nlme 3.1.169
- Reference script
- generators/r/quality_subgroup_capability.R · sha256 301362213a445f16
- Dataset
- reference_data/datasets/QUAL_ZONE_01.json
Settings compared
response= "value_gap"statistic= "raw_individuals"subgroup_mode= "individual"units= "g"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stages/0/center | tolerance | 50.936410256410255 | 50.936410256410255 | 2.15E-16 | 17 | passed |
/stages/0/sigma | tolerance | 2.2502978282780162 | 2.250297828278016 | 3.44E-17 | 16 | passed |
/stages/0/mean_moving_range | tolerance | 2.5391891891891887 | 2.5391891891891887 | 2.21E-17 | 17 | passed |
/stages/0/moving_ranges | exact | 37 | 37 | 0.00E+2 | passed | |
/stages/0/subgroups | exact | 39 | 39 | 0.00E+2 | passed | |
/gap_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/units | exact | g | g | passed | ||
/signal_count | exact | 8 | 8 | 0.00E+2 | passed | |
/points/14/event | exact | after_gap | after_gap | passed | ||
/points/0/z | tolerance | -0.35835712334457426 | -0.35835712334457426 | 2.35E-18 | 17 | passed |
/points/0/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/0/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/0/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/0/signal | exact | False | False | passed | ||
/points/1/z | tolerance | -0.59832535919947916 | -0.5983253591994792 | 3.52E-18 | 17 | passed |
/points/1/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/1/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/1/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/1/signal | exact | False | False | passed | ||
/points/2/z | tolerance | -1.3671124851790846 | -1.3671124851790846 | 3.11E-17 | 16 | passed |
/points/2/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/2/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/2/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/2/signal | exact | False | False | passed | ||
/points/3/z | tolerance | -2.1314557549391528 | -2.131455754939153 | 4.68E-17 | 16 | passed |
/points/3/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/3/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/3/score | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/points/3/signal | exact | False | False | passed | ||
/points/4/z | tolerance | -1.3760001976181535 | -1.3760001976181535 | 8.83E-18 | 17 | passed |
/points/4/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/4/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/4/score | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/points/4/signal | exact | True | True | passed | ||
/points/5/z | tolerance | 0.38821072153735298 | 0.388210721537353 | 3.73E-18 | 17 | passed |
/points/5/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/5/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/5/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/5/signal | exact | False | False | passed | ||
/points/6/z | tolerance | -1.1404758179827861 | -1.140475817982786 | 2.24E-17 | 16 | passed |
/points/6/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/6/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/6/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/6/signal | exact | False | False | passed | ||
/points/7/z | tolerance | -1.9625892185968108 | -1.9625892185968108 | 8.31E-18 | 17 | passed |
/points/7/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/7/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/7/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/7/signal | exact | False | False | passed | ||
/points/8/z | tolerance | -0.91383915078648448 | -0.9138391507864845 | 2.39E-18 | 17 | passed |
/points/8/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/8/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/8/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/8/signal | exact | False | False | passed | ||
/points/9/z | tolerance | -0.81607431395670882 | -0.8160743139567088 | 1.09E-18 | 17 | passed |
/points/9/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/9/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/9/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/9/signal | exact | False | False | passed | ||
/points/10/z | tolerance | -0.26947999895387054 | -0.26947999895387054 | 3.52E-18 | 16 | passed |
/points/10/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/10/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/10/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/10/signal | exact | False | False | passed | ||
/points/11/z | tolerance | 0.49930712702573504 | 0.49930712702573504 | 2.47E-18 | 17 | passed |
/points/11/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/11/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/11/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/11/signal | exact | False | False | passed | ||
/points/12/z | tolerance | -1.0471548373725448 | -1.0471548373725448 | 2.22E-17 | 16 | passed |
/points/12/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/12/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/12/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/12/signal | exact | False | False | passed | ||
/points/13/z | tolerance | 0.094916211048022711 | 0.09491621104802271 | 1.39E-19 | 17 | passed |
/points/13/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/13/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/13/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/13/signal | exact | False | False | passed | ||
/points/14/z | tolerance | -1.8159419633521472 | -1.8159419633521472 | 7.38E-18 | 17 | passed |
/points/14/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/14/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/14/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/14/signal | exact | False | False | passed | ||
/points/15/z | tolerance | -0.14505202480688212 | -0.14505202480688212 | 1.70E-18 | 16 | passed |
/points/15/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/15/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/15/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/15/signal | exact | False | False | passed | ||
/points/16/z | tolerance | -0.68720248359018599 | -0.687202483590186 | 3.73E-18 | 17 | passed |
/points/16/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/16/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/16/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/16/signal | exact | False | False | passed | ||
/points/17/z | tolerance | -2.087017192743799 | -2.087017192743799 | 4.33E-17 | 16 | passed |
/points/17/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/17/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/17/score | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/points/17/signal | exact | False | False | passed | ||
/points/18/z | tolerance | -0.10061346261152868 | -0.10061346261152868 | 4.35E-18 | 16 | passed |
/points/18/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/18/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/18/score | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/points/18/signal | exact | False | False | passed | ||
/points/19/z | tolerance | -0.46056581639388755 | -0.46056581639388755 | 4.51E-19 | 18 | passed |
/points/19/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/19/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/19/score | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/points/19/signal | exact | False | False | passed | ||
/points/20/z | tolerance | 1.0992277166629956 | 1.0992277166629956 | 3.13E-17 | 16 | passed |
/points/20/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/20/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/20/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/20/signal | exact | False | False | passed | ||
/points/21/z | tolerance | -0.35835712334457426 | -0.35835712334457426 | 2.35E-18 | 17 | passed |
/points/21/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/21/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/21/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/21/signal | exact | False | False | passed | ||
/points/22/z | tolerance | 0.93924889275972567 | 0.9392488927597257 | 3.15E-18 | 17 | passed |
/points/22/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/22/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/22/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/22/signal | exact | False | False | passed | ||
/points/23/z | tolerance | -0.60721307163855109 | -0.6072130716385511 | 4.01E-18 | 17 | passed |
/points/23/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/23/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/23/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/23/signal | exact | False | False | passed | ||
/points/24/z | tolerance | 1.6591536003244434 | 1.6591536003244434 | 3.28E-17 | 16 | passed |
/points/24/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/24/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/24/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/24/signal | exact | False | False | passed | ||
/points/25/z | tolerance | 0.72594379422203348 | 0.7259437942220335 | 1.71E-18 | 17 | passed |
/points/25/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/25/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/25/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/25/signal | exact | False | False | passed | ||
/points/26/z | tolerance | -1.0915933995678984 | -1.0915933995678984 | 4.08E-17 | 16 | passed |
/points/26/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/26/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/26/score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/points/26/signal | exact | False | False | passed | ||
/points/27/z | tolerance | 2.5657002691096404 | 2.5657002691096404 | 4.12E-17 | 16 | passed |
/points/27/zone | exact | 3 | 3 | 0.00E+2 | passed | |
/points/27/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/27/score | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/points/27/signal | exact | False | False | passed | ||
/points/28/z | tolerance | 1.0725645793457861 | 1.072564579345786 | 1.56E-17 | 16 | passed |
/points/28/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/28/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/28/score | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/points/28/signal | exact | False | False | passed | ||
/points/29/z | tolerance | 0.21045647275593915 | 0.21045647275593915 | 1.54E-19 | 18 | passed |
/points/29/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/29/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/29/score | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/points/29/signal | exact | False | False | passed | ||
/points/30/z | tolerance | 1.0503452982481076 | 1.0503452982481076 | 2.83E-17 | 16 | passed |
/points/30/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/30/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/30/score | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/points/30/signal | exact | True | True | passed | ||
/points/31/z | tolerance | 1.5747203321532708 | 1.5747203321532708 | 1.46E-17 | 17 | passed |
/points/31/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/31/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/31/score | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/points/31/signal | exact | True | True | passed | ||
/points/32/z | tolerance | 1.55694490727513 | 1.55694490727513 | 1.89E-17 | 16 | passed |
/points/32/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/32/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/32/score | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/points/32/signal | exact | True | True | passed | ||
/points/33/z | tolerance | 1.1836609848341682 | 1.1836609848341682 | 4.94E-17 | 16 | passed |
/points/33/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/33/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/33/score | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/points/33/signal | exact | True | True | passed | ||
/points/34/z | tolerance | 1.9524481108137703 | 1.9524481108137703 | 4.33E-17 | 16 | passed |
/points/34/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/34/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/34/score | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/points/34/signal | exact | True | True | passed | ||
/points/35/z | tolerance | 0.72594379422203348 | 0.7259437942220335 | 1.71E-18 | 17 | passed |
/points/35/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/35/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/35/score | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/points/35/signal | exact | True | True | passed | ||
/points/36/z | tolerance | 1.6902605938611905 | 1.6902605938611905 | 4.12E-17 | 16 | passed |
/points/36/zone | exact | 2 | 2 | 0.00E+2 | passed | |
/points/36/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/36/score | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/points/36/signal | exact | True | True | passed | ||
/points/37/z | tolerance | -0.11838888748966943 | -0.11838888748966943 | 1.79E-18 | 16 | passed |
/points/37/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/37/side | exact | -1 | -1 | 0.00E+2 | passed | |
/points/37/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/37/signal | exact | False | False | passed | ||
/points/38/z | tolerance | 0.46375627726945035 | 0.46375627726945035 | 4.54E-18 | 17 | passed |
/points/38/zone | exact | 1 | 1 | 0.00E+2 | passed | |
/points/38/side | exact | 1 | 1 | 0.00E+2 | passed | |
/points/38/score | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/points/38/signal | exact | False | False | passed |
Convention
- docs/manual/chapters/103-raw-zone.tex:9-20: centre is the mean of the finite observations; sigma = MR-bar/(2/sqrt(pi)) over consecutive eligible pairs; z = (x - xbar)/sigma with no sqrt(n); missing rows break adjacency and restart score accumulation.
- docs/manual/chapters/103-raw-zone.tex:22-24: same zones, weights 0, 2, 4, 8 and signal 8; the score restarts after the gap, so the two runs are scored separately.
- docs/manual/chapters/84-subgroup-monitoring.tex:112-120: zones at 1, 2, 3 with boundary points in the inner zone; weights 0, 2, 4, 8 and signal score 8; scores accumulate on one side, a strict side change starts a new score with that point's weight; a centre-line point adds zero; reset after signal restarts the next point from zero.
- Expected computed from the re-read QUAL_ZONE_01 CSV.
Reference code
The lines of the reference script that produce this case's expected values.
336 x <- z$value_gap
337 present <- which(!is.na(x)); xv <- x[present]
338 centre <- mean(xv)
339 adjacent <- diff(present) == 1
340 mr <- abs(diff(xv))[adjacent]
341 sigma_raw <- mean(mr) / d2_2
342 zz <- (xv - centre) / sigma_raw
343 runs <- cumsum(c(TRUE, !adjacent))
344 steps <- do.call(rbind, lapply(split(seq_along(zz), runs), function(idx) zone_scores(zz[idx])))
345 out <- c(list("/stages/0/center" = num(centre, "Mean of the 39 finite observations."),
346 "/stages/0/sigma" = num(sigma_raw, "MR-bar of adjacent observations / d2(2); no sqrt(n)."),
347 "/stages/0/mean_moving_range" = num(mean(mr), "Mean of the 37 adjacent moving ranges; none spans the missing row."),
348 "/stages/0/moving_ranges" = exact(length(mr), "Adjacent pairs."),
349 "/stages/0/subgroups" = exact(length(xv), "Observations in the stage."),
350 "/gap_count" = exact(1L, "The missing row breaks adjacency once."),
351 "/missing_count" = exact(1L, "One missing observation."),
352 "/units" = exact("g", "Units recorded with the raw chart."),
353 "/signal_count" = exact(as.integer(sum(steps$signal)), "Signals over both runs."),
354 "/points/14/event" = exact("after_gap", "The observation after the missing row starts a new run.")),
355 zone_outputs(steps, zz))
356 emit("STAT-QUAL-ZONE-005", zone_ep, zone_menu, "Raw-individual zone chart with a missing observation", "QUAL_ZONE_01",
357 list(response = "value_gap", statistic = "raw_individuals", subgroup_mode = "individual", units = "g"),
358 out, c("docs/manual/chapters/103-raw-zone.tex:9-20: centre is the mean of the finite observations; sigma = MR-bar/(2/sqrt(pi)) over consecutive eligible pairs; z = (x - xbar)/sigma with no sqrt(n); missing rows break adjacency and restart score accumulation.",
359 "docs/manual/chapters/103-raw-zone.tex:22-24: same zones, weights 0, 2, 4, 8 and signal 8; the score restarts after the gap, so the two runs are scored separately.",
360 zone_notes[2]),
361 zone_source, zone_cite, zone_req, kind = "axis_coverage")
Regression II remaining axis STAT-REG-AXIS-ADV-DA-MEAN-LDA-001
Case STAT-REG-AXIS-ADV-DA-MEAN-LDA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_DISCRIMINANT_MISSING.json
Settings compared
imputation= "mean"model= "lda"predictors= ["x"]prior_mode= "equal"response= "class"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_predictor_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- R class means and pooled covariance are fitted after mean filling on training rows; NumPy split moments deferred.
- R re-reads exported CSV.
Reference code
Whole script generators/r/regression_advanced_remaining_axes.R
Regression II remaining axis STAT-REG-AXIS-ADV-DA-MEAN-QDA-001
Case STAT-REG-AXIS-ADV-DA-MEAN-QDA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_DISCRIMINANT_MISSING.json
Settings compared
imputation= "mean"model= "qda"predictors= ["x"]prior_mode= "equal"response= "class"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_predictor_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- R class means and pooled covariance are fitted after mean filling on training rows; NumPy split moments deferred.
- R re-reads exported CSV.
Reference code
Whole script generators/r/regression_advanced_remaining_axes.R
Regression II option axis STAT-REG-AXIS-ADV-DA-PRIOR-CUSTOM-001
Case STAT-REG-AXIS-ADV-DA-PRIOR-CUSTOM-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
custom_priors= [0.7, 0.3]model= "lda"predictors= ["x"]prior_mode= "custom"response= "class"standardize= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/artifact/priors/0 | tolerance | 0.69999999999999996 | 0.7 | 4.41E-18 | 17 | passed |
Convention
- MASS::lda prior chosen explicitly; balanced design has observed prior 1/2.
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-DA-PRIOR-OBSERVED-001
Case STAT-REG-AXIS-ADV-DA-PRIOR-OBSERVED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
model= "lda"predictors= ["x"]prior_mode= "observed"response= "class"standardize= true
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/artifact/priors/0 | tolerance | 0.5 | 0.5 | 0.00E+1 | passed |
Convention
- MASS::lda prior chosen explicitly; balanced design has observed prior 1/2.
- R re-reads the exported CSV.
Reference code
Regression II remaining axis STAT-REG-AXIS-ADV-DA-SCORE-MEAN-001
Case STAT-REG-AXIS-ADV-DA-SCORE-MEAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_DISCRIMINANT_MISSING.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "lda", "imputation": "mean", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [0], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/1/probabilities/0 | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/1/row_id | exact | STAT-REG-AXIS-ADV-DA-SCORE-MEAN-001:1 | STAT-REG-AXIS-ADV-DA-SCORE-MEAN-001:1 | passed |
Convention
- Stored full-population LDA artifact uses zero training mean; the 50/50 class tie has no unique label.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
123 lda_score$artifact$imputation <- "mean"
124 lda_score$artifact$imputation_values <- list(0)
125 filled_x <- da$x
126 filled_x[is.na(filled_x)] <- 0
127 lda_ref <- MASS::lda(class ~ x, data = read_dataset("REG_DISCRIMINANT"),
128 prior = c(0.5, 0.5))
129 lda_pred <- stats::predict(lda_ref, newdata = data.frame(x = filled_x))
130 emit("STAT-REG-AXIS-ADV-DA-SCORE-MEAN-001", "STAT-REG-DISCRIMINANT-SCORE-LDA-001",
131 "REG_DISCRIMINANT_MISSING", lda_score,
132 list("/1/probabilities/0" = tol(lda_pred$posterior[2L, 1L],
133 "R LDA posterior after mean filling", "1e-9"),
134 "/1/row_id" = exact("STAT-REG-AXIS-ADV-DA-SCORE-MEAN-001:1",
135 "missing-x source row keeps identity")),
136 "Stored full-population LDA artifact uses zero training mean; the 50/50 class tie has no unique label.")Whole script generators/r/regression_advanced_remaining_axes.R
Regression II option axis STAT-REG-AXIS-ADV-MIXED-CATEGORICAL-001
Case STAT-REG-AXIS-ADV-MIXED-CATEGORICAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
estimation= "reml"fixed_categorical_columns= ["sex"]fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.66018518518518554 | 0.6601851851851851 | 4.43E-16 | 15 | passed |
/analyzed_count | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- Female/Male factor levels are alphabetic; nlme random intercept is REML.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
65 mixed <- nlme::lme(distance ~ age + sex, random = ~1 | subject, data = orth,
66 method = "REML", control = nlme::lmeControl(opt = "optim"))
67 emit("STAT-REG-AXIS-ADV-MIXED-CATEGORICAL-001", "STAT-REG-MIXED-REML-001",
68 "REG_ORTHODONT", list(response_column = "distance", group_column = "subject",
69 fixed_numeric_columns = list("age"),
70 fixed_categorical_columns = list("sex"), estimation = "reml"),
71 list("/coefficients/1/estimate" = tol(nlme::fixef(mixed)[["age"]], "adjusted age slope"),
72 "/analyzed_count" = exact(as.integer(nrow(orth)), "complete observations")),
73 list("Female/Male factor levels are alphabetic; nlme random intercept is REML."))
Regression II option axis STAT-REG-AXIS-ADV-NONLINEAR-4PL-001
Case STAT-REG-AXIS-ADV-NONLINEAR-4PL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_4PL.json
Settings compared
curve= "four_parameter_logistic"parameters= [{"name": "lo", "start": 1, "lower": 0, "upper": 3}, {"name": "hi", "start": 5, "lower": 2, "upper": 8}, {"name": "mid", "start": 4, "lower": 0.1, "upper": 10}, {"name": "slope", "start": 2, "lower": 0.1, "upper": 5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/estimates/2 | tolerance | 3.9562545374796203 | 3.9562545363235766 | 1.16E-9 | 9 | passed |
/artifact/estimates/3 | tolerance | 2.0211389313295189 | 2.0211389326586517 | 1.33E-9 | 9 | passed |
Convention
- R nls port curve matches manual 4PL direction and positive midpoint/slope.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
125 logistic_fit <- stats::nls(y ~ lo + (hi - lo) / (1 + (x / mid)^slope), data = logistic,
126 start = list(lo = 1, hi = 5, mid = 4, slope = 2),
127 algorithm = "port",
128 lower = c(lo = 0, hi = 2, mid = 0.1, slope = 0.1),
129 upper = c(lo = 3, hi = 8, mid = 10, slope = 5),
130 control = stats::nls.control(maxiter = 1000, tol = 1e-12))
131 emit("STAT-REG-AXIS-ADV-NONLINEAR-4PL-001", "STAT-REG-NONLINEAR-DECAY-001",
132 "REG_4PL", list(x_column = "x", response = "y", curve = "four_parameter_logistic",
133 parameters = list(list(name = "lo", start = 1, lower = 0, upper = 3),
134 list(name = "hi", start = 5, lower = 2, upper = 8),
135 list(name = "mid", start = 4, lower = 0.1, upper = 10),
136 list(name = "slope", start = 2, lower = 0.1, upper = 5))),
137 list("/artifact/estimates/2" = tol(coef(logistic_fit)[["mid"]], "four-parameter midpoint"),
138 "/artifact/estimates/3" = tol(coef(logistic_fit)[["slope"]], "four-parameter slope")),
139 list("R nls port curve matches manual 4PL direction and positive midpoint/slope."),
140 kind = "nominal")
Regression II option axis STAT-REG-AXIS-ADV-NONLINEAR-GROWTH-001
Case STAT-REG-AXIS-ADV-NONLINEAR-GROWTH-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_GROWTH.json
Settings compared
curve= "asymptotic_growth"parameters= [{"name": "a", "start": 4, "lower": 0, "upper": 10}, {"name": "k", "start": 0.8, "lower": 0.01, "upper": 3}, {"name": "c", "start": 1, "lower": 0, "upper": 5}]response= "growth"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/estimates/0 | tolerance | 3.9812497207258604 | 3.9812497212211793 | 4.95E-10 | 9 | passed |
/artifact/estimates/1 | tolerance | 0.79285348703672465 | 0.7928534872687004 | 2.32E-10 | 9 | passed |
Convention
- NLS port bounded fit on original response scale; same parameter order as manual.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
110 growth_fit <- stats::nls(growth ~ c + a * (1 - exp(-k * x)), data = curve,
111 start = list(a = 4, k = 0.8, c = 1), algorithm = "port",
112 lower = c(a = 0, k = 0.01, c = 0),
113 upper = c(a = 10, k = 3, c = 5),
114 control = stats::nls.control(maxiter = 1000, tol = 1e-12))
115 emit("STAT-REG-AXIS-ADV-NONLINEAR-GROWTH-001", "STAT-REG-NONLINEAR-DECAY-001",
116 "REG_GROWTH",
117 list(x_column = "x", response = "growth", curve = "asymptotic_growth",
118 parameters = list(list(name = "a", start = 4, lower = 0, upper = 10),
119 list(name = "k", start = 0.8, lower = 0.01, upper = 3),
120 list(name = "c", start = 1, lower = 0, upper = 5))),
121 list("/artifact/estimates/0" = tol(coef(growth_fit)[["a"]], "growth amplitude"),
122 "/artifact/estimates/1" = tol(coef(growth_fit)[["k"]], "growth rate")),
123 list("NLS port bounded fit on original response scale; same parameter order as manual."),
124 kind = "nominal")
Regression II option axis STAT-REG-AXIS-ADV-PANEL-90-001
Case STAT-REG-AXIS-ADV-PANEL-90-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
confidence_level= 0.9entity_column= "subject"predictor_columns= ["age"]response_column= "distance"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/estimate | tolerance | 0.6601851851851851 | 0.6601851851851851 | 2.81E-18 | 17 | passed |
Convention
- 90% intervals change quantile only; plm within slope is invariant.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
102 panel <- plm::plm(distance ~ age, data = orth, index = c("subject", "time"),
103 model = "within", effect = "individual")
104 emit("STAT-REG-AXIS-ADV-PANEL-90-001", "STAT-REG-PANEL-001", "REG_ORTHODONT",
105 list(response_column = "distance", predictor_columns = list("age"),
106 entity_column = "subject", time_column = "time", confidence_level = 0.9),
107 list("/coefficients/0/estimate" = tol(coef(panel)[["age"]], "within age slope", "1e-9")),
108 list("90% intervals change quantile only; plm within slope is invariant."))
Regression II remaining axis STAT-REG-AXIS-ADV-PLS-MEAN-001
Case STAT-REG-AXIS-ADV-PLS-MEAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_PLS_MISSING.json
Settings compared
cv_folds= 3imputation= "mean"predictors= ["x"]response= "y"scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_predictor_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- PLS mean filling uses training-only mean; random train split prevents R coefficient oracle.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
97 emit("STAT-REG-AXIS-ADV-PLS-MEAN-001", "STAT-REG-PLS-FIT-001",
98 "REG_PLS_MISSING", list(response = "y", predictors = list("x"),
99 imputation = "mean", scale = FALSE, cv_folds = 3L),
100 list("/source_count" = exact(as.integer(nrow(pls_data)), "source rows"),
101 "/missing_response_count" = exact(1L, "one missing y"),
102 "/incomplete_predictor_count" = exact(0L, "mean-filled x retained")),
103 "PLS mean filling uses training-only mean; random train split prevents R coefficient oracle.",
104 kind = "determinism", repeat_count = 2L,
105 deferred = list(list(path = "/artifact/coefficients",
106 reason = "NumPy training split/CV folds are not reproducible with R RNG.")))Whole script generators/r/regression_advanced_remaining_axes.R
Regression II option axis STAT-REG-AXIS-ADV-PLS-SCALE-001
Case STAT-REG-AXIS-ADV-PLS-SCALE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_PLS.json
Settings compared
cv_folds= 3predictors= ["x"]response= "y"scale= trueseed= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/training_metrics/row_count | exact | 23 | 23 | 0.00E+2 | passed |
Convention
- R pls::plsr scale=TRUE; split-dependent coefficients deferred.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
171 emit("STAT-REG-AXIS-ADV-PLS-SCALE-001", "STAT-REG-PLS-FIT-001", "REG_PLS",
172 list(response = "y", predictors = list("x"), scale = TRUE, cv_folds = 3L,
173 seed = 3L),
174 list("/source_count" = exact(as.integer(nrow(pls_data)), "complete PLS source"),
175 "/training_metrics/row_count" = exact(23L, "floor(0.25*30) held out")),
176 list("R pls::plsr scale=TRUE; split-dependent coefficients deferred."),
177 kind = "determinism", repeat_count = 2L,
178 deferred = list(list(path = "/artifact/coefficients",
179 reason = "NumPy-selected train rows and CV folds differ from R RNG.")))
Regression II remaining axis STAT-REG-AXIS-ADV-PLS-SCORE-MEAN-001
Case STAT-REG-AXIS-ADV-PLS-SCORE-MEAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_PLS_MISSING.json
Settings compared
artifact= {"response": "y", "predictors": ["x"], "imputation": "mean", "scale": false, "component_count": 1, "imputation_values": [15.5], "x_means": [15.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/1/predicted | tolerance | 34.000466750593802 | 34.0004667505938 | 3.65E-16 | 16 | passed |
/1/row_id | exact | STAT-REG-AXIS-ADV-PLS-SCORE-MEAN-001:1 | STAT-REG-AXIS-ADV-PLS-SCORE-MEAN-001:1 | passed |
Convention
- Mean imputation inserts stored training x_mean; centered PLS prediction equals intercept.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
139 pls_score$artifact$imputation <- "mean"
140 pls_score$artifact$imputation_values <- list(pls_score$artifact$x_means[[1L]])
141 expected_mean <- as.double(pls_score$artifact$intercept)
142 emit("STAT-REG-AXIS-ADV-PLS-SCORE-MEAN-001", "STAT-REG-PLS-SCORE-001",
143 "REG_PLS_MISSING", pls_score,
144 list("/1/predicted" = tol(expected_mean,
145 "centered PLS prediction at training mean", "1e-9"),
146 "/1/row_id" = exact("STAT-REG-AXIS-ADV-PLS-SCORE-MEAN-001:1",
147 "missing-x source row keeps identity")),
148 "Mean imputation inserts stored training x_mean; centered PLS prediction equals intercept.")Whole script generators/r/regression_advanced_remaining_axes.R
Regression II option axis STAT-REG-AXIS-ADV-SELECTION-AIC-BACKWARD-001
Case STAT-REG-AXIS-ADV-SELECTION-AIC-BACKWARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age", "age_sq"]criterion= "aic"direction= "backward"method= "stepwise"response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/selected | set | ['age_sq'] | ['age_sq'] | passed | ||
/n | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- R step backward criterion aic with k= 2 and explicit null/full scope.
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-SELECTION-AIC-BOTH-001
Case STAT-REG-AXIS-ADV-SELECTION-AIC-BOTH-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age", "age_sq"]criterion= "aic"direction= "both"method= "stepwise"response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/selected | set | ['age_sq'] | ['age_sq'] | passed | ||
/n | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- R step both criterion aic with k= 2 and explicit null/full scope.
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-SELECTION-AIC-FORWARD-001
Case STAT-REG-AXIS-ADV-SELECTION-AIC-FORWARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age", "age_sq"]criterion= "aic"direction= "forward"method= "stepwise"response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/selected | set | ['age_sq'] | ['age_sq'] | passed | ||
/n | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- R step forward criterion aic with k= 2 and explicit null/full scope.
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-SELECTION-BEST-AIC-001
Case STAT-REG-AXIS-ADV-SELECTION-BEST-AIC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age", "age_sq"]criterion= "aic"method= "best_subsets"response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/selected | set | ['age_sq'] | ['age_sq'] | passed |
Convention
- R AIC enumerates all three nonempty two-predictor subsets; BIC uses k=log(n).
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-SELECTION-BEST-BIC-001
Case STAT-REG-AXIS-ADV-SELECTION-BEST-BIC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age", "age_sq"]criterion= "bic"method= "best_subsets"response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/selected | set | ['age_sq'] | ['age_sq'] | passed |
Convention
- R AIC enumerates all three nonempty two-predictor subsets; BIC uses k=log(n).
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-SELECTION-BIC-BACKWARD-001
Case STAT-REG-AXIS-ADV-SELECTION-BIC-BACKWARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age", "age_sq"]criterion= "bic"direction= "backward"method= "stepwise"response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/selected | set | ['age_sq'] | ['age_sq'] | passed | ||
/n | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- R step backward criterion bic with k= 4.6821312271242199 and explicit null/full scope.
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-SELECTION-BIC-BOTH-001
Case STAT-REG-AXIS-ADV-SELECTION-BIC-BOTH-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age", "age_sq"]criterion= "bic"direction= "both"method= "stepwise"response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/selected | set | ['age_sq'] | ['age_sq'] | passed | ||
/n | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- R step both criterion bic with k= 4.6821312271242199 and explicit null/full scope.
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-SELECTION-BIC-FORWARD-001
Case STAT-REG-AXIS-ADV-SELECTION-BIC-FORWARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age", "age_sq"]criterion= "bic"direction= "forward"method= "stepwise"response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/selected | set | ['age_sq'] | ['age_sq'] | passed | ||
/n | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- R step forward criterion bic with k= 4.6821312271242199 and explicit null/full scope.
- R re-reads the exported CSV.
Reference code
Regression II option axis STAT-REG-AXIS-ADV-STRUCT-CROSSED-001
Case STAT-REG-AXIS-ADV-STRUCT-CROSSED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_CROSSED.json
Settings compared
components= [{"name": "a", "level_column": "a", "relation": "crossed"}, {"name": "b", "level_column": "b", "relation": "crossed"}]estimation= "reml"fixed_numeric_columns= ["x"]max_rows= 1000model_mode= "variance_components"response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.7989671110061346 | 0.798967110981314 | 2.48E-11 | 10 | passed |
/analyzed_count | exact | 64 | 64 | 0.00E+2 | passed |
Convention
- Two independent crossed grouping factors; lmer REML; bobyqa maxfun 100000.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
75 crossed_fit <- lme4::lmer(y ~ x + (1 | a) + (1 | b), data = crossed, REML = TRUE,
76 control = lme4::lmerControl(optimizer = "bobyqa",
77 optCtrl = list(maxfun = 100000L)))
78 crossed_config <- list(response_column = "y", fixed_numeric_columns = list("x"),
79 model_mode = "variance_components",
80 components = list(list(name = "a", level_column = "a", relation = "crossed"),
81 list(name = "b", level_column = "b", relation = "crossed")),
82 estimation = "reml", max_rows = 1000L)
83 emit("STAT-REG-AXIS-ADV-STRUCT-CROSSED-001", "STAT-REG-MIXED-STRUCT-SLOPE-001",
84 "REG_CROSSED", crossed_config,
85 list("/coefficients/1/estimate" = tol(lme4::fixef(crossed_fit)[["x"]],
86 "crossed random-intercept fixed slope"),
87 "/analyzed_count" = exact(as.integer(nrow(crossed)), "balanced crossed cells")),
88 list("Two independent crossed grouping factors; lmer REML; bobyqa maxfun 100000."),
89 kind = "nominal")
Regression II option axis STAT-REG-AXIS-ADV-STRUCT-CROSSED-ML-001
Case STAT-REG-AXIS-ADV-STRUCT-CROSSED-ML-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_CROSSED.json
Settings compared
components= [{"name": "a", "level_column": "a", "relation": "crossed"}, {"name": "b", "level_column": "b", "relation": "crossed"}]estimation= "ml"fixed_numeric_columns= ["x"]max_rows= 1000model_mode= "variance_components"response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.79896941240533648 | 0.7989694124050418 | 2.95E-13 | 12 | passed |
Convention
- Variance-component mode with ML explicitly; do not compare REML likelihoods.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
90 crossed_fit_ml <- lme4::lmer(y ~ x + (1 | a) + (1 | b), data = crossed, REML = FALSE,
91 control = lme4::lmerControl(optimizer = "bobyqa",
92 optCtrl = list(maxfun = 100000L)))
93 crossed_config_ml <- crossed_config
94 crossed_config_ml$estimation <- "ml"
95 emit("STAT-REG-AXIS-ADV-STRUCT-CROSSED-ML-001", "STAT-REG-MIXED-STRUCT-SLOPE-001",
96 "REG_CROSSED", crossed_config_ml,
97 list("/coefficients/1/estimate" = tol(lme4::fixef(crossed_fit_ml)[["x"]],
98 "ML crossed-model fixed slope")),
99 list("Variance-component mode with ML explicitly; do not compare REML likelihoods."),
100 kind = "axis_coverage")
Regression II remaining axis STAT-REG-AXIS-ADV-STRUCT-NESTED-001
Case STAT-REG-AXIS-ADV-STRUCT-NESTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_ADV_NESTED.json
Settings compared
components= [{"name": "a", "level_column": "a", "relation": "crossed"}, {"name": "ab", "level_column": "ab", "relation": "nested", "parent_column": "a"}]estimation= "reml"fixed_numeric_columns= ["x"]max_rows= 1000model_mode= "variance_components"response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.79895617346657066 | 0.7989561734713525 | 4.78E-12 | 11 | passed |
/analyzed_count | exact | 64 | 64 | 0.00E+2 | passed |
Convention
- R lmer a and a:ab random intercepts; ab labels are unique within parent a.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
45 nested_fit <- lme4::lmer(y ~ x + (1 | a) + (1 | a:ab), data = nested, REML = TRUE,
46 control = lme4::lmerControl(optimizer = "bobyqa",
47 optCtrl = list(maxfun = 100000L)))
48 emit("STAT-REG-AXIS-ADV-STRUCT-NESTED-001", "STAT-REG-MIXED-STRUCT-SLOPE-001",
49 "REG_ADV_NESTED", list(response_column = "y", fixed_numeric_columns = list("x"),
50 model_mode = "variance_components", estimation = "reml",
51 max_rows = 1000L,
52 components = list(list(name = "a", level_column = "a",
53 relation = "crossed"),
54 list(name = "ab", level_column = "ab",
55 relation = "nested", parent_column = "a"))),
56 list("/coefficients/1/estimate" = tol(lme4::fixef(nested_fit)[["x"]],
57 "nested fixed slope"),
58 "/analyzed_count" = exact(as.integer(nrow(nested)), "all nested observations")),
59 "R lmer a and a:ab random intercepts; ab labels are unique within parent a.")Whole script generators/r/regression_advanced_remaining_axes.R
Regression II remaining axis STAT-REG-AXIS-ADV-TREE-BALANCED-001
Case STAT-REG-AXIS-ADV-TREE-BALANCED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
class_weight= "balanced"cv_folds= 2max_depth= 1min_samples_leaf= 1numeric_predictors= ["x"]positive_class= "B"response= "class"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/threshold/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/source_count | exact | 40 | 40 | 0.00E+2 | passed |
Convention
- Balanced weights on an exactly balanced two-class table preserve the pure split.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
62 class_cfg$class_weight <- "balanced"
63 class_cfg$split_assignment <- NULL
64 emit("STAT-REG-AXIS-ADV-TREE-BALANCED-001", "STAT-REG-TREE-CLASS-001",
65 "REG_TREE", class_cfg,
66 list("/artifact/threshold/0" = tol(0, "unambiguous class split", "1e-12"),
67 "/source_count" = exact(as.integer(nrow(tree)), "complete source rows")),
68 "Balanced weights on an exactly balanced two-class table preserve the pure split.",
69 kind = "determinism", repeat_count = 2L)Whole script generators/r/regression_advanced_remaining_axes.R
Regression II remaining axis STAT-REG-AXIS-ADV-TREE-REG-SEED-001
Case STAT-REG-AXIS-ADV-TREE-REG-SEED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
cv_folds= 2depth_grid= [1]max_depth= 1min_leaf_grid= [1]numeric_predictors= ["x"]response= "y"seed= 7
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/threshold/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/source_count | exact | 40 | 40 | 0.00E+2 | passed |
Convention
- Seed changes the holdout, not the pure two-leaf split; repeat verifies replay.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
72 reg_cfg$seed <- 7L
73 emit("STAT-REG-AXIS-ADV-TREE-REG-SEED-001", "STAT-REG-TREE-REG-001",
74 "REG_TREE", reg_cfg,
75 list("/artifact/threshold/0" = tol(0, "unambiguous numeric split", "1e-12"),
76 "/source_count" = exact(as.integer(nrow(tree)), "complete source rows")),
77 "Seed changes the holdout, not the pure two-leaf split; repeat verifies replay.",
78 kind = "determinism", repeat_count = 2L)Whole script generators/r/regression_advanced_remaining_axes.R
Regression II remaining axis STAT-REG-AXIS-ADV-VALIDATED-KNN-001
Case STAT-REG-AXIS-ADV-VALIDATED-KNN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_PLS_MISSING.json
Settings compared
algorithm= "ols"cv_folds= 3imputation= "knn"numeric_predictors= ["x"]response= "y"seed= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_numeric_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- R verifies population arithmetic; imputer is trained after NumPy split.
- R re-reads exported CSV.
Reference code
Whole script generators/r/regression_advanced_remaining_axes.R
Regression II option axis STAT-REG-AXIS-ADV-VALIDATED-LASSO-001
Case STAT-REG-AXIS-ADV-VALIDATED-LASSO-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
algorithm= "lasso"cv_folds= 3imputation= "drop"numeric_predictors= ["age"]response= "distance"seed= 7test_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 108 | 108 | 0.00E+2 | passed | |
/training_metrics/row_count | exact | 81 | 81 | 0.00E+2 | passed |
Convention
- R verifies population counts; NumPy split and CV folds are not R reproducible.
- R re-reads the exported CSV.
Reference code
Regression II remaining axis STAT-REG-AXIS-ADV-VALIDATED-MEAN-001
Case STAT-REG-AXIS-ADV-VALIDATED-MEAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lme4/rpart/MASS/pls
- Citation
- R lme4::lmer, rpart::rpart, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, lme4 2.0.6, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_remaining_axes.R · sha256 b1f30831b6d1324e
- Dataset
- reference_data/datasets/REG_PLS_MISSING.json
Settings compared
algorithm= "ols"cv_folds= 3imputation= "mean"numeric_predictors= ["x"]response= "y"seed= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_numeric_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- R verifies population arithmetic; imputer is trained after NumPy split.
- R re-reads exported CSV.
Reference code
Whole script generators/r/regression_advanced_remaining_axes.R
Regression II option axis STAT-REG-AXIS-ADV-VALIDATED-RIDGE-001
Case STAT-REG-AXIS-ADV-VALIDATED-RIDGE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R statistical packages
- Citation
- R nlme::lme, lme4::lmer, plm::plm, stats::nls/step, MASS::lda, pls::plsr
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, lme4 2.0.6, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_axes.R · sha256 603ee3cda6c6de34
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
algorithm= "ridge"cv_folds= 3imputation= "drop"numeric_predictors= ["age"]response= "distance"seed= 7test_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 108 | 108 | 0.00E+2 | passed | |
/training_metrics/row_count | exact | 81 | 81 | 0.00E+2 | passed |
Convention
- R verifies population counts; NumPy split and CV folds are not R reproducible.
- R re-reads the exported CSV.
Reference code
Fit axis STAT-REG-AXIS-FIT-CLUSTER-001
Case STAT-REG-AXIS-FIT-CLUSTER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
cluster_column= "cluster"covariance= "cluster"x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/std_error | tolerance | 0.0056683229933789442 | 0.005668322993378932 | 1.22E-17 | 14 | passed |
Convention
- Manual CR1 factor is G/(G-1)*(N-1)/(N-K); cluster scores are row sums of x_i*e_i.
- No random split is applied; G=12 clusters.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
116 X <- stats::model.matrix(default_fit)
117 e <- stats::residuals(default_fit)
118 score <- rowsum(X * as.vector(e), group = d$cluster)
119 B <- solve(crossprod(X))
120 G <- nrow(score)
121 N <- nrow(X)
122 K <- ncol(X)
123 cluster_cov <- (G / (G - 1)) * ((N - 1) / (N - K)) * B %*% crossprod(score) %*% B
124 emit("STAT-REG-AXIS-FIT-CLUSTER-001", fit_entry, "REG_CORE",
125 list(y_columns = list("y"), x_columns = list("x", "z"),
126 covariance = "cluster", cluster_column = "cluster"),
127 list("/responses/0/parameters/1/std_error" = tol(sqrt(diag(cluster_cov))[["x"]],
128 "CR1 x SE")),
129 list("Manual CR1 factor is G/(G-1)*(N-1)/(N-K); cluster scores are row sums of x_i*e_i.",
130 "No random split is applied; G=12 clusters."))
Fit axis STAT-REG-AXIS-FIT-EXPONENTIAL-001
Case STAT-REG-AXIS-FIT-EXPONENTIAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
model_type= "exponential"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/estimate | tolerance | 0.10938214953488003 | 0.10938214953488005 | 2.49E-17 | 15 | passed |
Convention
- Exponential fits log(y) against untransformed x; the reported coefficient is on log scale.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
57 exp_fit <- stats::lm(log(y) ~ x, data = p)
58 emit("STAT-REG-AXIS-FIT-EXPONENTIAL-001", fit_entry, "REG_POSITIVE",
59 list(y_columns = list("y"), x_columns = list("x"), model_type = "exponential"),
60 list("/responses/0/parameters/1/estimate" = tol(coef(exp_fit)[["x"]], "log-response slope")),
61 list("Exponential fits log(y) against untransformed x; the reported coefficient is on log scale."))
Fit axis STAT-REG-AXIS-FIT-HC3-001
Case STAT-REG-AXIS-FIT-HC3-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariance= "hc3"x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/std_error | tolerance | 0.032520095298630536 | 0.032520095298630536 | 1.71E-19 | 17 | passed |
Convention
- HC3 sandwich covariance, t inference with N-K residual degrees of freedom.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
110 hc3 <- sandwich::vcovHC(default_fit, type = "HC3")
111 emit("STAT-REG-AXIS-FIT-HC3-001", fit_entry, "REG_CORE",
112 list(y_columns = list("y"), x_columns = list("x", "z"), covariance = "hc3"),
113 list("/responses/0/parameters/1/std_error" = tol(sqrt(diag(hc3))[["x"]], "HC3 x SE")),
114 list("HC3 sandwich covariance, t inference with N-K residual degrees of freedom."))
Fit axis STAT-REG-AXIS-FIT-INTERACTIONS-001
Case STAT-REG-AXIS-FIT-INTERACTIONS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
interactions= truex_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/3/estimate | tolerance | 0.00056180945707337148 | 0.0005618094570734719 | 1.00E-16 | 12 | passed |
Convention
- Pairwise interaction is the product x*z, added after main effects.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
79 interaction <- stats::lm(y ~ x * z, data = d)
80 emit("STAT-REG-AXIS-FIT-INTERACTIONS-001", fit_entry, "REG_CORE",
81 list(y_columns = list("y"), x_columns = list("x", "z"), interactions = TRUE),
82 list("/responses/0/parameters/3/estimate" = tol(coef(interaction)[["x:z"]], "x:z slope")),
83 list("Pairwise interaction is the product x*z, added after main effects."))
Fit axis STAT-REG-AXIS-FIT-LASSO-001
Case STAT-REG-AXIS-FIT-LASSO-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CENTERED.json
Settings compared
algorithm= "lasso"cv_folds= 3x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/0/estimate | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/responses/0/observations | exact | 72 | 72 | 0.00E+2 | passed |
Convention
- For an unpenalized intercept, mean(x)=0 makes intercept=mean(y) for every penalty.
- The selected penalty itself depends on Python's seeded K-fold assignment and is deferred.
- All numeric references use re-read exported CSV values.
Reference code
Fit axis STAT-REG-AXIS-FIT-LOGARITHMIC-001
Case STAT-REG-AXIS-FIT-LOGARITHMIC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
model_type= "logarithmic"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/estimate | tolerance | 4.796541840656344 | 4.796541840656344 | 3.57E-17 | 17 | passed |
Convention
- Logarithmic model fits untransformed y against log(x).
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
62 log_fit <- stats::lm(y ~ log(x), data = p)
63 emit("STAT-REG-AXIS-FIT-LOGARITHMIC-001", fit_entry, "REG_POSITIVE",
64 list(y_columns = list("y"), x_columns = list("x"), model_type = "logarithmic"),
65 list("/responses/0/parameters/1/estimate" = tol(coef(log_fit)[[2]], "log-x slope")),
66 list("Logarithmic model fits untransformed y against log(x)."))
Fit axis STAT-REG-AXIS-FIT-MISSING-KNN-001
Case STAT-REG-AXIS-FIT-MISSING-KNN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
missing= "knn"x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/estimate | tolerance | 1.398762625407082 | 1.3987626254070822 | 1.83E-16 | 15 | passed |
Convention
- REG_CORE has no missing selected values, so this strategy's fitted model equals R complete-data OLS.
- All numeric references use re-read exported CSV values.
Reference code
Fit axis STAT-REG-AXIS-FIT-MISSING-NEIGHBOR-AVERAGE-001
Case STAT-REG-AXIS-FIT-MISSING-NEIGHBOR-AVERAGE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
missing= "neighbor_average"x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/estimate | tolerance | 1.398762625407082 | 1.3987626254070822 | 1.83E-16 | 15 | passed |
Convention
- REG_CORE has no missing selected values, so this strategy's fitted model equals R complete-data OLS.
- All numeric references use re-read exported CSV values.
Reference code
Fit axis STAT-REG-AXIS-FIT-POLYNOMIAL-001
Case STAT-REG-AXIS-FIT-POLYNOMIAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/2/estimate | tolerance | 0.013633366063093101 | 0.013633366063092869 | 2.32E-16 | 13 | passed |
Convention
- Polynomial degree two adds the square of numeric x.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
52 poly <- stats::lm(y ~ x + I(x^2), data = p)
53 emit("STAT-REG-AXIS-FIT-POLYNOMIAL-001", fit_entry, "REG_POSITIVE",
54 list(y_columns = list("y"), x_columns = list("x"), model_type = "polynomial"),
55 list("/responses/0/parameters/2/estimate" = tol(coef(poly)[[3]], "quadratic coefficient")),
56 list("Polynomial degree two adds the square of numeric x."))
Fit axis STAT-REG-AXIS-FIT-POWER-001
Case STAT-REG-AXIS-FIT-POWER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
model_type= "power"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/estimate | tolerance | 0.38216934160947863 | 0.3821693416094786 | 5.55E-17 | 15 | passed |
Convention
- Power model fits log(y) against log(x).
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
67 power_fit <- stats::lm(log(y) ~ log(x), data = p)
68 emit("STAT-REG-AXIS-FIT-POWER-001", fit_entry, "REG_POSITIVE",
69 list(y_columns = list("y"), x_columns = list("x"), model_type = "power"),
70 list("/responses/0/parameters/1/estimate" = tol(coef(power_fit)[[2]], "log-log slope")),
71 list("Power model fits log(y) against log(x)."))
Fit axis STAT-REG-AXIS-FIT-RIDGE-001
Case STAT-REG-AXIS-FIT-RIDGE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CENTERED.json
Settings compared
algorithm= "ridge"cv_folds= 3x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/0/estimate | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/responses/0/observations | exact | 72 | 72 | 0.00E+2 | passed |
Convention
- For an unpenalized intercept, mean(x)=0 makes intercept=mean(y) for every penalty.
- The selected penalty itself depends on Python's seeded K-fold assignment and is deferred.
- All numeric references use re-read exported CSV values.
Reference code
Regression setting STAT-REG-AXIS-GENERAL-INTERACTION-001
Case STAT-REG-AXIS-GENERAL-INTERACTION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x", "z"]response_column= "y"terms= [{"kind": "interaction", "columns": ["x", "z"]}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/residual_variance | tolerance | 0.23111192796927188 | 0.2311119279692719 | 2.75E-17 | 15 | passed |
Convention
- The explicit x:z term adds one product column to the already included main effects.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
258 config_interaction <- list(response_column = "y", covariate_columns = list("x", "z"),
259 terms = list(list(kind = "interaction", columns = list("x", "z"))))
260 interaction_fit <- stats::lm(y ~ x * z, data = d)
261 emit("STAT-REG-AXIS-GENERAL-INTERACTION-001", general_entry, "generalLinearMenuItem",
262 "nominal", config_interaction,
263 list("/residual_variance" = tol(summary(interaction_fit)$sigma^2,
264 "numeric interaction model MSE", "1e-9")),
265 list("The explicit x:z term adds one product column to the already included main effects."))
Regression setting STAT-REG-AXIS-GENERAL-MAIN-001
Case STAT-REG-AXIS-GENERAL-MAIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]response_column= "y"terms= [{"kind": "main", "columns": ["x"]}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/x | tolerance | 1.3959190180708527 | 1.3959190180708525 | 1.98E-16 | 15 | passed |
Convention
- An explicit main term does not duplicate the automatically included covariate main effect.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
250 config_main <- list(response_column = "y", covariate_columns = list("x"),
251 terms = list(list(kind = "main", columns = list("x"))))
252 main_fit <- stats::lm(y ~ x, data = d)
253 emit("STAT-REG-AXIS-GENERAL-MAIN-001", general_entry, "generalLinearMenuItem",
254 "nominal", config_main,
255 list("/coefficients/x" = tol(coef(main_fit)[["x"]], "explicit main-term slope", "1e-9")),
256 list("An explicit main term does not duplicate the automatically included covariate main effect."))
Regression setting STAT-REG-AXIS-GENERAL-NESTED-001
Case STAT-REG-AXIS-GENERAL-NESTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_NESTED.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group", "child"]response_column= "y"terms= [{"kind": "nested", "columns": ["group", "child"]}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/residual_variance | tolerance | 0.23965476729562254 | 0.23965476729562252 | 2.28E-17 | 16 | passed |
Convention
- R group/child spans group and child-within-group contrasts; the child has no crossed main effect.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
275 nested_data <- d
276 nested_data$child <- rep(c("L", "R"), length.out = nrow(nested_data))
277 export_dataset(nested_data, "REG_NESTED", "REG_CORE with balanced within-parent child factor",
278 "R stats::lm factor nesting and Tabelz manual chapter 08",
279 "Constructed test data; no third-party dataset license.",
280 c(x = "Float64", z = "Float64", group = "String", binary = "String",
281 ordinal = "String", nominal = "String", exposure = "Float64",
282 cluster = "String", weight = "Float64", y = "Float64",
283 count = "Int64", nb_count = "Int64", child = "String"))
284 nested_data <- read_dataset("REG_NESTED")
285 nested_fit <- stats::lm(y ~ x + group / child, data = nested_data,
286 contrasts = list(group = stats::contr.sum(3),
287 child = stats::contr.sum(2)))
288 config_nested <- list(response_column = "y", factor_columns = list("group", "child"),
289 covariate_columns = list("x"),
290 terms = list(list(kind = "nested", columns = list("group", "child"))))
291 emit("STAT-REG-AXIS-GENERAL-NESTED-001", general_entry, "generalLinearMenuItem",
292 "nominal", config_nested,
293 list("/residual_variance" = tol(summary(nested_fit)$sigma^2,
294 "nested-factor residual variance", "1e-9")),
295 list("R group/child spans group and child-within-group contrasts; the child has no crossed main effect."),
296 dataset = "REG_NESTED")
Regression setting STAT-REG-AXIS-GENERAL-QUADRATIC-001
Case STAT-REG-AXIS-GENERAL-QUADRATIC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]response_column= "y"terms= [{"kind": "quadratic", "columns": ["x"]}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/x^2 | tolerance | 0.013633366063092905 | 0.013633366063093042 | 1.37E-16 | 13 | passed |
Convention
- A quadratic term is x squared and remains an adjustment term in Type II inference.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
267 config_quadratic <- list(response_column = "y", covariate_columns = list("x"),
268 terms = list(list(kind = "quadratic", columns = list("x"))))
269 quadratic_fit <- stats::lm(y ~ x + I(x^2), data = d)
270 emit("STAT-REG-AXIS-GENERAL-QUADRATIC-001", general_entry, "generalLinearMenuItem",
271 "nominal", config_quadratic,
272 list("/coefficients/x^2" = tol(coef(quadratic_fit)[[3]], "quadratic x coefficient", "1e-9")),
273 list("A quadratic term is x squared and remains an adjustment term in Type II inference."))
Regression setting STAT-REG-AXIS-GENERAL-TYPEII-001
Case STAT-REG-AXIS-GENERAL-TYPEII-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"test_type= "II"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/0/f_statistic | tolerance | 28.058376984959352 | 28.058376984959338 | 1.39E-14 | 15 | passed |
Convention
- car::Anova type=2 tests group conditional on x while preserving marginality.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
225 general_entry <- "tabelz.executor.general_linear"
226 general_config <- list(response_column = "y", factor_columns = list("group"),
227 covariate_columns = list("x"))
228 general_fit <- stats::lm(y ~ group + x, data = d,
229 contrasts = list(group = stats::contr.sum(3)))
230 type2 <- car::Anova(general_fit, type = 2)
231 config_ii <- general_config
232 config_ii$test_type <- "II"
233 emit("STAT-REG-AXIS-GENERAL-TYPEII-001", general_entry, "generalLinearMenuItem",
234 "nominal", config_ii,
235 list("/term_tests/0/f_statistic" = tol(type2["group", "F value"],
236 "Type II whole-factor F", "1e-9")),
237 list("car::Anova type=2 tests group conditional on x while preserving marginality."))
Regression setting STAT-REG-AXIS-GENERAL-WEIGHTED-001
Case STAT-REG-AXIS-GENERAL-WEIGHTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"weight_column= "weight"weight_kind= "precision"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/residual_variance | tolerance | 0.33889153996250643 | 0.33889153996250637 | 5.82E-17 | 15 | passed |
Convention
- Manual precision weights are inverse relative variances; R lm weights use the same WLS SSE/df.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
239 weighted_fit <- stats::lm(y ~ group + x, data = d, weights = weight,
240 contrasts = list(group = stats::contr.sum(3)))
241 weighted_config <- general_config
242 weighted_config$weight_column <- "weight"
243 weighted_config$weight_kind <- "precision"
244 emit("STAT-REG-AXIS-GENERAL-WEIGHTED-001", general_entry, "generalLinearMenuItem",
245 "axis_coverage", weighted_config,
246 list("/residual_variance" = tol(summary(weighted_fit)$sigma^2,
247 "precision-weighted residual variance", "1e-9")),
248 list("Manual precision weights are inverse relative variances; R lm weights use the same WLS SSE/df."))
Regression setting STAT-REG-AXIS-POISSON-NOOFFSET-001
Case STAT-REG-AXIS-POISSON-NOOFFSET-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
count_column= "count"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 0.18087893409186312 | 0.1808789340893291 | 2.53E-12 | 10 | passed |
Convention
- Without exposure, the model is count intensity per row, not per unit exposure.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
105 no_offset <- stats::glm(count ~ x, data = d, family = stats::poisson())
106 emit("STAT-REG-AXIS-POISSON-NOOFFSET-001",
107 "tabelz.analysis.poisson_regression:compute_poisson_regression",
108 "poissonRegressionMenuItem", "nominal",
109 list(count_column = "count", predictors = list("x")),
110 list("/coefficients/1/coefficient" = tol(coef(no_offset)[["x"]], "no-offset log-count slope")),
111 list("Without exposure, the model is count intensity per row, not per unit exposure."))
Fit axis STAT-REG-AXIS-VIF-EXPONENTIAL-001
Case STAT-REG-AXIS-VIF-EXPONENTIAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "exponential"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.0001090211033234 | 1.0001090211033234 | 4.78E-17 | 16 | passed |
Convention
- Exponential response transformation leaves the X design untransformed.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
151 vif_config <- function(model, missing = "drop", interactions = FALSE, degree = 2L)
152 list(y_columns = list("y"), x_columns = list("x", "z"), model_type = model,
153 missing = missing, degree = degree, interactions = interactions,
154 split_percent = 100L)
155 vif_r <- function(x, z) 1 / (1 - summary(stats::lm(x ~ z))$r.squared)
156 emit("STAT-REG-AXIS-VIF-EXPONENTIAL-001", vif_entry, "REG_POSITIVE",
157 vif_config("exponential"), list("/0" = tol(vif_r(p$x, p$z), "exponential X VIF")),
158 list("Exponential response transformation leaves the X design untransformed."))
Fit axis STAT-REG-AXIS-VIF-INTERACTIONS-001
Case STAT-REG-AXIS-VIF-INTERACTIONS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
degree= 2interactions= truemissing= "drop"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.1194468557613388 | 1.119446855761339 | 2.66E-16 | 15 | passed |
Convention
- The base X interaction x*z is an additional VIF design term.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
174 interaction_design <- data.frame(x = d$x, z = d$z, xz = d$x * d$z)
175 interaction_vif <- 1 / (1 - summary(stats::lm(x ~ z + xz, data = interaction_design))$r.squared)
176 emit("STAT-REG-AXIS-VIF-INTERACTIONS-001", vif_entry, "REG_CORE",
177 vif_config("linear", interactions = TRUE),
178 list("/0" = tol(interaction_vif, "x VIF with x:z interaction")),
179 list("The base X interaction x*z is an additional VIF design term."))
Fit axis STAT-REG-AXIS-VIF-LOGARITHMIC-001
Case STAT-REG-AXIS-VIF-LOGARITHMIC-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "logarithmic"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.0002018754032056 | 1.0002018754032054 | 2.24E-16 | 15 | passed |
Convention
- Both x and z are log transformed before computing auxiliary R-squared.
- All numeric references use re-read exported CSV values.
Reference code
Fit axis STAT-REG-AXIS-VIF-MISSING-KNN-001
Case STAT-REG-AXIS-VIF-MISSING-KNN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
degree= 2interactions= falsemissing= "knn"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.0001090211033234 | 1.0001090211033237 | 2.70E-16 | 15 | passed |
Convention
- No selected field is missing, so imputation strategy cannot change the design.
- All numeric references use re-read exported CSV values.
Reference code
Fit axis STAT-REG-AXIS-VIF-MISSING-NEIGHBOR-AVERAGE-001
Case STAT-REG-AXIS-VIF-MISSING-NEIGHBOR-AVERAGE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
degree= 2interactions= falsemissing= "neighbor_average"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.0001090211033234 | 1.0001090211033237 | 2.70E-16 | 15 | passed |
Convention
- No selected field is missing, so imputation strategy cannot change the design.
- All numeric references use re-read exported CSV values.
Reference code
Fit axis STAT-REG-AXIS-VIF-POLYNOMIAL-001
Case STAT-REG-AXIS-VIF-POLYNOMIAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "polynomial"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 31.878929592923591 | 31.878929592923395 | 1.96E-13 | 14 | passed |
Convention
- Quadratic design includes x, z, x-squared and z-squared; R auxiliary regression conditions on the other three.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
164 poly_design <- data.frame(x = p$x, z = p$z, x2 = p$x^2, z2 = p$z^2)
165 poly_vif <- 1 / (1 - summary(stats::lm(x ~ z + x2 + z2, data = poly_design))$r.squared)
166 emit("STAT-REG-AXIS-VIF-POLYNOMIAL-001", vif_entry, "REG_POSITIVE",
167 vif_config("polynomial"), list("/0" = tol(poly_vif, "quadratic-design x VIF")),
168 list("Quadratic design includes x, z, x-squared and z-squared; R auxiliary regression conditions on the other three."))
Fit axis STAT-REG-AXIS-VIF-POWER-001
Case STAT-REG-AXIS-VIF-POWER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "power"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.0002018754032056 | 1.0002018754032054 | 2.24E-16 | 15 | passed |
Convention
- Both x and z are log transformed before computing auxiliary R-squared.
- All numeric references use re-read exported CSV values.
Reference code
All models of x1 and x2, Zellner-Siow medium scale
Case STAT-REG-BAYES-REGRESSION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, pt, solve, combn
- Citation
- Liang, Paulo, Molina, Clyde and Berger (2008), Mixtures of g priors for Bayesian variable selection, Journal of the American Statistical Association 103(481), 410-423, eqs. 5 and 9, section 3.2; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.95hyper_a= 3predictors= ["x1", "x2"]prior= "zellner_siow"prior_scale= 0.353553390593274response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/[numerator=x1]/bf10 | tolerance | 159.54961679681637 | 159.54961679681608 | 2.88E-13 | 14 | passed |
/bayes_factors/[numerator=x1]/bf01 | tolerance | 0.0062676427563814361 | 0.0062676427563814465 | 1.04E-17 | 14 | passed |
/bayes_factors/[numerator=x1]/log_bf10 | tolerance | 5.0723549509464787 | 5.072354950946477 | 1.77E-15 | 15 | passed |
/bayes_factors/[numerator=x1]/posterior_probability | tolerance | 0.69937634362569168 | 0.6993763436256912 | 4.48E-16 | 15 | passed |
/bayes_factors/[numerator=x1]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/bayes_factors/[numerator=x2]/bf10 | tolerance | 0.40516848610885581 | 0.40516848610885553 | 2.80E-16 | 15 | passed |
/bayes_factors/[numerator=x2]/bf01 | tolerance | 2.4681090318839161 | 2.468109031883918 | 1.74E-15 | 15 | passed |
/bayes_factors/[numerator=x2]/log_bf10 | tolerance | -0.903452283302286 | -0.9034522833022867 | 6.63E-16 | 15 | passed |
/bayes_factors/[numerator=x2]/posterior_probability | tolerance | 0.0017760321839445676 | 0.001776032183944568 | 3.99E-19 | 15 | passed |
/bayes_factors/[numerator=x2]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/bayes_factors/[numerator=x1 + x2]/bf10 | tolerance | 67.17648946063089 | 67.17648946063089 | 6.19E-18 | 19 | passed |
/bayes_factors/[numerator=x1 + x2]/bf01 | tolerance | 0.014886160441385597 | 0.014886160441385597 | 1.86E-19 | 16 | passed |
/bayes_factors/[numerator=x1 + x2]/log_bf10 | tolerance | 4.2073233270972876 | 4.207323327097288 | 2.41E-17 | 17 | passed |
/bayes_factors/[numerator=x1 + x2]/posterior_probability | tolerance | 0.29446418311625372 | 0.294464183116254 | 2.77E-16 | 15 | passed |
/bayes_factors/[numerator=x1 + x2]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/posteriors/0/mean | tolerance | 0.93066950425417561 | 0.9306695042541759 | 3.29E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.24200532511913933 | 0.2420053251191398 | 4.72E-16 | 14 | passed |
/posteriors/0/median | tolerance | 0.93620805542637242 | 0.9362080554263772 | 4.77E-15 | 14 | passed |
/posteriors/0/lower | tolerance | 0.43480471008963029 | 0.434804710089628 | 2.28E-15 | 14 | passed |
/posteriors/0/upper | tolerance | 1.3951018236008945 | 1.3951018236008947 | 2.42E-16 | 15 | passed |
Convention
- Candidate models: x1; x2; x1 + x2, plus intercept only; n = 20; the most probable model (null included) is x1, whose coefficient posteriors are compared by index.
- BF10(g) = (1 + g)^((n-1-p)/2) (1 + g (1 - R^2))^(-(n-1)/2) against the intercept-only model (Liang, Paulo, Molina, Clyde and Berger 2008, eq. 5), averaged over g by R integrate on u = log g.
- Zellner-Siow prior g ~ Inverse-Gamma(1/2, n r^2/2), r = 0.35355339059327379 (Liang et al. 2008, section 3.2).
- Posterior model probabilities proportional to prior probability times BF10 over the candidate set including the intercept-only model (BF 1).
- Coefficient posteriors given g: Student-t on n - 1 df with centre g/(1+g) beta-hat and scale sqrt(g/(1+g) s^2 (X'X)^-1_jj), s^2 = SSY (1 - g/(1+g) R^2)/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot.
- Tolerance 1e-6: both sides integrate numerically.
- docs/manual/chapters/79-bayesian-analysis.tex:33-34: 'Linear regression & Zellner--Siow or hyper-g prior; declare candidate models and their prior probabilities, including the intercept-only model.'
- docs/manual/chapters/79-bayesian-analysis.tex:93-96: 'Regression compares up to 64 declared models ... Coefficient summaries for the most probable model are conditional on that model'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
572 emit("regression", "bayesRegressionMenuItem",
573 "tabelz.analysis.bayesian.linear:compute_bayes_regression", id, title, kind,
574 configuration, outputs,
575 c(sprintf("Candidate models: %s, plus intercept only; n = %d; the most probable model (null included) is %s, whose coefficient posteriors are compared by index.",
576 paste(vapply(models, paste, "", collapse = " + "), collapse = "; "), n, selected),
577 "BF10(g) = (1 + g)^((n-1-p)/2) (1 + g (1 - R^2))^(-(n-1)/2) against the intercept-only model (Liang, Paulo, Molina, Clyde and Berger 2008, eq. 5), averaged over g by R integrate on u = log g.",
578 if (prior == "hyper_g") sprintf("Hyper-g prior pi(g) = (a - 2)/2 (1 + g)^(-a/2), a = %g (Liang et al. 2008, eq. 9).", hyper_a)
579 else sprintf("Zellner-Siow prior g ~ Inverse-Gamma(1/2, n r^2/2), r = %s (Liang et al. 2008, section 3.2).", format(r, digits = 17)),
580 "Posterior model probabilities proportional to prior probability times BF10 over the candidate set including the intercept-only model (BF 1).",
581 "Coefficient posteriors given g: Student-t on n - 1 df with centre g/(1+g) beta-hat and scale sqrt(g/(1+g) s^2 (X'X)^-1_jj), s^2 = SSY (1 - g/(1+g) R^2)/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot.",
582 "Tolerance 1e-6: both sides integrate numerically.",
583 paste0(manual, ":33-34: 'Linear regression & Zellner--Siow or hyper-g prior; declare candidate models and their prior probabilities, including the intercept-only model.'"),
584 paste0(manual, ":93-96: 'Regression compares up to 64 declared models ... Coefficient summaries for the most probable model are conditional on that model'")),
585 "R stats: integrate, uniroot, pt, solve, combn",
586 "Liang, Paulo, Molina, Clyde and Berger (2008), Mixtures of g priors for Bayesian variable selection, Journal of the American Statistical Association 103(481), 410-423, eqs. 5 and 9, section 3.2; R Core Team, stats package help: integrate, uniroot.",
587 "REQ-STAT-REG-BAYES-REGRESSION-001")
Hyper-g prior, a = 3
Case STAT-REG-BAYES-REGRESSION-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, pt, solve, combn
- Citation
- Liang, Paulo, Molina, Clyde and Berger (2008), Mixtures of g priors for Bayesian variable selection, Journal of the American Statistical Association 103(481), 410-423, eqs. 5 and 9, section 3.2; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.95hyper_a= 3predictors= ["x1", "x2"]prior= "hyper_g"prior_scale= 0.353553390593274response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/[numerator=x1]/bf10 | tolerance | 126.09221116684985 | 126.09221116684964 | 2.13E-13 | 14 | passed |
/bayes_factors/[numerator=x1]/bf01 | tolerance | 0.0079307039724821962 | 0.00793070397248221 | 1.39E-17 | 14 | passed |
/bayes_factors/[numerator=x1]/log_bf10 | tolerance | 4.8370134739486144 | 4.837013473948613 | 1.81E-15 | 15 | passed |
/bayes_factors/[numerator=x1]/posterior_probability | tolerance | 0.69629436953459378 | 0.6962943695345933 | 4.42E-16 | 15 | passed |
/bayes_factors/[numerator=x1]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/bayes_factors/[numerator=x2]/bf10 | tolerance | 0.50726935608907775 | 0.5072693560890776 | 1.11E-16 | 15 | passed |
/bayes_factors/[numerator=x2]/bf01 | tolerance | 1.9713392658089079 | 1.9713392658089086 | 7.14E-16 | 15 | passed |
/bayes_factors/[numerator=x2]/log_bf10 | tolerance | -0.67871314212976863 | -0.678713142129769 | 3.35E-16 | 15 | passed |
/bayes_factors/[numerator=x2]/posterior_probability | tolerance | 0.0028011944053775448 | 0.002801194405377548 | 3.04E-18 | 14 | passed |
/bayes_factors/[numerator=x2]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/bayes_factors/[numerator=x1 + x2]/bf10 | tolerance | 53.490898322333699 | 53.4908983223337 | 1.00E-16 | 17 | passed |
/bayes_factors/[numerator=x1 + x2]/bf01 | tolerance | 0.018694769229225614 | 0.018694769229225614 | 1.54E-19 | 17 | passed |
/bayes_factors/[numerator=x1 + x2]/log_bf10 | tolerance | 3.9795115146129003 | 3.9795115146129003 | 1.36E-17 | 17 | passed |
/bayes_factors/[numerator=x1 + x2]/posterior_probability | tolerance | 0.29538233153754362 | 0.295382331537544 | 3.87E-16 | 14 | passed |
/bayes_factors/[numerator=x1 + x2]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/posteriors/0/mean | tolerance | 0.92614310683796208 | 0.9261431068379622 | 1.13E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.24730703586769517 | 0.2473070358676965 | 1.34E-15 | 14 | passed |
/posteriors/0/median | tolerance | 0.93398732499927961 | 0.9339873151015775 | 9.90E-9 | 7 | passed |
/posteriors/0/lower | tolerance | 0.40987478732576471 | 0.40987460516854934 | 1.82E-7 | 6 | passed |
/posteriors/0/upper | tolerance | 1.3944487778792192 | 1.3944487742430418 | 3.64E-9 | 8 | passed |
Convention
- Candidate models: x1; x2; x1 + x2, plus intercept only; n = 20; the most probable model (null included) is x1, whose coefficient posteriors are compared by index.
- BF10(g) = (1 + g)^((n-1-p)/2) (1 + g (1 - R^2))^(-(n-1)/2) against the intercept-only model (Liang, Paulo, Molina, Clyde and Berger 2008, eq. 5), averaged over g by R integrate on u = log g.
- Hyper-g prior pi(g) = (a - 2)/2 (1 + g)^(-a/2), a = 3 (Liang et al. 2008, eq. 9).
- Posterior model probabilities proportional to prior probability times BF10 over the candidate set including the intercept-only model (BF 1).
- Coefficient posteriors given g: Student-t on n - 1 df with centre g/(1+g) beta-hat and scale sqrt(g/(1+g) s^2 (X'X)^-1_jj), s^2 = SSY (1 - g/(1+g) R^2)/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot.
- Tolerance 1e-6: both sides integrate numerically.
- docs/manual/chapters/79-bayesian-analysis.tex:33-34: 'Linear regression & Zellner--Siow or hyper-g prior; declare candidate models and their prior probabilities, including the intercept-only model.'
- docs/manual/chapters/79-bayesian-analysis.tex:93-96: 'Regression compares up to 64 declared models ... Coefficient summaries for the most probable model are conditional on that model'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
591 regression_case("STAT-REG-BAYES-REGRESSION-002", "Hyper-g prior, a = 3", "axis_coverage",
592 c("x1", "x2"), NULL, prior = "hyper_g", hyper_a = 3)
Zellner-Siow unit scale, 90% interval
Case STAT-REG-BAYES-REGRESSION-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, pt, solve, combn
- Citation
- Liang, Paulo, Molina, Clyde and Berger (2008), Mixtures of g priors for Bayesian variable selection, Journal of the American Statistical Association 103(481), 410-423, eqs. 5 and 9, section 3.2; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.9hyper_a= 3predictors= ["x1", "x2"]prior= "zellner_siow"prior_scale= 1response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/[numerator=x1]/bf10 | tolerance | 235.46934106784553 | 235.4693410678449 | 6.22E-13 | 14 | passed |
/bayes_factors/[numerator=x1]/bf01 | tolerance | 0.0042468373821620839 | 0.004246837382162095 | 1.13E-17 | 14 | passed |
/bayes_factors/[numerator=x1]/log_bf10 | tolerance | 5.4615807184330416 | 5.461580718433039 | 2.66E-15 | 15 | passed |
/bayes_factors/[numerator=x1]/posterior_probability | tolerance | 0.75791585143085083 | 0.7579158514308503 | 5.56E-16 | 15 | passed |
/bayes_factors/[numerator=x1]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/bayes_factors/[numerator=x2]/bf10 | tolerance | 0.17515272012684732 | 0.1751527201268473 | 2.56E-17 | 15 | passed |
/bayes_factors/[numerator=x2]/bf01 | tolerance | 5.7093032827340053 | 5.709303282734007 | 1.81E-15 | 15 | passed |
/bayes_factors/[numerator=x2]/log_bf10 | tolerance | -1.7420969991889101 | -1.7420969991889104 | 2.67E-16 | 15 | passed |
/bayes_factors/[numerator=x2]/posterior_probability | tolerance | 0.00056377200701945981 | 0.0005637720070194609 | 1.09E-18 | 14 | passed |
/bayes_factors/[numerator=x2]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/bayes_factors/[numerator=x1 + x2]/bf10 | tolerance | 74.035564721568917 | 74.03556472156892 | 4.35E-16 | 17 | passed |
/bayes_factors/[numerator=x1 + x2]/bf01 | tolerance | 0.013507021980054785 | 0.013507021980054785 | 1.46E-19 | 16 | passed |
/bayes_factors/[numerator=x1 + x2]/log_bf10 | tolerance | 4.3045455820964174 | 4.304545582096417 | 4.46E-17 | 16 | passed |
/bayes_factors/[numerator=x1 + x2]/posterior_probability | tolerance | 0.23830163119174003 | 0.2383016311917405 | 4.68E-16 | 14 | passed |
/bayes_factors/[numerator=x1 + x2]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/posteriors/0/mean | tolerance | 0.98297145075649695 | 0.9829714507564975 | 5.50E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.2243627981374543 | 0.2243627981374543 | 1.18E-19 | 18 | passed |
/posteriors/0/median | tolerance | 0.9836952572331692 | 0.9836952572331699 | 6.62E-16 | 15 | passed |
/posteriors/0/lower | tolerance | 0.61459727808364017 | 0.614597278083624 | 1.62E-14 | 13 | passed |
/posteriors/0/upper | tolerance | 1.3488270691115085 | 1.3488270691115372 | 2.87E-14 | 13 | passed |
Convention
- Candidate models: x1; x2; x1 + x2, plus intercept only; n = 20; the most probable model (null included) is x1, whose coefficient posteriors are compared by index.
- BF10(g) = (1 + g)^((n-1-p)/2) (1 + g (1 - R^2))^(-(n-1)/2) against the intercept-only model (Liang, Paulo, Molina, Clyde and Berger 2008, eq. 5), averaged over g by R integrate on u = log g.
- Zellner-Siow prior g ~ Inverse-Gamma(1/2, n r^2/2), r = 1 (Liang et al. 2008, section 3.2).
- Posterior model probabilities proportional to prior probability times BF10 over the candidate set including the intercept-only model (BF 1).
- Coefficient posteriors given g: Student-t on n - 1 df with centre g/(1+g) beta-hat and scale sqrt(g/(1+g) s^2 (X'X)^-1_jj), s^2 = SSY (1 - g/(1+g) R^2)/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot.
- Tolerance 1e-6: both sides integrate numerically.
- docs/manual/chapters/79-bayesian-analysis.tex:33-34: 'Linear regression & Zellner--Siow or hyper-g prior; declare candidate models and their prior probabilities, including the intercept-only model.'
- docs/manual/chapters/79-bayesian-analysis.tex:93-96: 'Regression compares up to 64 declared models ... Coefficient summaries for the most probable model are conditional on that model'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
593 regression_case("STAT-REG-BAYES-REGRESSION-003", "Zellner-Siow unit scale, 90% interval",
594 "axis_coverage", c("x1", "x2"), NULL, r = 1, level = 0.9)
Declared models with custom prior weights
Case STAT-REG-BAYES-REGRESSION-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats: integrate, uniroot, pt, solve, combn
- Citation
- Liang, Paulo, Molina, Clyde and Berger (2008), Mixtures of g priors for Bayesian variable selection, Journal of the American Statistical Association 103(481), 410-423, eqs. 5 and 9, section 3.2; R Core Team, stats package help: integrate, uniroot.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/hypothesis_bayesian.R · sha256 5f55d2b476c40d20
- Dataset
- reference_data/datasets/HYP_BAYES.json
Settings compared
confidence_level= 0.95hyper_a= 3model_prior= [0.5, 0.25]models= ["x1", "x1 + x2"]null_model_prior= 0.25predictors= ["x1", "x2"]prior= "zellner_siow"prior_scale= 0.353553390593274response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 20 | 20 | 0.00E+2 | passed | |
/bayes_factors/[numerator=x1]/bf10 | tolerance | 159.54961679681637 | 159.54961679681608 | 2.88E-13 | 14 | passed |
/bayes_factors/[numerator=x1]/bf01 | tolerance | 0.0062676427563814361 | 0.0062676427563814465 | 1.04E-17 | 14 | passed |
/bayes_factors/[numerator=x1]/log_bf10 | tolerance | 5.0723549509464787 | 5.072354950946477 | 1.77E-15 | 15 | passed |
/bayes_factors/[numerator=x1]/posterior_probability | tolerance | 0.82395878336252371 | 0.8239587833625235 | 2.26E-16 | 15 | passed |
/bayes_factors/[numerator=x1]/prior_probability | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/bayes_factors/[numerator=x1 + x2]/bf10 | tolerance | 67.17648946063089 | 67.17648946063089 | 6.19E-18 | 19 | passed |
/bayes_factors/[numerator=x1 + x2]/bf01 | tolerance | 0.014886160441385597 | 0.014886160441385597 | 1.86E-19 | 16 | passed |
/bayes_factors/[numerator=x1 + x2]/log_bf10 | tolerance | 4.2073233270972876 | 4.207323327097288 | 2.41E-17 | 17 | passed |
/bayes_factors/[numerator=x1 + x2]/posterior_probability | tolerance | 0.17345907698742674 | 0.17345907698742705 | 3.07E-16 | 14 | passed |
/bayes_factors/[numerator=x1 + x2]/prior_probability | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/posteriors/0/mean | tolerance | 0.93066950425417561 | 0.9306695042541759 | 3.29E-16 | 15 | passed |
/posteriors/0/sd | tolerance | 0.24200532511913933 | 0.2420053251191398 | 4.72E-16 | 14 | passed |
/posteriors/0/median | tolerance | 0.93620805542637242 | 0.9362080554263772 | 4.77E-15 | 14 | passed |
/posteriors/0/lower | tolerance | 0.43480471008963029 | 0.434804710089628 | 2.28E-15 | 14 | passed |
/posteriors/0/upper | tolerance | 1.3951018236008945 | 1.3951018236008947 | 2.42E-16 | 15 | passed |
Convention
- Candidate models: x1; x1 + x2, plus intercept only; n = 20; the most probable model (null included) is x1, whose coefficient posteriors are compared by index.
- BF10(g) = (1 + g)^((n-1-p)/2) (1 + g (1 - R^2))^(-(n-1)/2) against the intercept-only model (Liang, Paulo, Molina, Clyde and Berger 2008, eq. 5), averaged over g by R integrate on u = log g.
- Zellner-Siow prior g ~ Inverse-Gamma(1/2, n r^2/2), r = 0.35355339059327379 (Liang et al. 2008, section 3.2).
- Posterior model probabilities proportional to prior probability times BF10 over the candidate set including the intercept-only model (BF 1).
- Coefficient posteriors given g: Student-t on n - 1 df with centre g/(1+g) beta-hat and scale sqrt(g/(1+g) s^2 (X'X)^-1_jj), s^2 = SSY (1 - g/(1+g) R^2)/(n - 1), mixed over the posterior of g by R integrate; quantiles by uniroot.
- Tolerance 1e-6: both sides integrate numerically.
- docs/manual/chapters/79-bayesian-analysis.tex:33-34: 'Linear regression & Zellner--Siow or hyper-g prior; declare candidate models and their prior probabilities, including the intercept-only model.'
- docs/manual/chapters/79-bayesian-analysis.tex:93-96: 'Regression compares up to 64 declared models ... Coefficient summaries for the most probable model are conditional on that model'
- Expected computed from the exported CSV.
- docs/manual/chapters/79-bayesian-analysis.tex:68-69: 'The results show the posterior mean, SD, median and equal-tailed credible interval. A highest-density interval is given when one interval can represent the supported posterior shape'
- docs/manual/chapters/79-bayesian-analysis.tex:74-75: 'The result names both models in BF10, shows its reciprocal and logarithm'
Reference code
The lines of the reference script that produce this case's expected values.
595 regression_case("STAT-REG-BAYES-REGRESSION-004", "Declared models with custom prior weights",
596 "axis_coverage", c("x1", "x2"), list("x1", c("x1", "x2")),
597 model_prior = c(0.5, 0.25), null_prior = 0.25)
STAT REG BINARY 001
Case STAT-REG-BINARY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 0.072222061481396774 | 0.07222206148139672 | 5.58E-17 | 15 | passed |
/log_likelihood | tolerance | -18.127056845888642 | -18.127056845888642 | 3.00E-16 | 16 | passed |
Convention
- R glm binomial logit; event explicitly coded TRUE; Wald inference per manual.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
87 binary_entry <- "tabelz.analysis.logistic_regression:compute_binary_logistic_regression"
88 binary_fit <- stats::glm(I(binary == "event") ~ x, family = stats::binomial(), data = d)
89 emit("STAT-REG-BINARY-001", binary_entry, "logisticRegressionMenuItem", "nominal",
90 list(outcome_column = "binary", event_value = "event", predictors = list("x")),
91 list("/coefficients/1/coefficient" = tol(coef(binary_fit)[["x"]], "binary logit slope"),
92 "/log_likelihood" = tol(as.numeric(stats::logLik(binary_fit)), "binomial log likelihood")),
93 list("R glm binomial logit; event explicitly coded TRUE; Wald inference per manual."))
Regression setting STAT-REG-BOUNDARY-BINARY-CORRECTED-001
Case STAT-REG-BOUNDARY-BINARY-CORRECTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_BIN_MIN.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 3 | 3 | 0.00E+2 | passed | |
/coefficients/1/coefficient | tolerance | 0 | 8.66101954420646e-16 | 8.66E-16 | passed |
Convention
- Events occur at x=-1 and +1 and non-event at x=0: both outcomes, finite MLE and residual df one.
- This corrects coverage lost by the separately retained failed REG_MIN3 draft.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
179 binary_min <- d[1:3, , drop = FALSE]
180 binary_min$x <- c(-1, 0, 1)
181 binary_min$binary <- c("event", "other", "event")
182 export_dataset(binary_min, "REG_BIN_MIN", "Three deliberately non-separated binary rows",
183 "R stats::glm binomial manual; three rows exceed intercept-plus-slope count",
184 "Constructed test data; no third-party dataset license.",
185 c(x = "Float64", z = "Float64", group = "String", binary = "String",
186 ordinal = "String", nominal = "String", exposure = "Float64",
187 cluster = "String", weight = "Float64", y = "Float64",
188 count = "Int64", nb_count = "Int64"))
189 binary_min <- read_dataset("REG_BIN_MIN")
190 binary_min_fit <- stats::glm(I(binary == "event") ~ x, data = binary_min,
191 family = stats::binomial())
192 emit("STAT-REG-BOUNDARY-BINARY-CORRECTED-001",
193 "tabelz.analysis.logistic_regression:compute_binary_logistic_regression",
194 "logisticRegressionMenuItem", "boundary",
195 list(outcome_column = "binary", event_value = "event", predictors = list("x")),
196 list("/n" = exact(3, "three complete rows"),
197 "/coefficients/1/coefficient" = list(comparison = "tolerance", value = "0", absolute_tolerance = "1e-12", relative_tolerance = "0",
198 rationale = paste("Exactly zero by the design's symmetry; any implementation returns rounding",
199 "noise of order 1e-15, so an absolute 1e-12 replaces a relative tier that",
200 "cannot compare with zero. R gives", format(coef(binary_min_fit)[["x"]], digits = 17)))),
201 list("Events occur at x=-1 and +1 and non-event at x=0: both outcomes, finite MLE and residual df one.",
202 "This corrects coverage lost by the separately retained failed REG_MIN3 draft."),
203 dataset = "REG_BIN_MIN")
Design boundary STAT-REG-BOUNDARY-BINARY-MIN-001
Case STAT-REG-BOUNDARY-BINARY-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN3.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- REG_MIN3's three rows all have the same outcome, so a binary logit is undefined and must be refused.
- Until 2026-09-25 this case wrongly asserted both outcomes occur; STAT-REG-BOUNDARY-BINARY-CORRECTED-001 covers the valid minimum design.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
80 bfit <- stats::glm(I(binary == "event") ~ x, data = d3, family = stats::binomial())
81 emit("STAT-REG-BOUNDARY-BINARY-MIN-001",
82 "tabelz.analysis.logistic_regression:compute_binary_logistic_regression",
83 "logisticRegressionMenuItem", "REG_MIN3",
84 list(outcome_column = "binary", event_value = "event", predictors = list("x")),
85 list(),
86 list("REG_MIN3's three rows all have the same outcome, so a binary logit is undefined and must be refused.",
87 "Until 2026-09-25 this case wrongly asserted both outcomes occur; STAT-REG-BOUNDARY-BINARY-CORRECTED-001 covers the valid minimum design."),
88 error = list(error_class = "ValueError", message_contains = "exactly two outcome values"))
Regression completion STAT-REG-BOUNDARY-BINARY-MIN-PASS-001
Case STAT-REG-BOUNDARY-BINARY-MIN-PASS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fit
- Citation
- R stats::glm/lm and car::Anova help pages; Tabelz manual chapters 07 and 08
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_lastmile.R · sha256 512832af1db86a5f
- Dataset
- reference_data/datasets/REG_BIN_MIN.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 3 | 3 | 0.00E+2 | passed | |
/coefficients/0/coefficient | tolerance | 0.69314718055974278 | 0.6931471805597424 | 3.32E-16 | 15 | passed |
Convention
- Symmetric events at x=-1 and +1 make the slope mathematically zero; compare the nonzero intercept and n instead.
- The fit uses only the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
28 binary_entry <- "tabelz.analysis.logistic_regression:compute_binary_logistic_regression"
29 binary_menu <- "logisticRegressionMenuItem"
30 small_fit <- stats::glm(I(binary == "event") ~ x, data = small,
31 family = stats::binomial())
32 emit("STAT-REG-BOUNDARY-BINARY-MIN-PASS-001", binary_entry, binary_menu,
33 "boundary", "REG_BIN_MIN",
34 list(outcome_column = "binary", event_value = "event", predictors = list("x")),
35 list("/n" = exact(3, "three-row accepted minimum"),
36 "/coefficients/0/coefficient" = tol(coef(small_fit)[[1]], "nonzero intercept")),
37 list("Symmetric events at x=-1 and +1 make the slope mathematically zero; compare the nonzero intercept and n instead."))
Design boundary STAT-REG-BOUNDARY-BINARY-ONELEVEL-001
Case STAT-REG-BOUNDARY-BINARY-ONELEVEL-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_DEGENERATE.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Only one observed binary level is present.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
89 emit("STAT-REG-BOUNDARY-BINARY-ONELEVEL-001",
90 "tabelz.analysis.logistic_regression:compute_binary_logistic_regression",
91 "logisticRegressionMenuItem", "REG_DEGENERATE",
92 list(outcome_column = "binary", event_value = "event", predictors = list("x")),
93 list(), list("Only one observed binary level is present."),
94 list(error_class = "ValueError", message_contains = "exactly two"))
Design boundary STAT-REG-BOUNDARY-EFFECTS-MIN-001
Case STAT-REG-BOUNDARY-EFFECTS-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN3.json
Settings compared
covariate_columns= ["x"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/x | tolerance | -0.090029661103937703 | -0.090029661103938 | 2.91E-16 | 14 | passed |
/residual_df | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Three rows, intercept and one covariate give residual df one.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
193 emit("STAT-REG-BOUNDARY-EFFECTS-MIN-001", "tabelz.executor.linear_effects",
194 "linearEffectsMenuItem", "REG_MIN3",
195 list(response_column = "y", covariate_columns = list("x")),
196 list("/coefficients/x" = tol(coef(gfit)[["x"]], "n=3 effects slope", "1e-9"),
197 "/residual_df" = exact(1, "one residual degree of freedom")),
198 list("Three rows, intercept and one covariate give residual df one."))
Design boundary STAT-REG-BOUNDARY-EFFECTS-ONELEVEL-001
Case STAT-REG-BOUNDARY-EFFECTS-ONELEVEL-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_DEGENERATE.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A one-level factor has no estimable contrast.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
199 emit("STAT-REG-BOUNDARY-EFFECTS-ONELEVEL-001", "tabelz.executor.linear_effects",
200 "linearEffectsMenuItem", "REG_DEGENERATE",
201 list(response_column = "y", factor_columns = list("group")),
202 list(), list("A one-level factor has no estimable contrast."),
203 list(error_class = "LinearEffectsExecutionError", message_contains = "two"))
Design boundary STAT-REG-BOUNDARY-GENERAL-MIN-001
Case STAT-REG-BOUNDARY-GENERAL-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN3.json
Settings compared
covariate_columns= ["x"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/x | tolerance | -0.090029661103937703 | -0.09002966110393872 | 1.01E-15 | 13 | passed |
/residual_df | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Three rows, intercept and one covariate give residual df one.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
180 gfit <- stats::lm(y ~ x, data = d3)
181 emit("STAT-REG-BOUNDARY-GENERAL-MIN-001", "tabelz.executor.general_linear",
182 "generalLinearMenuItem", "REG_MIN3",
183 list(response_column = "y", covariate_columns = list("x")),
184 list("/coefficients/x" = tol(coef(gfit)[["x"]], "n=3 general-linear slope", "1e-9"),
185 "/residual_df" = exact(1, "one residual degree of freedom")),
186 list("Three rows, intercept and one covariate give residual df one."))
Design boundary STAT-REG-BOUNDARY-GENERAL-ONELEVEL-001
Case STAT-REG-BOUNDARY-GENERAL-ONELEVEL-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_DEGENERATE.json
Settings compared
factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A one-level factor has no estimable contrast.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
187 emit("STAT-REG-BOUNDARY-GENERAL-ONELEVEL-001", "tabelz.executor.general_linear",
188 "generalLinearMenuItem", "REG_DEGENERATE",
189 list(response_column = "y", factor_columns = list("group")),
190 list(), list("A one-level factor has no estimable contrast."),
191 list(error_class = "GeneralLinearExecutionError", message_contains = "two"))
Design boundary STAT-REG-BOUNDARY-NB-MIN-001
Case STAT-REG-BOUNDARY-NB-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN8.json
Settings compared
count= "nb_count"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | -1.1143482340505979 | -1.1143482340501933 | 4.05E-13 | 12 | passed |
/n | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Eight-row design is the smallest constructed subset on which the R NB2 fit has finite dispersion.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
164 nbfit <- MASS::glm.nb(nb_count ~ x, data = d8,
165 control = stats::glm.control(maxit = 1000, epsilon = 1e-12))
166 emit("STAT-REG-BOUNDARY-NB-MIN-001",
167 "tabelz.analysis.negative_binomial:compute_negative_binomial",
168 "nbRegressionMenuItem", "REG_MIN8",
169 list(count = "nb_count", predictors = list("x")),
170 list("/coefficients/1/coefficient" = tol(coef(nbfit)[["x"]], "small-design NB2 slope"),
171 "/n" = exact(8, "eight observations")),
172 list("Eight-row design is the smallest constructed subset on which the R NB2 fit has finite dispersion."))
Design boundary STAT-REG-BOUNDARY-NB-ZEROEXPOSURE-001
Case STAT-REG-BOUNDARY-NB-ZEROEXPOSURE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_DEGENERATE.json
Settings compared
count= "nb_count"exposure= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One exposure is zero; manual requires positive exposure.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
173 emit("STAT-REG-BOUNDARY-NB-ZEROEXPOSURE-001",
174 "tabelz.analysis.negative_binomial:compute_negative_binomial",
175 "nbRegressionMenuItem", "REG_DEGENERATE",
176 list(count = "nb_count", predictors = list("x"), exposure = "exposure"),
177 list(), list("One exposure is zero; manual requires positive exposure."),
178 list(error_class = "ValueError", message_contains = "exposure"))
Design boundary STAT-REG-BOUNDARY-NOMINAL-MIN-001
Case STAT-REG-BOUNDARY-NOMINAL-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN5.json
Settings compared
outcome_column= "nominal"predictors= ["x"]reference_value= "A"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Issue #11 ruling: complete separation of C establishes that no finite MLE exists; the fit is refused.
- Until 2026-09-25 this case compared nnet::multinom's arbitrary stopping point.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
133 stopifnot(max(d5$x[d5$nominal == "C"]) < min(d5$x[d5$nominal != "C"]))
134 emit("STAT-REG-BOUNDARY-NOMINAL-MIN-001",
135 "tabelz.analysis.nominal_logistic:compute_nominal_logistic_regression",
136 "nominalRegressionMenuItem", "REG_MIN5",
137 list(outcome_column = "nominal", reference_value = "A", predictors = list("x")),
138 list(),
139 list("Issue #11 ruling: complete separation of C establishes that no finite MLE exists; the fit is refused.",
140 "Until 2026-09-25 this case compared nnet::multinom's arbitrary stopping point."),
141 list(error_class = "ValueError", message_contains = "No finite maximum-likelihood estimate"))
Design boundary STAT-REG-BOUNDARY-NOMINAL-ONELEVEL-001
Case STAT-REG-BOUNDARY-NOMINAL-ONELEVEL-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_DEGENERATE.json
Settings compared
outcome_column= "nominal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Only one nominal category is present.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
142 emit("STAT-REG-BOUNDARY-NOMINAL-ONELEVEL-001",
143 "tabelz.analysis.nominal_logistic:compute_nominal_logistic_regression",
144 "nominalRegressionMenuItem", "REG_DEGENERATE",
145 list(outcome_column = "nominal", predictors = list("x")),
146 list(), list("Only one nominal category is present."),
147 list(error_class = "ValueError", message_contains = "three"))
Design boundary STAT-REG-BOUNDARY-OLS-DOMAIN-001
Case STAT-REG-BOUNDARY-OLS-DOMAIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
model_type= "logarithmic"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Logarithmic regression requires strictly positive x; REG_CORE contains negative x.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
60 emit("STAT-REG-BOUNDARY-OLS-DOMAIN-001", "tabelz.analysis.fit_y_by_x:compute_fits",
61 "fitYByXMenuItem", "REG_CORE",
62 list(y_columns = list("y"), x_columns = list("x"), model_type = "logarithmic"),
63 list(), list("Logarithmic regression requires strictly positive x; REG_CORE contains negative x."),
64 list(error_class = "ValueError", message_contains = "positive"))
Design boundary STAT-REG-BOUNDARY-OLS-MIN-001
Case STAT-REG-BOUNDARY-OLS-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN3.json
Settings compared
x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/estimate | tolerance | -0.090029661103937703 | -0.09002966110393788 | 1.80E-16 | 14 | passed |
/responses/0/observations | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- Three rows give one residual degree of freedom for intercept plus one slope.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
49 d3 <- read_dataset("REG_MIN3")
50 d4 <- read_dataset("REG_MIN4")
51 d5 <- read_dataset("REG_MIN5")
52 d8 <- read_dataset("REG_MIN8")
53 fit <- stats::lm(y ~ x, data = d3)
54 emit("STAT-REG-BOUNDARY-OLS-MIN-001", "tabelz.analysis.fit_y_by_x:compute_fits",
55 "fitYByXMenuItem", "REG_MIN3",
56 list(y_columns = list("y"), x_columns = list("x")),
57 list("/responses/0/parameters/1/estimate" = tol(coef(fit)[["x"]], "n=3 slope", "1e-9"),
58 "/responses/0/observations" = exact(3, "three observations")),
59 list("Three rows give one residual degree of freedom for intercept plus one slope."))
Design boundary STAT-REG-BOUNDARY-ORDINAL-MIN-001
Case STAT-REG-BOUNDARY-ORDINAL-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN4.json
Settings compared
level_order= ["low", "middle", "high"]outcome_column= "ordinal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | -10.437130316938166 | -10.437130070042478 | 2.47E-7 | 7 | passed |
/n | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Four rows exceed one slope plus two thresholds.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
108 ord_start <- c(coef(ofit)[["x"]], ofit$zeta[[1L]], log(ofit$zeta[[2L]] - ofit$zeta[[1L]]))
109 ord_refined <- stats::optim(ord_start, function(p) -ord_loglik(p), method = "Nelder-Mead",
110 control = list(reltol = 1e-16, maxit = 100000L))
111 stopifnot(-ord_refined$value >= ord_loglik(ord_start))
112 ord_min_slope <- ord_refined$par[[1L]]
113 emit("STAT-REG-BOUNDARY-ORDINAL-MIN-001",
114 "tabelz.analysis.ordinal_logistic:compute_ordinal_logistic_regression",
115 "ordinalRegressionMenuItem", "REG_MIN4",
116 list(outcome_column = "ordinal", predictors = list("x"),
117 level_order = list("low", "middle", "high")),
118 list("/coefficients/0/coefficient" = tol(ord_min_slope, "n=4 ordered slope, polr refined by Nelder-Mead"),
119 "/n" = exact(4, "four observations")),
120 list("Four rows exceed one slope plus two thresholds."))
Design boundary STAT-REG-BOUNDARY-ORDINAL-ONELEVEL-001
Case STAT-REG-BOUNDARY-ORDINAL-ONELEVEL-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_DEGENERATE.json
Settings compared
outcome_column= "ordinal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Only one ordered level is present.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
121 emit("STAT-REG-BOUNDARY-ORDINAL-ONELEVEL-001",
122 "tabelz.analysis.ordinal_logistic:compute_ordinal_logistic_regression",
123 "ordinalRegressionMenuItem", "REG_DEGENERATE",
124 list(outcome_column = "ordinal", predictors = list("x")),
125 list(), list("Only one ordered level is present."),
126 list(error_class = "ValueError", message_contains = "three"))
Design boundary STAT-REG-BOUNDARY-POISSON-MIN-001
Case STAT-REG-BOUNDARY-POISSON-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN3.json
Settings compared
count_column= "count"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | -13.866489280647015 | -13.866489288888134 | 8.24E-9 | 9 | passed |
/n | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- Three rows exceed intercept and slope count.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
149 pfit <- stats::glm(count ~ x, data = d3, family = stats::poisson())
150 emit("STAT-REG-BOUNDARY-POISSON-MIN-001",
151 "tabelz.analysis.poisson_regression:compute_poisson_regression",
152 "poissonRegressionMenuItem", "REG_MIN3",
153 list(count_column = "count", predictors = list("x")),
154 list("/coefficients/1/coefficient" = tol(coef(pfit)[["x"]], "n=3 Poisson slope"),
155 "/n" = exact(3, "three observations")),
156 list("Three rows exceed intercept and slope count."))
Design boundary STAT-REG-BOUNDARY-POISSON-ZEROEXPOSURE-001
Case STAT-REG-BOUNDARY-POISSON-ZEROEXPOSURE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_DEGENERATE.json
Settings compared
count_column= "count"exposure_column= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One exposure is zero; manual requires positive exposure.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
157 emit("STAT-REG-BOUNDARY-POISSON-ZEROEXPOSURE-001",
158 "tabelz.analysis.poisson_regression:compute_poisson_regression",
159 "poissonRegressionMenuItem", "REG_DEGENERATE",
160 list(count_column = "count", predictors = list("x"), exposure_column = "exposure"),
161 list(), list("One exposure is zero; manual requires positive exposure."),
162 list(error_class = "ValueError", message_contains = "exposure"))
Design boundary STAT-REG-BOUNDARY-VIF-COLLINEAR-001
Case STAT-REG-BOUNDARY-VIF-COLLINEAR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_DEGENERATE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | absent | None | passed |
Convention
- z equals x exactly; R auxiliary regression has R-squared one, so VIF is undefined.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
73 emit("STAT-REG-BOUNDARY-VIF-COLLINEAR-001", "tabelz.analysis.fit_y_by_x:compute_fit_vif",
74 "fitYByXMenuItem", "REG_DEGENERATE",
75 list(y_columns = list("y"), x_columns = list("x", "z"), missing = "drop",
76 model_type = "linear", degree = 2L, interactions = FALSE, split_percent = 100L),
77 list("/0" = list(comparison = "absent", rationale = "Perfect collinearity makes VIF undefined.")),
78 list("z equals x exactly; R auxiliary regression has R-squared one, so VIF is undefined."))
Design boundary STAT-REG-BOUNDARY-VIF-MIN-001
Case STAT-REG-BOUNDARY-VIF-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R minimal-design fit and manual design conditions
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_boundaries.R · sha256 d598c8abc1c5a2a7
- Dataset
- reference_data/datasets/REG_MIN3.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 35.792672425141205 | 35.79267242514028 | 9.23E-13 | 13 | passed |
Convention
- Three rows are the smallest design for an auxiliary intercept-plus-slope fit.
- Reference data are re-read from the exported minimal-design CSV.
Reference code
The lines of the reference script that produce this case's expected values.
66 vif_fit <- stats::lm(x ~ z, data = d3)
67 emit("STAT-REG-BOUNDARY-VIF-MIN-001", "tabelz.analysis.fit_y_by_x:compute_fit_vif",
68 "fitYByXMenuItem", "REG_MIN3",
69 list(y_columns = list("y"), x_columns = list("x", "z"), missing = "drop",
70 model_type = "linear", degree = 2L, interactions = FALSE, split_percent = 100L),
71 list("/0" = tol(1 / (1 - summary(vif_fit)$r.squared), "n=3 auxiliary VIF", "1e-9")),
72 list("Three rows are the smallest design for an auxiliary intercept-plus-slope fit."))
CHAID root split on a binary nominal predictor
Case STAT-REG-CHAID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- perfect-association chi-square identity (c - 1) N, checked with stats::chisq.test; Kass (1980) Bonferroni multiplier
- Citation
- Kass (1980) An exploratory technique for investigating large quantities of categorical data, Applied Statistics 29(2), 119-127; R Core Team, stats package help: chisq.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_chaid.R · sha256 eb0c2c6fc3193963
- Dataset
- reference_data/datasets/REG_CHAID.json
Settings compared
max_depth= 3min_child= 1min_parent= 2predictors= ["shift"]target= "late"target_kind= "categorical"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 30 | 30 | 0.00E+2 | passed | |
/test_rows | exact | 12 | 12 | 0.00E+2 | passed | |
/missing_target | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/classes | sequence | ['no', 'yes'] | ['no', 'yes'] | passed | ||
/risk_name | exact | misclassification rate | misclassification rate | passed | ||
/training_risk | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_risk | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/nodes/0/n | exact | 30 | 30 | 0.00E+2 | passed | |
/nodes/0/split/predictor | exact | shift | shift | passed | ||
/nodes/0/split/statistic | tolerance | 30 | 30.0 | 0.00E+2 | passed | |
/nodes/0/split/df/0 | exact | 1 | 1 | 0.00E+2 | passed | |
/nodes/0/split/p_value | tail_probability | 4.3204630578274968e-08 | 4.3204630578274955e-08 | 1.30E-23 | 15 | passed |
/nodes/0/split/multiplier | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/nodes/0/split/adjusted_p | tail_probability | 4.3204630578274968e-08 | 4.3204630578274955e-08 | 1.30E-23 | 15 | passed |
/nodes/0/split/eligible | exact | True | True | passed | ||
/nodes/0/split/groups/0 | sequence | ['day'] | ['day'] | passed | ||
/nodes/1/stop_reason | exact | pure node | pure node | passed | ||
/nodes/1/parent | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/split/groups/1 | sequence | ['night'] | ['night'] | passed | ||
/nodes/2/stop_reason | exact | pure node | pure node | passed | ||
/nodes/2/parent | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Analytic oracle: the predictor determines the target, so whichever 30 rows form the training set the root table is perfectly associated, its chi-square is (c - 1) N = (c - 1) x 30 with (c - 1)^2 df, nothing merges (each pairwise 2 x 2 has at least 4 rows: chi-square >= 4, p <= 0.0455 < 0.05), the multiplier is 1 and both risks are 0. stats::chisq.test confirms the identity on the full 42-row tables.
- Minimum parent 2 and child 1 so the 30-row root may split; depth 3 leaves the pure children to stop as pure nodes.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:17-22: categories with similar target distributions are merged using Pearson chi-square tests; nominal categories may merge freely, ordered ones only with neighbours.
- docs/manual/chapters/90-learning-and-mixtures.tex:44-49: the overall split test includes a Bonferroni multiplier for the candidate category reduction; the smallest adjusted p selects the split if the thresholds and size rules permit.
- docs/manual/chapters/90-learning-and-mixtures.tex:51-58: merge and split thresholds 0.05; a seeded random split reserves 30% for assessment; read held-out misclassification separately from training error.
Reference code
The lines of the reference script that produce this case's expected values.
30 emit <- function(id, title, kind, configuration, outputs, notes) {
31 expected <- list(schema_version = "2.0.0", case_id = id, outputs = outputs,
32 expected_error = NULL, deferred_outputs = list(), generator_run = run)
33 write_expected("regression", id, expected)
34 case <- list(
35 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
36 entry_point = "tabelz.analysis.chaid:compute_chaid",
37 menu_items = list("chaidMenuItem"), title = title, case_kind = kind,
38 dataset = list(path = "reference_data/datasets/REG_CHAID.json", sha256 = ""),
39 excluded_rows = list(), configuration = configuration, "repeat" = 1L,
40 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"),
41 sha256 = ""),
42 oracle = list(oracle_class = "analytic",
43 source = "perfect-association chi-square identity (c - 1) N, checked with stats::chisq.test; Kass (1980) Bonferroni multiplier",
44 citation = "Kass (1980) An exploratory technique for investigating large quantities of categorical data, Applied Statistics 29(2), 119-127; R Core Team, stats package help: chisq.test.",
45 generator = list(path = "generators/r/regression_chaid.R", sha256 = ""),
46 independent = TRUE,
47 convention_notes = c(notes, "Expected computed from the exported CSV.", manual)),
48 supported = TRUE, unsupported_reason = NULL,
49 requirement_ids = list("REQ-STAT-REG-CHAID-001"), risk_ids = list("RISK-REFERENCE-001"),
50 review_reference = NULL
51 )
52 write_case("regression", id, case)
CHAID root split on an ordered three-category predictor
Case STAT-REG-CHAID-ORDINAL-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- perfect-association chi-square identity (c - 1) N, checked with stats::chisq.test; Kass (1980) Bonferroni multiplier
- Citation
- Kass (1980) An exploratory technique for investigating large quantities of categorical data, Applied Statistics 29(2), 119-127; R Core Team, stats package help: chisq.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_chaid.R · sha256 eb0c2c6fc3193963
- Dataset
- reference_data/datasets/REG_CHAID.json
Settings compared
max_depth= 3min_child= 1min_parent= 2ordinal= ["machine"]predictors= ["machine"]target= "grade"target_kind= "categorical"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 30 | 30 | 0.00E+2 | passed | |
/test_rows | exact | 12 | 12 | 0.00E+2 | passed | |
/missing_target | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/classes | sequence | ['A', 'B', 'C'] | ['A', 'B', 'C'] | passed | ||
/risk_name | exact | misclassification rate | misclassification rate | passed | ||
/training_risk | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_risk | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/nodes/0/n | exact | 30 | 30 | 0.00E+2 | passed | |
/nodes/0/split/predictor | exact | machine | machine | passed | ||
/nodes/0/split/statistic | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/nodes/0/split/df/0 | exact | 4 | 4 | 0.00E+2 | passed | |
/nodes/0/split/p_value | tail_probability | 2.9008631203404549e-12 | 2.9008631203404573e-12 | 2.39E-27 | 15 | passed |
/nodes/0/split/multiplier | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/nodes/0/split/adjusted_p | tail_probability | 2.9008631203404549e-12 | 2.9008631203404573e-12 | 2.39E-27 | 15 | passed |
/nodes/0/split/eligible | exact | True | True | passed | ||
/nodes/0/split/groups/0 | sequence | ['m1'] | ['m1'] | passed | ||
/nodes/1/stop_reason | exact | pure node | pure node | passed | ||
/nodes/1/parent | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/split/groups/1 | sequence | ['m2'] | ['m2'] | passed | ||
/nodes/2/stop_reason | exact | pure node | pure node | passed | ||
/nodes/2/parent | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/split/groups/2 | sequence | ['m3'] | ['m3'] | passed | ||
/nodes/3/stop_reason | exact | pure node | pure node | passed | ||
/nodes/3/parent | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Analytic oracle: the predictor determines the target, so whichever 30 rows form the training set the root table is perfectly associated, its chi-square is (c - 1) N = (c - 1) x 30 with (c - 1)^2 df, nothing merges (each pairwise 2 x 2 has at least 4 rows: chi-square >= 4, p <= 0.0455 < 0.05), the multiplier is 1 and both risks are 0. stats::chisq.test confirms the identity on the full 42-row tables.
- Declared ordinal: only adjacent categories may merge, and none does; the ordinal multiplier C(c - 1, r - 1) for r = c is 1.
- Minimum parent 2 and child 1 so the 30-row root may split; depth 3 leaves the pure children to stop as pure nodes.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:17-22: categories with similar target distributions are merged using Pearson chi-square tests; nominal categories may merge freely, ordered ones only with neighbours.
- docs/manual/chapters/90-learning-and-mixtures.tex:44-49: the overall split test includes a Bonferroni multiplier for the candidate category reduction; the smallest adjusted p selects the split if the thresholds and size rules permit.
- docs/manual/chapters/90-learning-and-mixtures.tex:51-58: merge and split thresholds 0.05; a seeded random split reserves 30% for assessment; read held-out misclassification separately from training error.
Reference code
The lines of the reference script that produce this case's expected values.
135 emit("STAT-REG-CHAID-ORDINAL-001", "CHAID root split on an ordered three-category predictor", "axis_coverage",
136 list(target = "grade", target_kind = "categorical", predictors = list("machine"),
137 ordinal = list("machine"), min_parent = 2L, min_child = 1L, max_depth = 3L),
138 root_outputs(3L, c("A", "B", "C"), "machine", list("m1", "m2", "m3")),
139 list(invariance, "Declared ordinal: only adjacent categories may merge, and none does; the ordinal multiplier C(c - 1, r - 1) for r = c is 1.", sizes))
CHAID root split with Kass merge/re-split
Case STAT-REG-CHAID-RESPLIT-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- perfect-association chi-square identity (c - 1) N, checked with stats::chisq.test; Kass (1980) Bonferroni multiplier
- Citation
- Kass (1980) An exploratory technique for investigating large quantities of categorical data, Applied Statistics 29(2), 119-127; R Core Team, stats package help: chisq.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_chaid.R · sha256 eb0c2c6fc3193963
- Dataset
- reference_data/datasets/REG_CHAID.json
Settings compared
algorithm= "kass_resplit"max_depth= 3min_child= 1min_parent= 2predictors= ["machine"]resplit_alpha= 0.01target= "grade"target_kind= "categorical"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 30 | 30 | 0.00E+2 | passed | |
/test_rows | exact | 12 | 12 | 0.00E+2 | passed | |
/missing_target | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/classes | sequence | ['A', 'B', 'C'] | ['A', 'B', 'C'] | passed | ||
/risk_name | exact | misclassification rate | misclassification rate | passed | ||
/training_risk | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_risk | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/nodes/0/n | exact | 30 | 30 | 0.00E+2 | passed | |
/nodes/0/split/predictor | exact | machine | machine | passed | ||
/nodes/0/split/statistic | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/nodes/0/split/df/0 | exact | 4 | 4 | 0.00E+2 | passed | |
/nodes/0/split/p_value | tail_probability | 2.9008631203404549e-12 | 2.9008631203404573e-12 | 2.39E-27 | 15 | passed |
/nodes/0/split/multiplier | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/nodes/0/split/adjusted_p | tail_probability | 2.9008631203404549e-12 | 2.9008631203404573e-12 | 2.39E-27 | 15 | passed |
/nodes/0/split/eligible | exact | True | True | passed | ||
/nodes/0/split/groups/0 | sequence | ['m1'] | ['m1'] | passed | ||
/nodes/1/stop_reason | exact | pure node | pure node | passed | ||
/nodes/1/parent | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/split/groups/1 | sequence | ['m2'] | ['m2'] | passed | ||
/nodes/2/stop_reason | exact | pure node | pure node | passed | ||
/nodes/2/parent | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/split/groups/2 | sequence | ['m3'] | ['m3'] | passed | ||
/nodes/3/stop_reason | exact | pure node | pure node | passed | ||
/nodes/3/parent | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Analytic oracle: the predictor determines the target, so whichever 30 rows form the training set the root table is perfectly associated, its chi-square is (c - 1) N = (c - 1) x 30 with (c - 1)^2 df, nothing merges (each pairwise 2 x 2 has at least 4 rows: chi-square >= 4, p <= 0.0455 < 0.05), the multiplier is 1 and both risks are 0. stats::chisq.test confirms the identity on the full 42-row tables.
- Kass merge/re-split mode: no compound forms, so no re-split is attempted and the partition is the three single categories.
- Minimum parent 2 and child 1 so the 30-row root may split; depth 3 leaves the pure children to stop as pure nodes.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:17-22: categories with similar target distributions are merged using Pearson chi-square tests; nominal categories may merge freely, ordered ones only with neighbours.
- docs/manual/chapters/90-learning-and-mixtures.tex:44-49: the overall split test includes a Bonferroni multiplier for the candidate category reduction; the smallest adjusted p selects the split if the thresholds and size rules permit.
- docs/manual/chapters/90-learning-and-mixtures.tex:51-58: merge and split thresholds 0.05; a seeded random split reserves 30% for assessment; read held-out misclassification separately from training error.
Reference code
The lines of the reference script that produce this case's expected values.
141 emit("STAT-REG-CHAID-RESPLIT-001", "CHAID root split with Kass merge/re-split", "axis_coverage",
142 list(target = "grade", target_kind = "categorical", predictors = list("machine"),
143 algorithm = "kass_resplit", resplit_alpha = 0.01, min_parent = 2L, min_child = 1L,
144 max_depth = 3L),
145 root_outputs(3L, c("A", "B", "C"), "machine", list("m1", "m2", "m3")),
146 list(invariance, "Kass merge/re-split mode: no compound forms, so no re-split is attempted and the partition is the three single categories.", sizes))
CHAID root split on a three-category nominal predictor
Case STAT-REG-CHAID-THREE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- perfect-association chi-square identity (c - 1) N, checked with stats::chisq.test; Kass (1980) Bonferroni multiplier
- Citation
- Kass (1980) An exploratory technique for investigating large quantities of categorical data, Applied Statistics 29(2), 119-127; R Core Team, stats package help: chisq.test.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_chaid.R · sha256 eb0c2c6fc3193963
- Dataset
- reference_data/datasets/REG_CHAID.json
Settings compared
max_depth= 3min_child= 1min_parent= 2predictors= ["machine"]target= "grade"target_kind= "categorical"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 30 | 30 | 0.00E+2 | passed | |
/test_rows | exact | 12 | 12 | 0.00E+2 | passed | |
/missing_target | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/classes | sequence | ['A', 'B', 'C'] | ['A', 'B', 'C'] | passed | ||
/risk_name | exact | misclassification rate | misclassification rate | passed | ||
/training_risk | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_risk | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/nodes/0/n | exact | 30 | 30 | 0.00E+2 | passed | |
/nodes/0/split/predictor | exact | machine | machine | passed | ||
/nodes/0/split/statistic | tolerance | 60 | 60.0 | 0.00E+2 | passed | |
/nodes/0/split/df/0 | exact | 4 | 4 | 0.00E+2 | passed | |
/nodes/0/split/p_value | tail_probability | 2.9008631203404549e-12 | 2.9008631203404573e-12 | 2.39E-27 | 15 | passed |
/nodes/0/split/multiplier | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/nodes/0/split/adjusted_p | tail_probability | 2.9008631203404549e-12 | 2.9008631203404573e-12 | 2.39E-27 | 15 | passed |
/nodes/0/split/eligible | exact | True | True | passed | ||
/nodes/0/split/groups/0 | sequence | ['m1'] | ['m1'] | passed | ||
/nodes/1/stop_reason | exact | pure node | pure node | passed | ||
/nodes/1/parent | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/split/groups/1 | sequence | ['m2'] | ['m2'] | passed | ||
/nodes/2/stop_reason | exact | pure node | pure node | passed | ||
/nodes/2/parent | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/split/groups/2 | sequence | ['m3'] | ['m3'] | passed | ||
/nodes/3/stop_reason | exact | pure node | pure node | passed | ||
/nodes/3/parent | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Analytic oracle: the predictor determines the target, so whichever 30 rows form the training set the root table is perfectly associated, its chi-square is (c - 1) N = (c - 1) x 30 with (c - 1)^2 df, nothing merges (each pairwise 2 x 2 has at least 4 rows: chi-square >= 4, p <= 0.0455 < 0.05), the multiplier is 1 and both risks are 0. stats::chisq.test confirms the identity on the full 42-row tables.
- Three categories and three classes: chi-square 2N on 4 df; the nominal Kass multiplier for c = r = 3 is 1.
- Minimum parent 2 and child 1 so the 30-row root may split; depth 3 leaves the pure children to stop as pure nodes.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:17-22: categories with similar target distributions are merged using Pearson chi-square tests; nominal categories may merge freely, ordered ones only with neighbours.
- docs/manual/chapters/90-learning-and-mixtures.tex:44-49: the overall split test includes a Bonferroni multiplier for the candidate category reduction; the smallest adjusted p selects the split if the thresholds and size rules permit.
- docs/manual/chapters/90-learning-and-mixtures.tex:51-58: merge and split thresholds 0.05; a seeded random split reserves 30% for assessment; read held-out misclassification separately from training error.
Reference code
The lines of the reference script that produce this case's expected values.
129 emit("STAT-REG-CHAID-THREE-001", "CHAID root split on a three-category nominal predictor", "axis_coverage",
130 list(target = "grade", target_kind = "categorical", predictors = list("machine"),
131 min_parent = 2L, min_child = 1L, max_depth = 3L),
132 root_outputs(3L, c("A", "B", "C"), "machine", list("m1", "m2", "m3")),
133 list(invariance, "Three categories and three classes: chi-square 2N on 4 df; the nominal Kass multiplier for c = r = 3 is 1.", sizes))
Curve estimation original-scale curves
Case STAT-REG-CURVE-ESTIMATION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.lm, pf, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_curve_estimation.R · sha256 f830ec43141611cc
- Dataset
- reference_data/datasets/REG_CURVE.json
Settings compared
confidence_level= 0.95curves= ["linear", "quadratic", "cubic", "logarithmic", "inverse"]predictor= "t"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[curve=linear]/r_squared | tolerance | 0.98942431485151172 | 0.9894243148515118 | 1.12E-16 | 15 | passed |
/fits/[curve=linear]/adjusted_r_squared | tolerance | 0.98836674633666288 | 0.988366746336663 | 1.13E-16 | 15 | passed |
/fits/[curve=linear]/standard_error | tolerance | 1.5837932101132839 | 1.583793210113281 | 2.90E-15 | 14 | passed |
/fits/[curve=linear]/f_value | tolerance | 935.56521488629039 | 935.5652148862938 | 3.41E-12 | 14 | passed |
/fits/[curve=linear]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=linear]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=linear]/p_value | tail_probability | 3.270135381274213e-11 | 3.270135381274155e-11 | 5.82E-25 | 13 | passed |
/fits/[curve=linear]/coefficients/0/estimate | tolerance | -2.9151515151515044 | -2.915151515151529 | 2.44E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/standard_error | tolerance | 0.9747573381789385 | 0.9747573381789373 | 1.22E-15 | 14 | passed |
/fits/[curve=linear]/coefficients/0/t_value | tolerance | -2.9906433129271432 | -2.990643312927172 | 2.89E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/p_value | tail_probability | 0.013558740627382567 | 0.0135587406273819 | 6.67E-16 | 13 | passed |
/fits/[curve=linear]/coefficients/0/lower | tolerance | -5.0870462116067205 | -5.087046211606743 | 2.23E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/upper | tolerance | -0.74325681869628824 | -0.7432568186963149 | 2.66E-14 | 13 | passed |
/fits/[curve=linear]/coefficients/0/parameter | tolerance | -2.9151515151515044 | -2.915151515151529 | 2.44E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/parameter_lower | tolerance | -5.0870462116067205 | -5.087046211606743 | 2.23E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/parameter_upper | tolerance | -0.74325681869628824 | -0.7432568186963149 | 2.66E-14 | 13 | passed |
/fits/[curve=linear]/coefficients/1/estimate | tolerance | 4.0510489510489505 | 4.051048951048952 | 1.74E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/standard_error | tolerance | 0.13244344174607151 | 0.1324434417460713 | 1.99E-16 | 14 | passed |
/fits/[curve=linear]/coefficients/1/t_value | tolerance | 30.587010558181234 | 30.587010558181294 | 6.03E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/1/p_value | tail_probability | 3.270135381274213e-11 | 3.27013538127415e-11 | 6.27E-25 | 13 | passed |
/fits/[curve=linear]/coefficients/1/lower | tolerance | 3.7559465728037478 | 3.75594657280375 | 2.19E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/upper | tolerance | 4.3461513292941536 | 4.3461513292941545 | 8.86E-16 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter | tolerance | 4.0510489510489505 | 4.051048951048952 | 1.74E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter_lower | tolerance | 3.7559465728037478 | 3.75594657280375 | 2.19E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter_upper | tolerance | 4.3461513292941536 | 4.3461513292941545 | 8.86E-16 | 15 | passed |
/fits/[curve=quadratic]/r_squared | tolerance | 0.99579994516029158 | 0.9957999451602916 | 2.53E-18 | 17 | passed |
/fits/[curve=quadratic]/adjusted_r_squared | tolerance | 0.9948665996403564 | 0.9948665996403564 | 2.86E-18 | 17 | passed |
/fits/[curve=quadratic]/standard_error | tolerance | 1.0520840731048537 | 1.0520840731048529 | 8.43E-16 | 15 | passed |
/fits/[curve=quadratic]/f_value | tolerance | 1066.9145818896898 | 1066.9145818896916 | 1.79E-12 | 14 | passed |
/fits/[curve=quadratic]/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/fits/[curve=quadratic]/df2 | exact | 9 | 9 | 0.00E+2 | passed | |
/fits/[curve=quadratic]/p_value | tail_probability | 2.016727983116802e-11 | 2.016727983116789e-11 | 1.29E-25 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/estimate | tolerance | 0.31363636363638192 | 0.3136363636363552 | 2.67E-14 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/standard_error | tolerance | 1.0873592087902506 | 1.087359208790252 | 1.34E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/t_value | tolerance | 0.28843859609679523 | 0.2884385960967703 | 2.49E-14 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/p_value | tail_probability | 0.77954379035318722 | 0.7795437903532055 | 1.83E-14 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/lower | tolerance | -2.1461410590630727 | -2.146141059063102 | 2.93E-14 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/upper | tolerance | 2.7734137863358361 | 2.773413786335812 | 2.40E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter | tolerance | 0.31363636363638192 | 0.3136363636363552 | 2.67E-14 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter_lower | tolerance | -2.1461410590630727 | -2.146141059063102 | 2.93E-14 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter_upper | tolerance | 2.7734137863358361 | 2.773413786335812 | 2.40E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/estimate | tolerance | 2.6672827172827134 | 2.667282717282719 | 5.75E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/standard_error | tolerance | 0.3845743394134416 | 0.38457433941344166 | 5.71E-17 | 15 | passed |
/fits/[curve=quadratic]/coefficients/1/t_value | tolerance | 6.9356752230294196 | 6.935675223029434 | 1.42E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/p_value | tail_probability | 6.7917799226063782e-05 | 6.791779922606277e-05 | 1.02E-18 | 13 | passed |
/fits/[curve=quadratic]/coefficients/1/lower | tolerance | 1.7973151207502085 | 1.797315120750214 | 5.55E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/upper | tolerance | 3.5372503138152185 | 3.5372503138152243 | 5.76E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter | tolerance | 2.6672827172827134 | 2.667282717282719 | 5.75E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter_lower | tolerance | 1.7973151207502085 | 1.797315120750214 | 5.55E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter_upper | tolerance | 3.5372503138152185 | 3.5372503138152243 | 5.76E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/estimate | tolerance | 0.10644355644355667 | 0.1064435564435564 | 2.75E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/standard_error | tolerance | 0.028798113502786167 | 0.028798113502786164 | 3.42E-18 | 15 | passed |
/fits/[curve=quadratic]/coefficients/2/t_value | tolerance | 3.6961989344634829 | 3.6961989344634736 | 9.32E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/p_value | tail_probability | 0.0049496153210565443 | 0.004949615321056615 | 7.11E-17 | 13 | passed |
/fits/[curve=quadratic]/coefficients/2/lower | tolerance | 0.041297697708153239 | 0.041297697708152975 | 2.64E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/upper | tolerance | 0.17158941517896009 | 0.17158941517895981 | 2.76E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter | tolerance | 0.10644355644355667 | 0.1064435564435564 | 2.75E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter_lower | tolerance | 0.041297697708153239 | 0.041297697708152975 | 2.64E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter_upper | tolerance | 0.17158941517896009 | 0.17158941517895981 | 2.76E-16 | 14 | passed |
/fits/[curve=cubic]/r_squared | tolerance | 0.99948771476280873 | 0.9994877147628086 | 1.09E-16 | 15 | passed |
/fits/[curve=cubic]/adjusted_r_squared | tolerance | 0.99929560779886195 | 0.9992956077988618 | 1.10E-16 | 15 | passed |
/fits/[curve=cubic]/standard_error | tolerance | 0.38972220155309634 | 0.3897222015530993 | 2.94E-15 | 14 | passed |
/fits/[curve=cubic]/f_value | tolerance | 5202.7666994929423 | 5202.766699492863 | 7.91E-11 | 13 | passed |
/fits/[curve=cubic]/df1 | exact | 3 | 3 | 0.00E+2 | passed | |
/fits/[curve=cubic]/df2 | exact | 8 | 8 | 0.00E+2 | passed | |
/fits/[curve=cubic]/p_value | tail_probability | 1.6945677443311567e-13 | 1.6945677443312526e-13 | 9.59E-27 | 13 | passed |
/fits/[curve=cubic]/coefficients/0/estimate | tolerance | 4.0646464646465041 | 4.064646464646454 | 4.97E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/0/standard_error | tolerance | 0.63761787986475338 | 0.6376178798647575 | 4.11E-15 | 14 | passed |
/fits/[curve=cubic]/coefficients/0/t_value | tolerance | 6.374737272908134 | 6.374737272908015 | 1.19E-13 | 13 | passed |
/fits/[curve=cubic]/coefficients/0/p_value | tail_probability | 0.00021484719168032797 | 0.00021484719168035507 | 2.71E-17 | 12 | passed |
/fits/[curve=cubic]/coefficients/0/lower | tolerance | 2.5942969969982697 | 2.5942969969982106 | 5.91E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/0/upper | tolerance | 5.5349959322947386 | 5.534995932294699 | 3.99E-14 | 14 | passed |
/fits/[curve=cubic]/coefficients/0/parameter | tolerance | 4.0646464646465041 | 4.064646464646454 | 4.97E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/0/parameter_lower | tolerance | 2.5942969969982697 | 2.5942969969982106 | 5.91E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/0/parameter_upper | tolerance | 5.5349959322947386 | 5.534995932294699 | 3.99E-14 | 14 | passed |
/fits/[curve=cubic]/coefficients/1/estimate | tolerance | -0.23184963184964852 | -0.23184963184962895 | 1.96E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/1/standard_error | tolerance | 0.40772634059444318 | 0.4077263405944456 | 2.44E-15 | 14 | passed |
/fits/[curve=cubic]/coefficients/1/t_value | tolerance | -0.56864030788794306 | -0.5686403078878917 | 5.14E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/1/p_value | tail_probability | 0.58520500838334089 | 0.5852050083833743 | 3.34E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/1/lower | tolerance | -1.1720682592920968 | -1.1720682592920828 | 1.40E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/1/upper | tolerance | 0.70836899559279987 | 0.7083689955928248 | 2.50E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/1/parameter | tolerance | -0.23184963184964852 | -0.23184963184962895 | 1.96E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/1/parameter_lower | tolerance | -1.1720682592920968 | -1.1720682592920828 | 1.40E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/1/parameter_upper | tolerance | 0.70836899559279987 | 0.7083689955928248 | 2.50E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/2/estimate | tolerance | 0.64230214230214455 | 0.6423021423021423 | 2.22E-15 | 14 | passed |
/fits/[curve=cubic]/coefficients/2/standard_error | tolerance | 0.071413372520685109 | 0.07141337252068557 | 4.58E-16 | 14 | passed |
/fits/[curve=cubic]/coefficients/2/t_value | tolerance | 8.9941438085156911 | 8.994143808515602 | 8.89E-14 | 14 | passed |
/fits/[curve=cubic]/coefficients/2/p_value | tail_probability | 1.8620068854698013e-05 | 1.8620068854699338e-05 | 1.33E-18 | 13 | passed |
/fits/[curve=cubic]/coefficients/2/lower | tolerance | 0.47762260996056916 | 0.4776226099605659 | 3.28E-15 | 14 | passed |
/fits/[curve=cubic]/coefficients/2/upper | tolerance | 0.80698167464371995 | 0.8069816746437188 | 1.11E-15 | 14 | passed |
/fits/[curve=cubic]/coefficients/2/parameter | tolerance | 0.64230214230214455 | 0.6423021423021423 | 2.22E-15 | 14 | passed |
/fits/[curve=cubic]/coefficients/2/parameter_lower | tolerance | 0.47762260996056916 | 0.4776226099605659 | 3.28E-15 | 14 | passed |
/fits/[curve=cubic]/coefficients/2/parameter_upper | tolerance | 0.80698167464371995 | 0.8069816746437188 | 1.11E-15 | 14 | passed |
/fits/[curve=cubic]/coefficients/3/estimate | tolerance | -0.027479927479927571 | -0.027479927479927488 | 8.31E-17 | 14 | passed |
/fits/[curve=cubic]/coefficients/3/standard_error | tolerance | 0.0036211341907905572 | 0.003621134190790583 | 2.56E-17 | 14 | passed |
/fits/[curve=cubic]/coefficients/3/t_value | tolerance | -7.5887625346268157 | -7.588762534626738 | 7.73E-14 | 13 | passed |
/fits/[curve=cubic]/coefficients/3/p_value | tail_probability | 6.3717449265666336e-05 | 6.371744926567096e-05 | 4.62E-18 | 13 | passed |
/fits/[curve=cubic]/coefficients/3/lower | tolerance | -0.035830277898019791 | -0.03583027789801976 | 2.76E-17 | 15 | passed |
/fits/[curve=cubic]/coefficients/3/upper | tolerance | -0.019129577061835355 | -0.019129577061835212 | 1.43E-16 | 14 | passed |
/fits/[curve=cubic]/coefficients/3/parameter | tolerance | -0.027479927479927571 | -0.027479927479927488 | 8.31E-17 | 14 | passed |
/fits/[curve=cubic]/coefficients/3/parameter_lower | tolerance | -0.035830277898019791 | -0.03583027789801976 | 2.76E-17 | 15 | passed |
/fits/[curve=cubic]/coefficients/3/parameter_upper | tolerance | -0.019129577061835355 | -0.019129577061835212 | 1.43E-16 | 14 | passed |
/fits/[curve=logarithmic]/r_squared | tolerance | 0.82979648971823483 | 0.829796489718235 | 2.23E-16 | 15 | passed |
/fits/[curve=logarithmic]/adjusted_r_squared | tolerance | 0.81277613869005827 | 0.8127761386900585 | 2.22E-16 | 15 | passed |
/fits/[curve=logarithmic]/standard_error | tolerance | 6.3537259191113469 | 6.353725919111342 | 4.46E-15 | 15 | passed |
/fits/[curve=logarithmic]/f_value | tolerance | 48.753194828034971 | 48.75319482803502 | 4.97E-14 | 14 | passed |
/fits/[curve=logarithmic]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=logarithmic]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=logarithmic]/p_value | tail_probability | 3.7956131600958105e-05 | 3.7956131600957935e-05 | 1.70E-19 | 14 | passed |
/fits/[curve=logarithmic]/coefficients/0/estimate | tolerance | -6.0598937775669279 | -6.059893777566936 | 8.02E-15 | 14 | passed |
/fits/[curve=logarithmic]/coefficients/0/standard_error | tolerance | 4.6028154705097952 | 4.602815470509793 | 2.64E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/0/t_value | tolerance | -1.3165623989040236 | -1.316562398904026 | 2.44E-15 | 14 | passed |
/fits/[curve=logarithmic]/coefficients/0/p_value | tail_probability | 0.21736028061859292 | 0.21736028061859228 | 6.42E-16 | 14 | passed |
/fits/[curve=logarithmic]/coefficients/0/lower | tolerance | -16.315605755933284 | -16.31560575593329 | 6.77E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/0/upper | tolerance | 4.1958182007994287 | 4.195818200799417 | 1.16E-14 | 14 | passed |
/fits/[curve=logarithmic]/coefficients/0/parameter | tolerance | -6.0598937775669279 | -6.059893777566936 | 8.02E-15 | 14 | passed |
/fits/[curve=logarithmic]/coefficients/0/parameter_lower | tolerance | -16.315605755933284 | -16.31560575593329 | 6.77E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/0/parameter_upper | tolerance | 4.1958182007994287 | 4.195818200799417 | 1.16E-14 | 14 | passed |
/fits/[curve=logarithmic]/coefficients/1/estimate | tolerance | 17.697249679667763 | 17.697249679667767 | 3.74E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/1/standard_error | tolerance | 2.5345696949716801 | 2.5345696949716787 | 1.38E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/1/t_value | tolerance | 6.9823488045238005 | 6.982348804523805 | 4.41E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/1/p_value | tail_probability | 3.7956131600958179e-05 | 3.7956131600957955e-05 | 2.24E-19 | 14 | passed |
/fits/[curve=logarithmic]/coefficients/1/lower | tolerance | 12.049876469234363 | 12.04987646923437 | 6.84E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/1/upper | tolerance | 23.344622890101164 | 23.344622890101164 | 3.52E-16 | 16 | passed |
/fits/[curve=logarithmic]/coefficients/1/parameter | tolerance | 17.697249679667763 | 17.697249679667767 | 3.74E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/1/parameter_lower | tolerance | 12.049876469234363 | 12.04987646923437 | 6.84E-15 | 15 | passed |
/fits/[curve=logarithmic]/coefficients/1/parameter_upper | tolerance | 23.344622890101164 | 23.344622890101164 | 3.52E-16 | 16 | passed |
/fits/[curve=inverse]/r_squared | tolerance | 0.52108967741563406 | 0.5210896774156342 | 1.07E-16 | 15 | passed |
/fits/[curve=inverse]/adjusted_r_squared | tolerance | 0.47319864515719745 | 0.47319864515719756 | 1.12E-16 | 15 | passed |
/fits/[curve=inverse]/standard_error | tolerance | 10.657892105652095 | 10.657892105652092 | 3.11E-15 | 15 | passed |
/fits/[curve=inverse]/f_value | tolerance | 10.880735971687846 | 10.88073597168785 | 3.78E-15 | 15 | passed |
/fits/[curve=inverse]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=inverse]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=inverse]/p_value | tail_probability | 0.0080325227934635399 | 0.008032522793463533 | 6.90E-18 | 15 | passed |
/fits/[curve=inverse]/coefficients/0/estimate | tolerance | 33.828212566285337 | 33.828212566285345 | 7.56E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/0/standard_error | tolerance | 4.4077745553359415 | 4.4077745553359415 | 3.54E-17 | 17 | passed |
/fits/[curve=inverse]/coefficients/0/t_value | tolerance | 7.6746694145991992 | 7.674669414599201 | 1.73E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/0/p_value | tail_probability | 1.6906972774617145e-05 | 1.6906972774617098e-05 | 4.70E-20 | 14 | passed |
/fits/[curve=inverse]/coefficients/0/lower | tolerance | 24.007078828744802 | 24.00707882874481 | 7.58E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/0/upper | tolerance | 43.649346303825872 | 43.64934630382588 | 7.55E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/0/parameter | tolerance | 33.828212566285337 | 33.828212566285345 | 7.56E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/0/parameter_lower | tolerance | 24.007078828744802 | 24.00707882874481 | 7.58E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/0/parameter_upper | tolerance | 43.649346303825872 | 43.64934630382588 | 7.55E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/1/estimate | tolerance | -40.26105983479794 | -40.261059834797955 | 1.47E-14 | 15 | passed |
/fits/[curve=inverse]/coefficients/1/standard_error | tolerance | 12.205513828878118 | 12.205513828878114 | 3.58E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/1/t_value | tolerance | -3.298596060703376 | -3.298596060703378 | 2.19E-15 | 15 | passed |
/fits/[curve=inverse]/coefficients/1/p_value | tail_probability | 0.0080325227934635798 | 0.008032522793463542 | 3.81E-17 | 14 | passed |
/fits/[curve=inverse]/coefficients/1/lower | tolerance | -67.456639405377018 | -67.45663940537703 | 1.44E-14 | 15 | passed |
/fits/[curve=inverse]/coefficients/1/upper | tolerance | -13.065480264218859 | -13.065480264218877 | 1.80E-14 | 14 | passed |
/fits/[curve=inverse]/coefficients/1/parameter | tolerance | -40.26105983479794 | -40.261059834797955 | 1.47E-14 | 15 | passed |
/fits/[curve=inverse]/coefficients/1/parameter_lower | tolerance | -67.456639405377018 | -67.45663940537703 | 1.44E-14 | 15 | passed |
/fits/[curve=inverse]/coefficients/1/parameter_upper | tolerance | -13.065480264218859 | -13.065480264218877 | 1.80E-14 | 14 | passed |
/n | exact | 12 | 12 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Original-scale curves: linear, quadratic, cubic (powers of t), logarithmic (ln t) and inverse (1 / t).
- lm() of the curve's fitted-scale response on its design columns with an intercept; R-squared, F, residual SE, coefficient SE, t, p and confint are on that fitted scale.
- Curve parameters: b0 = exp(coefficient) for power, compound, exponential and logistic; b1 = exp(coefficient) for compound and logistic; a parameter interval is the exp of the fitted interval (bounds sorted).
- docs/manual/chapters/86-regression-and-count-models.tex:31-37: 'offers named linearized curves. Linear, quadratic and cubic models fit the original response; power, exponential and growth forms fit a logarithmic response. The logistic growth curve requires a declared upper bound.'
- docs/manual/chapters/86-regression-and-count-models.tex:65-67: 'The reported R^2, tests and intervals use the named fitting scale'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
37 emit <- function(id, title, kind, config, outputs, notes) {
38 write_expected("regression", id, list(
39 schema_version = "2.0.0", case_id = id, outputs = outputs, expected_error = NULL,
40 deferred_outputs = list(), generator_run = run))
41 write_case("regression", id, list(
42 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
43 entry_point = entry, menu_items = list(menu), title = title, case_kind = kind,
44 dataset = list(path = "reference_data/datasets/REG_CURVE.json", sha256 = ""),
45 excluded_rows = list(), configuration = config, "repeat" = 1L,
46 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
47 oracle = list(oracle_class = "independent_implementation", source = "R 4.6.1 stats::lm",
48 citation = "R Core Team, stats package help: lm, summary.lm, confint.lm, pf, pt.",
49 generator = list(path = "generators/r/regression_curve_estimation.R", sha256 = ""),
50 independent = TRUE,
51 convention_notes = c(notes, notes_common, "Expected computed from the exported CSV.")),
52 supported = TRUE, unsupported_reason = NULL,
53 requirement_ids = list("REQ-STAT-REG-CURVE-ESTIMATION-001"),
54 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
Curve estimation log-scale curves 90 percent
Case STAT-REG-CURVE-ESTIMATION-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.lm, pf, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_curve_estimation.R · sha256 f830ec43141611cc
- Dataset
- reference_data/datasets/REG_CURVE.json
Settings compared
confidence_level= 0.9curves= ["power", "compound", "s", "growth", "exponential"]predictor= "t"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[curve=power]/r_squared | tolerance | 0.97589643713122165 | 0.9758964371312218 | 1.11E-16 | 15 | passed |
/fits/[curve=power]/adjusted_r_squared | tolerance | 0.97348608084434385 | 0.973486080844344 | 1.09E-16 | 15 | passed |
/fits/[curve=power]/standard_error | tolerance | 0.12960596873216043 | 0.1296059687321602 | 2.21E-16 | 14 | passed |
/fits/[curve=power]/f_value | tolerance | 404.87642530030951 | 404.876425300311 | 1.47E-12 | 14 | passed |
/fits/[curve=power]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=power]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=power]/p_value | tail_probability | 2.022622486831102e-09 | 2.0226224868310693e-09 | 3.27E-23 | 13 | passed |
/fits/[curve=power]/coefficients/0/estimate | tolerance | 1.1775146280449487 | 1.177514628044947 | 1.59E-15 | 14 | passed |
/fits/[curve=power]/coefficients/0/standard_error | tolerance | 0.093890162330803315 | 0.09389016233080313 | 1.81E-16 | 14 | passed |
/fits/[curve=power]/coefficients/0/t_value | tolerance | 12.541405817323119 | 12.541405817323126 | 6.76E-15 | 15 | passed |
/fits/[curve=power]/coefficients/0/p_value | tail_probability | 1.9270809113056189e-07 | 1.9270809113056083e-07 | 1.06E-21 | 14 | passed |
/fits/[curve=power]/coefficients/0/lower | tolerance | 1.0073423590058903 | 1.0073423590058892 | 1.10E-15 | 14 | passed |
/fits/[curve=power]/coefficients/0/upper | tolerance | 1.347686897084007 | 1.347686897084005 | 1.98E-15 | 14 | passed |
/fits/[curve=power]/coefficients/0/parameter | tolerance | 3.2462959154474409 | 3.246295915447436 | 4.89E-15 | 14 | passed |
/fits/[curve=power]/coefficients/0/parameter_lower | tolerance | 2.7383138807883851 | 2.738313880788382 | 3.10E-15 | 14 | passed |
/fits/[curve=power]/coefficients/0/parameter_upper | tolerance | 3.8485132199733902 | 3.8485132199733827 | 7.51E-15 | 14 | passed |
/fits/[curve=power]/coefficients/1/estimate | tolerance | 1.0403081685157474 | 1.040308168515748 | 6.33E-16 | 15 | passed |
/fits/[curve=power]/coefficients/1/standard_error | tolerance | 0.051701216706232338 | 0.05170121670623225 | 9.05E-17 | 14 | passed |
/fits/[curve=power]/coefficients/1/t_value | tolerance | 20.121541325164657 | 20.121541325164706 | 4.94E-14 | 14 | passed |
/fits/[curve=power]/coefficients/1/p_value | tail_probability | 2.0226224868311165e-09 | 2.0226224868310693e-09 | 4.72E-23 | 13 | passed |
/fits/[curve=power]/coefficients/1/lower | tolerance | 0.94660172323363967 | 0.9466017232336406 | 8.87E-16 | 15 | passed |
/fits/[curve=power]/coefficients/1/upper | tolerance | 1.1340146137978551 | 1.1340146137978555 | 4.09E-16 | 15 | passed |
/fits/[curve=power]/coefficients/1/parameter | tolerance | 1.0403081685157474 | 1.040308168515748 | 6.33E-16 | 15 | passed |
/fits/[curve=power]/coefficients/1/parameter_lower | tolerance | 0.94660172323363967 | 0.9466017232336406 | 8.87E-16 | 15 | passed |
/fits/[curve=power]/coefficients/1/parameter_upper | tolerance | 1.1340146137978551 | 1.1340146137978555 | 4.09E-16 | 15 | passed |
/fits/[curve=compound]/r_squared | tolerance | 0.95627921898053225 | 0.9562792189805321 | 1.08E-16 | 15 | passed |
/fits/[curve=compound]/adjusted_r_squared | tolerance | 0.95190714087858552 | 0.9519071408785853 | 2.19E-16 | 15 | passed |
/fits/[curve=compound]/standard_error | tolerance | 0.17455340982399503 | 0.17455340982399528 | 2.51E-16 | 14 | passed |
/fits/[curve=compound]/f_value | tolerance | 218.72418485724816 | 218.7241848572475 | 6.52E-13 | 14 | passed |
/fits/[curve=compound]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=compound]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=compound]/p_value | tail_probability | 4.00503223571717e-08 | 4.005032235717225e-08 | 5.49E-22 | 13 | passed |
/fits/[curve=compound]/coefficients/0/estimate | tolerance | 1.5070450855553674 | 1.5070450855553663 | 1.09E-15 | 15 | passed |
/fits/[curve=compound]/coefficients/0/standard_error | tolerance | 0.10743019735381026 | 0.10743019735381047 | 2.12E-16 | 14 | passed |
/fits/[curve=compound]/coefficients/0/t_value | tolerance | 14.028132896303541 | 14.028132896303504 | 3.73E-14 | 14 | passed |
/fits/[curve=compound]/coefficients/0/p_value | tail_probability | 6.6436794777500471e-08 | 6.643679477750222e-08 | 1.75E-21 | 13 | passed |
/fits/[curve=compound]/coefficients/0/lower | tolerance | 1.3123320294356005 | 1.3123320294355991 | 1.38E-15 | 14 | passed |
/fits/[curve=compound]/coefficients/0/upper | tolerance | 1.7017581416751344 | 1.7017581416751335 | 8.93E-16 | 15 | passed |
/fits/[curve=compound]/coefficients/0/parameter | tolerance | 4.5133744352707437 | 4.513374435270738 | 5.36E-15 | 14 | passed |
/fits/[curve=compound]/coefficients/0/parameter_lower | tolerance | 3.7148267039947878 | 3.714826703994783 | 4.93E-15 | 14 | passed |
/fits/[curve=compound]/coefficients/0/parameter_upper | tolerance | 5.4835798318801157 | 5.483579831880111 | 4.48E-15 | 15 | passed |
/fits/[curve=compound]/coefficients/1/estimate | tolerance | 0.21587816686651781 | 0.2158781668665179 | 8.54E-17 | 15 | passed |
/fits/[curve=compound]/coefficients/1/standard_error | tolerance | 0.014596889428480907 | 0.014596889428480931 | 2.43E-17 | 14 | passed |
/fits/[curve=compound]/coefficients/1/t_value | tolerance | 14.789326720890573 | 14.789326720890555 | 1.78E-14 | 14 | passed |
/fits/[curve=compound]/coefficients/1/p_value | tail_probability | 4.0050322357171839e-08 | 4.005032235717234e-08 | 5.02E-22 | 13 | passed |
/fits/[curve=compound]/coefficients/1/lower | tolerance | 0.18942187226341542 | 0.18942187226341548 | 5.50E-17 | 15 | passed |
/fits/[curve=compound]/coefficients/1/upper | tolerance | 0.2423344614696202 | 0.24233446146962032 | 1.16E-16 | 15 | passed |
/fits/[curve=compound]/coefficients/1/parameter | tolerance | 1.240951180819527 | 1.240951180819527 | 4.44E-17 | 16 | passed |
/fits/[curve=compound]/coefficients/1/parameter_lower | tolerance | 1.2085506989702162 | 1.2085506989702164 | 1.86E-16 | 15 | passed |
/fits/[curve=compound]/coefficients/1/parameter_upper | tolerance | 1.2742202991480207 | 1.2742202991480207 | 7.49E-18 | 17 | passed |
/fits/[curve=s]/r_squared | tolerance | 0.76276465978207919 | 0.7627646597820794 | 2.23E-16 | 15 | passed |
/fits/[curve=s]/adjusted_r_squared | tolerance | 0.73904112576028713 | 0.7390411257602874 | 2.24E-16 | 15 | passed |
/fits/[curve=s]/standard_error | tolerance | 0.40660627227677282 | 0.40660627227677254 | 2.80E-16 | 15 | passed |
/fits/[curve=s]/f_value | tolerance | 32.152235795957516 | 32.15223579595755 | 3.55E-14 | 14 | passed |
/fits/[curve=s]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=s]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=s]/p_value | tail_probability | 0.00020658570749108835 | 0.00020658570749108762 | 7.29E-19 | 14 | passed |
/fits/[curve=s]/coefficients/0/estimate | tolerance | 3.5930546057584491 | 3.5930546057584496 | 4.93E-16 | 15 | passed |
/fits/[curve=s]/coefficients/0/standard_error | tolerance | 0.16815977898960921 | 0.16815977898960913 | 8.34E-17 | 15 | passed |
/fits/[curve=s]/coefficients/0/t_value | tolerance | 21.366908468525452 | 21.366908468525462 | 1.04E-14 | 15 | passed |
/fits/[curve=s]/coefficients/0/p_value | tail_probability | 1.1234381231613971e-09 | 1.1234381231613934e-09 | 3.68E-24 | 14 | passed |
/fits/[curve=s]/coefficients/0/lower | tolerance | 3.2882715439191785 | 3.2882715439191794 | 9.18E-16 | 15 | passed |
/fits/[curve=s]/coefficients/0/upper | tolerance | 3.8978376675977193 | 3.8978376675977198 | 4.69E-16 | 15 | passed |
/fits/[curve=s]/coefficients/0/parameter | tolerance | 3.5930546057584491 | 3.5930546057584496 | 4.93E-16 | 15 | passed |
/fits/[curve=s]/coefficients/0/parameter_lower | tolerance | 3.2882715439191785 | 3.2882715439191794 | 9.18E-16 | 15 | passed |
/fits/[curve=s]/coefficients/0/parameter_upper | tolerance | 3.8978376675977193 | 3.8978376675977198 | 4.69E-16 | 15 | passed |
/fits/[curve=s]/coefficients/1/estimate | tolerance | -2.6403676954260353 | -2.640367695426036 | 9.21E-16 | 15 | passed |
/fits/[curve=s]/coefficients/1/standard_error | tolerance | 0.46564915744932694 | 0.46564915744932667 | 2.73E-16 | 15 | passed |
/fits/[curve=s]/coefficients/1/t_value | tolerance | -5.6702941542707856 | -5.670294154270791 | 5.38E-15 | 15 | passed |
/fits/[curve=s]/coefficients/1/p_value | tail_probability | 0.00020658570749109017 | 0.0002065857074910888 | 1.38E-18 | 14 | passed |
/fits/[curve=s]/coefficients/1/lower | tolerance | -3.4843386901729536 | -3.4843386901729536 | 1.20E-17 | 17 | passed |
/fits/[curve=s]/coefficients/1/upper | tolerance | -1.7963967006791175 | -1.7963967006791188 | 1.33E-15 | 15 | passed |
/fits/[curve=s]/coefficients/1/parameter | tolerance | -2.6403676954260353 | -2.640367695426036 | 9.21E-16 | 15 | passed |
/fits/[curve=s]/coefficients/1/parameter_lower | tolerance | -3.4843386901729536 | -3.4843386901729536 | 1.20E-17 | 17 | passed |
/fits/[curve=s]/coefficients/1/parameter_upper | tolerance | -1.7963967006791175 | -1.7963967006791188 | 1.33E-15 | 15 | passed |
/fits/[curve=growth]/r_squared | tolerance | 0.95627921898053225 | 0.9562792189805321 | 1.08E-16 | 15 | passed |
/fits/[curve=growth]/adjusted_r_squared | tolerance | 0.95190714087858552 | 0.9519071408785853 | 2.19E-16 | 15 | passed |
/fits/[curve=growth]/standard_error | tolerance | 0.17455340982399503 | 0.17455340982399528 | 2.51E-16 | 14 | passed |
/fits/[curve=growth]/f_value | tolerance | 218.72418485724816 | 218.7241848572475 | 6.52E-13 | 14 | passed |
/fits/[curve=growth]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=growth]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=growth]/p_value | tail_probability | 4.00503223571717e-08 | 4.005032235717225e-08 | 5.49E-22 | 13 | passed |
/fits/[curve=growth]/coefficients/0/estimate | tolerance | 1.5070450855553674 | 1.5070450855553663 | 1.09E-15 | 15 | passed |
/fits/[curve=growth]/coefficients/0/standard_error | tolerance | 0.10743019735381026 | 0.10743019735381047 | 2.12E-16 | 14 | passed |
/fits/[curve=growth]/coefficients/0/t_value | tolerance | 14.028132896303541 | 14.028132896303504 | 3.73E-14 | 14 | passed |
/fits/[curve=growth]/coefficients/0/p_value | tail_probability | 6.6436794777500471e-08 | 6.643679477750222e-08 | 1.75E-21 | 13 | passed |
/fits/[curve=growth]/coefficients/0/lower | tolerance | 1.3123320294356005 | 1.3123320294355991 | 1.38E-15 | 14 | passed |
/fits/[curve=growth]/coefficients/0/upper | tolerance | 1.7017581416751344 | 1.7017581416751335 | 8.93E-16 | 15 | passed |
/fits/[curve=growth]/coefficients/0/parameter | tolerance | 1.5070450855553674 | 1.5070450855553663 | 1.09E-15 | 15 | passed |
/fits/[curve=growth]/coefficients/0/parameter_lower | tolerance | 1.3123320294356005 | 1.3123320294355991 | 1.38E-15 | 14 | passed |
/fits/[curve=growth]/coefficients/0/parameter_upper | tolerance | 1.7017581416751344 | 1.7017581416751335 | 8.93E-16 | 15 | passed |
/fits/[curve=growth]/coefficients/1/estimate | tolerance | 0.21587816686651781 | 0.2158781668665179 | 8.54E-17 | 15 | passed |
/fits/[curve=growth]/coefficients/1/standard_error | tolerance | 0.014596889428480907 | 0.014596889428480931 | 2.43E-17 | 14 | passed |
/fits/[curve=growth]/coefficients/1/t_value | tolerance | 14.789326720890573 | 14.789326720890555 | 1.78E-14 | 14 | passed |
/fits/[curve=growth]/coefficients/1/p_value | tail_probability | 4.0050322357171839e-08 | 4.005032235717234e-08 | 5.02E-22 | 13 | passed |
/fits/[curve=growth]/coefficients/1/lower | tolerance | 0.18942187226341542 | 0.18942187226341548 | 5.50E-17 | 15 | passed |
/fits/[curve=growth]/coefficients/1/upper | tolerance | 0.2423344614696202 | 0.24233446146962032 | 1.16E-16 | 15 | passed |
/fits/[curve=growth]/coefficients/1/parameter | tolerance | 0.21587816686651781 | 0.2158781668665179 | 8.54E-17 | 15 | passed |
/fits/[curve=growth]/coefficients/1/parameter_lower | tolerance | 0.18942187226341542 | 0.18942187226341548 | 5.50E-17 | 15 | passed |
/fits/[curve=growth]/coefficients/1/parameter_upper | tolerance | 0.2423344614696202 | 0.24233446146962032 | 1.16E-16 | 15 | passed |
/fits/[curve=exponential]/r_squared | tolerance | 0.95627921898053225 | 0.9562792189805321 | 1.08E-16 | 15 | passed |
/fits/[curve=exponential]/adjusted_r_squared | tolerance | 0.95190714087858552 | 0.9519071408785853 | 2.19E-16 | 15 | passed |
/fits/[curve=exponential]/standard_error | tolerance | 0.17455340982399503 | 0.17455340982399528 | 2.51E-16 | 14 | passed |
/fits/[curve=exponential]/f_value | tolerance | 218.72418485724816 | 218.7241848572475 | 6.52E-13 | 14 | passed |
/fits/[curve=exponential]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=exponential]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=exponential]/p_value | tail_probability | 4.00503223571717e-08 | 4.005032235717225e-08 | 5.49E-22 | 13 | passed |
/fits/[curve=exponential]/coefficients/0/estimate | tolerance | 1.5070450855553674 | 1.5070450855553663 | 1.09E-15 | 15 | passed |
/fits/[curve=exponential]/coefficients/0/standard_error | tolerance | 0.10743019735381026 | 0.10743019735381047 | 2.12E-16 | 14 | passed |
/fits/[curve=exponential]/coefficients/0/t_value | tolerance | 14.028132896303541 | 14.028132896303504 | 3.73E-14 | 14 | passed |
/fits/[curve=exponential]/coefficients/0/p_value | tail_probability | 6.6436794777500471e-08 | 6.643679477750222e-08 | 1.75E-21 | 13 | passed |
/fits/[curve=exponential]/coefficients/0/lower | tolerance | 1.3123320294356005 | 1.3123320294355991 | 1.38E-15 | 14 | passed |
/fits/[curve=exponential]/coefficients/0/upper | tolerance | 1.7017581416751344 | 1.7017581416751335 | 8.93E-16 | 15 | passed |
/fits/[curve=exponential]/coefficients/0/parameter | tolerance | 4.5133744352707437 | 4.513374435270738 | 5.36E-15 | 14 | passed |
/fits/[curve=exponential]/coefficients/0/parameter_lower | tolerance | 3.7148267039947878 | 3.714826703994783 | 4.93E-15 | 14 | passed |
/fits/[curve=exponential]/coefficients/0/parameter_upper | tolerance | 5.4835798318801157 | 5.483579831880111 | 4.48E-15 | 15 | passed |
/fits/[curve=exponential]/coefficients/1/estimate | tolerance | 0.21587816686651781 | 0.2158781668665179 | 8.54E-17 | 15 | passed |
/fits/[curve=exponential]/coefficients/1/standard_error | tolerance | 0.014596889428480907 | 0.014596889428480931 | 2.43E-17 | 14 | passed |
/fits/[curve=exponential]/coefficients/1/t_value | tolerance | 14.789326720890573 | 14.789326720890555 | 1.78E-14 | 14 | passed |
/fits/[curve=exponential]/coefficients/1/p_value | tail_probability | 4.0050322357171839e-08 | 4.005032235717234e-08 | 5.02E-22 | 13 | passed |
/fits/[curve=exponential]/coefficients/1/lower | tolerance | 0.18942187226341542 | 0.18942187226341548 | 5.50E-17 | 15 | passed |
/fits/[curve=exponential]/coefficients/1/upper | tolerance | 0.2423344614696202 | 0.24233446146962032 | 1.16E-16 | 15 | passed |
/fits/[curve=exponential]/coefficients/1/parameter | tolerance | 0.21587816686651781 | 0.2158781668665179 | 8.54E-17 | 15 | passed |
/fits/[curve=exponential]/coefficients/1/parameter_lower | tolerance | 0.18942187226341542 | 0.18942187226341548 | 5.50E-17 | 15 | passed |
/fits/[curve=exponential]/coefficients/1/parameter_upper | tolerance | 0.2423344614696202 | 0.24233446146962032 | 1.16E-16 | 15 | passed |
Convention
- Curves fitted to ln Y: power (on ln t), compound, growth and exponential (on t), S (on 1 / t); confint(level = 0.90).
- lm() of the curve's fitted-scale response on its design columns with an intercept; R-squared, F, residual SE, coefficient SE, t, p and confint are on that fitted scale.
- Curve parameters: b0 = exp(coefficient) for power, compound, exponential and logistic; b1 = exp(coefficient) for compound and logistic; a parameter interval is the exp of the fitted interval (bounds sorted).
- docs/manual/chapters/86-regression-and-count-models.tex:31-37: 'offers named linearized curves. Linear, quadratic and cubic models fit the original response; power, exponential and growth forms fit a logarithmic response. The logistic growth curve requires a declared upper bound.'
- docs/manual/chapters/86-regression-and-count-models.tex:65-67: 'The reported R^2, tests and intervals use the named fitting scale'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
123 curves <- c("power", "compound", "s", "growth", "exponential")
124 outputs <- do.call(c, lapply(curves, function(curve) curve_outputs(curve, d$t, d$y, level = 0.90)))
125 emit("STAT-REG-CURVE-ESTIMATION-002", "Curve estimation log-scale curves 90 percent", "axis_coverage",
126 list(response = "y", predictor = "t", curves = as.list(curves), confidence_level = 0.90),
127 outputs, "Curves fitted to ln Y: power (on ln t), compound, growth and exponential (on t), S (on 1 / t); confint(level = 0.90).")
Curve estimation logistic with upper bound
Case STAT-REG-CURVE-ESTIMATION-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.lm, pf, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_curve_estimation.R · sha256 f830ec43141611cc
- Dataset
- reference_data/datasets/REG_CURVE.json
Settings compared
confidence_level= 0.95curves= ["logistic"]predictor= "t"response= "y"upper_bound= 50
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[curve=logistic]/r_squared | tolerance | 0.99255999696671382 | 0.9925599969667138 | 4.35E-20 | 19 | passed |
/fits/[curve=logistic]/adjusted_r_squared | tolerance | 0.99181599666338516 | 0.9918159966633852 | 2.36E-18 | 17 | passed |
/fits/[curve=logistic]/standard_error | tolerance | 0.1376645365017935 | 0.13766453650179344 | 5.59E-17 | 15 | passed |
/fits/[curve=logistic]/f_value | tolerance | 1334.085473522056 | 1334.0854735220576 | 1.55E-12 | 14 | passed |
/fits/[curve=logistic]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=logistic]/df2 | exact | 10 | 10 | 0.00E+2 | passed | |
/fits/[curve=logistic]/p_value | tail_probability | 5.6275172180001754e-12 | 5.627517218000141e-12 | 3.48E-26 | 14 | passed |
/fits/[curve=logistic]/coefficients/0/estimate | tolerance | -1.0278686058134641 | -1.0278686058134614 | 2.70E-15 | 14 | passed |
/fits/[curve=logistic]/coefficients/0/standard_error | tolerance | 0.084726665264922688 | 0.08472666526492269 | 4.30E-19 | 17 | passed |
/fits/[curve=logistic]/coefficients/0/t_value | tolerance | -12.131583399388285 | -12.131583399388253 | 3.19E-14 | 14 | passed |
/fits/[curve=logistic]/coefficients/0/p_value | tail_probability | 2.6364696590170015e-07 | 2.636469659017064e-07 | 6.24E-21 | 13 | passed |
/fits/[curve=logistic]/coefficients/0/lower | tolerance | -1.2166513804894743 | -1.2166513804894716 | 2.67E-15 | 14 | passed |
/fits/[curve=logistic]/coefficients/0/upper | tolerance | -0.83908583113745394 | -0.8390858311374512 | 2.77E-15 | 14 | passed |
/fits/[curve=logistic]/coefficients/0/parameter | tolerance | 0.35776869461885019 | 0.3577686946188512 | 1.00E-15 | 14 | passed |
/fits/[curve=logistic]/coefficients/0/parameter_lower | tolerance | 0.29622043751543725 | 0.2962204375154381 | 8.34E-16 | 14 | passed |
/fits/[curve=logistic]/coefficients/0/parameter_upper | tolerance | 0.43210536019347268 | 0.4321053601934739 | 1.22E-15 | 14 | passed |
/fits/[curve=logistic]/coefficients/1/estimate | tolerance | -0.42048052501100713 | -0.4204805250110074 | 2.81E-16 | 15 | passed |
/fits/[curve=logistic]/coefficients/1/standard_error | tolerance | 0.011512086871095433 | 0.011512086871095428 | 5.07E-18 | 15 | passed |
/fits/[curve=logistic]/coefficients/1/t_value | tolerance | -36.52513481867048 | -36.52513481867052 | 4.29E-14 | 14 | passed |
/fits/[curve=logistic]/coefficients/1/p_value | tail_probability | 5.6275172180001947e-12 | 5.627517218000137e-12 | 5.73E-26 | 13 | passed |
/fits/[curve=logistic]/coefficients/1/lower | tolerance | -0.44613105303593598 | -0.44613105303593625 | 2.74E-16 | 15 | passed |
/fits/[curve=logistic]/coefficients/1/upper | tolerance | -0.39482999698607829 | -0.39482999698607857 | 2.79E-16 | 15 | passed |
/fits/[curve=logistic]/coefficients/1/parameter | tolerance | 0.6567311682300474 | 0.6567311682300472 | 2.20E-16 | 15 | passed |
/fits/[curve=logistic]/coefficients/1/parameter_lower | tolerance | 0.64009987953206693 | 0.6400998795320667 | 2.23E-16 | 15 | passed |
/fits/[curve=logistic]/coefficients/1/parameter_upper | tolerance | 0.6737945766215323 | 0.6737945766215321 | 2.18E-16 | 15 | passed |
Convention
- Logistic: lm of ln(1 / Y - 1 / U) on t with U = 50; b0 and b1 are exp of the fitted coefficients.
- lm() of the curve's fitted-scale response on its design columns with an intercept; R-squared, F, residual SE, coefficient SE, t, p and confint are on that fitted scale.
- Curve parameters: b0 = exp(coefficient) for power, compound, exponential and logistic; b1 = exp(coefficient) for compound and logistic; a parameter interval is the exp of the fitted interval (bounds sorted).
- docs/manual/chapters/86-regression-and-count-models.tex:31-37: 'offers named linearized curves. Linear, quadratic and cubic models fit the original response; power, exponential and growth forms fit a logarithmic response. The logistic growth curve requires a declared upper bound.'
- docs/manual/chapters/86-regression-and-count-models.tex:65-67: 'The reported R^2, tests and intervals use the named fitting scale'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
130 outputs <- curve_outputs("logistic", d$t, d$y, upper = 50)
131 emit("STAT-REG-CURVE-ESTIMATION-003", "Curve estimation logistic with upper bound", "axis_coverage",
132 list(response = "y", predictor = "t", curves = list("logistic"), upper_bound = 50, confidence_level = 0.95),
133 outputs, "Logistic: lm of ln(1 / Y - 1 / U) on t with U = 50; b0 and b1 are exp of the fitted coefficients.")
Curve estimation sequence with input positions
Case STAT-REG-CURVE-ESTIMATION-004 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.lm, pf, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_curve_estimation.R · sha256 f830ec43141611cc
- Dataset
- reference_data/datasets/REG_CURVE.json
Settings compared
confidence_level= 0.95curves= ["linear", "quadratic"]predictor= ""response= "y_gap"sequence= "input_position"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[curve=linear]/r_squared | tolerance | 0.99177279057793233 | 0.9917727905779323 | 1.70E-18 | 17 | passed |
/fits/[curve=linear]/adjusted_r_squared | tolerance | 0.99085865619770264 | 0.9908586561977026 | 3.65E-18 | 17 | passed |
/fits/[curve=linear]/standard_error | tolerance | 1.4661560585798499 | 1.4661560585798505 | 6.41E-16 | 15 | passed |
/fits/[curve=linear]/f_value | tolerance | 1084.9310692468143 | 1084.9310692468132 | 1.11E-12 | 14 | passed |
/fits/[curve=linear]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=linear]/df2 | exact | 9 | 9 | 0.00E+2 | passed | |
/fits/[curve=linear]/p_value | tail_probability | 1.0786558825635552e-10 | 1.0786558825635579e-10 | 2.73E-25 | 14 | passed |
/fits/[curve=linear]/coefficients/0/estimate | tolerance | -2.6495541401273908 | -2.6495541401273988 | 7.96E-15 | 14 | passed |
/fits/[curve=linear]/coefficients/0/standard_error | tolerance | 0.91688434735956992 | 0.9168843473595705 | 5.53E-16 | 15 | passed |
/fits/[curve=linear]/coefficients/0/t_value | tolerance | -2.8897364730432336 | -2.8897364730432407 | 7.06E-15 | 14 | passed |
/fits/[curve=linear]/coefficients/0/p_value | tail_probability | 0.017891947873494931 | 0.017891947873494747 | 1.84E-16 | 13 | passed |
/fits/[curve=linear]/coefficients/0/lower | tolerance | -4.7236906339643996 | -4.7236906339644085 | 8.87E-15 | 14 | passed |
/fits/[curve=linear]/coefficients/0/upper | tolerance | -0.57541764629038195 | -0.575417646290389 | 7.10E-15 | 13 | passed |
/fits/[curve=linear]/coefficients/0/parameter | tolerance | -2.6495541401273908 | -2.6495541401273988 | 7.96E-15 | 14 | passed |
/fits/[curve=linear]/coefficients/0/parameter_lower | tolerance | -4.7236906339643996 | -4.7236906339644085 | 8.87E-15 | 14 | passed |
/fits/[curve=linear]/coefficients/0/parameter_upper | tolerance | -0.57541764629038195 | -0.575417646290389 | 7.10E-15 | 13 | passed |
/fits/[curve=linear]/coefficients/1/estimate | tolerance | 4.0422929936305732 | 4.042292993630575 | 1.73E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/standard_error | tolerance | 0.12272321264971227 | 0.12272321264971237 | 9.54E-17 | 15 | passed |
/fits/[curve=linear]/coefficients/1/t_value | tolerance | 32.938291838630825 | 32.93829183863082 | 7.33E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/p_value | tail_probability | 1.0786558825635552e-10 | 1.078655882563556e-10 | 7.94E-26 | 15 | passed |
/fits/[curve=linear]/coefficients/1/lower | tolerance | 3.7646737990934191 | 3.764673799093421 | 1.83E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/upper | tolerance | 4.3199121881677272 | 4.319912188167729 | 1.73E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter | tolerance | 4.0422929936305732 | 4.042292993630575 | 1.73E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter_lower | tolerance | 3.7646737990934191 | 3.764673799093421 | 1.83E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter_upper | tolerance | 4.3199121881677272 | 4.319912188167729 | 1.73E-15 | 15 | passed |
/fits/[curve=quadratic]/r_squared | tolerance | 0.996339598601233 | 0.996339598601233 | 7.85E-19 | 18 | passed |
/fits/[curve=quadratic]/adjusted_r_squared | tolerance | 0.99542449825154122 | 0.9954244982515412 | 3.23E-18 | 17 | passed |
/fits/[curve=quadratic]/standard_error | tolerance | 1.0372765044580008 | 1.037276504458003 | 2.21E-15 | 14 | passed |
/fits/[curve=quadratic]/f_value | tolerance | 1088.7763281227624 | 1088.7763281227578 | 4.57E-12 | 14 | passed |
/fits/[curve=quadratic]/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/fits/[curve=quadratic]/df2 | exact | 8 | 8 | 0.00E+2 | passed | |
/fits/[curve=quadratic]/p_value | tail_probability | 1.7952083125882702e-10 | 1.7952083125882969e-10 | 2.67E-24 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/estimate | tolerance | 0.10828934506353202 | 0.10828934506352343 | 8.59E-15 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/standard_error | tolerance | 1.0875663542051688 | 1.0875663542051737 | 4.87E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/t_value | tolerance | 0.099570333933945238 | 0.0995703339339369 | 8.34E-15 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/p_value | tail_probability | 0.92313535749408626 | 0.9231353574940927 | 6.44E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/lower | tolerance | -2.3996431650425061 | -2.399643165042525 | 1.91E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/upper | tolerance | 2.6162218551695702 | 2.6162218551695724 | 2.20E-15 | 15 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter | tolerance | 0.10828934506353202 | 0.10828934506352343 | 8.59E-15 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter_lower | tolerance | -2.3996431650425061 | -2.399643165042525 | 1.91E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter_upper | tolerance | 2.6162218551695702 | 2.6162218551695724 | 2.20E-15 | 15 | passed |
/fits/[curve=quadratic]/coefficients/1/estimate | tolerance | 2.8094460378331356 | 2.809446037833139 | 3.58E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/standard_error | tolerance | 0.39977362920799997 | 0.3997736292080014 | 1.44E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/t_value | tolerance | 7.0275921986124716 | 7.027592198612456 | 1.59E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/p_value | tail_probability | 0.0001095832183170204 | 0.0001095832183170222 | 1.80E-18 | 13 | passed |
/fits/[curve=quadratic]/coefficients/1/lower | tolerance | 1.8875663957339106 | 1.887566395733911 | 4.51E-16 | 15 | passed |
/fits/[curve=quadratic]/coefficients/1/upper | tolerance | 3.7313256799323606 | 3.7313256799323673 | 6.70E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter | tolerance | 2.8094460378331356 | 2.809446037833139 | 3.58E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter_lower | tolerance | 1.8875663957339106 | 1.887566395733911 | 4.51E-16 | 15 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter_upper | tolerance | 3.7313256799323606 | 3.7313256799323673 | 6.70E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/estimate | tolerance | 0.095160753225269304 | 0.09516075322526911 | 1.94E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/standard_error | tolerance | 0.03012110195245269 | 0.030121101952452784 | 9.41E-17 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/t_value | tolerance | 3.159271974029509 | 3.1592719740294926 | 1.64E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/p_value | tail_probability | 0.013409675309865268 | 0.013409675309865603 | 3.35E-16 | 13 | passed |
/fits/[curve=quadratic]/coefficients/2/lower | tolerance | 0.025701367566007119 | 0.025701367566006716 | 4.03E-16 | 13 | passed |
/fits/[curve=quadratic]/coefficients/2/upper | tolerance | 0.16462013888453148 | 0.1646201388845315 | 2.28E-17 | 15 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter | tolerance | 0.095160753225269304 | 0.09516075322526911 | 1.94E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter_lower | tolerance | 0.025701367566007119 | 0.025701367566006716 | 4.03E-16 | 13 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter_upper | tolerance | 0.16462013888453148 | 0.1646201388845315 | 2.28E-17 | 15 | passed |
/n | exact | 11 | 11 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Blank predictor with input positions: t is the row's position 1..N in the table, so the missing row leaves the gap t = 6 (the t column of REG_CURVE equals the positions).
- lm() of the curve's fitted-scale response on its design columns with an intercept; R-squared, F, residual SE, coefficient SE, t, p and confint are on that fitted scale.
- Curve parameters: b0 = exp(coefficient) for power, compound, exponential and logistic; b1 = exp(coefficient) for compound and logistic; a parameter interval is the exp of the fitted interval (bounds sorted).
- docs/manual/chapters/86-regression-and-count-models.tex:31-37: 'offers named linearized curves. Linear, quadratic and cubic models fit the original response; power, exponential and growth forms fit a logarithmic response. The logistic growth curve requires a declared upper bound.'
- docs/manual/chapters/86-regression-and-count-models.tex:65-67: 'The reported R^2, tests and intervals use the named fitting scale'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
137 keep <- is.finite(d$y_gap)
138 outputs <- curve_outputs("linear", d$t[keep], d$y_gap[keep])
139 outputs <- c(outputs, curve_outputs("quadratic", d$t[keep], d$y_gap[keep]))
140 outputs[["/n"]] <- exact(sum(keep), "complete rows")
141 outputs[["/missing_count"]] <- exact(sum(!keep), "rows with a missing response")
142 emit("STAT-REG-CURVE-ESTIMATION-004", "Curve estimation sequence with input positions", "missing_excluded",
143 list(response = "y_gap", predictor = "", sequence = "input_position", curves = list("linear", "quadratic"), confidence_level = 0.95),
144 outputs, "Blank predictor with input positions: t is the row's position 1..N in the table, so the missing row leaves the gap t = 6 (the t column of REG_CURVE equals the positions).")
Curve estimation sequence with retained order
Case STAT-REG-CURVE-ESTIMATION-005 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.lm, pf, pt.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_curve_estimation.R · sha256 f830ec43141611cc
- Dataset
- reference_data/datasets/REG_CURVE.json
Settings compared
confidence_level= 0.95curves= ["linear", "quadratic"]predictor= ""response= "y_gap"sequence= "retained_order"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[curve=linear]/r_squared | tolerance | 0.9831842105059686 | 0.9831842105059687 | 1.14E-16 | 15 | passed |
/fits/[curve=linear]/adjusted_r_squared | tolerance | 0.98131578945107623 | 0.9813157894510763 | 1.07E-16 | 15 | passed |
/fits/[curve=linear]/standard_error | tolerance | 2.0961026846618149 | 2.0961026846618136 | 1.30E-15 | 15 | passed |
/fits/[curve=linear]/f_value | tolerance | 526.21126695802673 | 526.2112669580273 | 5.65E-13 | 14 | passed |
/fits/[curve=linear]/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/fits/[curve=linear]/df2 | exact | 9 | 9 | 0.00E+2 | passed | |
/fits/[curve=linear]/p_value | tail_probability | 2.7009505595846655e-09 | 2.7009505595846506e-09 | 1.49E-23 | 14 | passed |
/fits/[curve=linear]/coefficients/0/estimate | tolerance | -3.6981818181818049 | -3.698181818181822 | 1.69E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/standard_error | tolerance | 1.355486284340043 | 1.3554862843400426 | 4.09E-16 | 15 | passed |
/fits/[curve=linear]/coefficients/0/t_value | tolerance | -2.728306336188691 | -2.7283063361887043 | 1.33E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/p_value | tail_probability | 0.023289007792781868 | 0.02328900779278139 | 4.78E-16 | 13 | passed |
/fits/[curve=linear]/coefficients/0/lower | tolerance | -6.764504825376358 | -6.764504825376374 | 1.60E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/upper | tolerance | -0.63185881098725183 | -0.63185881098727 | 1.82E-14 | 13 | passed |
/fits/[curve=linear]/coefficients/0/parameter | tolerance | -3.6981818181818049 | -3.698181818181822 | 1.69E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/parameter_lower | tolerance | -6.764504825376358 | -6.764504825376374 | 1.60E-14 | 14 | passed |
/fits/[curve=linear]/coefficients/0/parameter_upper | tolerance | -0.63185881098725183 | -0.63185881098727 | 1.82E-14 | 13 | passed |
/fits/[curve=linear]/coefficients/1/estimate | tolerance | 4.5845454545454531 | 4.584545454545456 | 2.71E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/standard_error | tolerance | 0.19985554930422908 | 0.19985554930422902 | 5.57E-17 | 15 | passed |
/fits/[curve=linear]/coefficients/1/t_value | tolerance | 22.939295258530212 | 22.939295258530233 | 2.12E-14 | 15 | passed |
/fits/[curve=linear]/coefficients/1/p_value | tail_probability | 2.7009505595846655e-09 | 2.7009505595846386e-09 | 2.69E-23 | 14 | passed |
/fits/[curve=linear]/coefficients/1/lower | tolerance | 4.1324407921619217 | 4.132440792161924 | 2.69E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/upper | tolerance | 5.0366501169289846 | 5.036650116928987 | 2.63E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter | tolerance | 4.5845454545454531 | 4.584545454545456 | 2.71E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter_lower | tolerance | 4.1324407921619217 | 4.132440792161924 | 2.69E-15 | 15 | passed |
/fits/[curve=linear]/coefficients/1/parameter_upper | tolerance | 5.0366501169289846 | 5.036650116928987 | 2.63E-15 | 15 | passed |
/fits/[curve=quadratic]/r_squared | tolerance | 0.98602444446255166 | 0.9860244444625517 | 3.55E-18 | 17 | passed |
/fits/[curve=quadratic]/adjusted_r_squared | tolerance | 0.98253055557818958 | 0.9825305555781896 | 5.65E-19 | 18 | passed |
/fits/[curve=quadratic]/standard_error | tolerance | 2.0268178694669823 | 2.0268178694669823 | 1.96E-17 | 17 | passed |
/fits/[curve=quadratic]/f_value | tolerance | 282.21402485802861 | 282.21402485802867 | 5.52E-14 | 15 | passed |
/fits/[curve=quadratic]/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/fits/[curve=quadratic]/df2 | exact | 8 | 8 | 0.00E+2 | passed | |
/fits/[curve=quadratic]/p_value | tail_probability | 3.8148399458772192e-08 | 3.8148399458772205e-08 | 1.30E-23 | 15 | passed |
/fits/[curve=quadratic]/coefficients/0/estimate | tolerance | -1.404242424242413 | -1.4042424242424298 | 1.68E-14 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/standard_error | tolerance | 2.2258674094331443 | 2.225867409433149 | 4.90E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/t_value | tolerance | -0.63087424627868005 | -0.6308742462786862 | 6.11E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/p_value | tail_probability | 0.54571971381554851 | 0.5457197138155447 | 3.77E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/lower | tolerance | -6.5371018748114285 | -6.537101874811456 | 2.75E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/upper | tolerance | 3.728617026326603 | 3.7286170263265968 | 6.25E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter | tolerance | -1.404242424242413 | -1.4042424242424298 | 1.68E-14 | 13 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter_lower | tolerance | -6.5371018748114285 | -6.537101874811456 | 2.75E-14 | 14 | passed |
/fits/[curve=quadratic]/coefficients/0/parameter_upper | tolerance | 3.728617026326603 | 3.7286170263265968 | 6.25E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/estimate | tolerance | 3.5258041958041941 | 3.525804195804199 | 4.91E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/standard_error | tolerance | 0.85252469194011049 | 0.8525246919401114 | 8.89E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/t_value | tolerance | 4.1357209112388738 | 4.1357209112388755 | 1.73E-15 | 15 | passed |
/fits/[curve=quadratic]/coefficients/1/p_value | tail_probability | 0.0032725887306278433 | 0.0032725887306278333 | 1.00E-17 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/lower | tolerance | 1.5598787308266417 | 1.5598787308266446 | 2.93E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/upper | tolerance | 5.491729660781747 | 5.491729660781753 | 6.18E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter | tolerance | 3.5258041958041941 | 3.525804195804199 | 4.91E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter_lower | tolerance | 1.5598787308266417 | 1.5598787308266446 | 2.93E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/1/parameter_upper | tolerance | 5.491729660781747 | 5.491729660781753 | 6.18E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/estimate | tolerance | 0.088228438228438288 | 0.08822843822843802 | 2.63E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/standard_error | tolerance | 0.069194421167714446 | 0.0691944211677145 | 5.50E-17 | 15 | passed |
/fits/[curve=quadratic]/coefficients/2/t_value | tolerance | 1.2750802266932606 | 1.2750802266932557 | 4.89E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/p_value | tail_probability | 0.23806243824761555 | 0.23806243824761722 | 1.67E-15 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/lower | tolerance | -0.071334183117369915 | -0.07133418311737029 | 3.74E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/upper | tolerance | 0.24779105957424649 | 0.24779105957424635 | 1.37E-16 | 15 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter | tolerance | 0.088228438228438288 | 0.08822843822843802 | 2.63E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter_lower | tolerance | -0.071334183117369915 | -0.07133418311737029 | 3.74E-16 | 14 | passed |
/fits/[curve=quadratic]/coefficients/2/parameter_upper | tolerance | 0.24779105957424649 | 0.24779105957424635 | 1.37E-16 | 15 | passed |
/n | exact | 11 | 11 | 0.00E+2 | passed |
Convention
- Blank predictor with retained order: the 11 complete rows are renumbered t = 1..11 in table order.
- lm() of the curve's fitted-scale response on its design columns with an intercept; R-squared, F, residual SE, coefficient SE, t, p and confint are on that fitted scale.
- Curve parameters: b0 = exp(coefficient) for power, compound, exponential and logistic; b1 = exp(coefficient) for compound and logistic; a parameter interval is the exp of the fitted interval (bounds sorted).
- docs/manual/chapters/86-regression-and-count-models.tex:31-37: 'offers named linearized curves. Linear, quadratic and cubic models fit the original response; power, exponential and growth forms fit a logarithmic response. The logistic growth curve requires a declared upper bound.'
- docs/manual/chapters/86-regression-and-count-models.tex:65-67: 'The reported R^2, tests and intervals use the named fitting scale'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
146 outputs <- curve_outputs("linear", as.double(seq_len(sum(keep))), d$y_gap[keep])
147 outputs <- c(outputs, curve_outputs("quadratic", as.double(seq_len(sum(keep))), d$y_gap[keep]))
148 outputs[["/n"]] <- exact(sum(keep), "complete rows")
149 emit("STAT-REG-CURVE-ESTIMATION-005", "Curve estimation sequence with retained order", "axis_coverage",
150 list(response = "y_gap", predictor = "", sequence = "retained_order", curves = list("linear", "quadratic"), confidence_level = 0.95),
151 outputs, "Blank predictor with retained order: the 11 complete rows are renumbered t = 1..11 in table order.")
Small-sample boundary STAT-REG-DA-MIN-001
Case STAT-REG-DA-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/MASS/pls/stats
- Citation
- R nlme::lme, MASS::lda, pls::plsr and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_b.R · sha256 e3e09e1965800ae1
- Dataset
- reference_data/datasets/REG_MIN_DA.json
Settings compared
model= "lda"predictors= ["x"]prior_mode= "equal"response= "class"seed= 0standardize= falsetest_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 6 | 6 | 0.00E+2 | passed | |
/class_order/0 | exact | A | A | passed |
Convention
- Three rows per class allow one stratified holdout and two training values per class.
- R lda fits the full CSV; split-dependent fitted moments are deferred.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
67 da <- read_dataset("REG_DISCRIMINANT")[c(1L,5L,9L,13L,17L,21L),]
68 export_dataset(da,"REG_MIN_DA","Two classes with three distinct predictor values each",
69 "R MASS lda small stratified-split boundary",
70 "Constructed validation data; no third-party license.",
71 c(x="Float64",class="String"))
72 da <- read_dataset("REG_MIN_DA")
73 fit <- MASS::lda(class~x,data=da,prior=c(0.5,0.5))
74 emit("STAT-REG-DA-MIN-001",
75 "tabelz.analysis.discriminant_analysis:compute_discriminant_analysis",
76 "discriminantAnalysisMenuItem","REG_MIN_DA",
77 list(response="class",predictors=list("x"),model="lda",standardize=FALSE,
78 prior_mode="equal",test_fraction=0.25,seed=0L),
79 list("/source_count"=exact(nrow(da),"six usable rows"),
80 "/class_order/0"=list(comparison="exact",value="A",rationale="R factor class order")),
81 c("Three rows per class allow one stratified holdout and two training values per class.",
82 "R lda fits the full CSV; split-dependent fitted moments are deferred."),
83 deferred=list(list(path="/artifact/class_means",
84 reason="The training split uses a NumPy stratified permutation not replayable in R.")))
Regression edge STAT-REG-DA-ONECLASS-001
Case STAT-REG-DA-ONECLASS-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic design condition
- Citation
- Tabelz manual regression model design conditions; R stats/plm references
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_b.R · sha256 4a5d01b584989ad6
- Dataset
- reference_data/datasets/REG_EDGE_DA_ONECLASS.json
Settings compared
model= "lda"predictors= ["x"]prior_mode= "equal"response= "class"seed= 0standardize= falsetest_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- LDA requires at least two observed classes; no stratified split exists for one class.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
63 da <- read_dataset("REG_MIN_DA")
64 da$class <- rep("A",nrow(da))
65 export_dataset(da,"REG_EDGE_DA_ONECLASS","One-class discriminant response",
66 "Analytic two-class stratified-discriminant requirement",
67 "Constructed validation data; no third-party license.",
68 c(x="Float64",class="String"))
69 emit("STAT-REG-DA-ONECLASS-001","STAT-REG-DISCRIMINANT-LDA-001",
70 "REG_EDGE_DA_ONECLASS",
71 list(response="class",predictors=list("x"),model="lda",standardize=FALSE,
72 prior_mode="equal",test_fraction=0.25,seed=0L),
73 error=err("ValueError","at least two classes"),
74 note="LDA requires at least two observed classes; no stratified split exists for one class.")
Retained scoring boundary STAT-REG-DA-SCORE-MIDPOINT-001
Case STAT-REG-DA-SCORE-MIDPOINT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls and analytic retained tree
- Citation
- R MASS::lda, pls::plsr and rpart::rpart documentation; Tabelz retained-artifact contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_boundaries.R · sha256 9a546ee72b8c92a9
- Dataset
- reference_data/datasets/REG_SCORE_BOUND_DA.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "lda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/probabilities/0 | tolerance | 0.5 | 0.5 | 0.00E+1 | passed |
Convention
- The stored class means are -2 and 2 with equal priors; x=0 has equal posterior mass.
- The missing row is not imputed under drop mode.
- R re-reads the exported CSV.
Reference code
Whole script generators/r/regression_advanced_score_boundaries.R
Corrected retained scoring boundary STAT-REG-DA-SCORE-MIDPOINT-CORRECTED-001
Case STAT-REG-DA-SCORE-MIDPOINT-CORRECTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls or strict scoring contract
- Citation
- R MASS::lda, pls::plsr and Tabelz manual retained-scoring semantics
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_corrections.R · sha256 8c11616dfc0c8448
- Dataset
- reference_data/datasets/REG_SCORE_MID_DA.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "lda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/probabilities/0 | tolerance | 0.5 | 0.5 | 0.00E+1 | passed |
Convention
- A one-row, fully observed scoring table lets the midpoint posterior be evaluated.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
38 empty <- structure(list(),names=character())
39 lda <- MASS::lda(class~x,data=read_dataset("REG_DISCRIMINANT"),prior=c(0.5,0.5))
40 posterior <- stats::predict(lda,newdata=da)$posterior[1L,1L]
41 emit("STAT-REG-DA-SCORE-MIDPOINT-CORRECTED-001",
42 "STAT-REG-DISCRIMINANT-SCORE-LDA-001","REG_SCORE_MID_DA",
43 list("/0/probabilities/0"=tol(posterior,"R MASS LDA equal-prior midpoint posterior")),
44 NULL,"A one-row, fully observed scoring table lets the midpoint posterior be evaluated.")Whole script generators/r/regression_advanced_score_corrections.R
Retained scoring boundary STAT-REG-DA-SCORE-MISSING-001
Case STAT-REG-DA-SCORE-MISSING-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls and analytic retained tree
- Citation
- R MASS::lda, pls::plsr and rpart::rpart documentation; Tabelz retained-artifact contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_boundaries.R · sha256 9a546ee72b8c92a9
- Dataset
- reference_data/datasets/REG_SCORE_BOUND_DA.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "lda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/1/predicted | absent | None | passed |
Convention
- The stored class means are -2 and 2 with equal priors; x=0 has equal posterior mass.
- The missing row is not imputed under drop mode.
- R re-reads the exported CSV.
Reference code
Whole script generators/r/regression_advanced_score_boundaries.R
Regression II STAT-REG-DISCRIMINANT-LDA-001
Case STAT-REG-DISCRIMINANT-LDA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
model= "lda"predictors= ["x"]prior_mode= "equal"response= "class"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/class_order/0 | exact | A | A | passed | ||
/class_order/1 | exact | B | B | passed | ||
/artifact/priors/0 | tolerance | 0.5 | 0.5 | 0.00E+1 | passed |
Convention
- MASS lda/qda on full CSV; random split precludes exact fitted moments.
- R reference re-reads exported CSV.
Reference code
Regression II STAT-REG-DISCRIMINANT-QDA-001
Case STAT-REG-DISCRIMINANT-QDA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
model= "qda"predictors= ["x"]prior_mode= "equal"response= "class"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/class_order/0 | exact | A | A | passed | ||
/class_order/1 | exact | B | B | passed | ||
/artifact/priors/0 | tolerance | 0.5 | 0.5 | 0.00E+1 | passed |
Convention
- MASS lda/qda on full CSV; random split precludes exact fitted moments.
- R reference re-reads exported CSV.
Reference code
Regression II STAT-REG-DISCRIMINANT-SCORE-LDA-001
Case STAT-REG-DISCRIMINANT-SCORE-LDA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "lda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/predicted | exact | A | A | passed | ||
/12/predicted | exact | B | B | passed | ||
/0/row_id | exact | STAT-REG-DISCRIMINANT-SCORE-LDA-001:0 | STAT-REG-DISCRIMINANT-SCORE-LDA-001:0 | passed |
Convention
- Artifact moments computed from full CSV; MASS discriminant predictions are the oracle.
- R reference re-reads exported CSV.
Reference code
Regression II STAT-REG-DISCRIMINANT-SCORE-QDA-001
Case STAT-REG-DISCRIMINANT-SCORE-QDA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "qda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]], "class_covariances": [[[0.727272727272727]], [[0.727272727272727]]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/predicted | exact | A | A | passed | ||
/12/predicted | exact | B | B | passed | ||
/0/row_id | exact | STAT-REG-DISCRIMINANT-SCORE-QDA-001:0 | STAT-REG-DISCRIMINANT-SCORE-QDA-001:0 | passed |
Convention
- Artifact moments computed from full CSV; MASS discriminant predictions are the oracle.
- R reference re-reads exported CSV.
Reference code
STAT REG EFFECTS 001
Case STAT-REG-EFFECTS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/residual_variance | tolerance | 0.23796443428945249 | 0.2379644342894525 | 2.21E-18 | 17 | passed |
/residual_df | exact | 68 | 68 | 0.00E+2 | passed |
Convention
- Treatment contrasts use alphabetically first factor level A as reference; Type II tests.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
143 effects_entry <- "tabelz.executor.linear_effects"
144 effects_fit <- stats::lm(y ~ x + group, data = d)
145 emit("STAT-REG-EFFECTS-001", effects_entry, "linearEffectsMenuItem", "nominal",
146 list(response_column = "y", factor_columns = list("group"), covariate_columns = list("x")),
147 list("/residual_variance" = tol(summary(effects_fit)$sigma^2, "linear-effects residual variance", "1e-9"),
148 "/residual_df" = exact(stats::df.residual(effects_fit), "full model residual df")),
149 list("Treatment contrasts use alphabetically first factor level A as reference; Type II tests."))
Regression forest study design on independent rows
Case STAT-REG-FOREST-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- documented study design counts (manual chapter 76) evaluated by hand
- Citation
- Breiman (2001) Random forests, Machine Learning 45, 5-32; Tabelz manual chapter 76 (study design: 20% test reservation rounded up, 5-fold CV, 12-candidate grid, 500 trees, 10 permutations).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_forest.R · sha256 94a0ffe8dda384b9
- Dataset
- reference_data/datasets/REG_FOREST.json
Settings compared
categorical_predictors= ["tool"]dependence= "independent"numeric_predictors= ["load", "speed"]response= "wear"seed= 7
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/response | exact | wear | wear | passed | ||
/numeric_predictors | sequence | ['load', 'speed'] | ['load', 'speed'] | passed | ||
/categorical_predictors | sequence | ['tool'] | ['tool'] | passed | ||
/seed | exact | 7 | 7 | 0.00E+2 | passed | |
/encoded_feature_count | exact | 5 | 5 | 0.00E+2 | passed | |
/trees | exact | 500 | 500 | 0.00E+2 | passed | |
/source_count | exact | 32 | 32 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/missing_response_count | exact | 2 | 2 | 0.00E+2 | passed | |
/split/test_fraction | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/split/seed | exact | 7 | 7 | 0.00E+2 | passed | |
/test_metrics/row_count | exact | 6 | 6 | 0.00E+2 | passed | |
/baseline_test_metrics/row_count | exact | 6 | 6 | 0.00E+2 | passed | |
/importance/0/predictor | exact | load | load | passed | ||
/importance/1/predictor | exact | speed | speed | passed | ||
/importance/2/predictor | exact | tool | tool | passed | ||
/importance/0/permutations | exact | 10 | 10 | 0.00E+2 | passed | |
/artifact/fit | exact | training | training | passed | ||
/artifact/fit_row_count | exact | 24 | 24 | 0.00E+2 | passed | |
/deployment_artifact/fit | exact | deployment | deployment | passed | ||
/deployment_artifact/fit_row_count | exact | 30 | 30 | 0.00E+2 | passed | |
/candidates/0/settings/min_samples_leaf | exact | 1 | 1 | 0.00E+2 | passed | |
/candidates/0/settings/max_features | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/0/settings/max_depth | exact | 10 | 10 | 0.00E+2 | passed | |
/candidates/1/settings/min_samples_leaf | exact | 1 | 1 | 0.00E+2 | passed | |
/candidates/1/settings/max_features | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/1/settings/max_depth | absent | None | passed | |||
/candidates/2/settings/min_samples_leaf | exact | 1 | 1 | 0.00E+2 | passed | |
/candidates/2/settings/max_features | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/2/settings/max_depth | exact | 10 | 10 | 0.00E+2 | passed | |
/candidates/3/settings/min_samples_leaf | exact | 1 | 1 | 0.00E+2 | passed | |
/candidates/3/settings/max_features | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/3/settings/max_depth | absent | None | passed | |||
/candidates/4/settings/min_samples_leaf | exact | 3 | 3 | 0.00E+2 | passed | |
/candidates/4/settings/max_features | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/4/settings/max_depth | exact | 10 | 10 | 0.00E+2 | passed | |
/candidates/5/settings/min_samples_leaf | exact | 3 | 3 | 0.00E+2 | passed | |
/candidates/5/settings/max_features | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/5/settings/max_depth | absent | None | passed | |||
/candidates/6/settings/min_samples_leaf | exact | 3 | 3 | 0.00E+2 | passed | |
/candidates/6/settings/max_features | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/6/settings/max_depth | exact | 10 | 10 | 0.00E+2 | passed | |
/candidates/7/settings/min_samples_leaf | exact | 3 | 3 | 0.00E+2 | passed | |
/candidates/7/settings/max_features | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/7/settings/max_depth | absent | None | passed | |||
/candidates/8/settings/min_samples_leaf | exact | 5 | 5 | 0.00E+2 | passed | |
/candidates/8/settings/max_features | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/8/settings/max_depth | exact | 10 | 10 | 0.00E+2 | passed | |
/candidates/9/settings/min_samples_leaf | exact | 5 | 5 | 0.00E+2 | passed | |
/candidates/9/settings/max_features | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/9/settings/max_depth | absent | None | passed | |||
/candidates/10/settings/min_samples_leaf | exact | 5 | 5 | 0.00E+2 | passed | |
/candidates/10/settings/max_features | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/10/settings/max_depth | exact | 10 | 10 | 0.00E+2 | passed | |
/candidates/11/settings/min_samples_leaf | exact | 5 | 5 | 0.00E+2 | passed | |
/candidates/11/settings/max_features | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/11/settings/max_depth | absent | None | passed |
Convention
- Deterministic study-design quantities only: 32 rows, 30 with a response, ceil(0.2 x 30) = 6 held out and 24 training rows; the 12-candidate grid is enumerated in the product's order (leaf size slowest, then feature fraction, then depth); 500 trees; 10 permutations.
- Every fitted or resampled quantity is deferred with its reason: the forest's bootstrap and feature sampling and the numpy-seeded split have no independent R reproduction.
- Expected computed from the exported CSV.
- docs/manual/chapters/76-forest-penalty-quantiles.tex:13-20: one numeric response, numeric and/or categorical predictors, independent observations declared; missing responses are omitted and counted; at least 25 usable responses.
- docs/manual/chapters/76-forest-penalty-quantiles.tex:22-27: the forest averages 500 regression trees on bootstrap samples with a random feature subset at each split.
- docs/manual/chapters/76-forest-penalty-quantiles.tex:30-37: a seeded split reserves 20% of the usable rows, rounded up; five-fold cross-validation selects among 12 combinations of leaf sizes 1, 3, 5, feature fractions 0.5 and 1, and depth 10 or unlimited.
- docs/manual/chapters/76-forest-penalty-quantiles.tex:54-59: permutation importance over ten permutations per predictor.
Reference code
The lines of the reference script that produce this case's expected values.
24 emit <- function(id, title, kind, configuration, outputs, deferred, notes, error = NULL) {
25 expected <- list(schema_version = "2.0.0", case_id = id, outputs = outputs,
26 expected_error = error, deferred_outputs = deferred, generator_run = run)
27 write_expected("regression", id, expected)
28 case <- list(
29 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
30 entry_point = "tabelz.analysis.regression_forest:compute_regression_forest",
31 menu_items = list("regressionForestMenuItem"), title = title, case_kind = kind,
32 dataset = list(path = "reference_data/datasets/REG_FOREST.json", sha256 = ""),
33 excluded_rows = list(), configuration = configuration, "repeat" = 1L,
34 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"),
35 sha256 = ""),
36 oracle = list(oracle_class = "analytic",
37 source = "documented study design counts (manual chapter 76) evaluated by hand",
38 citation = "Breiman (2001) Random forests, Machine Learning 45, 5-32; Tabelz manual chapter 76 (study design: 20% test reservation rounded up, 5-fold CV, 12-candidate grid, 500 trees, 10 permutations).",
39 generator = list(path = "generators/r/regression_forest.R", sha256 = ""),
40 independent = TRUE,
41 convention_notes = c(notes, "Expected computed from the exported CSV.", manual)),
42 supported = TRUE, unsupported_reason = NULL,
43 requirement_ids = list("REQ-STAT-REG-FOREST-001"), risk_ids = list("RISK-REFERENCE-001"),
44 review_reference = NULL
45 )
46 write_case("regression", id, case)
Regression forest refuses dependent rows
Case STAT-REG-FOREST-DEPENDENT-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- documented study design counts (manual chapter 76) evaluated by hand
- Citation
- Breiman (2001) Random forests, Machine Learning 45, 5-32; Tabelz manual chapter 76 (study design: 20% test reservation rounded up, 5-fold CV, 12-candidate grid, 500 trees, 10 permutations).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_forest.R · sha256 94a0ffe8dda384b9
- Dataset
- reference_data/datasets/REG_FOREST.json
Settings compared
categorical_predictors= ["tool"]dependence= "clustered"numeric_predictors= ["load", "speed"]response= "wear"seed= 7
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The manual requires independent observations for the random split; declaring clustered rows is refused before any fitting.
- Expected computed from the exported CSV.
- docs/manual/chapters/76-forest-penalty-quantiles.tex:13-20: one numeric response, numeric and/or categorical predictors, independent observations declared; missing responses are omitted and counted; at least 25 usable responses.
- docs/manual/chapters/76-forest-penalty-quantiles.tex:22-27: the forest averages 500 regression trees on bootstrap samples with a random feature subset at each split.
- docs/manual/chapters/76-forest-penalty-quantiles.tex:30-37: a seeded split reserves 20% of the usable rows, rounded up; five-fold cross-validation selects among 12 combinations of leaf sizes 1, 3, 5, feature fractions 0.5 and 1, and depth 10 or unlimited.
- docs/manual/chapters/76-forest-penalty-quantiles.tex:54-59: permutation importance over ten permutations per predictor.
Reference code
The lines of the reference script that produce this case's expected values.
126 emit("STAT-REG-FOREST-DEPENDENT-001", "Regression forest refuses dependent rows", "invalid_input",
127 list(response = "wear", numeric_predictors = list("load", "speed"),
128 categorical_predictors = list("tool"), dependence = "clustered", seed = 7L),
129 setNames(list(), character(0)), list(),
130 list("The manual requires independent observations for the random split; declaring clustered rows is refused before any fitting."),
131 error = list(error_class = "ValueError", message_contains = "needs independent observations"))
Binomial GEE with an exchangeable working correlation
Case STAT-REG-GEE-001 · status: passed
Reference
- Evidence type
- R
- Source
- Base-R GEE with explicit dense block matrices
- Citation
- Liang and Zeger (1986); Mancl and DeRouen (2001); formulas as stated in manual chapter 67
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1
- Reference script
- generators/r/regression_gee.R · sha256 1f1de72c0127d183
- Dataset
- reference_data/datasets/REG_GEE_CLUSTERED.json
Settings compared
cluster_column= "cluster"family= "binomial"predictors= ["x", "group"]response_column= "event"working_correlation= "exchangeable"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/[term=Intercept]/estimate | tolerance | 0.069014835520755644 | 0.06901483552075578 | 1.38E-16 | 14 | passed |
/coefficients/[term=Intercept]/std_error | tolerance | 0.33311548372552302 | 0.333115483725523 | 5.53E-19 | 17 | passed |
/coefficients/[term=Intercept]/p_value | tolerance | 0.83786516270031464 | 0.8378651627003142 | 4.48E-16 | 15 | passed |
/coefficients/[term=Intercept]/lower | tolerance | -0.6237367363280002 | -0.6237367363279999 | 3.37E-16 | 15 | passed |
/coefficients/[term=Intercept]/upper | tolerance | 0.7617664073695114 | 0.7617664073695115 | 1.11E-16 | 15 | passed |
/coefficients/[term=x]/estimate | tolerance | 0.89364225100873396 | 0.893642251008734 | 3.43E-18 | 17 | passed |
/coefficients/[term=x]/std_error | tolerance | 0.32806904210726462 | 0.32806904210726456 | 5.65E-17 | 15 | passed |
/coefficients/[term=x]/p_value | tolerance | 0.012715560163912726 | 0.012715560163912704 | 2.24E-17 | 14 | passed |
/coefficients/[term=x]/lower | tolerance | 0.21138532901591822 | 0.21138532901591855 | 3.35E-16 | 14 | passed |
/coefficients/[term=x]/upper | tolerance | 1.5758991730015497 | 1.5758991730015492 | 4.53E-16 | 15 | passed |
/coefficients/[term=group = b (vs a)]/estimate | tolerance | 0.89714777637345289 | 0.8971477763734528 | 1.13E-16 | 15 | passed |
/coefficients/[term=group = b (vs a)]/std_error | tolerance | 0.54514044971697795 | 0.5451404497169778 | 1.13E-16 | 15 | passed |
/coefficients/[term=group = b (vs a)]/p_value | tolerance | 0.11470757612997834 | 0.11470757612997823 | 1.12E-16 | 15 | passed |
/coefficients/[term=group = b (vs a)]/lower | tolerance | -0.23653385017904804 | -0.2365338501790477 | 3.29E-16 | 14 | passed |
/coefficients/[term=group = b (vs a)]/upper | tolerance | 2.0308294029259537 | 2.0308294029259533 | 4.36E-16 | 15 | passed |
/degrees_of_freedom | exact | 21 | 21 | 0.00E+2 | passed | |
/rho | tolerance | 0.12395787894620826 | 0.12395787894620829 | 2.58E-17 | 15 | passed |
Convention
- Converged in 11 iterations; rho = 0.1239578789.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
186 b <- gee(d$event, rep(1, nrow(d)), rep(0, nrow(d)), "binomial", "exchangeable")
187 emit("STAT-REG-GEE-001", "Binomial GEE with an exchangeable working correlation",
188 list(family = "binomial", working = "exchangeable"), b,
189 c(sprintf("Converged in %d iterations; rho = %.10g.", b$iterations, b$rho)))
Poisson GEE with exposure and independence working correlation
Case STAT-REG-GEE-002 · status: passed
Reference
- Evidence type
- R
- Source
- Base-R GEE with explicit dense block matrices
- Citation
- Liang and Zeger (1986); Mancl and DeRouen (2001); formulas as stated in manual chapter 67
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1
- Reference script
- generators/r/regression_gee.R · sha256 1f1de72c0127d183
- Dataset
- reference_data/datasets/REG_GEE_CLUSTERED.json
Settings compared
cluster_column= "cluster"exposure_column= "exposure"family= "poisson"predictors= ["x", "group"]response_column= "count"working_correlation= "independence"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/[term=Intercept]/estimate | tolerance | 0.2520004539756161 | 0.2520004539756161 | 1.05E-18 | 17 | passed |
/coefficients/[term=Intercept]/std_error | tolerance | 0.16538082054466599 | 0.1653808205446659 | 8.26E-17 | 15 | passed |
/coefficients/[term=Intercept]/p_value | tolerance | 0.14248756290093545 | 0.14248756290093526 | 1.95E-16 | 14 | passed |
/coefficients/[term=Intercept]/lower | tolerance | -0.091927790081495209 | -0.09192779008149499 | 2.22E-16 | 14 | passed |
/coefficients/[term=Intercept]/upper | tolerance | 0.59592869803272741 | 0.5959286980327272 | 2.21E-16 | 15 | passed |
/coefficients/[term=x]/estimate | tolerance | 0.55019807798470111 | 0.5501980779847011 | 3.95E-18 | 17 | passed |
/coefficients/[term=x]/std_error | tolerance | 0.090211233114104381 | 0.09021123311410438 | 4.96E-19 | 17 | passed |
/coefficients/[term=x]/p_value | tolerance | 4.7263012267512877e-06 | 4.726301226751279e-06 | 8.48E-21 | 14 | passed |
/coefficients/[term=x]/lower | tolerance | 0.36259354865065352 | 0.3625935486506535 | 1.19E-18 | 17 | passed |
/coefficients/[term=x]/upper | tolerance | 0.73780260731874869 | 0.7378026073187487 | 3.29E-18 | 17 | passed |
/coefficients/[term=group = b (vs a)]/estimate | tolerance | -0.07736028762671876 | -0.07736028762671882 | 5.55E-17 | 15 | passed |
/coefficients/[term=group = b (vs a)]/std_error | tolerance | 0.17149230438180599 | 0.17149230438180607 | 8.11E-17 | 15 | passed |
/coefficients/[term=group = b (vs a)]/p_value | tolerance | 0.65654066004890332 | 0.656540660048903 | 3.29E-16 | 15 | passed |
/coefficients/[term=group = b (vs a)]/lower | tolerance | -0.43399805808337588 | -0.433998058083376 | 1.13E-16 | 15 | passed |
/coefficients/[term=group = b (vs a)]/upper | tolerance | 0.27927748282993836 | 0.27927748282993836 | 1.60E-18 | 17 | passed |
/degrees_of_freedom | exact | 21 | 21 | 0.00E+2 | passed |
Convention
- Independence coefficients equal the Poisson GLM; the covariance is the bias-reduced sandwich.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
190 pz <- gee(d$count, rep(1, nrow(d)), log(d$exposure), "poisson", "independence")
191 emit("STAT-REG-GEE-002", "Poisson GEE with exposure and independence working correlation",
192 list(family = "poisson", working = "independence"), pz,
193 c("Independence coefficients equal the Poisson GLM; the covariance is the bias-reduced sandwich."),
194 kind = "axis_coverage")
STAT REG GENERAL 001
Case STAT-REG-GENERAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"test_type= "III"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/residual_variance | tolerance | 0.23796443428945255 | 0.23796443428945255 | 2.28E-18 | 17 | passed |
/residual_df | exact | 68 | 68 | 0.00E+2 | passed |
Convention
- Sum-to-zero factor contrasts and Type III partial tests per manual; residual variance is SSE/df.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
133 glm_entry <- "tabelz.executor.general_linear"
134 glm_fit <- stats::lm(y ~ x + group, data = d,
135 contrasts = list(group = stats::contr.sum(3)))
136 emit("STAT-REG-GENERAL-001", glm_entry, "generalLinearMenuItem", "nominal",
137 list(response_column = "y", factor_columns = list("group"), covariate_columns = list("x"),
138 test_type = "III"),
139 list("/residual_variance" = tol(summary(glm_fit)$sigma^2, "GLM residual variance", "1e-9"),
140 "/residual_df" = exact(stats::df.residual(glm_fit), "full model residual df")),
141 list("Sum-to-zero factor contrasts and Type III partial tests per manual; residual variance is SSE/df."))
STAT REG GENERALIZED LINEAR 001
Case STAT-REG-GENERALIZED-LINEAR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm with contr.sum, MASS::glm.nb/theta.ml, MASS::gamma.dispersion, sandwich::vcovHC(type = 'HC0'); Wald/F/LR tests and marginal means from the fitted coefficients
- Citation
- R Core Team, stats package help: glm, summary.glm, logLik.glm; Venables & Ripley (2002) MASS: glm.nb, theta.ml, gamma.dispersion; Zeileis (2006) sandwich.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_glm_general.R · sha256 c450a6f63ea68bc5
- Dataset
- reference_data/datasets/REG_GLM_01.json
Settings compared
comparisons= "holm"confidence_level= 0.95covariance= "model"covariates= ["x"]factors= ["g"]family= "gaussian"link= "canonical"lr_tests= falseresponse= "ypos"scale= "default"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 40 | 40 | 0.00E+2 | passed | |
/statistic_kind | exact | t | t | passed | ||
/type3_kind | exact | F | F | passed | ||
/fit/df_residual | exact | 36 | 36 | 0.00E+2 | passed | |
/fit/df_null | exact | 39 | 39 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 21.1771485597706 | 21.1771485597706 | 4.00E-16 | 16 | passed |
/fit/null_deviance | tolerance | 36.387416975000001 | 36.387416975 | 2.82E-16 | 17 | passed |
/fit/pearson_chi_square | tolerance | 21.1771485597706 | 21.1771485597706 | 4.00E-16 | 16 | passed |
/coefficients/0/term | exact | Intercept | Intercept | passed | ||
/coefficients/0/estimate | tolerance | 1.6351141827656557 | 1.635114182765656 | 1.99E-16 | 15 | passed |
/coefficients/0/standard_error | tolerance | 0.12390807705411178 | 0.12390807705411178 | 4.03E-18 | 16 | passed |
/coefficients/0/statistic | tolerance | 13.196187219107488 | 13.19618721910749 | 1.60E-15 | 15 | passed |
/coefficients/0/p_value | tail_probability | 2.3310797888188366e-15 | 2.3310797888188244e-15 | 1.22E-29 | 14 | passed |
/coefficients/0/lower | tolerance | 1.3838169550191881 | 1.3838169550191886 | 4.55E-16 | 15 | passed |
/coefficients/0/upper | tolerance | 1.8864114105121232 | 1.8864114105121232 | 4.34E-17 | 16 | passed |
/coefficients/1/term | exact | g[sum:A] | g[sum:A] | passed | ||
/coefficients/1/estimate | tolerance | -0.44071147143947842 | -0.4407114714394785 | 5.49E-17 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.17244461590865889 | 0.17244461590865887 | 2.41E-17 | 15 | passed |
/coefficients/1/statistic | tolerance | -2.5556696514834427 | -2.5556696514834436 | 9.05E-16 | 15 | passed |
/coefficients/1/p_value | tail_probability | 0.014965927591400046 | 0.014965927591400013 | 3.33E-17 | 14 | passed |
/coefficients/1/lower | tolerance | -0.79044536246520747 | -0.7904453624652075 | 1.64E-18 | 17 | passed |
/coefficients/1/upper | tolerance | -0.090977580413749315 | -0.09097758041374954 | 2.22E-16 | 14 | passed |
/coefficients/2/term | exact | g[sum:B] | g[sum:B] | passed | ||
/coefficients/2/estimate | tolerance | -0.27039053616443137 | -0.2703905361644309 | 4.98E-16 | 14 | passed |
/coefficients/2/standard_error | tolerance | 0.17267410461499239 | 0.17267410461499236 | 3.25E-17 | 15 | passed |
/coefficients/2/statistic | tolerance | -1.565900901975517 | -1.5659009019755143 | 2.65E-15 | 14 | passed |
/coefficients/2/p_value | tail_probability | 0.12612090208729099 | 0.12612090208729154 | 5.52E-16 | 14 | passed |
/coefficients/2/lower | tolerance | -0.62058985185876825 | -0.6205898518587676 | 6.67E-16 | 14 | passed |
/coefficients/2/upper | tolerance | 0.079808779529905449 | 0.07980877952990578 | 3.33E-16 | 14 | passed |
/coefficients/3/term | exact | x | x | passed | ||
/coefficients/3/estimate | tolerance | 0.41351273210315481 | 0.41351273210315487 | 5.75E-17 | 15 | passed |
/coefficients/3/standard_error | tolerance | 0.11245887384599647 | 0.11245887384599645 | 1.57E-17 | 15 | passed |
/coefficients/3/statistic | tolerance | 3.6770129200246822 | 3.677012920024683 | 8.51E-16 | 15 | passed |
/coefficients/3/p_value | tail_probability | 0.00076466266730168563 | 0.0007646626673016827 | 2.92E-18 | 14 | passed |
/coefficients/3/lower | tolerance | 0.18543556469907208 | 0.18543556469907221 | 1.34E-16 | 15 | passed |
/coefficients/3/upper | tolerance | 0.64158989950723755 | 0.6415898995072375 | 1.20E-18 | 17 | passed |
/type3/0/term | exact | g | g | passed | ||
/type3/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/type3/0/statistic | tolerance | 8.4200316694682993 | 8.420031669468296 | 3.57E-15 | 15 | passed |
/type3/0/denominator_df | exact | 36 | 36 | 0.00E+2 | passed | |
/type3/0/p_value | tail_probability | 0.0010002419902322369 | 0.0010002419902322398 | 2.86E-18 | 14 | passed |
/type3/1/term | exact | x | x | passed | ||
/type3/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/type3/1/statistic | tolerance | 13.520424014028437 | 13.520424014028446 | 9.18E-15 | 15 | passed |
/type3/1/denominator_df | exact | 36 | 36 | 0.00E+2 | passed | |
/type3/1/p_value | tail_probability | 0.00076466266730168563 | 0.0007646626673016827 | 2.92E-18 | 14 | passed |
/fit/scale | tolerance | 0.58825412666029442 | 0.5882541266602944 | 1.45E-18 | 17 | passed |
/fit/ml_scale | tolerance | 0.52942871399426505 | 0.529428713994265 | 4.41E-18 | 17 | passed |
/fit/log_likelihood | tolerance | -44.0384062899874 | -44.0384062899874 | 4.11E-16 | 17 | passed |
/fit/aic | tolerance | 98.076812579974799 | 98.0768125799748 | 1.78E-16 | 17 | passed |
/fit/bic | tolerance | 106.52120985054448 | 106.52120985054448 | 8.81E-18 | 19 | passed |
/fit/parameters_counted | exact | 5 | 5 | 0.00E+2 | passed | |
/means/0/level | exact | A | A | passed | ||
/means/0/link_mean | tolerance | 1.289531315346508 | 1.2895313153465082 | 2.22E-16 | 15 | passed |
/means/0/link_se | tolerance | 0.20730467230762176 | 0.20730467230762176 | 3.21E-18 | 16 | passed |
/means/0/link_lower | tolerance | 0.86909795306420223 | 0.8690979530642025 | 2.25E-16 | 15 | passed |
/means/0/link_upper | tolerance | 1.7099646776288138 | 1.709964677628814 | 1.89E-16 | 15 | passed |
/means/0/mean | tolerance | 1.289531315346508 | 1.2895313153465082 | 2.22E-16 | 15 | passed |
/means/0/mean_se | tolerance | 0.20730467230762176 | 0.20730467230762176 | 3.21E-18 | 16 | passed |
/means/1/level | exact | B | B | passed | ||
/means/1/link_mean | tolerance | 1.459852250621555 | 1.4598522506215559 | 8.80E-16 | 15 | passed |
/means/1/link_se | tolerance | 0.21275383936190587 | 0.21275383936190587 | 3.47E-18 | 16 | passed |
/means/1/link_lower | tolerance | 1.0283674653261152 | 1.0283674653261161 | 9.15E-16 | 15 | passed |
/means/1/link_upper | tolerance | 1.8913370359169948 | 1.8913370359169956 | 8.46E-16 | 15 | passed |
/means/1/mean | tolerance | 1.459852250621555 | 1.4598522506215559 | 8.80E-16 | 15 | passed |
/means/1/mean_se | tolerance | 0.21275383936190587 | 0.21275383936190587 | 3.47E-18 | 16 | passed |
/means/2/level | exact | C | C | passed | ||
/means/2/link_mean | tolerance | 2.441344794389896 | 2.4413447943898965 | 4.89E-16 | 15 | passed |
/means/2/link_se | tolerance | 0.21476950947023266 | 0.21476950947023263 | 3.21E-17 | 15 | passed |
/means/2/link_lower | tolerance | 2.005772040639803 | 2.005772040639804 | 8.55E-16 | 15 | passed |
/means/2/link_upper | tolerance | 2.8769175481399891 | 2.876917548139989 | 2.25E-17 | 17 | passed |
/means/2/mean | tolerance | 2.441344794389896 | 2.4413447943898965 | 4.89E-16 | 15 | passed |
/means/2/mean_se | tolerance | 0.21476950947023266 | 0.21476950947023263 | 3.21E-17 | 15 | passed |
/comparisons/0/first | exact | A | A | passed | ||
/comparisons/0/second | exact | B | B | passed | ||
/comparisons/0/difference | tolerance | -0.17032093527504705 | -0.1703209352750476 | 5.52E-16 | 14 | passed |
/comparisons/0/standard_error | tolerance | 0.29743894668818271 | 0.29743894668818266 | 5.06E-17 | 15 | passed |
/comparisons/0/statistic | tolerance | -0.57262486023258208 | -0.572624860232584 | 1.89E-15 | 14 | passed |
/comparisons/0/p_value | tail_probability | 0.57045803209601698 | 0.5704580320960155 | 1.45E-15 | 14 | passed |
/comparisons/0/holm_p_value | tail_probability | 0.57045803209601698 | 0.5704580320960155 | 1.45E-15 | 14 | passed |
/comparisons/0/lower | tolerance | -0.77355507871129459 | -0.7735550787112948 | 2.18E-16 | 15 | passed |
/comparisons/0/upper | tolerance | 0.43291320816120044 | 0.43291320816119966 | 7.81E-16 | 14 | passed |
/comparisons/1/first | exact | A | A | passed | ||
/comparisons/1/second | exact | C | C | passed | ||
/comparisons/1/difference | tolerance | -1.1518134790433883 | -1.1518134790433878 | 4.78E-16 | 15 | passed |
/comparisons/1/standard_error | tolerance | 0.30154942967136611 | 0.30154942967136605 | 5.62E-17 | 15 | passed |
/comparisons/1/statistic | tolerance | -3.8196506632383782 | -3.8196506632383773 | 8.81E-16 | 15 | passed |
/comparisons/1/p_value | tail_probability | 0.00050851866394768992 | 0.0005085186639476909 | 9.73E-19 | 14 | passed |
/comparisons/1/holm_p_value | tail_probability | 0.0015255559918430698 | 0.0015255559918430726 | 2.77E-18 | 14 | passed |
/comparisons/1/lower | tolerance | -1.7633840683589623 | -1.7633840683589614 | 8.57E-16 | 15 | passed |
/comparisons/1/upper | tolerance | -0.54024288972781431 | -0.5402428897278142 | 1.08E-16 | 15 | passed |
/comparisons/2/first | exact | B | B | passed | ||
/comparisons/2/second | exact | C | C | passed | ||
/comparisons/2/difference | tolerance | -0.98149254376834116 | -0.9814925437683402 | 9.96E-16 | 14 | passed |
/comparisons/2/standard_error | tolerance | 0.30194314213314977 | 0.3019431421331497 | 5.88E-17 | 15 | passed |
/comparisons/2/statistic | tolerance | -3.2505873020806222 | -3.2505873020806195 | 2.68E-15 | 15 | passed |
/comparisons/2/p_value | tail_probability | 0.0025009609469498094 | 0.0025009609469498293 | 1.99E-17 | 14 | passed |
/comparisons/2/holm_p_value | tail_probability | 0.0050019218938996187 | 0.005001921893899659 | 3.99E-17 | 14 | passed |
/comparisons/2/lower | tolerance | -1.5938616189657697 | -1.5938616189657684 | 1.31E-15 | 15 | passed |
/comparisons/2/upper | tolerance | -0.36912346857091261 | -0.36912346857091183 | 7.82E-16 | 14 | passed |
Convention
- stats::glm(ypos ~ g + x, gaussian) with contr.sum; dispersion deviance/df gives t and F inference.
- Factors are sum-to-zero coded on sorted levels (last level = -1), covariates enter as recorded; coefficient tests are t with Type III F when the dispersion is a moment estimate (normal: deviance/df; gamma: Pearson/df) and z with chi-square otherwise (docs/manual/chapters/86-regression-and-count-models.tex:107-170).
- Log-likelihood, AIC and BIC of true-likelihood families are evaluated at the maximum-likelihood dispersion and count the dispersion (and theta) as parameters.
- Marginal means average the linear predictor over the equal-weight factor grid at covariate means and the mean offset, then invert the link; pairwise differences are on the link scale with Holm-adjusted p-values and unadjusted intervals (manual lines 160-169).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
48 emit <- function(id, kind, config, outputs, notes) {
49 write_expected("regression", id, list(
50 schema_version = "2.0.0", case_id = id, outputs = outputs,
51 expected_error = NULL, deferred_outputs = list(), generator_run = run))
52 write_case("regression", id, list(
53 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
54 entry_point = "tabelz.analysis.generalized_linear_models:compute_generalized_linear",
55 menu_items = list("generalizedLinearMenuItem"), title = gsub("-", " ", id),
56 case_kind = kind,
57 dataset = list(path = "reference_data/datasets/REG_GLM_01.json", sha256 = ""),
58 excluded_rows = list(), configuration = config, "repeat" = 1L,
59 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
60 oracle = list(
61 oracle_class = "independent_implementation",
62 source = "R stats::glm with contr.sum, MASS::glm.nb/theta.ml, MASS::gamma.dispersion, sandwich::vcovHC(type = 'HC0'); Wald/F/LR tests and marginal means from the fitted coefficients",
63 citation = "R Core Team, stats package help: glm, summary.glm, logLik.glm; Venables & Ripley (2002) MASS: glm.nb, theta.ml, gamma.dispersion; Zeileis (2006) sandwich.",
64 generator = list(path = "generators/r/regression_glm_general.R", sha256 = ""),
65 independent = TRUE,
66 convention_notes = c(
67 notes,
68 "Factors are sum-to-zero coded on sorted levels (last level = -1), covariates enter as recorded; coefficient tests are t with Type III F when the dispersion is a moment estimate (normal: deviance/df; gamma: Pearson/df) and z with chi-square otherwise (docs/manual/chapters/86-regression-and-count-models.tex:107-170).",
69 "Log-likelihood, AIC and BIC of true-likelihood families are evaluated at the maximum-likelihood dispersion and count the dispersion (and theta) as parameters.",
70 "Marginal means average the linear predictor over the equal-weight factor grid at covariate means and the mean offset, then invert the link; pairwise differences are on the link scale with Holm-adjusted p-values and unadjusted intervals (manual lines 160-169).",
71 "Expected computed from the exported CSV."
72 )),
73 supported = TRUE, unsupported_reason = NULL,
74 requirement_ids = list("REQ-STAT-REG-GENERALIZED-LINEAR-001"),
75 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
STAT REG GENERALIZED LINEAR 002
Case STAT-REG-GENERALIZED-LINEAR-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm with contr.sum, MASS::glm.nb/theta.ml, MASS::gamma.dispersion, sandwich::vcovHC(type = 'HC0'); Wald/F/LR tests and marginal means from the fitted coefficients
- Citation
- R Core Team, stats package help: glm, summary.glm, logLik.glm; Venables & Ripley (2002) MASS: glm.nb, theta.ml, gamma.dispersion; Zeileis (2006) sandwich.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_glm_general.R · sha256 c450a6f63ea68bc5
- Dataset
- reference_data/datasets/REG_GLM_01.json
Settings compared
comparisons= "holm"confidence_level= 0.9covariance= "model"covariates= ["x"]factors= ["g"]family= "poisson"link= "canonical"lr_tests= trueoffset= "log_exposure"response= "count"scale= "default"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 40 | 40 | 0.00E+2 | passed | |
/statistic_kind | exact | z | z | passed | ||
/type3_kind | exact | chi-square | chi-square | passed | ||
/fit/df_residual | exact | 36 | 36 | 0.00E+2 | passed | |
/fit/df_null | exact | 39 | 39 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 33.8716791860802 | 33.87167918608019 | 6.65E-15 | 15 | passed |
/fit/null_deviance | tolerance | 68.558591590257478 | 68.55859159025746 | 1.39E-14 | 15 | passed |
/fit/pearson_chi_square | tolerance | 28.794159987256609 | 28.794159987256627 | 1.82E-14 | 15 | passed |
/coefficients/0/term | exact | Intercept | Intercept | passed | ||
/coefficients/0/estimate | tolerance | 0.38379305358373139 | 0.3837930535837305 | 8.87E-16 | 14 | passed |
/coefficients/0/standard_error | tolerance | 0.11331252073494606 | 0.11331252073494694 | 8.77E-16 | 14 | passed |
/coefficients/0/statistic | tolerance | 3.3870312926978068 | 3.3870312926977726 | 3.42E-14 | 13 | passed |
/coefficients/0/p_value | tail_probability | 0.00070653328507950858 | 0.0007065332850795955 | 8.69E-17 | 12 | passed |
/coefficients/0/lower | tolerance | 0.19741054287384155 | 0.19741054287383913 | 2.42E-15 | 13 | passed |
/coefficients/0/upper | tolerance | 0.57017556429362126 | 0.5701755642936219 | 6.68E-16 | 14 | passed |
/coefficients/0/exp_estimate | tolerance | 1.4678416456801033 | 1.467841645680102 | 1.30E-15 | 15 | passed |
/coefficients/0/exp_lower | tolerance | 1.2182440794806377 | 1.2182440794806348 | 2.86E-15 | 14 | passed |
/coefficients/0/exp_upper | tolerance | 1.7685775232426384 | 1.7685775232426395 | 1.10E-15 | 15 | passed |
/coefficients/1/term | exact | g[sum:A] | g[sum:A] | passed | ||
/coefficients/1/estimate | tolerance | -0.26775542055150375 | -0.2677554205515039 | 1.70E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.12828930370370203 | 0.1282893037037025 | 4.76E-16 | 14 | passed |
/coefficients/1/statistic | tolerance | -2.0871219409679993 | -2.087121940967993 | 6.22E-15 | 14 | passed |
/coefficients/1/p_value | tail_probability | 0.036877113200278359 | 0.03687711320027891 | 5.49E-16 | 13 | passed |
/coefficients/1/lower | tolerance | -0.4787725470476169 | -0.47877254704761796 | 1.06E-15 | 14 | passed |
/coefficients/1/upper | tolerance | -0.056738294055390603 | -0.05673829405538991 | 6.93E-16 | 13 | passed |
/coefficients/1/exp_estimate | tolerance | 0.76509488470603193 | 0.7650948847060318 | 1.11E-16 | 15 | passed |
/coefficients/1/exp_lower | tolerance | 0.61954338564021683 | 0.6195433856402162 | 6.70E-16 | 14 | passed |
/coefficients/1/exp_upper | tolerance | 0.94484130760016594 | 0.9448413076001666 | 6.62E-16 | 15 | passed |
/coefficients/2/term | exact | g[sum:B] | g[sum:B] | passed | ||
/coefficients/2/estimate | tolerance | 0.013331368835957206 | 0.013331368835957383 | 1.77E-16 | 13 | passed |
/coefficients/2/standard_error | tolerance | 0.13068311605926947 | 0.13068311605926972 | 2.46E-16 | 14 | passed |
/coefficients/2/statistic | tolerance | 0.10201293968159554 | 0.1020129396815967 | 1.17E-15 | 13 | passed |
/coefficients/2/p_value | tail_probability | 0.91874640428739329 | 0.9187464042873924 | 8.86E-16 | 15 | passed |
/coefficients/2/lower | tolerance | -0.20162322859545229 | -0.20162322859545256 | 2.74E-16 | 14 | passed |
/coefficients/2/upper | tolerance | 0.22828596626736669 | 0.22828596626736736 | 6.67E-16 | 14 | passed |
/coefficients/2/exp_estimate | tolerance | 1.0134206277402229 | 1.0134206277402231 | 2.23E-16 | 15 | passed |
/coefficients/2/exp_lower | tolerance | 0.81740284394921692 | 0.8174028439492167 | 2.25E-16 | 15 | passed |
/coefficients/2/exp_upper | tolerance | 1.2564445748285085 | 1.2564445748285091 | 6.31E-16 | 15 | passed |
/coefficients/3/term | exact | x | x | passed | ||
/coefficients/3/estimate | tolerance | 0.51054527711065867 | 0.5105452771106592 | 5.54E-16 | 14 | passed |
/coefficients/3/standard_error | tolerance | 0.093137069859869012 | 0.09313706985986958 | 5.69E-16 | 14 | passed |
/coefficients/3/statistic | tolerance | 5.4816549187000234 | 5.481654918699996 | 2.75E-14 | 14 | passed |
/coefficients/3/p_value | tail_probability | 4.213655165680836e-08 | 4.21365516568148e-08 | 6.44E-21 | 12 | passed |
/coefficients/3/lower | tolerance | 0.35734842994802052 | 0.3573484299480201 | 4.46E-16 | 14 | passed |
/coefficients/3/upper | tolerance | 0.66374212427329682 | 0.6637421242732984 | 1.55E-15 | 14 | passed |
/coefficients/3/exp_estimate | tolerance | 1.6661994877301993 | 1.6661994877302002 | 9.13E-16 | 15 | passed |
/coefficients/3/exp_lower | tolerance | 1.4295338755027325 | 1.4295338755027318 | 6.90E-16 | 15 | passed |
/coefficients/3/exp_upper | tolerance | 1.942046131600798 | 1.942046131600801 | 3.08E-15 | 14 | passed |
/type3/0/term | exact | g | g | passed | ||
/type3/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/type3/0/statistic | tolerance | 5.7837001276463997 | 5.783700127646363 | 3.64E-14 | 14 | passed |
/type3/0/p_value | tail_probability | 0.055473488123829184 | 0.05547348812383018 | 9.93E-16 | 13 | passed |
/type3/1/term | exact | x | x | passed | ||
/type3/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/type3/1/statistic | tolerance | 30.048540647708158 | 30.04854064770786 | 2.98E-13 | 14 | passed |
/type3/1/p_value | tail_probability | 4.21365516568084e-08 | 4.2136551656814885e-08 | 6.49E-21 | 12 | passed |
/fit/scale | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/fit/log_likelihood | tolerance | -69.225963817565287 | -69.22596381756529 | 2.82E-16 | 17 | passed |
/fit/aic | tolerance | 146.45192763513057 | 146.45192763513057 | 3.44E-15 | 16 | passed |
/fit/bic | tolerance | 153.20744545158632 | 153.20744545158632 | 3.77E-15 | 16 | passed |
/fit/parameters_counted | exact | 4 | 4 | 0.00E+2 | passed | |
/lr_tests/0/term | exact | g | g | passed | ||
/lr_tests/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/lr_tests/0/statistic | tolerance | 5.8010932859442619 | 5.801093285944262 | 2.08E-17 | 17 | passed |
/lr_tests/0/p_value | tail_probability | 0.054993150219340717 | 0.05499315021934072 | 2.11E-19 | 17 | passed |
/lr_tests/1/term | exact | x | x | passed | ||
/lr_tests/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/lr_tests/1/statistic | tolerance | 34.050101355978256 | 34.050101355978256 | 3.79E-16 | 16 | passed |
/lr_tests/1/p_value | tail_probability | 5.3711110602089626e-09 | 5.371111060208967e-09 | 4.15E-24 | 15 | passed |
/means/0/level | exact | A | A | passed | ||
/means/0/link_mean | tolerance | 0.6882162240315346 | 0.6882162240315337 | 8.92E-16 | 14 | passed |
/means/0/link_se | tolerance | 0.17159108561846267 | 0.1715910856184639 | 1.23E-15 | 14 | passed |
/means/0/link_lower | tolerance | 0.4059740044994658 | 0.40597400449946275 | 3.05E-15 | 14 | passed |
/means/0/link_upper | tolerance | 0.97045844356360345 | 0.9704584435636047 | 1.22E-15 | 14 | passed |
/means/0/mean | tolerance | 1.9901623613603754 | 1.9901623613603738 | 1.57E-15 | 15 | passed |
/means/0/mean_se | tolerance | 0.34149412014283004 | 0.3414941201428322 | 2.16E-15 | 14 | passed |
/means/1/level | exact | B | B | passed | ||
/means/1/link_mean | tolerance | 0.9693030134189955 | 0.969303013418995 | 4.48E-16 | 15 | passed |
/means/1/link_se | tolerance | 0.17099619883070447 | 0.17099619883070485 | 3.84E-16 | 14 | passed |
/means/1/link_lower | tolerance | 0.68803929557739629 | 0.6880392955773951 | 1.22E-15 | 14 | passed |
/means/1/link_upper | tolerance | 1.2505667312605948 | 1.250566731260595 | 2.33E-16 | 15 | passed |
/means/1/mean | tolerance | 2.6361064880596174 | 2.636106488059616 | 1.28E-15 | 15 | passed |
/means/1/mean_se | tolerance | 0.45076418917115241 | 0.4507641891711532 | 7.75E-16 | 14 | passed |
/means/2/level | exact | C | C | passed | ||
/means/2/link_mean | tolerance | 1.2103956962985849 | 1.2103956962985842 | 6.66E-16 | 15 | passed |
/means/2/link_se | tolerance | 0.14547540226198508 | 0.1454754022619854 | 3.29E-16 | 14 | passed |
/means/2/link_lower | tolerance | 0.97110995325573446 | 0.9711099532557331 | 1.33E-15 | 14 | passed |
/means/2/link_upper | tolerance | 1.4496814393414355 | 1.4496814393414352 | 2.70E-16 | 15 | passed |
/means/2/mean | tolerance | 3.3548118765849004 | 3.3548118765848978 | 2.63E-15 | 15 | passed |
/means/2/mean_se | tolerance | 0.4880426072594734 | 0.4880426072594741 | 7.26E-16 | 14 | passed |
/comparisons/0/first | exact | A | A | passed | ||
/comparisons/0/second | exact | B | B | passed | ||
/comparisons/0/difference | tolerance | -0.28108678938746096 | -0.2810867893874613 | 3.29E-16 | 14 | passed |
/comparisons/0/standard_error | tolerance | 0.22674737905101983 | 0.22674737905102046 | 6.35E-16 | 14 | passed |
/comparisons/0/statistic | tolerance | -1.2396473580592715 | -1.2396473580592695 | 1.99E-15 | 14 | passed |
/comparisons/0/p_value | tail_probability | 0.21510585595164325 | 0.2151058559516441 | 8.59E-16 | 14 | passed |
/comparisons/0/holm_p_value | tail_probability | 0.4302117119032865 | 0.4302117119032882 | 1.72E-15 | 14 | passed |
/comparisons/0/lower | tolerance | -0.65405303822127103 | -0.6540530382212726 | 1.56E-15 | 14 | passed |
/comparisons/0/upper | tolerance | 0.091879459446349121 | 0.09187945944635001 | 8.88E-16 | 14 | passed |
/comparisons/0/ratio | tolerance | 0.75496280987696063 | 0.7549628098769604 | 2.24E-16 | 15 | passed |
/comparisons/1/first | exact | A | A | passed | ||
/comparisons/1/second | exact | C | C | passed | ||
/comparisons/1/difference | tolerance | -0.5221794722670503 | -0.5221794722670504 | 1.15E-16 | 15 | passed |
/comparisons/1/standard_error | tolerance | 0.21715053609086932 | 0.21715053609087007 | 7.47E-16 | 14 | passed |
/comparisons/1/statistic | tolerance | -2.4046888470426704 | -2.4046888470426624 | 8.01E-15 | 14 | passed |
/comparisons/1/p_value | tail_probability | 0.016186240778369144 | 0.01618624077836949 | 3.47E-16 | 13 | passed |
/comparisons/1/holm_p_value | tail_probability | 0.048558722335107433 | 0.048558722335108474 | 1.04E-15 | 13 | passed |
/comparisons/1/lower | tolerance | -0.87936031915057311 | -0.8793603191505746 | 1.44E-15 | 14 | passed |
/comparisons/1/upper | tolerance | -0.1649986253835275 | -0.16499862538352622 | 1.28E-15 | 14 | passed |
/comparisons/1/ratio | tolerance | 0.59322621791428209 | 0.593226217914282 | 1.06E-16 | 15 | passed |
/comparisons/2/first | exact | B | B | passed | ||
/comparisons/2/second | exact | C | C | passed | ||
/comparisons/2/difference | tolerance | -0.24109268287958935 | -0.24109268287958915 | 1.96E-16 | 15 | passed |
/comparisons/2/standard_error | tolerance | 0.22139139427514187 | 0.2213913942751422 | 3.36E-16 | 14 | passed |
/comparisons/2/statistic | tolerance | -1.0889885023261701 | -1.0889885023261674 | 2.70E-15 | 14 | passed |
/comparisons/2/p_value | tail_probability | 0.27615895598028517 | 0.2761589559802864 | 1.22E-15 | 14 | passed |
/comparisons/2/holm_p_value | tail_probability | 0.4302117119032865 | 0.4302117119032882 | 1.72E-15 | 14 | passed |
/comparisons/2/lower | tolerance | -0.60524912072889969 | -0.6052491207289002 | 5.57E-16 | 15 | passed |
/comparisons/2/upper | tolerance | 0.123063754969721 | 0.12306375496972191 | 9.11E-16 | 14 | passed |
/comparisons/2/ratio | tolerance | 0.78576879569864178 | 0.785768795698642 | 2.17E-16 | 15 | passed |
Convention
- stats::glm(count ~ g + x + offset(log_exposure), poisson); LR tests refit without each term; marginal means use the mean offset.
- Factors are sum-to-zero coded on sorted levels (last level = -1), covariates enter as recorded; coefficient tests are t with Type III F when the dispersion is a moment estimate (normal: deviance/df; gamma: Pearson/df) and z with chi-square otherwise (docs/manual/chapters/86-regression-and-count-models.tex:107-170).
- Log-likelihood, AIC and BIC of true-likelihood families are evaluated at the maximum-likelihood dispersion and count the dispersion (and theta) as parameters.
- Marginal means average the linear predictor over the equal-weight factor grid at covariate means and the mean offset, then invert the link; pairwise differences are on the link scale with Holm-adjusted p-values and unadjusted intervals (manual lines 160-169).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
219 fit <- stats::glm(count ~ g + x + offset(log_exposure), family = stats::poisson(), data = d,
220 contrasts = sum_contrasts, control = control)
221 p <- length(stats::coef(fit))
222 V <- summary(fit)$cov.unscaled
223 ll <- as.numeric(stats::logLik(fit))
224 drop_g <- stats::glm(count ~ x + offset(log_exposure), family = stats::poisson(), data = d, control = control)
225 drop_x <- stats::glm(count ~ g + offset(log_exposure), family = stats::poisson(), data = d,
226 contrasts = sum_contrasts, control = control)
227 lr_g <- 2 * (ll - as.numeric(stats::logLik(drop_g)))
228 lr_x <- 2 * (ll - as.numeric(stats::logLik(drop_x)))
229 emit("STAT-REG-GENERALIZED-LINEAR-002", "axis_coverage",
230 list(response = "count", family = "poisson", factors = list("g"), covariates = list("x"),
231 offset = "log_exposure", link = "canonical", scale = "default", covariance = "model",
232 confidence_level = 0.90, comparisons = "holm", lr_tests = TRUE),
233 c(glm_outputs(fit, V, FALSE, 0.90, coef_terms, type3, exp_link = TRUE),
234 list("/fit/scale" = tol(1, "fixed dispersion", "1e-12"),
235 "/fit/log_likelihood" = tol(ll, "Poisson log-likelihood"),
236 "/fit/aic" = tol(-2 * ll + 2 * p, "AIC"),
237 "/fit/bic" = tol(-2 * ll + log(n) * p, "BIC"),
238 "/fit/parameters_counted" = exact(as.integer(p), "coefficients only"),
239 "/lr_tests/0/term" = exact("g", "LR test term"),
240 "/lr_tests/0/df" = exact(2L, "LR df"),
241 "/lr_tests/0/statistic" = tol(lr_g, "LR chi-square dropping g"),
242 "/lr_tests/0/p_value" = prob(stats::pchisq(lr_g, 2, lower.tail = FALSE), "LR tail"),
243 "/lr_tests/1/term" = exact("x", "LR test term"),
244 "/lr_tests/1/df" = exact(1L, "LR df"),
245 "/lr_tests/1/statistic" = tol(lr_x, "LR chi-square dropping x"),
246 "/lr_tests/1/p_value" = prob(stats::pchisq(lr_x, 1, lower.tail = FALSE), "LR tail")),
247 means_outputs(fit, V, FALSE, 0.90, exp, exp, base = mean(d$log_exposure), ratio = TRUE)),
248 list("stats::glm(count ~ g + x + offset(log_exposure), poisson); LR tests refit without each term; marginal means use the mean offset."))
STAT REG GENERALIZED LINEAR 003
Case STAT-REG-GENERALIZED-LINEAR-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm with contr.sum, MASS::glm.nb/theta.ml, MASS::gamma.dispersion, sandwich::vcovHC(type = 'HC0'); Wald/F/LR tests and marginal means from the fitted coefficients
- Citation
- R Core Team, stats package help: glm, summary.glm, logLik.glm; Venables & Ripley (2002) MASS: glm.nb, theta.ml, gamma.dispersion; Zeileis (2006) sandwich.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_glm_general.R · sha256 c450a6f63ea68bc5
- Dataset
- reference_data/datasets/REG_GLM_01.json
Settings compared
comparisons= "holm"confidence_level= 0.95covariance= "hc0"covariates= ["x"]factors= ["g"]family= "binomial"link= "probit"lr_tests= falseresponse= "events"scale= "default"trials= "trials"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 40 | 40 | 0.00E+2 | passed | |
/statistic_kind | exact | z | z | passed | ||
/type3_kind | exact | chi-square | chi-square | passed | ||
/fit/df_residual | exact | 36 | 36 | 0.00E+2 | passed | |
/fit/df_null | exact | 39 | 39 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 42.189379666196928 | 42.18937966619692 | 7.52E-15 | 15 | passed |
/fit/null_deviance | tolerance | 96.994106468500206 | 96.9941064685002 | 1.20E-16 | 17 | passed |
/fit/pearson_chi_square | tolerance | 41.501906897383641 | 41.50190689559982 | 1.78E-9 | 10 | passed |
/coefficients/0/term | exact | Intercept | Intercept | passed | ||
/coefficients/0/estimate | tolerance | -0.24149993886540047 | -0.24149993882386178 | 4.15E-11 | 9 | passed |
/coefficients/0/standard_error | tolerance | 0.08392694124740474 | 0.08392694126327446 | 1.59E-11 | 9 | passed |
/coefficients/0/statistic | tolerance | -2.8775019710713972 | -2.8775019700323523 | 1.04E-9 | 9 | passed |
/coefficients/0/p_value | tail_probability | 0.0040083740612421826 | 0.004008374074442713 | 1.32E-11 | 8 | passed |
/coefficients/0/lower | tolerance | -0.40599372104292286 | -0.40599372103248826 | 1.04E-11 | 10 | passed |
/coefficients/0/upper | tolerance | -0.077006156687878108 | -0.0770061566152353 | 7.26E-11 | 9 | passed |
/coefficients/1/term | exact | g[sum:A] | g[sum:A] | passed | ||
/coefficients/1/estimate | tolerance | -0.46791316999676102 | -0.46791316995073184 | 4.60E-11 | 10 | passed |
/coefficients/1/standard_error | tolerance | 0.077859542615454955 | 0.07785954256284826 | 5.26E-11 | 9 | passed |
/coefficients/1/statistic | tolerance | -6.0097086918139855 | -6.009708695283332 | 3.47E-9 | 9 | passed |
/coefficients/1/p_value | tail_probability | 1.8585697828574615e-09 | 1.8585697430863236e-09 | 3.98E-17 | 7 | passed |
/coefficients/1/lower | tolerance | -0.62051506937581424 | -0.6205150692266779 | 1.49E-10 | 9 | passed |
/coefficients/1/upper | tolerance | -0.31531127061770781 | -0.3153112706747858 | 5.71E-11 | 9 | passed |
/coefficients/2/term | exact | g[sum:B] | g[sum:B] | passed | ||
/coefficients/2/estimate | tolerance | 0.14372291394673198 | 0.1437229139303457 | 1.64E-11 | 9 | passed |
/coefficients/2/standard_error | tolerance | 0.10133680717029851 | 0.10133680714691701 | 2.34E-11 | 9 | passed |
/coefficients/2/statistic | tolerance | 1.4182696096315999 | 1.4182696097971368 | 1.66E-10 | 9 | passed |
/coefficients/2/p_value | tail_probability | 0.15611206576049982 | 0.15611206571218889 | 4.83E-11 | 9 | passed |
/coefficients/2/lower | tolerance | -0.054893578415333377 | -0.05489357838589279 | 2.94E-11 | 9 | passed |
/coefficients/2/upper | tolerance | 0.34233940630879733 | 0.3423394062465842 | 6.22E-11 | 9 | passed |
/coefficients/3/term | exact | x | x | passed | ||
/coefficients/3/estimate | tolerance | 0.41975624153760771 | 0.4197562415017178 | 3.59E-11 | 10 | passed |
/coefficients/3/standard_error | tolerance | 0.068613540729449557 | 0.06861354074680166 | 1.74E-11 | 9 | passed |
/coefficients/3/statistic | tolerance | 6.117688098807653 | 6.11768809673744 | 2.07E-9 | 9 | passed |
/coefficients/3/p_value | tail_probability | 9.4942662237600883e-10 | 9.49426634706466e-10 | 1.23E-17 | 7 | passed |
/coefficients/3/lower | tolerance | 0.28527617285611451 | 0.2852761727862151 | 6.99E-11 | 9 | passed |
/coefficients/3/upper | tolerance | 0.55423631021910091 | 0.5542363102172205 | 1.88E-12 | 11 | passed |
/type3/0/term | exact | g | g | passed | ||
/type3/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/type3/0/statistic | tolerance | 36.203809056309524 | 36.20380909770531 | 4.14E-8 | 8 | passed |
/type3/0/p_value | tail_probability | 1.3754434879389093e-08 | 1.375443459470126e-08 | 2.85E-16 | 7 | passed |
/type3/1/term | exact | x | x | passed | ||
/type3/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/type3/1/statistic | tolerance | 37.426107674292794 | 37.42610764896295 | 2.53E-8 | 9 | passed |
/type3/1/p_value | tail_probability | 9.4942662237601028e-10 | 9.494266347064684e-10 | 1.23E-17 | 7 | passed |
/fit/log_likelihood | tolerance | -69.10516944847366 | -69.10516944847366 | 5.43E-17 | 18 | passed |
/fit/aic | tolerance | 146.21033889694732 | 146.21033889694732 | 1.09E-16 | 18 | passed |
/fit/parameters_counted | exact | 4 | 4 | 0.00E+2 | passed | |
/means/0/level | exact | A | A | passed | ||
/means/0/link_mean | tolerance | -0.61284818549643483 | -0.6128481854171235 | 7.93E-11 | 9 | passed |
/means/0/link_se | tolerance | 0.086226552656520031 | 0.08622655263833993 | 1.82E-11 | 9 | passed |
/means/0/link_lower | tolerance | -0.78184912321426059 | -0.781849123099317 | 1.15E-10 | 9 | passed |
/means/0/link_upper | tolerance | -0.44384724777860907 | -0.44384724773493 | 4.37E-11 | 10 | passed |
/means/0/mean | tolerance | 0.26998836322841641 | 0.2699883632546398 | 2.62E-11 | 10 | passed |
/means/0/mean_se | tolerance | 0.02850980842292454 | 0.028509808418299247 | 4.63E-12 | 9 | passed |
/means/1/level | exact | B | B | passed | ||
/means/1/link_mean | tolerance | -0.0012121015529418522 | -0.0012121015360458953 | 1.69E-11 | 7 | passed |
/means/1/link_se | tolerance | 0.12964154682985185 | 0.1296415468060806 | 2.38E-11 | 9 | passed |
/means/1/link_lower | tolerance | -0.25530486423951426 | -0.25530486417602755 | 6.35E-11 | 9 | passed |
/means/1/link_upper | tolerance | 0.2528806611336305 | 0.25288066110393576 | 2.97E-11 | 9 | passed |
/means/1/mean | tolerance | 0.49951644156079783 | 0.4995164415675383 | 6.74E-12 | 10 | passed |
/means/1/mean_se | tolerance | 0.051719456334197729 | 0.05171945632471544 | 9.48E-12 | 9 | passed |
/means/2/level | exact | C | C | passed | ||
/means/2/link_mean | tolerance | 0.17925524055035522 | 0.17925524055399455 | 3.64E-12 | 10 | passed |
/means/2/link_se | tolerance | 0.14265878272007998 | 0.14265878270741275 | 1.27E-11 | 10 | passed |
/means/2/link_lower | tolerance | -0.10035083565932648 | -0.10035083563085989 | 2.85E-11 | 9 | passed |
/means/2/link_upper | tolerance | 0.45886131676003694 | 0.458861316738849 | 2.12E-11 | 10 | passed |
/means/2/mean | tolerance | 0.57113135480054544 | 0.5711313548019743 | 1.43E-12 | 11 | passed |
/means/2/mean_se | tolerance | 0.056005555447917778 | 0.05600555544290829 | 5.01E-12 | 10 | passed |
/comparisons/0/first | exact | A | A | passed | ||
/comparisons/0/second | exact | B | B | passed | ||
/comparisons/0/difference | tolerance | -0.611636083943493 | -0.6116360838810775 | 6.24E-11 | 9 | passed |
/comparisons/0/standard_error | tolerance | 0.14421856668578284 | 0.1442185666151587 | 7.06E-11 | 9 | passed |
/comparisons/0/statistic | tolerance | -4.2410356585785465 | -4.2410356602226065 | 1.64E-9 | 9 | passed |
/comparisons/0/p_value | tail_probability | 2.2249078239952836e-05 | 2.2249078076961617e-05 | 1.63E-13 | 8 | passed |
/comparisons/0/holm_p_value | tail_probability | 4.4498156479905673e-05 | 4.4498156153923234e-05 | 3.26E-13 | 8 | passed |
/comparisons/0/lower | tolerance | -0.89429928054961538 | -0.8942992803487791 | 2.01E-10 | 9 | passed |
/comparisons/0/upper | tolerance | -0.32897288733737062 | -0.3289728874133758 | 7.60E-11 | 9 | passed |
/comparisons/1/first | exact | A | A | passed | ||
/comparisons/1/second | exact | C | C | passed | ||
/comparisons/1/difference | tolerance | -0.79210342604679007 | -0.7921034259711179 | 7.57E-11 | 10 | passed |
/comparisons/1/standard_error | tolerance | 0.15994407074454087 | 0.15994407067380864 | 7.07E-11 | 9 | passed |
/comparisons/1/statistic | tolerance | -4.9523775552262901 | -4.952377556943269 | 1.72E-9 | 9 | passed |
/comparisons/1/p_value | tail_probability | 7.3312186683004034e-07 | 7.331218603594731e-07 | 6.47E-15 | 8 | passed |
/comparisons/1/holm_p_value | tail_probability | 2.199365600490121e-06 | 2.199365581078419e-06 | 1.94E-14 | 8 | passed |
/comparisons/1/lower | tolerance | -1.1055880442468167 | -1.1055880440325119 | 2.14E-10 | 9 | passed |
/comparisons/1/upper | tolerance | -0.47861880784676353 | -0.47861880790972394 | 6.30E-11 | 9 | passed |
/comparisons/2/first | exact | B | B | passed | ||
/comparisons/2/second | exact | C | C | passed | ||
/comparisons/2/difference | tolerance | -0.18046734210329707 | -0.18046734209004045 | 1.33E-11 | 10 | passed |
/comparisons/2/standard_error | tolerance | 0.19545645576414697 | 0.19545645573276596 | 3.14E-11 | 9 | passed |
/comparisons/2/statistic | tolerance | -0.92331226102382136 | -0.9233122611042376 | 8.04E-11 | 10 | passed |
/comparisons/2/p_value | tail_probability | 0.35584450011013696 | 0.35584450006824175 | 4.19E-11 | 9 | passed |
/comparisons/2/holm_p_value | tail_probability | 0.35584450011013696 | 0.35584450006824175 | 4.19E-11 | 9 | passed |
/comparisons/2/lower | tolerance | -0.56355495594687133 | -0.5635549558721091 | 7.48E-11 | 9 | passed |
/comparisons/2/upper | tolerance | 0.20262027174027714 | 0.20262027169202823 | 4.82E-11 | 9 | passed |
Convention
- stats::glm(cbind(events, trials - events) ~ g + x, binomial(probit)); HC0 = (X'WX)^-1 [sum u_i^2 x_i x_i'] (X'WX)^-1 with u_i = m_i (y_i - mu_i) mu_eta_i / V(mu_i), equal to sandwich::vcovHC(type = 'HC0').
- Factors are sum-to-zero coded on sorted levels (last level = -1), covariates enter as recorded; coefficient tests are t with Type III F when the dispersion is a moment estimate (normal: deviance/df; gamma: Pearson/df) and z with chi-square otherwise (docs/manual/chapters/86-regression-and-count-models.tex:107-170).
- Log-likelihood, AIC and BIC of true-likelihood families are evaluated at the maximum-likelihood dispersion and count the dispersion (and theta) as parameters.
- Marginal means average the linear predictor over the equal-weight factor grid at covariate means and the mean offset, then invert the link; pairwise differences are on the link scale with Holm-adjusted p-values and unadjusted intervals (manual lines 160-169).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
251 fit <- stats::glm(cbind(events, trials - events) ~ g + x, family = stats::binomial(link = "probit"),
252 data = d, contrasts = sum_contrasts, control = control)
253 X <- stats::model.matrix(fit)
254 u <- stats::residuals(fit, type = "working") * stats::weights(fit, type = "working")
255 bread <- summary(fit)$cov.unscaled
256 V <- bread %*% crossprod(X * u) %*% bread
257 stopifnot(max(abs(V - sandwich::vcovHC(fit, type = "HC0"))) < 1e-10)
258 ll <- as.numeric(stats::logLik(fit))
259 p <- length(stats::coef(fit))
260 emit("STAT-REG-GENERALIZED-LINEAR-003", "axis_coverage",
261 list(response = "events", trials = "trials", family = "binomial", factors = list("g"),
262 covariates = list("x"), link = "probit", scale = "default", covariance = "hc0",
263 confidence_level = 0.95, comparisons = "holm", lr_tests = FALSE),
264 c(glm_outputs(fit, V, FALSE, 0.95, coef_terms, type3),
265 list("/fit/log_likelihood" = tol(ll, "binomial log-likelihood with the combinatorial term"),
266 "/fit/aic" = tol(-2 * ll + 2 * p, "AIC"),
267 "/fit/parameters_counted" = exact(as.integer(p), "coefficients only")),
268 means_outputs(fit, V, FALSE, 0.95, stats::pnorm, stats::dnorm)),
269 list("stats::glm(cbind(events, trials - events) ~ g + x, binomial(probit)); HC0 = (X'WX)^-1 [sum u_i^2 x_i x_i'] (X'WX)^-1 with u_i = m_i (y_i - mu_i) mu_eta_i / V(mu_i), equal to sandwich::vcovHC(type = 'HC0')."))
STAT REG GENERALIZED LINEAR 004
Case STAT-REG-GENERALIZED-LINEAR-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm with contr.sum, MASS::glm.nb/theta.ml, MASS::gamma.dispersion, sandwich::vcovHC(type = 'HC0'); Wald/F/LR tests and marginal means from the fitted coefficients
- Citation
- R Core Team, stats package help: glm, summary.glm, logLik.glm; Venables & Ripley (2002) MASS: glm.nb, theta.ml, gamma.dispersion; Zeileis (2006) sandwich.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_glm_general.R · sha256 c450a6f63ea68bc5
- Dataset
- reference_data/datasets/REG_GLM_01.json
Settings compared
comparisons= "holm"confidence_level= 0.95covariance= "model"covariates= ["x"]factors= ["g"]family= "gamma"link= "canonical"lr_tests= falseresponse= "ypos"scale= "default"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 40 | 40 | 0.00E+2 | passed | |
/statistic_kind | exact | t | t | passed | ||
/type3_kind | exact | F | F | passed | ||
/fit/df_residual | exact | 36 | 36 | 0.00E+2 | passed | |
/fit/df_null | exact | 39 | 39 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 7.4015634653049238 | 7.401563465304923 | 8.71E-16 | 15 | passed |
/fit/null_deviance | tolerance | 12.435169462090924 | 12.435169462090924 | 1.14E-16 | 17 | passed |
/fit/pearson_chi_square | tolerance | 6.3977242073842833 | 6.397724207384282 | 9.20E-16 | 15 | passed |
/coefficients/0/term | exact | Intercept | Intercept | passed | ||
/coefficients/0/estimate | tolerance | 0.6844376845097222 | 0.6844376845097223 | 1.11E-16 | 15 | passed |
/coefficients/0/standard_error | tolerance | 0.04956872920417825 | 0.04956872920418114 | 2.89E-15 | 13 | passed |
/coefficients/0/statistic | tolerance | 13.807852157969576 | 13.807852157968773 | 8.03E-13 | 13 | passed |
/coefficients/0/p_value | tail_probability | 5.929338814244517e-16 | 5.929338814255024e-16 | 1.05E-27 | 11 | passed |
/coefficients/0/lower | tolerance | 0.58390764217450386 | 0.5839076421744981 | 5.77E-15 | 14 | passed |
/coefficients/0/upper | tolerance | 0.78496772684494054 | 0.7849677268449465 | 5.99E-15 | 14 | passed |
/coefficients/1/term | exact | g[sum:A] | g[sum:A] | passed | ||
/coefficients/1/estimate | tolerance | 0.15144656362616221 | 0.15144656362616218 | 2.61E-17 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.062111267418457392 | 0.06211126741846004 | 2.65E-15 | 13 | passed |
/coefficients/1/statistic | tolerance | 2.4383106305951401 | 2.4383106305950353 | 1.05E-13 | 13 | passed |
/coefficients/1/p_value | tail_probability | 0.019820392437137221 | 0.019820392437142113 | 4.89E-15 | 12 | passed |
/coefficients/1/lower | tolerance | 0.025479074781496247 | 0.02547907478149089 | 5.36E-15 | 12 | passed |
/coefficients/1/upper | tolerance | 0.27741405247082818 | 0.2774140524708335 | 5.33E-15 | 13 | passed |
/coefficients/2/term | exact | g[sum:B] | g[sum:B] | passed | ||
/coefficients/2/estimate | tolerance | 0.062208509632005853 | 0.06220850963200593 | 7.59E-17 | 14 | passed |
/coefficients/2/standard_error | tolerance | 0.061473251629982892 | 0.06147325162998442 | 1.53E-15 | 13 | passed |
/coefficients/2/statistic | tolerance | 1.0119606167321129 | 1.011960616732089 | 2.40E-14 | 13 | passed |
/coefficients/2/p_value | tail_probability | 0.3183103894543946 | 0.31831038945440565 | 1.11E-14 | 13 | passed |
/coefficients/2/lower | tolerance | -0.062465023219524164 | -0.062465023219527155 | 2.99E-15 | 13 | passed |
/coefficients/2/upper | tolerance | 0.18688204248353588 | 0.186882042483539 | 3.13E-15 | 13 | passed |
/coefficients/3/term | exact | x | x | passed | ||
/coefficients/3/estimate | tolerance | -0.14860982010117738 | -0.14860982010117774 | 3.56E-16 | 14 | passed |
/coefficients/3/standard_error | tolerance | 0.038784634612833525 | 0.0387846346128387 | 5.18E-15 | 12 | passed |
/coefficients/3/statistic | tolerance | -3.8316674008836369 | -3.8316674008831346 | 5.02E-13 | 12 | passed |
/coefficients/3/p_value | tail_probability | 0.0004912252368102605 | 0.0004912252368109704 | 7.10E-16 | 11 | passed |
/coefficients/3/lower | tolerance | -0.22726870488968379 | -0.22726870488969464 | 1.08E-14 | 13 | passed |
/coefficients/3/upper | tolerance | -0.069950935312670964 | -0.06995093531266083 | 1.01E-14 | 12 | passed |
/type3/0/term | exact | g | g | passed | ||
/type3/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/type3/0/statistic | tolerance | 9.6549601312259377 | 9.65496013122283 | 3.11E-12 | 12 | passed |
/type3/0/denominator_df | exact | 36 | 36 | 0.00E+2 | passed | |
/type3/0/p_value | tail_probability | 0.00043953193110398618 | 0.00043953193110487517 | 8.89E-16 | 11 | passed |
/type3/1/term | exact | x | x | passed | ||
/type3/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/type3/1/statistic | tolerance | 14.681675070994364 | 14.681675070990519 | 3.85E-12 | 12 | passed |
/type3/1/denominator_df | exact | 36 | 36 | 0.00E+2 | passed | |
/type3/1/p_value | tail_probability | 0.00049122523681026083 | 0.0004912252368109704 | 7.10E-16 | 11 | passed |
/fit/scale | tolerance | 0.17771456131623009 | 0.17771456131623006 | 2.70E-17 | 15 | passed |
/fit/ml_scale | tolerance | 0.17967564231913627 | 0.1796756423191367 | 4.44E-16 | 14 | passed |
/fit/log_likelihood | tolerance | -39.078154278025956 | -39.078154278025956 | 3.52E-16 | 17 | passed |
/fit/aic | tolerance | 88.156308556051911 | 88.15630855605191 | 2.96E-16 | 17 | passed |
/fit/bic | tolerance | 96.600705826621592 | 96.60070582662159 | 1.09E-16 | 17 | passed |
/fit/parameters_counted | exact | 5 | 5 | 0.00E+2 | passed | |
/means/0/level | exact | A | A | passed | ||
/means/0/link_mean | tolerance | 0.80169655902160852 | 0.8016965590216085 | 3.57E-18 | 17 | passed |
/means/0/link_se | tolerance | 0.085176236812073244 | 0.08517623681207545 | 2.21E-15 | 13 | passed |
/means/0/link_lower | tolerance | 0.62895114411695252 | 0.6289511441169481 | 4.44E-15 | 14 | passed |
/means/0/link_upper | tolerance | 0.97444197392626453 | 0.974441973926269 | 4.44E-15 | 14 | passed |
/means/0/mean | tolerance | 1.2473547363361535 | 1.2473547363361535 | 4.21E-17 | 16 | passed |
/means/0/mean_se | tolerance | 0.13252518202209937 | 0.13252518202210278 | 3.41E-15 | 13 | passed |
/means/1/level | exact | B | B | passed | ||
/means/1/link_mean | tolerance | 0.71245850502745223 | 0.7124585050274523 | 1.08E-16 | 15 | passed |
/means/1/link_se | tolerance | 0.080255310165146213 | 0.0802553101651467 | 4.85E-16 | 14 | passed |
/means/1/link_lower | tolerance | 0.54969319193469379 | 0.549693191934693 | 7.75E-16 | 14 | passed |
/means/1/link_upper | tolerance | 0.87522381812021066 | 0.8752238181202117 | 1.00E-15 | 14 | passed |
/means/1/mean | tolerance | 1.403590515017388 | 1.4035905150173877 | 2.59E-16 | 15 | passed |
/means/1/mean_se | tolerance | 0.15810828466878554 | 0.15810828466878643 | 8.91E-16 | 14 | passed |
/means/2/level | exact | C | C | passed | ||
/means/2/link_mean | tolerance | 0.4365949221372783 | 0.4365949221372783 | 3.76E-18 | 17 | passed |
/means/2/link_se | tolerance | 0.049348891373424526 | 0.04934889137343949 | 1.50E-14 | 12 | passed |
/means/2/link_lower | tolerance | 0.33651073158780009 | 0.3365107315877698 | 3.03E-14 | 13 | passed |
/means/2/link_upper | tolerance | 0.5366791126867565 | 0.5366791126867868 | 3.03E-14 | 13 | passed |
/means/2/mean | tolerance | 2.2904526582779874 | 2.2904526582779874 | 1.44E-17 | 17 | passed |
/means/2/mean_se | tolerance | 0.25889284024652831 | 0.2588928402466068 | 7.85E-14 | 12 | passed |
/comparisons/0/first | exact | A | A | passed | ||
/comparisons/0/second | exact | B | B | passed | ||
/comparisons/0/difference | tolerance | 0.089238053994156352 | 0.08923805399415626 | 9.69E-17 | 14 | passed |
/comparisons/0/standard_error | tolerance | 0.11332760946056263 | 0.11332760946056372 | 1.09E-15 | 14 | passed |
/comparisons/0/statistic | tolerance | 0.78743436324941363 | 0.7874343632494051 | 8.55E-15 | 13 | passed |
/comparisons/0/p_value | tail_probability | 0.43618156021983046 | 0.4361815602198354 | 4.94E-15 | 13 | passed |
/comparisons/0/holm_p_value | tail_probability | 0.43618156021983046 | 0.4361815602198354 | 4.94E-15 | 13 | passed |
/comparisons/0/lower | tolerance | -0.14060099089826608 | -0.14060099089826833 | 2.25E-15 | 13 | passed |
/comparisons/0/upper | tolerance | 0.31907709888657876 | 0.31907709888658087 | 2.11E-15 | 14 | passed |
/comparisons/1/first | exact | A | A | passed | ||
/comparisons/1/second | exact | C | C | passed | ||
/comparisons/1/difference | tolerance | 0.36510163688433028 | 0.3651016368843303 | 2.84E-18 | 17 | passed |
/comparisons/1/standard_error | tolerance | 0.093794696586538065 | 0.09379469658654896 | 1.09E-14 | 12 | passed |
/comparisons/1/statistic | tolerance | 3.8925616284442643 | 3.8925616284438123 | 4.52E-13 | 12 | passed |
/comparisons/1/p_value | tail_probability | 0.00041200936066047866 | 0.00041200936066101924 | 5.41E-16 | 11 | passed |
/comparisons/1/holm_p_value | tail_probability | 0.0012360280819814361 | 0.0012360280819830576 | 1.62E-15 | 11 | passed |
/comparisons/1/lower | tolerance | 0.17487717541339087 | 0.17487717541336883 | 2.20E-14 | 12 | passed |
/comparisons/1/upper | tolerance | 0.55532609835526969 | 0.5553260983552917 | 2.20E-14 | 13 | passed |
/comparisons/2/first | exact | B | B | passed | ||
/comparisons/2/second | exact | C | C | passed | ||
/comparisons/2/difference | tolerance | 0.27586358289017393 | 0.27586358289017404 | 1.12E-16 | 15 | passed |
/comparisons/2/standard_error | tolerance | 0.09252512353230842 | 0.0925251235323172 | 8.78E-15 | 13 | passed |
/comparisons/2/statistic | tolerance | 2.9814992118745609 | 2.981499211874279 | 2.82E-13 | 13 | passed |
/comparisons/2/p_value | tail_probability | 0.0051187719095812543 | 0.005118771909585025 | 3.77E-15 | 12 | passed |
/comparisons/2/holm_p_value | tail_probability | 0.010237543819162509 | 0.01023754381917005 | 7.54E-15 | 12 | passed |
/comparisons/2/lower | tolerance | 0.08821393491432411 | 0.08821393491430643 | 1.77E-14 | 12 | passed |
/comparisons/2/upper | tolerance | 0.46351323086602375 | 0.4635132308660417 | 1.79E-14 | 13 | passed |
Convention
- stats::glm(ypos ~ g + x, Gamma(inverse)); the moment dispersion is Pearson/df (summary.glm) and the ML dispersion solves log(nu) - digamma(nu) = D/(2n) (MASS::gamma.dispersion).
- Factors are sum-to-zero coded on sorted levels (last level = -1), covariates enter as recorded; coefficient tests are t with Type III F when the dispersion is a moment estimate (normal: deviance/df; gamma: Pearson/df) and z with chi-square otherwise (docs/manual/chapters/86-regression-and-count-models.tex:107-170).
- Log-likelihood, AIC and BIC of true-likelihood families are evaluated at the maximum-likelihood dispersion and count the dispersion (and theta) as parameters.
- Marginal means average the linear predictor over the equal-weight factor grid at covariate means and the mean offset, then invert the link; pairwise differences are on the link scale with Holm-adjusted p-values and unadjusted intervals (manual lines 160-169).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
273 fit <- stats::glm(ypos ~ g + x, family = stats::Gamma(link = "inverse"), data = d,
274 contrasts = sum_contrasts, control = control)
275 p <- length(stats::coef(fit)); df <- n - p
276 pearson <- sum(stats::residuals(fit, type = "pearson")^2)
277 scale <- pearson / df
278 stopifnot(abs(scale - summary(fit)$dispersion) < 1e-12 * scale)
279 V <- scale * summary(fit)$cov.unscaled
280 mu <- stats::fitted(fit)
281 target <- stats::deviance(fit) / (2 * n)
282 shape <- stats::uniroot(function(s) log(s) - digamma(s) - target, c(1e-3, 1e6), tol = 1e-14)$root
283 ml_scale <- 1 / shape
284 stopifnot(abs(ml_scale - MASS::gamma.dispersion(fit)) < 1e-6)
285 ll <- sum(stats::dgamma(d$ypos, shape = shape, scale = mu * ml_scale, log = TRUE))
286 emit("STAT-REG-GENERALIZED-LINEAR-004", "axis_coverage",
287 list(response = "ypos", family = "gamma", factors = list("g"), covariates = list("x"),
288 link = "canonical", scale = "default", covariance = "model", confidence_level = 0.95,
289 comparisons = "holm", lr_tests = FALSE),
290 c(glm_outputs(fit, V, TRUE, 0.95, coef_terms, type3),
291 list("/fit/scale" = tol(scale, "Pearson chi-square / residual df"),
292 "/fit/ml_scale" = tol(ml_scale, "ML dispersion solving log(nu) - digamma(nu) = D/(2n)"),
293 "/fit/log_likelihood" = tol(ll, "gamma log-likelihood at the ML dispersion"),
294 "/fit/aic" = tol(-2 * ll + 2 * (p + 1), "AIC counting the dispersion"),
295 "/fit/bic" = tol(-2 * ll + log(n) * (p + 1), "BIC counting the dispersion"),
296 "/fit/parameters_counted" = exact(as.integer(p + 1L), "coefficients plus dispersion")),
297 means_outputs(fit, V, TRUE, 0.95, function(eta) 1 / eta, function(eta) -1 / eta^2)),
298 list("stats::glm(ypos ~ g + x, Gamma(inverse)); the moment dispersion is Pearson/df (summary.glm) and the ML dispersion solves log(nu) - digamma(nu) = D/(2n) (MASS::gamma.dispersion)."))
STAT REG GENERALIZED LINEAR 005
Case STAT-REG-GENERALIZED-LINEAR-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm with contr.sum, MASS::glm.nb/theta.ml, MASS::gamma.dispersion, sandwich::vcovHC(type = 'HC0'); Wald/F/LR tests and marginal means from the fitted coefficients
- Citation
- R Core Team, stats package help: glm, summary.glm, logLik.glm; Venables & Ripley (2002) MASS: glm.nb, theta.ml, gamma.dispersion; Zeileis (2006) sandwich.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_glm_general.R · sha256 c450a6f63ea68bc5
- Dataset
- reference_data/datasets/REG_GLM_01.json
Settings compared
comparisons= "holm"confidence_level= 0.95covariance= "model"covariates= ["x"]factors= ["g"]family= "negative_binomial"link= "canonical"lr_tests= falseresponse= "nbcount"scale= "default"theta= "estimate"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 40 | 40 | 0.00E+2 | passed | |
/statistic_kind | exact | z | z | passed | ||
/type3_kind | exact | chi-square | chi-square | passed | ||
/fit/df_residual | exact | 36 | 36 | 0.00E+2 | passed | |
/fit/df_null | exact | 39 | 39 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 42.248206223586656 | 42.24820622191938 | 1.67E-9 | 10 | passed |
/fit/null_deviance | tolerance | 49.574028543151627 | 49.57402854114482 | 2.01E-9 | 10 | passed |
/fit/pearson_chi_square | tolerance | 37.298578204618714 | 37.29857820117358 | 3.45E-9 | 10 | passed |
/coefficients/0/term | exact | Intercept | Intercept | passed | ||
/coefficients/0/estimate | tolerance | 0.84814776056703134 | 0.8481477603444781 | 2.23E-10 | 9 | passed |
/coefficients/0/standard_error | tolerance | 0.15410011052909503 | 0.15410011086757544 | 3.38E-10 | 8 | passed |
/coefficients/0/statistic | tolerance | 5.5038750955788309 | 5.503875082045375 | 1.35E-8 | 8 | passed |
/coefficients/0/p_value | tail_probability | 3.715328188713317e-08 | 3.7153284740682296e-08 | 2.85E-15 | 7 | passed |
/coefficients/0/lower | tolerance | 0.54611709391636354 | 0.5461170930304009 | 8.86E-10 | 8 | passed |
/coefficients/0/upper | tolerance | 1.1501784272176991 | 1.1501784276585554 | 4.41E-10 | 9 | passed |
/coefficients/0/exp_estimate | tolerance | 2.335317276710426 | 2.3353172761906937 | 5.20E-10 | 9 | passed |
/coefficients/0/exp_lower | tolerance | 1.7265360083776804 | 1.726536006848034 | 1.53E-9 | 9 | passed |
/coefficients/0/exp_upper | tolerance | 3.1587564675391353 | 3.1587564689316925 | 1.39E-9 | 9 | passed |
/coefficients/1/term | exact | g[sum:A] | g[sum:A] | passed | ||
/coefficients/1/estimate | tolerance | -0.4393930221659208 | -0.43939302166369704 | 5.02E-10 | 8 | passed |
/coefficients/1/standard_error | tolerance | 0.21815943856427919 | 0.21815943835031038 | 2.14E-10 | 9 | passed |
/coefficients/1/statistic | tolerance | -2.0140912768092618 | -2.0140912764825694 | 3.27E-10 | 9 | passed |
/coefficients/1/p_value | tail_probability | 0.043999951210487331 | 0.04399995124478047 | 3.43E-11 | 9 | passed |
/coefficients/1/lower | tolerance | -0.86697766463938652 | -0.8669776637177916 | 9.22E-10 | 8 | passed |
/coefficients/1/upper | tolerance | -0.011808379692455129 | -0.01180837960960246 | 8.29E-11 | 8 | passed |
/coefficients/1/exp_estimate | tolerance | 0.64442745557770831 | 0.6444274559013551 | 3.24E-10 | 9 | passed |
/coefficients/1/exp_lower | tolerance | 0.4202196767172503 | 0.4202196771045226 | 3.87E-10 | 9 | passed |
/coefficients/1/exp_upper | tolerance | 0.98826106560876192 | 0.988261065690642 | 8.19E-11 | 10 | passed |
/coefficients/2/term | exact | g[sum:B] | g[sum:B] | passed | ||
/coefficients/2/estimate | tolerance | 0.34322698360319015 | 0.34322698391478434 | 3.12E-10 | 9 | passed |
/coefficients/2/standard_error | tolerance | 0.19877788587575584 | 0.19877788583034445 | 4.54E-11 | 9 | passed |
/coefficients/2/statistic | tolerance | 1.7266859544814799 | 1.726685956443496 | 1.96E-9 | 8 | passed |
/coefficients/2/p_value | tail_probability | 0.084224079504951546 | 0.08422407915239383 | 3.53E-10 | 8 | passed |
/coefficients/2/lower | tolerance | -0.046370513636304345 | -0.04637051323570551 | 4.01E-10 | 8 | passed |
/coefficients/2/upper | tolerance | 0.7328244808426847 | 0.7328244810652742 | 2.23E-10 | 9 | passed |
/coefficients/2/exp_estimate | tolerance | 1.4094886564335665 | 1.409488656872755 | 4.39E-10 | 9 | passed |
/coefficients/2/exp_lower | tolerance | 0.95468817166663422 | 0.9546881720490813 | 3.82E-10 | 9 | passed |
/coefficients/2/exp_upper | tolerance | 2.0809499180729532 | 2.080949918536151 | 4.63E-10 | 9 | passed |
/coefficients/3/term | exact | x | x | passed | ||
/coefficients/3/estimate | tolerance | 0.26304081830519416 | 0.26304081929558915 | 9.90E-10 | 8 | passed |
/coefficients/3/standard_error | tolerance | 0.13897925961940266 | 0.13897925975233516 | 1.33E-10 | 9 | passed |
/coefficients/3/statistic | tolerance | 1.8926623945582703 | 1.8926623998741616 | 5.32E-9 | 8 | passed |
/coefficients/3/p_value | tail_probability | 0.058402780413592467 | 0.05840277970620459 | 7.07E-10 | 7 | passed |
/coefficients/3/lower | tolerance | -0.0093535251468768732 | -0.009353524417024861 | 7.30E-10 | 7 | passed |
/coefficients/3/upper | tolerance | 0.53543516175726524 | 0.5354351630082032 | 1.25E-9 | 8 | passed |
/coefficients/3/exp_estimate | tolerance | 1.3008798175774337 | 1.3008798188658186 | 1.29E-9 | 9 | passed |
/coefficients/3/exp_lower | tolerance | 0.99069008300024763 | 0.9906900837233048 | 7.23E-10 | 9 | passed |
/coefficients/3/exp_upper | tolerance | 1.708191420121316 | 1.7081914222581573 | 2.14E-9 | 8 | passed |
/type3/0/term | exact | g | g | passed | ||
/type3/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/type3/0/statistic | tolerance | 4.7397471480989761 | 4.739747157311826 | 9.21E-9 | 8 | passed |
/type3/0/p_value | tail_probability | 0.093492545414839784 | 0.09349254498417338 | 4.31E-10 | 8 | passed |
/type3/1/term | exact | x | x | passed | ||
/type3/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/type3/1/statistic | tolerance | 3.5821709397750454 | 3.582170959897421 | 2.01E-8 | 8 | passed |
/type3/1/p_value | tail_probability | 0.058402780413592578 | 0.05840277970620457 | 7.07E-10 | 7 | passed |
/fit/theta | tolerance | 2.3571871105672249 | 2.357187110352537 | 2.15E-10 | 10 | passed |
/fit/theta_se | tolerance | 1.0501408959305252 | 1.0501408957479548 | 1.83E-10 | 9 | passed |
/fit/log_likelihood | tolerance | -81.251286229650262 | -81.25128622965023 | 2.86E-14 | 15 | passed |
/fit/aic | tolerance | 172.50257245930052 | 172.50257245930047 | 5.32E-14 | 15 | passed |
/fit/bic | tolerance | 180.9469697298702 | 180.94696972987015 | 5.24E-14 | 15 | passed |
/fit/parameters_counted | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- MASS::glm.nb polished by alternating MASS::theta.ml (eps 1e-14) and glm(negative.binomial(theta)) steps; theta SE = 1/sqrt(observed information) as in theta.ml; coefficient covariance is the expected information at fixed theta with dispersion 1.
- Theta and its SE carry 1e-7 and 1e-6 relative tolerances because both sides reach theta by an alternating search rather than in closed form.
- Factors are sum-to-zero coded on sorted levels (last level = -1), covariates enter as recorded; coefficient tests are t with Type III F when the dispersion is a moment estimate (normal: deviance/df; gamma: Pearson/df) and z with chi-square otherwise (docs/manual/chapters/86-regression-and-count-models.tex:107-170).
- Log-likelihood, AIC and BIC of true-likelihood families are evaluated at the maximum-likelihood dispersion and count the dispersion (and theta) as parameters.
- Marginal means average the linear predictor over the equal-weight factor grid at covariate means and the mean offset, then invert the link; pairwise differences are on the link scale with Holm-adjusted p-values and unadjusted intervals (manual lines 160-169).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
312 fit <- stats::glm(nbcount ~ g + x, family = MASS::negative.binomial(theta), data = d,
313 contrasts = sum_contrasts, control = control)
314 mu <- stats::fitted(fit)
315 y <- d$nbcount
316 p <- length(stats::coef(fit))
317 V <- summary(fit, dispersion = 1)$cov.unscaled
318 ll <- sum(stats::dnbinom(y, size = theta, mu = mu, log = TRUE))
319 info <- sum(-trigamma(y + theta) + trigamma(theta) - 1 / theta + 2 / (mu + theta) - (y + theta) / (mu + theta)^2)
320 emit("STAT-REG-GENERALIZED-LINEAR-005", "axis_coverage",
321 list(response = "nbcount", family = "negative_binomial", factors = list("g"),
322 covariates = list("x"), link = "canonical", theta = "estimate", scale = "default",
323 covariance = "model", confidence_level = 0.95, comparisons = "holm", lr_tests = FALSE),
324 c(glm_outputs(fit, V, FALSE, 0.95, coef_terms, type3, exp_link = TRUE),
325 list("/fit/theta" = tol(theta, "ML theta", "1e-7"),
326 "/fit/theta_se" = tol(1 / sqrt(info), "theta SE from the observed information", "1e-6"),
327 "/fit/log_likelihood" = tol(ll, "negative binomial log-likelihood"),
328 "/fit/aic" = tol(-2 * ll + 2 * (p + 1), "AIC counting theta"),
329 "/fit/bic" = tol(-2 * ll + log(n) * (p + 1), "BIC counting theta"),
330 "/fit/parameters_counted" = exact(as.integer(p + 1L), "coefficients plus theta"))),
331 list("MASS::glm.nb polished by alternating MASS::theta.ml (eps 1e-14) and glm(negative.binomial(theta)) steps; theta SE = 1/sqrt(observed information) as in theta.ml; coefficient covariance is the expected information at fixed theta with dispersion 1.",
332 "Theta and its SE carry 1e-7 and 1e-6 relative tolerances because both sides reach theta by an alternating search rather than in closed form."))
Binomial random-intercept GLMM at the zero-variance boundary (closed form)
Case STAT-REG-GLMM-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Closed-form maximum likelihood of a saturated design at the tau = 0 boundary
- Citation
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/REG_GLMM_BINOMIAL_BOUNDARY.json
Settings compared
event_value= "1"family= "binomial"fixed_numeric_columns= ["x"]group_column= "g"response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/variance_status | exact | boundary | boundary | passed | ||
/random_intercept_sd | tolerance | 0.0 | 0.0 | 0.00E+1 | passed | |
/coefficients/[term=Intercept]/estimate | tolerance | -1.0986122886681098 | -1.0986122886681098 | 1.79E-17 | 16 | passed |
/coefficients/[term=x]/estimate | tolerance | 2.1972245773362196 | 2.1972245773362196 | 3.58E-17 | 16 | passed |
/log_likelihood | tolerance | -26.992086941702798 | -26.992086941702805 | 7.09E-15 | 15 | passed |
/inference_available | exact | False | False | passed |
Convention
- Every group has the same rows, so there is no between-group variation and the marginal likelihood is maximized at tau = 0; the fit then equals the saturated logistic GLM.
- Intercept = logit(1/4) = log(1/3); slope = logit(3/4) - logit(1/4) = 2 log 3; log-likelihood = 12 log(1/4) + 36 log(3/4) (Bernoulli rows have no binomial constant).
Poisson random-intercept GLMM with exposure at the zero-variance boundary (closed form)
Case STAT-REG-GLMM-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Closed-form maximum likelihood of a saturated design at the tau = 0 boundary
- Citation
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/REG_GLMM_POISSON_BOUNDARY.json
Settings compared
exposure_column= "e"family= "poisson"fixed_categorical_columns= ["level"]group_column= "g"response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/variance_status | exact | boundary | boundary | passed | ||
/random_intercept_sd | tolerance | 0.0 | 0.0 | 0.00E+1 | passed | |
/coefficients/[term=Intercept]/estimate | tolerance | 0.6931471805599453 | 0.6931471805599453 | 1.38E-17 | 16 | passed |
/coefficients/[term=level = B (vs A)]/estimate | tolerance | 0.4054651081081644 | 0.4054651081081646 | 2.07E-16 | 15 | passed |
/log_likelihood | tolerance | -33.87021657780064 | -33.87021657780065 | 7.43E-15 | 15 | passed |
Convention
- Identical groups give the tau = 0 maximum, so the fit is the saturated Poisson GLM with log-exposure offset: each level's rate is its total count over its total exposure.
Regression II large-offset numeric STAT-REG-HARD-ADV-DA-SCORE-001
Case STAT-REG-HARD-ADV-DA-SCORE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/MASS/pls
- Citation
- R nlme::lme, plm::plm, stats::lm/nls, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_hard.R · sha256 57a7311aff0ed329
- Dataset
- reference_data/datasets/REG_ADV_HARD_DA.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "lda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[999998], [1000002]], "covariance": [[0.727272727272727]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/12/probabilities/0 | tolerance | 0.0040701377158961164 | 0.004070137715896127 | 1.04E-17 | 14 | passed |
Convention
- LDA class means carry the same million-unit translation as the CSV; pooled covariance is unchanged.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
101 base_da$artifact$class_means <- list(list(as.double(lda$means[1L, 1L])),
102 list(as.double(lda$means[2L, 1L])))
103 posterior <- stats::predict(lda, newdata = da)$posterior
104 emit("STAT-REG-HARD-ADV-DA-SCORE-001", "STAT-REG-DISCRIMINANT-SCORE-LDA-001",
105 "REG_ADV_HARD_DA", base_da,
106 list("/0/probabilities/0" = tol(posterior[1L, 1L],
107 "LDA posterior under million-unit offset", "1e-9"),
108 "/12/probabilities/0" = tol(posterior[13L, 1L],
109 "opposite-class LDA posterior", "1e-9")),
110 "LDA class means carry the same million-unit translation as the CSV; pooled covariance is unchanged.")
Regression II large-offset numeric STAT-REG-HARD-ADV-MIXED-001
Case STAT-REG-HARD-ADV-MIXED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/MASS/pls
- Citation
- R nlme::lme, plm::plm, stats::lm/nls, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_hard.R · sha256 57a7311aff0ed329
- Dataset
- reference_data/datasets/REG_ADV_HARD_ORTH.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.66018518518521341 | 0.660185185185185 | 2.84E-14 | 13 | passed |
Convention
- Both response and age are translated; fixed slope should remain stable.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
60 mixed <- nlme::lme(distance ~ age, random = ~1 | subject, data = orth,
61 method = "REML", control = nlme::lmeControl(opt = "optim"))
62 emit("STAT-REG-HARD-ADV-MIXED-001", "STAT-REG-MIXED-REML-001", "REG_ADV_HARD_ORTH",
63 list(response_column = "distance", group_column = "subject",
64 fixed_numeric_columns = list("age"), estimation = "reml"),
65 list("/coefficients/1/estimate" = tol(nlme::fixef(mixed)[["age"]],
66 "REML fixed slope after large offsets")),
67 "Both response and age are translated; fixed slope should remain stable.")
Regression II large-offset numeric STAT-REG-HARD-ADV-NONLINEAR-001
Case STAT-REG-HARD-ADV-NONLINEAR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/MASS/pls
- Citation
- R nlme::lme, plm::plm, stats::lm/nls, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_hard.R · sha256 57a7311aff0ed329
- Dataset
- reference_data/datasets/REG_ADV_HARD_DECAY.json
Settings compared
curve= "exponential_decay"parameters= [{"name": "a", "start": 4, "lower": 0, "upper": 10}, {"name": "k", "start": 0.8, "lower": 0.01, "upper": 3}, {"name": "c", "start": 10001, "lower": 9990, "upper": 10010}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/estimates/1 | tolerance | 0.81258832085857824 | 0.8125882327178846 | 8.81E-8 | 6 | passed |
Convention
- R nls port estimates rate on the original response scale with a large fitted c.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
84 nls_fit <- stats::nls(y ~ c + a * exp(-k * x), data = decay,
85 start = list(a = 4, k = 0.8, c = 10001), algorithm = "port",
86 lower = c(a = 0, k = 0.01, c = 9990),
87 upper = c(a = 10, k = 3, c = 10010),
88 control = stats::nls.control(maxiter = 1000, tol = 1e-12))
89 emit("STAT-REG-HARD-ADV-NONLINEAR-001", "STAT-REG-NONLINEAR-DECAY-001",
90 "REG_ADV_HARD_DECAY",
91 list(x_column = "x", response = "y", curve = "exponential_decay",
92 parameters = list(list(name = "a", start = 4, lower = 0, upper = 10),
93 list(name = "k", start = 0.8, lower = 0.01, upper = 3),
94 list(name = "c", start = 10001, lower = 9990, upper = 10010))),
95 list("/artifact/estimates/1" = tol(coef(nls_fit)[["k"]],
96 "decay rate with ten-thousand-unit baseline")),
97 "R nls port estimates rate on the original response scale with a large fitted c.")
Regression II large-offset numeric STAT-REG-HARD-ADV-PANEL-001
Case STAT-REG-HARD-ADV-PANEL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/MASS/pls
- Citation
- R nlme::lme, plm::plm, stats::lm/nls, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_hard.R · sha256 57a7311aff0ed329
- Dataset
- reference_data/datasets/REG_ADV_HARD_ORTH.json
Settings compared
entity_column= "subject"predictor_columns= ["age"]response_column= "distance"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/estimate | tolerance | 0.6601851851851851 | 0.6601851851851851 | 2.81E-18 | 17 | passed |
Convention
- Entity demeaning should cancel large age/response offsets before OLS.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
68 panel <- plm::plm(distance ~ age, data = orth, index = c("subject", "time"),
69 model = "within", effect = "individual")
70 emit("STAT-REG-HARD-ADV-PANEL-001", "STAT-REG-PANEL-001", "REG_ADV_HARD_ORTH",
71 list(response_column = "distance", predictor_columns = list("age"),
72 entity_column = "subject", time_column = "time"),
73 list("/coefficients/0/estimate" = tol(coef(panel)[["age"]],
74 "within slope after large offsets", "1e-9")),
75 "Entity demeaning should cancel large age/response offsets before OLS.")
Regression II large-offset numeric STAT-REG-HARD-ADV-PLS-SCORE-001
Case STAT-REG-HARD-ADV-PLS-SCORE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/MASS/pls
- Citation
- R nlme::lme, plm::plm, stats::lm/nls, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_hard.R · sha256 57a7311aff0ed329
- Dataset
- reference_data/datasets/REG_ADV_HARD_PLS.json
Settings compared
artifact= {"response": "y", "predictors": ["x"], "imputation": "drop", "scale": false, "component_count": 1, "imputation_values": [null], "x_means": [10000015.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/predicted | tolerance | 5.0083606988191605 | 5.008360698763212 | 5.59E-11 | 10 | passed |
/29/predicted | tolerance | 62.99257280305028 | 62.99257280242439 | 6.26E-10 | 11 | passed |
Convention
- R pls::plsr centers the large predictor before extracting the original-unit coefficient.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
114 pls_cfg$artifact$x_means <- list(mean(pls_data$x))
115 pls_cfg$artifact$coefficients <- list(as.double(stats::coef(pls_fit, ncomp = 1L))[1L])
116 pls_cfg$artifact$intercept <- mean(pls_data$y)
117 pls_pred <- as.double(stats::predict(pls_fit, newdata = pls_data, ncomp = 1L))
118 emit("STAT-REG-HARD-ADV-PLS-SCORE-001", "STAT-REG-PLS-SCORE-001",
119 "REG_ADV_HARD_PLS", pls_cfg,
120 list("/0/predicted" = tol(pls_pred[[1L]],
121 "PLS prediction after ten-million-unit x offset", "1e-9"),
122 "/29/predicted" = tol(pls_pred[[30L]],
123 "last PLS prediction after large offset", "1e-9")),
124 "R pls::plsr centers the large predictor before extracting the original-unit coefficient.")
Regression II large-offset numeric STAT-REG-HARD-ADV-SELECTION-001
Case STAT-REG-HARD-ADV-SELECTION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/MASS/pls
- Citation
- R nlme::lme, plm::plm, stats::lm/nls, MASS::lda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_hard.R · sha256 57a7311aff0ed329
- Dataset
- reference_data/datasets/REG_ADV_HARD_ORTH.json
Settings compared
candidate_predictors= ["age"]response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 0.66018518518827318 | 0.6601851851850711 | 3.20E-12 | 11 | passed |
Convention
- One strong candidate is retained; R lm is the independent refit.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
76 ols <- stats::lm(distance ~ age, data = orth)
77 emit("STAT-REG-HARD-ADV-SELECTION-001", "STAT-REG-SELECTION-001",
78 "REG_ADV_HARD_ORTH", list(response = "distance",
79 candidate_predictors = list("age")),
80 list("/coefficients/1/coefficient" = tol(coef(ols)[["age"]],
81 "large-offset OLS slope", "1e-9")),
82 "One strong candidate is retained; R lm is the independent refit.")
Extreme scale STAT-REG-HARD-BINARY-001
Case STAT-REG-HARD-BINARY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 722.22061481396645 | 722.2206148139666 | 1.13E-13 | 15 | passed |
Convention
- The binomial logit slope changes inversely with predictor units.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
51 b <- stats::glm(I(binary == "event") ~ x, family = stats::binomial(), data = d)
52 emit("STAT-REG-HARD-BINARY-001",
53 "tabelz.analysis.logistic_regression:compute_binary_logistic_regression",
54 "logisticRegressionMenuItem",
55 list(outcome_column = "binary", event_value = "event", predictors = list("x")),
56 list("/coefficients/1/coefficient" = tol(coef(b)[["x"]], "rescaled logit slope")),
57 list("The binomial logit slope changes inversely with predictor units."))
Extreme scale STAT-REG-HARD-EFFECTS-001
Case STAT-REG-HARD-EFFECTS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/x | tolerance | 13976708874.542391 | 13976708874.5424 | 9.36E-6 | 15 | passed |
Convention
- Treatment factor contrasts; large response and small predictor units.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
109 e <- stats::lm(y ~ x + group, data = d)
110 emit("STAT-REG-HARD-EFFECTS-001", "tabelz.executor.linear_effects",
111 "linearEffectsMenuItem",
112 list(response_column = "y", factor_columns = list("group"), covariate_columns = list("x")),
113 list("/coefficients/x" = tol(coef(e)[["x"]], "rescaled effects slope", "1e-9")),
114 list("Treatment factor contrasts; large response and small predictor units."))
Extreme scale STAT-REG-HARD-GENERAL-001
Case STAT-REG-HARD-GENERAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"test_type= "III"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/x | tolerance | 13976708874.542391 | 13976708874.5424 | 9.36E-6 | 15 | passed |
Convention
- Sum-to-zero factor contrasts; large response and small predictor units.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
100 g <- stats::lm(y ~ x + group, data = d,
101 contrasts = list(group = stats::contr.sum(3)))
102 emit("STAT-REG-HARD-GENERAL-001", "tabelz.executor.general_linear",
103 "generalLinearMenuItem",
104 list(response_column = "y", factor_columns = list("group"), covariate_columns = list("x"),
105 test_type = "III"),
106 list("/coefficients/x" = tol(coef(g)[["x"]], "rescaled general-linear slope", "1e-9")),
107 list("Sum-to-zero factor contrasts; large response and small predictor units."))
Extreme scale STAT-REG-HARD-NB-001
Case STAT-REG-HARD-NB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
count= "nb_count"exposure= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 1888.5301091697263 | 1888.5301091698377 | 1.11E-10 | 13 | passed |
Convention
- MASS glm.nb theta is inverse alpha; compare only coefficient here.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
92 nb <- MASS::glm.nb(nb_count ~ x + offset(log(exposure)), data = d,
93 control = stats::glm.control(maxit = 1000, epsilon = 1e-12))
94 emit("STAT-REG-HARD-NB-001", "tabelz.analysis.negative_binomial:compute_negative_binomial",
95 "nbRegressionMenuItem",
96 list(count = "nb_count", predictors = list("x"), exposure = "exposure"),
97 list("/coefficients/1/coefficient" = tol(coef(nb)[["x"]], "rescaled NB2 slope")),
98 list("MASS glm.nb theta is inverse alpha; compare only coefficient here."))
Extreme scale STAT-REG-HARD-NOMINAL-001
Case STAT-REG-HARD-NOMINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
outcome_column= "nominal"predictors= ["x"]reference_value= "A"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | -72.643547352671533 | -72.6435479158619 | 5.63E-7 | 8 | passed |
Convention
- R nnet B-versus-A log relative-risk slope; reference category A.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
76 n <- nnet::multinom(nom ~ x, data = core, trace = FALSE, maxit = 1000, reltol = 1e-15)
77 emit("STAT-REG-HARD-NOMINAL-001",
78 "tabelz.analysis.nominal_logistic:compute_nominal_logistic_regression",
79 "nominalRegressionMenuItem",
80 list(outcome_column = "nominal", reference_value = "A", predictors = list("x")),
81 list("/coefficients/1/coefficient" = tol(1e4 * coef(n)["B", "x"], "REG_CORE nominal slope times 1e4 (exact rescaling)")),
82 list("R nnet B-versus-A log relative-risk slope; reference category A."))
Extreme scale STAT-REG-HARD-OLS-001
Case STAT-REG-HARD-OLS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/estimate | tolerance | 13987626254.070812 | 13987626254.070822 | 9.76E-6 | 15 | passed |
Convention
- OLS slope changes by 1e10 under the opposing x/y unit scales.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
37 fit <- stats::lm(y ~ x + z, data = d)
38 emit("STAT-REG-HARD-OLS-001", "tabelz.analysis.fit_y_by_x:compute_fits",
39 "fitYByXMenuItem", list(y_columns = list("y"), x_columns = list("x", "z")),
40 list("/responses/0/parameters/1/estimate" = tol(coef(fit)[["x"]], "x slope", "1e-9")),
41 list("OLS slope changes by 1e10 under the opposing x/y unit scales."))
Extreme scale STAT-REG-HARD-ORDINAL-001
Case STAT-REG-HARD-ORDINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
level_order= ["low", "middle", "high"]outcome_column= "ordinal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | 379.42551798623015 | 379.42564307871197 | 1.25E-4 | 6 | passed |
Convention
- MASS polr uses the same low-to-high slope sign.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
63 core <- read_dataset("REG_CORE")
64 core$ord <- ordered(core$ordinal, levels = c("low", "middle", "high"))
65 core$nom <- factor(core$nominal, levels = c("A", "B", "C"))
66 o <- MASS::polr(ord ~ x, data = core, method = "logistic", Hess = TRUE,
67 control = list(maxit = 1000, reltol = 1e-15))
68 emit("STAT-REG-HARD-ORDINAL-001",
69 "tabelz.analysis.ordinal_logistic:compute_ordinal_logistic_regression",
70 "ordinalRegressionMenuItem",
71 list(outcome_column = "ordinal", predictors = list("x"),
72 level_order = list("low", "middle", "high")),
73 list("/coefficients/0/coefficient" = tol(1e4 * coef(o)[["x"]], "REG_CORE ordered-logit slope times 1e4 (exact rescaling)")),
74 list("MASS polr uses the same low-to-high slope sign."))
Extreme scale STAT-REG-HARD-POISSON-001
Case STAT-REG-HARD-POISSON-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
count_column= "count"exposure_column= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 1851.9366689031101 | 1851.9366687670731 | 1.36E-7 | 10 | passed |
Convention
- Log exposure is an offset; x slope changes inversely with x units.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
84 p <- stats::glm(count ~ x + offset(log(exposure)), data = d, family = stats::poisson())
85 emit("STAT-REG-HARD-POISSON-001",
86 "tabelz.analysis.poisson_regression:compute_poisson_regression",
87 "poissonRegressionMenuItem",
88 list(count_column = "count", predictors = list("x"), exposure_column = "exposure"),
89 list("/coefficients/1/coefficient" = tol(coef(p)[["x"]], "rescaled Poisson slope")),
90 list("Log exposure is an offset; x slope changes inversely with x units."))
Extreme scale STAT-REG-HARD-VIF-001
Case STAT-REG-HARD-VIF-001 · status: passed
Reference
- Evidence type
- R
- Source
- R scaled-data models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_hard.R · sha256 6c8d7cf7a33ed329
- Dataset
- reference_data/datasets/REG_SCALE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.0001090211033234 | 1.0001090211033234 | 4.78E-17 | 16 | passed |
Convention
- Auxiliary R lm R-squared is unchanged by linear rescaling of x.
- R re-reads REG_SCALE; x is REG_CORE x / 10000 and y is REG_CORE y * 1000000.
- This is an extreme-unit-scale numerical challenge, not a change of statistical model.
Reference code
The lines of the reference script that produce this case's expected values.
43 vif <- 1 / (1 - summary(stats::lm(x ~ z, data = d))$r.squared)
44 emit("STAT-REG-HARD-VIF-001", "tabelz.analysis.fit_y_by_x:compute_fit_vif",
45 "fitYByXMenuItem",
46 list(y_columns = list("y"), x_columns = list("x", "z"), missing = "drop",
47 model_type = "linear", degree = 2L, interactions = FALSE, split_percent = 100L),
48 list("/0" = tol(vif, "scale-invariant VIF", "1e-9")),
49 list("Auxiliary R lm R-squared is unchanged by linear rescaling of x."))
Regression completion STAT-REG-INTERACT-GENERAL-TYPEII-001
Case STAT-REG-INTERACT-GENERAL-TYPEII-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fit
- Citation
- R stats::glm/lm and car::Anova help pages; Tabelz manual chapters 07 and 08
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_lastmile.R · sha256 512832af1db86a5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]interactions= [["group", "x"]]response_column= "y"test_type= "II"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/term_tests/0/f_statistic | tolerance | 27.266217053240048 | 27.26621705324002 | 2.83E-14 | 14 | passed |
Convention
- Manual Type II preserves marginality: group main effect is not adjusted for group:x interaction.
- R car::Anova(type=2) supplies the comparison on the same sum-coded design.
- The fit uses only the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
81 interacting <- stats::lm(y ~ group * x, data = d,
82 contrasts = list(group = stats::contr.sum(3)))
83 type2 <- car::Anova(interacting, type = 2)
84 emit("STAT-REG-INTERACT-GENERAL-TYPEII-001", general_entry,
85 "generalLinearMenuItem", "axis_coverage", "REG_CORE",
86 list(response_column = "y", factor_columns = list("group"),
87 covariate_columns = list("x"), interactions = list(list("group", "x")),
88 test_type = "II"),
89 list("/term_tests/0/f_statistic" = tol(type2["group", "F value"],
90 "Type II group effect in interaction model")),
91 list("Manual Type II preserves marginality: group main effect is not adjusted for group:x interaction.",
92 "R car::Anova(type=2) supplies the comparison on the same sum-coded design."))
Regression II invalid design STAT-REG-INVALID-ADV-DISCRIMINANT-CONFIG-001
Case STAT-REG-INVALID-ADV-DISCRIMINANT-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
bad_setting= 1model= "lda"predictors= ["x"]prior_mode= "equal"response= "class"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-DISCRIMINANT-MIN-001
Case STAT-REG-INVALID-ADV-DISCRIMINANT-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
model= "lda"predictors= ["x"]prior_mode= "equal"response= "class"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-DISCRIMINANT-SCORE-CONFIG-001
Case STAT-REG-INVALID-ADV-DISCRIMINANT-SCORE-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "lda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]]}bad_setting= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-DISCRIMINANT-SCORE-ROLE-001
Case STAT-REG-INVALID-ADV-DISCRIMINANT-SCORE-ROLE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
artifact= {"response": "class", "predictors": ["absent_predictor"], "model": "lda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Stored artifact requires a predictor absent from the table.
- Input is from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
95 lda$artifact$predictors <- list("absent_predictor")
96 emit("STAT-REG-INVALID-ADV-DISCRIMINANT-SCORE-ROLE-001",
97 "STAT-REG-DISCRIMINANT-SCORE-LDA-001", lda, "REG_DISCRIMINANT",
98 "Unknown scoring predictor", "Stored artifact requires a predictor absent from the table.")
Regression II invalid design STAT-REG-INVALID-ADV-MIXED-CONFIG-001
Case STAT-REG-INVALID-ADV-MIXED-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
bad_setting= 1estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-MIXED-MIN-001
Case STAT-REG-INVALID-ADV-MIXED-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-MIXED-STRUCT-CONFIG-001
Case STAT-REG-INVALID-ADV-MIXED-STRUCT-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
bad_setting= 1estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"model_mode= "random_slope"random_slope_column= "age"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-MIXED-STRUCT-MIN-001
Case STAT-REG-INVALID-ADV-MIXED-STRUCT-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"model_mode= "random_slope"random_slope_column= "age"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-NONLINEAR-CONFIG-001
Case STAT-REG-INVALID-ADV-NONLINEAR-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_DECAY.json
Settings compared
bad_setting= 1curve= "exponential_decay"parameters= [{"name": "a", "start": 4, "lower": 0, "upper": 10}, {"name": "k", "start": 0.8, "lower": 0.01, "upper": 3}, {"name": "c", "start": 1, "lower": 0, "upper": 5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-NONLINEAR-MIN-001
Case STAT-REG-INVALID-ADV-NONLINEAR-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
curve= "exponential_decay"parameters= [{"name": "a", "start": 4, "lower": 0, "upper": 10}, {"name": "k", "start": 0.8, "lower": 0.01, "upper": 3}, {"name": "c", "start": 1, "lower": 0, "upper": 5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-PANEL-CONFIG-001
Case STAT-REG-INVALID-ADV-PANEL-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
bad_setting= 1entity_column= "subject"predictor_columns= ["age"]response_column= "distance"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-PANEL-MIN-001
Case STAT-REG-INVALID-ADV-PANEL-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
entity_column= "subject"predictor_columns= ["age"]response_column= "distance"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-PLS-CONFIG-001
Case STAT-REG-INVALID-ADV-PLS-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_PLS.json
Settings compared
bad_setting= 1cv_folds= 3predictors= ["x"]response= "y"scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-PLS-MIN-001
Case STAT-REG-INVALID-ADV-PLS-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
cv_folds= 3predictors= ["x"]response= "y"scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-PLS-SCORE-CONFIG-001
Case STAT-REG-INVALID-ADV-PLS-SCORE-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_PLS.json
Settings compared
artifact= {"response": "y", "predictors": ["x"], "imputation": "drop", "scale": false, "component_count": 1, "imputation_values": [null], "x_means": [15.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}bad_setting= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-PLS-SCORE-ROLE-001
Case STAT-REG-INVALID-ADV-PLS-SCORE-ROLE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_PLS.json
Settings compared
artifact= {"response": "y", "predictors": ["absent_predictor"], "imputation": "drop", "scale": false, "component_count": 1, "imputation_values": [null], "x_means": [15.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Stored artifact requires a predictor absent from the table.
- Input is from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
100 pls$artifact$predictors <- list("absent_predictor")
101 emit("STAT-REG-INVALID-ADV-PLS-SCORE-ROLE-001", "STAT-REG-PLS-SCORE-001",
102 pls, "REG_PLS", "Unknown scoring predictor",
103 "Stored artifact requires a predictor absent from the table.")
Regression II invalid design STAT-REG-INVALID-ADV-SELECTION-CONFIG-001
Case STAT-REG-INVALID-ADV-SELECTION-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
bad_setting= 1candidate_predictors= ["age"]response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-SELECTION-MIN-001
Case STAT-REG-INVALID-ADV-SELECTION-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_TWO.json
Settings compared
candidate_predictors= ["age"]response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-TREE-CLASS-CONFIG-001
Case STAT-REG-INVALID-ADV-TREE-CLASS-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
bad_setting= 1cv_folds= 2max_depth= 1min_samples_leaf= 1numeric_predictors= ["x"]positive_class= "B"response= "class"split_assignment= {"train_row_ids": ["STAT-REG-TREE-CLASS-001:0", "STAT-REG-TREE-CLASS-001:1", "STAT-REG-TREE-CLASS-001:12", "STAT-REG-TREE-CLASS-001:13", "STAT-REG-TREE-CLASS-001:14", "STAT-REG-TREE-CLASS-001:15", "STAT-REG-TREE-CLASS-001:16", "STAT-REG-TREE-CLASS-001:17", "STAT-REG-TREE-CLASS-001:20", "STAT-REG-TREE-CLASS-001:21", "STAT-REG-TREE-CLASS-001:22", "STAT-REG-TREE-CLASS-001:23", "STAT-REG-TREE-CLASS-001:24", "STAT-REG-TREE-CLASS-001:25", "STAT-REG-TREE-CLASS-001:28", "STAT-REG-TREE-CLASS-001:29", "STAT-REG-TREE-CLASS-001:30", "STAT-REG-TREE-CLASS-001:31", "STAT-REG-TREE-CLASS-001:32", "STAT-REG-TREE-CLASS-001:33", "STAT-REG-TREE-CLASS-001:36", "STAT-REG-TREE-CLASS-001:37", "STAT-REG-TREE-CLASS-001:38", "STAT-REG-TREE-CLASS-001:39", "STAT-REG-TREE-CLASS-001:4", "STAT-REG-TREE-CLASS-001:5", "STAT-REG-TREE-CLASS-001:6", "STAT-REG-TREE-CLASS-001:7", "STAT-REG-TREE-CLASS-001:8", "STAT-REG-TREE-CLASS-001:9"], "test_row_ids": ["STAT-REG-TREE-CLASS-001:10", "STAT-REG-TREE-CLASS-001:11", "STAT-REG-TREE-CLASS-001:18", "STAT-REG-TREE-CLASS-001:19", "STAT-REG-TREE-CLASS-001:2", "STAT-REG-TREE-CLASS-001:26", "STAT-REG-TREE-CLASS-001:27", "STAT-REG-TREE-CLASS-001:3", "STAT-REG-TREE-CLASS-001:34", "STAT-REG-TREE-CLASS-001:35"], "test_fraction": 0.25, "seed": 0}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-TREE-CLASS-MIN-001
Case STAT-REG-INVALID-ADV-TREE-CLASS-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
cv_folds= 2max_depth= 1min_samples_leaf= 1numeric_predictors= ["x"]positive_class= "B"response= "class"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-TREE-REG-CONFIG-001
Case STAT-REG-INVALID-ADV-TREE-REG-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
bad_setting= 1cv_folds= 2depth_grid= [1]max_depth= 1min_leaf_grid= [1]numeric_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-TREE-REG-MIN-001
Case STAT-REG-INVALID-ADV-TREE-REG-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
cv_folds= 2depth_grid= [1]max_depth= 1min_leaf_grid= [1]numeric_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-TREE-SCORE-CLASS-CONFIG-001
Case STAT-REG-INVALID-ADV-TREE-SCORE-CLASS-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "class_order": ["A", "B"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "class_probabilities": [[0.5, 0.5], [1, 0], [0, 1]], "n_node_samples": [40, 20, 20], "encoding": {"numeric_predictors": ["x"], "categorical_predictors": [], "categorical_levels": [], "feature_names": ["x"]}}bad_setting= 1row_ids= ["STAT-REG-TREE-SCORE-CLASS-001:0", "STAT-REG-TREE-SCORE-CLASS-001:1", "STAT-REG-TREE-SCORE-CLASS-001:2", "STAT-REG-TREE-SCORE-CLASS-001:3", "STAT-REG-TREE-SCORE-CLASS-001:4", "STAT-REG-TREE-SCORE-CLASS-001:5", "STAT-REG-TREE-SCORE-CLASS-001:6", "STAT-REG-TREE-SCORE-CLASS-001:7", "STAT-REG-TREE-SCORE-CLASS-001:8", "STAT-REG-TREE-SCORE-CLASS-001:9", "STAT-REG-TREE-SCORE-CLASS-001:10", "STAT-REG-TREE-SCORE-CLASS-001:11", "STAT-REG-TREE-SCORE-CLASS-001:12", "STAT-REG-TREE-SCORE-CLASS-001:13", "STAT-REG-TREE-SCORE-CLASS-001:14", "STAT-REG-TREE-SCORE-CLASS-001:15", "STAT-REG-TREE-SCORE-CLASS-001:16", "STAT-REG-TREE-SCORE-CLASS-001:17", "STAT-REG-TREE-SCORE-CLASS-001:18", "STAT-REG-TREE-SCORE-CLASS-001:19", "STAT-REG-TREE-SCORE-CLASS-001:20", "STAT-REG-TREE-SCORE-CLASS-001:21", "STAT-REG-TREE-SCORE-CLASS-001:22", "STAT-REG-TREE-SCORE-CLASS-001:23", "STAT-REG-TREE-SCORE-CLASS-001:24", "STAT-REG-TREE-SCORE-CLASS-001:25", "STAT-REG-TREE-SCORE-CLASS-001:26", "STAT-REG-TREE-SCORE-CLASS-001:27", "STAT-REG-TREE-SCORE-CLASS-001:28", "STAT-REG-TREE-SCORE-CLASS-001:29", "STAT-REG-TREE-SCORE-CLASS-001:30", "STAT-REG-TREE-SCORE-CLASS-001:31", "STAT-REG-TREE-SCORE-CLASS-001:32", "STAT-REG-TREE-SCORE-CLASS-001:33", "STAT-REG-TREE-SCORE-CLASS-001:34", "STAT-REG-TREE-SCORE-CLASS-001:35", "STAT-REG-TREE-SCORE-CLASS-001:36", "STAT-REG-TREE-SCORE-CLASS-001:37", "STAT-REG-TREE-SCORE-CLASS-001:38", "STAT-REG-TREE-SCORE-CLASS-001:39"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-TREE-SCORE-CLASS-ROLE-001
Case STAT-REG-INVALID-ADV-TREE-SCORE-CLASS-ROLE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "class_order": ["A", "B"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "class_probabilities": [[0.5, 0.5], [1, 0], [0, 1]], "n_node_samples": [40, 20, 20], "encoding": {"numeric_predictors": ["x"], "categorical_predictors": [], "categorical_levels": [], "feature_names": ["x"]}}row_ids= ["STAT-REG-TREE-SCORE-CLASS-001:0", "STAT-REG-TREE-SCORE-CLASS-001:1", "STAT-REG-TREE-SCORE-CLASS-001:2", "STAT-REG-TREE-SCORE-CLASS-001:3", "STAT-REG-TREE-SCORE-CLASS-001:4", "STAT-REG-TREE-SCORE-CLASS-001:5", "STAT-REG-TREE-SCORE-CLASS-001:6", "STAT-REG-TREE-SCORE-CLASS-001:7", "STAT-REG-TREE-SCORE-CLASS-001:8", "STAT-REG-TREE-SCORE-CLASS-001:9", "STAT-REG-TREE-SCORE-CLASS-001:10", "STAT-REG-TREE-SCORE-CLASS-001:11", "STAT-REG-TREE-SCORE-CLASS-001:12", "STAT-REG-TREE-SCORE-CLASS-001:13", "STAT-REG-TREE-SCORE-CLASS-001:14", "STAT-REG-TREE-SCORE-CLASS-001:15", "STAT-REG-TREE-SCORE-CLASS-001:16", "STAT-REG-TREE-SCORE-CLASS-001:17", "STAT-REG-TREE-SCORE-CLASS-001:18", "STAT-REG-TREE-SCORE-CLASS-001:19", "STAT-REG-TREE-SCORE-CLASS-001:20", "STAT-REG-TREE-SCORE-CLASS-001:21", "STAT-REG-TREE-SCORE-CLASS-001:22", "STAT-REG-TREE-SCORE-CLASS-001:23", "STAT-REG-TREE-SCORE-CLASS-001:24", "STAT-REG-TREE-SCORE-CLASS-001:25", "STAT-REG-TREE-SCORE-CLASS-001:26", "STAT-REG-TREE-SCORE-CLASS-001:27", "STAT-REG-TREE-SCORE-CLASS-001:28", "STAT-REG-TREE-SCORE-CLASS-001:29", "STAT-REG-TREE-SCORE-CLASS-001:30", "STAT-REG-TREE-SCORE-CLASS-001:31", "STAT-REG-TREE-SCORE-CLASS-001:32", "STAT-REG-TREE-SCORE-CLASS-001:33", "STAT-REG-TREE-SCORE-CLASS-001:34", "STAT-REG-TREE-SCORE-CLASS-001:35", "STAT-REG-TREE-SCORE-CLASS-001:36", "STAT-REG-TREE-SCORE-CLASS-001:37", "STAT-REG-TREE-SCORE-CLASS-001:38", "STAT-REG-TREE-SCORE-CLASS-001:39"]score_name= "__tabelz_reserved"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Reserved internal score-column names are not user columns.
- Input is from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
105 class_op$score_name <- "__tabelz_reserved"
106 emit("STAT-REG-INVALID-ADV-TREE-SCORE-CLASS-ROLE-001",
107 "STAT-REG-TREE-SCORE-CLASS-001", class_op, "REG_TREE", "score-column",
108 "Reserved internal score-column names are not user columns.")
Regression II invalid design STAT-REG-INVALID-ADV-TREE-SCORE-REG-CONFIG-001
Case STAT-REG-INVALID-ADV-TREE-SCORE-REG-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "value": [0, -2, 2], "n_node_samples": [40, 20, 20]}bad_setting= 1row_ids= ["STAT-REG-TREE-SCORE-REG-001:0", "STAT-REG-TREE-SCORE-REG-001:1", "STAT-REG-TREE-SCORE-REG-001:2", "STAT-REG-TREE-SCORE-REG-001:3", "STAT-REG-TREE-SCORE-REG-001:4", "STAT-REG-TREE-SCORE-REG-001:5", "STAT-REG-TREE-SCORE-REG-001:6", "STAT-REG-TREE-SCORE-REG-001:7", "STAT-REG-TREE-SCORE-REG-001:8", "STAT-REG-TREE-SCORE-REG-001:9", "STAT-REG-TREE-SCORE-REG-001:10", "STAT-REG-TREE-SCORE-REG-001:11", "STAT-REG-TREE-SCORE-REG-001:12", "STAT-REG-TREE-SCORE-REG-001:13", "STAT-REG-TREE-SCORE-REG-001:14", "STAT-REG-TREE-SCORE-REG-001:15", "STAT-REG-TREE-SCORE-REG-001:16", "STAT-REG-TREE-SCORE-REG-001:17", "STAT-REG-TREE-SCORE-REG-001:18", "STAT-REG-TREE-SCORE-REG-001:19", "STAT-REG-TREE-SCORE-REG-001:20", "STAT-REG-TREE-SCORE-REG-001:21", "STAT-REG-TREE-SCORE-REG-001:22", "STAT-REG-TREE-SCORE-REG-001:23", "STAT-REG-TREE-SCORE-REG-001:24", "STAT-REG-TREE-SCORE-REG-001:25", "STAT-REG-TREE-SCORE-REG-001:26", "STAT-REG-TREE-SCORE-REG-001:27", "STAT-REG-TREE-SCORE-REG-001:28", "STAT-REG-TREE-SCORE-REG-001:29", "STAT-REG-TREE-SCORE-REG-001:30", "STAT-REG-TREE-SCORE-REG-001:31", "STAT-REG-TREE-SCORE-REG-001:32", "STAT-REG-TREE-SCORE-REG-001:33", "STAT-REG-TREE-SCORE-REG-001:34", "STAT-REG-TREE-SCORE-REG-001:35", "STAT-REG-TREE-SCORE-REG-001:36", "STAT-REG-TREE-SCORE-REG-001:37", "STAT-REG-TREE-SCORE-REG-001:38"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-TREE-SCORE-REG-ROLE-001
Case STAT-REG-INVALID-ADV-TREE-SCORE-REG-ROLE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "value": [0, -2, 2], "n_node_samples": [40, 20, 20]}row_ids= ["STAT-REG-TREE-SCORE-REG-001:0", "STAT-REG-TREE-SCORE-REG-001:1", "STAT-REG-TREE-SCORE-REG-001:2", "STAT-REG-TREE-SCORE-REG-001:3", "STAT-REG-TREE-SCORE-REG-001:4", "STAT-REG-TREE-SCORE-REG-001:5", "STAT-REG-TREE-SCORE-REG-001:6", "STAT-REG-TREE-SCORE-REG-001:7", "STAT-REG-TREE-SCORE-REG-001:8", "STAT-REG-TREE-SCORE-REG-001:9", "STAT-REG-TREE-SCORE-REG-001:10", "STAT-REG-TREE-SCORE-REG-001:11", "STAT-REG-TREE-SCORE-REG-001:12", "STAT-REG-TREE-SCORE-REG-001:13", "STAT-REG-TREE-SCORE-REG-001:14", "STAT-REG-TREE-SCORE-REG-001:15", "STAT-REG-TREE-SCORE-REG-001:16", "STAT-REG-TREE-SCORE-REG-001:17", "STAT-REG-TREE-SCORE-REG-001:18", "STAT-REG-TREE-SCORE-REG-001:19", "STAT-REG-TREE-SCORE-REG-001:20", "STAT-REG-TREE-SCORE-REG-001:21", "STAT-REG-TREE-SCORE-REG-001:22", "STAT-REG-TREE-SCORE-REG-001:23", "STAT-REG-TREE-SCORE-REG-001:24", "STAT-REG-TREE-SCORE-REG-001:25", "STAT-REG-TREE-SCORE-REG-001:26", "STAT-REG-TREE-SCORE-REG-001:27", "STAT-REG-TREE-SCORE-REG-001:28", "STAT-REG-TREE-SCORE-REG-001:29", "STAT-REG-TREE-SCORE-REG-001:30", "STAT-REG-TREE-SCORE-REG-001:31", "STAT-REG-TREE-SCORE-REG-001:32", "STAT-REG-TREE-SCORE-REG-001:33", "STAT-REG-TREE-SCORE-REG-001:34", "STAT-REG-TREE-SCORE-REG-001:35", "STAT-REG-TREE-SCORE-REG-001:36", "STAT-REG-TREE-SCORE-REG-001:37", "STAT-REG-TREE-SCORE-REG-001:38"]score_name= "__tabelz_reserved"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Reserved internal score-column names are not user columns.
- Input is from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
110 reg_op$score_name <- "__tabelz_reserved"
111 emit("STAT-REG-INVALID-ADV-TREE-SCORE-REG-ROLE-001",
112 "STAT-REG-TREE-SCORE-REG-001", reg_op, "REG_TREE", "score-column",
113 "Reserved internal score-column names are not user columns.")
Regression II invalid design STAT-REG-INVALID-ADV-VALIDATED-CONFIG-001
Case STAT-REG-INVALID-ADV-VALIDATED-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
algorithm= "ols"bad_setting= 1imputation= "drop"numeric_predictors= ["age"]response= "distance"seed= 0test_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- An unknown setting must not be silently ignored.
- Input is from the exported CSV.
Reference code
Regression II invalid design STAT-REG-INVALID-ADV-VALIDATED-MIN-001
Case STAT-REG-INVALID-ADV-VALIDATED-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual input/design condition
- Citation
- Tabelz manual chapters for mixed, panel, nonlinear, validated and tree regression
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_invalid.R · sha256 9a17aa6da915a401
- Dataset
- reference_data/datasets/REG_ADV_ONE.json
Settings compared
algorithm= "ols"imputation= "drop"numeric_predictors= ["age"]response= "distance"seed= 0test_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One complete row has insufficient independent observations for the model.
- Input is from the exported CSV.
Reference code
Invalid design: STAT-REG-INVALID-BINARY-CONFIG-001
Case STAT-REG-INVALID-BINARY-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]threshold= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Manual: classification threshold is strictly between zero and one.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
84 emit("STAT-REG-INVALID-BINARY-CONFIG-001", binary, "logisticRegressionMenuItem", "REG_CORE",
85 list(outcome_column = "binary", event_value = "event", predictors = list("x"), threshold = 1),
86 "ValueError", "threshold",
87 list("Manual: classification threshold is strictly between zero and one."))
Invalid design: STAT-REG-INVALID-BINARY-MIN-001
Case STAT-REG-INVALID-BINARY-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_ONE.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A one-row population cannot contain two observed outcome categories.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
80 emit("STAT-REG-INVALID-BINARY-MIN-001", binary, "logisticRegressionMenuItem", "REG_ONE",
81 list(outcome_column = "binary", event_value = "event", predictors = list("x")),
82 "ValueError", "exactly two",
83 list("A one-row population cannot contain two observed outcome categories."))
Invalid design: STAT-REG-INVALID-EFFECTS-CONFIG-001
Case STAT-REG-INVALID-EFFECTS-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 1covariate_columns= ["x"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Confidence level one violates the strict linear-effects configuration bound.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
140 emit("STAT-REG-INVALID-EFFECTS-CONFIG-001", effects, "linearEffectsMenuItem", "REG_CORE",
141 list(response_column = "y", covariate_columns = list("x"), confidence_level = 1),
142 "ValidationError", "confidence_level",
143 list("Confidence level one violates the strict linear-effects configuration bound."))
Invalid design: STAT-REG-INVALID-EFFECTS-MIN-001
Case STAT-REG-INVALID-EFFECTS-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_ONE.json
Settings compared
covariate_columns= ["x"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The manual requires positive residual df; one row is below even the two-observation gate.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
136 emit("STAT-REG-INVALID-EFFECTS-MIN-001", effects, "linearEffectsMenuItem", "REG_ONE",
137 list(response_column = "y", covariate_columns = list("x")),
138 "LinearEffectsExecutionError", "at least two",
139 list("The manual requires positive residual df; one row is below even the two-observation gate."))
Invalid design: STAT-REG-INVALID-GENERAL-CONFIG-001
Case STAT-REG-INVALID-GENERAL-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 1covariate_columns= ["x"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Confidence level one violates the strict general-linear configuration bound.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
131 emit("STAT-REG-INVALID-GENERAL-CONFIG-001", general, "generalLinearMenuItem", "REG_CORE",
132 list(response_column = "y", covariate_columns = list("x"), confidence_level = 1),
133 "ValidationError", "confidence_level",
134 list("Confidence level one violates the strict general-linear configuration bound."))
Invalid design: STAT-REG-INVALID-GENERAL-MIN-001
Case STAT-REG-INVALID-GENERAL-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_ONE.json
Settings compared
covariate_columns= ["x"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The manual requires positive residual df; one row is below even the two-observation gate.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
127 emit("STAT-REG-INVALID-GENERAL-MIN-001", general, "generalLinearMenuItem", "REG_ONE",
128 list(response_column = "y", covariate_columns = list("x")),
129 "GeneralLinearExecutionError", "at least two",
130 list("The manual requires positive residual df; one row is below even the two-observation gate."))
Invalid design: STAT-REG-INVALID-NB-CONFIG-001
Case STAT-REG-INVALID-NB-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 1count= "nb_count"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Confidence level one violates the strict NB2 configuration bound.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
122 emit("STAT-REG-INVALID-NB-CONFIG-001", nb, "nbRegressionMenuItem", "REG_CORE",
123 list(count = "nb_count", predictors = list("x"), confidence_level = 1),
124 "ValueError", "confidence_level",
125 list("Confidence level one violates the strict NB2 configuration bound."))
Invalid design: STAT-REG-INVALID-NB-MIN-001
Case STAT-REG-INVALID-NB-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_TWO.json
Settings compared
count= "nb_count"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Two rows cannot identify NB2 intercept, slope and dispersion.
- Until 2026-09-25 this case used REG_ONE, where a constant response is refused first.
- REG_TWO is two exported source rows whose x and counts vary: no more rows than coefficients.
Reference code
The lines of the reference script that produce this case's expected values.
117 emit("STAT-REG-INVALID-NB-MIN-001", nb, "nbRegressionMenuItem", "REG_TWO",
118 list(count = "nb_count", predictors = list("x")),
119 "ValueError", "More complete rows",
120 list("Two rows cannot identify NB2 intercept, slope and dispersion.",
121 "Until 2026-09-25 this case used REG_ONE, where a constant response is refused first."))
Invalid design: STAT-REG-INVALID-NOMINAL-CONFIG-001
Case STAT-REG-INVALID-NOMINAL-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 1outcome_column= "nominal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Confidence level one lies outside the supported half-open interval.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
102 emit("STAT-REG-INVALID-NOMINAL-CONFIG-001", nominal, "nominalRegressionMenuItem", "REG_CORE",
103 list(outcome_column = "nominal", predictors = list("x"), confidence_level = 1),
104 "ValueError", "Confidence level",
105 list("Confidence level one lies outside the supported half-open interval."))
Invalid design: STAT-REG-INVALID-NOMINAL-MIN-001
Case STAT-REG-INVALID-NOMINAL-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_ONE.json
Settings compared
outcome_column= "nominal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A one-row population cannot supply three nominal categories.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
98 emit("STAT-REG-INVALID-NOMINAL-MIN-001", nominal, "nominalRegressionMenuItem", "REG_ONE",
99 list(outcome_column = "nominal", predictors = list("x")),
100 "ValueError", "three",
101 list("A one-row population cannot supply three nominal categories."))
Invalid design: STAT-REG-INVALID-OLS-CONFIG-001
Case STAT-REG-INVALID-OLS-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
alpha_level= 2x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A significance level of 2 lies outside the open unit interval.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
63 emit("STAT-REG-INVALID-OLS-CONFIG-001", fit, fit_menu, "REG_CORE",
64 list(y_columns = list("y"), x_columns = list("x"), alpha_level = 2),
65 "ValueError", "alpha level",
66 list("A significance level of 2 lies outside the open unit interval."))
Invalid design: STAT-REG-INVALID-OLS-MIN-001
Case STAT-REG-INVALID-OLS-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_ONE.json
Settings compared
x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One source row cannot supply positive residual degrees of freedom for intercept and slope.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
60 emit("STAT-REG-INVALID-OLS-MIN-001", fit, fit_menu, "REG_ONE",
61 list(y_columns = list("y"), x_columns = list("x")), "ValueError", "row",
62 list("One source row cannot supply positive residual degrees of freedom for intercept and slope."))
Invalid design: STAT-REG-INVALID-ORDINAL-CONFIG-001
Case STAT-REG-INVALID-ORDINAL-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 1outcome_column= "ordinal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Confidence level one lies outside the supported half-open interval.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
93 emit("STAT-REG-INVALID-ORDINAL-CONFIG-001", ordinal, "ordinalRegressionMenuItem", "REG_CORE",
94 list(outcome_column = "ordinal", predictors = list("x"), confidence_level = 1),
95 "ValueError", "Confidence level",
96 list("Confidence level one lies outside the supported half-open interval."))
Invalid design: STAT-REG-INVALID-ORDINAL-MIN-001
Case STAT-REG-INVALID-ORDINAL-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_ONE.json
Settings compared
outcome_column= "ordinal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A one-row population cannot supply three ordered outcome levels.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
89 emit("STAT-REG-INVALID-ORDINAL-MIN-001", ordinal, "ordinalRegressionMenuItem", "REG_ONE",
90 list(outcome_column = "ordinal", predictors = list("x")),
91 "ValueError", "three",
92 list("A one-row population cannot supply three ordered outcome levels."))
Invalid design: STAT-REG-INVALID-POISSON-CONFIG-001
Case STAT-REG-INVALID-POISSON-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 1count_column= "count"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Confidence level one lies outside the supported half-open interval.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
112 emit("STAT-REG-INVALID-POISSON-CONFIG-001", poisson, "poissonRegressionMenuItem", "REG_CORE",
113 list(count_column = "count", predictors = list("x"), confidence_level = 1),
114 "ValueError", "Confidence level",
115 list("Confidence level one lies outside the supported half-open interval."))
Invalid design: STAT-REG-INVALID-POISSON-MIN-001
Case STAT-REG-INVALID-POISSON-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_TWO.json
Settings compared
count_column= "count"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Two rows cannot fit an intercept and a predictor with positive residual degrees of freedom.
- Until 2026-09-25 this case used REG_ONE, where a constant predictor is refused first.
- REG_TWO is two exported source rows whose x and counts vary: no more rows than coefficients.
Reference code
The lines of the reference script that produce this case's expected values.
107 emit("STAT-REG-INVALID-POISSON-MIN-001", poisson, "poissonRegressionMenuItem", "REG_TWO",
108 list(count_column = "count", predictors = list("x")),
109 "ValueError", "More complete rows",
110 list("Two rows cannot fit an intercept and a predictor with positive residual degrees of freedom.",
111 "Until 2026-09-25 this case used REG_ONE, where a constant predictor is refused first."))
Invalid design: STAT-REG-INVALID-VIF-CONFIG-001
Case STAT-REG-INVALID-VIF-CONFIG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
degree= 2interactions= falsemissing= "bad"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A nonexistent missing-value strategy is not an estimator.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
74 vif_invalid <- vif_config
75 vif_invalid$missing <- "bad"
76 emit("STAT-REG-INVALID-VIF-CONFIG-001", vif, fit_menu, "REG_CORE",
77 vif_invalid, "ValueError", "missing",
78 list("A nonexistent missing-value strategy is not an estimator."))
Invalid design: STAT-REG-INVALID-VIF-MIN-001
Case STAT-REG-INVALID-VIF-MIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Manual design condition
- Citation
- Tabelz user manual, chapters/07-models-and-tests.tex, 07-linear-effects.tex and 08-general-linear.tex
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_invalid.R · sha256 16490144367b4b31
- Dataset
- reference_data/datasets/REG_ONE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- One row cannot estimate the auxiliary regression for a VIF.
- REG_ONE is a single exported source row: below the model's residual-df minimum.
Reference code
The lines of the reference script that produce this case's expected values.
68 vif_config <- list(y_columns = list("y"), x_columns = list("x", "z"),
69 missing = "drop", model_type = "linear", degree = 2L,
70 interactions = FALSE, split_percent = 100L)
71 emit("STAT-REG-INVALID-VIF-MIN-001", vif, fit_menu, "REG_ONE",
72 vif_config, "ValueError", "row",
73 list("One row cannot estimate the auxiliary regression for a VIF."))
Nearest-neighbour classification with city-block distance
Case STAT-REG-KNN-CITYBLOCK-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- separable-cluster argument checked with FNN::knn / FNN::knn.reg
- Citation
- Cover and Hart (1967) Nearest neighbor pattern classification, IEEE Trans. Inf. Theory 13; R FNN package documentation (knn, knn.reg).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · FNN 1.1.4.1, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_nearest_neighbour.R · sha256 112a4856125b2f29
- Dataset
- reference_data/datasets/REG_KNN.json
Settings compared
distance= "cityblock"features= ["f1", "f2"]k_values= [1, 3]target= "outcome"task= "classification"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 18 | 18 | 0.00E+2 | passed | |
/validation_rows | exact | 6 | 6 | 0.00E+2 | passed | |
/test_rows | exact | 6 | 6 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/chosen_k | exact | 1 | 1 | 0.00E+2 | passed | |
/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/error_name | exact | misclassification rate | misclassification rate | passed | ||
/grid/0/k | exact | 1 | 1 | 0.00E+2 | passed | |
/grid/0/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/grid/1/k | exact | 3 | 3 | 0.00E+2 | passed | |
/grid/1/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/0/feature | exact | f1 | f1 | passed | ||
/importance/0/reduced_validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/0/change | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/1/feature | exact | f2 | f2 | passed | ||
/importance/1/change | tolerance | 0 | 0.0 | 0.00E+2 | passed |
Convention
- Analytic oracle: the two clusters are at least three times farther apart than any within-cluster spread (also on each feature alone, asserted in the generator), so for any training subset with at least three rows per cluster the 1 and 3 nearest training rows of every validation or test row lie in its own cluster; FNN::knn.cv and knn.reg confirm a zero leave-one-out error on the full data.
- City-block neighbourhoods coincide with the Euclidean ones here because the between-cluster gap dominates on each feature.
- The product's seeded identity split (test floor(0.2 n) = 6 rows, then validation floor(0.25 of 24) = 6 rows) is reproduced only in its counts; which rows are held out does not change the compared outputs.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:63-69: features are standardized with training means and SDs; Euclidean and city-block distances; a constant feature cannot contribute.
- docs/manual/chapters/90-learning-and-mixtures.tex:71-79: regression predicts the mean of the k nearest training targets, classification their majority class; read held-out test error.
Reference code
The lines of the reference script that produce this case's expected values.
117 outputs <- common("misclassification rate")
118 emit("STAT-REG-KNN-CITYBLOCK-001", "Nearest-neighbour classification with city-block distance", "axis_coverage",
119 list(target = "outcome", task = "classification", features = list("f1", "f2"),
120 distance = "cityblock", k_values = list(1L, 3L)),
121 outputs, list(separation_note, "City-block neighbourhoods coincide with the Euclidean ones here because the between-cluster gap dominates on each feature.", split_note))
Nearest-neighbour classification of separable clusters
Case STAT-REG-KNN-CLASS-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- separable-cluster argument checked with FNN::knn / FNN::knn.reg
- Citation
- Cover and Hart (1967) Nearest neighbor pattern classification, IEEE Trans. Inf. Theory 13; R FNN package documentation (knn, knn.reg).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · FNN 1.1.4.1, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_nearest_neighbour.R · sha256 112a4856125b2f29
- Dataset
- reference_data/datasets/REG_KNN.json
Settings compared
distance= "euclidean"features= ["f1", "f2"]k_values= [1, 3]target= "outcome"task= "classification"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 18 | 18 | 0.00E+2 | passed | |
/validation_rows | exact | 6 | 6 | 0.00E+2 | passed | |
/test_rows | exact | 6 | 6 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/chosen_k | exact | 1 | 1 | 0.00E+2 | passed | |
/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/error_name | exact | misclassification rate | misclassification rate | passed | ||
/grid/0/k | exact | 1 | 1 | 0.00E+2 | passed | |
/grid/0/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/grid/1/k | exact | 3 | 3 | 0.00E+2 | passed | |
/grid/1/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/0/feature | exact | f1 | f1 | passed | ||
/importance/0/reduced_validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/0/change | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/1/feature | exact | f2 | f2 | passed | ||
/importance/1/change | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/classes | sequence | ['fail', 'pass'] | ['fail', 'pass'] | passed |
Convention
- Analytic oracle: the two clusters are at least three times farther apart than any within-cluster spread (also on each feature alone, asserted in the generator), so for any training subset with at least three rows per cluster the 1 and 3 nearest training rows of every validation or test row lie in its own cluster; FNN::knn.cv and knn.reg confirm a zero leave-one-out error on the full data.
- The product's seeded identity split (test floor(0.2 n) = 6 rows, then validation floor(0.25 of 24) = 6 rows) is reproduced only in its counts; which rows are held out does not change the compared outputs.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:63-69: features are standardized with training means and SDs; Euclidean and city-block distances; a constant feature cannot contribute.
- docs/manual/chapters/90-learning-and-mixtures.tex:71-79: regression predicts the mean of the k nearest training targets, classification their majority class; read held-out test error.
Reference code
The lines of the reference script that produce this case's expected values.
109 outputs <- common("misclassification rate")
110 outputs[["/classes"]] <- list(comparison = "sequence", values = list("fail", "pass"),
111 rationale = "classes in code-point order")
112 emit("STAT-REG-KNN-CLASS-001", "Nearest-neighbour classification of separable clusters", "nominal",
113 list(target = "outcome", task = "classification", features = list("f1", "f2"),
114 distance = "euclidean", k_values = list(1L, 3L)),
115 outputs, list(separation_note, split_note))
Nearest-neighbour regression with constant within-cluster targets
Case STAT-REG-KNN-REG-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- separable-cluster argument checked with FNN::knn / FNN::knn.reg
- Citation
- Cover and Hart (1967) Nearest neighbor pattern classification, IEEE Trans. Inf. Theory 13; R FNN package documentation (knn, knn.reg).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · FNN 1.1.4.1, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_nearest_neighbour.R · sha256 112a4856125b2f29
- Dataset
- reference_data/datasets/REG_KNN.json
Settings compared
distance= "euclidean"features= ["f1", "f2"]k_values= [1, 3]target= "hours"task= "regression"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 18 | 18 | 0.00E+2 | passed | |
/validation_rows | exact | 6 | 6 | 0.00E+2 | passed | |
/test_rows | exact | 6 | 6 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/chosen_k | exact | 1 | 1 | 0.00E+2 | passed | |
/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/error_name | exact | mean squared error | mean squared error | passed | ||
/grid/0/k | exact | 1 | 1 | 0.00E+2 | passed | |
/grid/0/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/grid/1/k | exact | 3 | 3 | 0.00E+2 | passed | |
/grid/1/validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/0/feature | exact | f1 | f1 | passed | ||
/importance/0/reduced_validation_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/0/change | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/importance/1/feature | exact | f2 | f2 | passed | ||
/importance/1/change | tolerance | 0 | 0.0 | 0.00E+2 | passed |
Convention
- Analytic oracle: the two clusters are at least three times farther apart than any within-cluster spread (also on each feature alone, asserted in the generator), so for any training subset with at least three rows per cluster the 1 and 3 nearest training rows of every validation or test row lie in its own cluster; FNN::knn.cv and knn.reg confirm a zero leave-one-out error on the full data.
- Repair hours are 0 in one cluster and 6 in the other, so the mean of within-cluster neighbours reproduces the target exactly and the mean squared error is 0.
- The product's seeded identity split (test floor(0.2 n) = 6 rows, then validation floor(0.25 of 24) = 6 rows) is reproduced only in its counts; which rows are held out does not change the compared outputs.
- Expected computed from the exported CSV.
- docs/manual/chapters/90-learning-and-mixtures.tex:63-69: features are standardized with training means and SDs; Euclidean and city-block distances; a constant feature cannot contribute.
- docs/manual/chapters/90-learning-and-mixtures.tex:71-79: regression predicts the mean of the k nearest training targets, classification their majority class; read held-out test error.
Reference code
The lines of the reference script that produce this case's expected values.
123 outputs <- common("mean squared error")
124 emit("STAT-REG-KNN-REG-001", "Nearest-neighbour regression with constant within-cluster targets", "axis_coverage",
125 list(target = "hours", task = "regression", features = list("f1", "f2"),
126 distance = "euclidean", k_values = list(1L, 3L)),
127 outputs, list(separation_note, "Repair hours are 0 in one cluster and 6 in the other, so the mean of within-cluster neighbours reproduces the target exactly and the mean squared error is 0.", split_note))
STAT REG LOGLINEAR GENERAL 001
Case STAT-REG-LOGLINEAR-GENERAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients
- Citation
- R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear.R · sha256 29efcb27edfe009b
- Dataset
- reference_data/datasets/REG_LOGLINEAR_01.json
Settings compared
coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"factors= ["A", "B", "C"]sampling= "poisson"terms= ["A*B", "C"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/rank | exact | 7 | 7 | 0.00E+2 | passed | |
/fit/allowable_cells | exact | 12 | 12 | 0.00E+2 | passed | |
/fit/structural_zero_cells | exact | 0 | 0 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 15.87738684503603 | 15.877386845036021 | 8.84E-15 | 15 | passed |
/fit/pearson | tolerance | 13.443947553011958 | 13.443947553011967 | 8.53E-15 | 15 | passed |
/fit/deviance_p | tail_probability | 0.0072029998775678811 | 0.007202999877567914 | 3.29E-17 | 14 | passed |
/fit/pearson_p | tail_probability | 0.019555348895106052 | 0.019555348895106 | 5.21E-17 | 14 | passed |
/fit/log_likelihood | tolerance | -30.41969177532701 | -30.419691775326996 | 1.42E-14 | 15 | passed |
/fit/boundary | exact | False | False | passed | ||
/total | tolerance | 109 | 109.0 | 0.00E+2 | passed | |
/fit/parameters/0/term | exact | (intercept) | (intercept) | passed | ||
/fit/parameters/0/label | exact | passed | ||||
/fit/parameters/0/estimate | tolerance | 1.8597324528142605 | 1.8597324528142598 | 6.93E-16 | 15 | passed |
/fit/parameters/0/standard_error | tolerance | 0.28680003399815368 | 0.2868000339992414 | 1.09E-12 | 11 | passed |
/fit/parameters/0/z_value | tolerance | 6.484422009609081 | 6.484422009584486 | 2.46E-11 | 11 | passed |
/fit/parameters/0/p_value | tail_probability | 8.9072584526885216e-11 | 8.907258454141441e-11 | 1.45E-20 | 9 | passed |
/fit/parameters/0/lower | tolerance | 1.2976147154130162 | 1.2976147154108837 | 2.13E-12 | 11 | passed |
/fit/parameters/0/upper | tolerance | 2.4218501902155047 | 2.421850190217636 | 2.13E-12 | 12 | passed |
/fit/parameters/1/term | exact | A | A | passed | ||
/fit/parameters/1/label | exact | A=a1 | A=a1 | passed | ||
/fit/parameters/1/estimate | tolerance | -0.84729786038720323 | -0.8472978603872028 | 4.46E-16 | 15 | passed |
/fit/parameters/1/standard_error | tolerance | 0.48795003629584782 | 0.4879500364742666 | 1.78E-10 | 9 | passed |
/fit/parameters/1/z_value | tolerance | -1.7364438925330463 | -1.7364438918981153 | 6.35E-10 | 9 | passed |
/fit/parameters/1/p_value | tail_probability | 0.08248537700368487 | 0.082485377115865 | 1.12E-10 | 8 | passed |
/fit/parameters/1/lower | tolerance | -1.803662357782077 | -1.803662358131771 | 3.50E-10 | 9 | passed |
/fit/parameters/1/upper | tolerance | 0.1090666370076705 | 0.10906663735736544 | 3.50E-10 | 8 | passed |
/fit/parameters/2/term | exact | B | B | passed | ||
/fit/parameters/2/label | exact | B=b1 | B=b1 | passed | ||
/fit/parameters/2/estimate | tolerance | 0.40546510810816533 | 0.4054651081081649 | 4.46E-16 | 14 | passed |
/fit/parameters/2/standard_error | tolerance | 0.34503277967117718 | 0.34503277967117724 | 5.66E-17 | 15 | passed |
/fit/parameters/2/z_value | tolerance | 1.1751495278059705 | 1.1751495278059692 | 1.35E-15 | 14 | passed |
/fit/parameters/2/p_value | tail_probability | 0.23993489875229568 | 0.23993489875229623 | 5.53E-16 | 14 | passed |
/fit/parameters/2/lower | tolerance | -0.27078671353308553 | -0.2707867135330862 | 6.69E-16 | 14 | passed |
/fit/parameters/2/upper | tolerance | 1.0817169297494162 | 1.081716929749416 | 1.77E-16 | 15 | passed |
/fit/parameters/3/term | exact | B | B | passed | ||
/fit/parameters/3/label | exact | B=b2 | B=b2 | passed | ||
/fit/parameters/3/estimate | tolerance | 0.45198512374305799 | 0.45198512374305666 | 1.33E-15 | 14 | passed |
/fit/parameters/3/standard_error | tolerance | 0.34188172937891392 | 0.3418817293789141 | 1.70E-16 | 15 | passed |
/fit/parameters/3/z_value | tolerance | 1.3220511214921182 | 1.3220511214921136 | 4.63E-15 | 14 | passed |
/fit/parameters/3/p_value | tail_probability | 0.18615112838511008 | 0.1861511283851115 | 1.42E-15 | 14 | passed |
/fit/parameters/3/lower | tolerance | -0.21809075281188239 | -0.21809075281188428 | 1.89E-15 | 14 | passed |
/fit/parameters/3/upper | tolerance | 1.1220610002979985 | 1.1220610002979976 | 8.98E-16 | 15 | passed |
/fit/parameters/4/term | exact | C | C | passed | ||
/fit/parameters/4/label | exact | C=c1 | C=c1 | passed | ||
/fit/parameters/4/estimate | tolerance | 0.16551443847757316 | 0.16551443847757347 | 3.07E-16 | 14 | passed |
/fit/parameters/4/standard_error | tolerance | 0.1922216234981062 | 0.19222162350363425 | 5.53E-12 | 10 | passed |
/fit/parameters/4/z_value | tolerance | 0.86106045441450474 | 0.8610604543897433 | 2.48E-11 | 10 | passed |
/fit/parameters/4/p_value | tail_probability | 0.38920474791547172 | 0.38920474792910864 | 1.36E-11 | 10 | passed |
/fit/parameters/4/lower | tolerance | -0.21123302062853308 | -0.2112330206393676 | 1.08E-11 | 10 | passed |
/fit/parameters/4/upper | tolerance | 0.54226189758367938 | 0.5422618975945146 | 1.08E-11 | 10 | passed |
/fit/parameters/5/term | exact | A*B | A*B | passed | ||
/fit/parameters/5/label | exact | A=a1, B=b1 | A=a1, B=b1 | passed | ||
/fit/parameters/5/estimate | tolerance | 1.0216512475319814 | 1.021651247531981 | 4.01E-16 | 15 | passed |
/fit/parameters/5/standard_error | tolerance | 0.57071383857426061 | 0.570713838726805 | 1.53E-10 | 9 | passed |
/fit/parameters/5/z_value | tolerance | 1.7901287448789371 | 1.790128744400458 | 4.78E-10 | 9 | passed |
/fit/parameters/5/p_value | tail_probability | 0.073433216727360417 | 0.07343321680426308 | 7.69E-11 | 8 | passed |
/fit/parameters/5/lower | tolerance | -0.096927321552175316 | -0.09692732185115771 | 2.99E-10 | 8 | passed |
/fit/parameters/5/upper | tolerance | 2.140229816616138 | 2.1402298169151197 | 2.99E-10 | 9 | passed |
/fit/parameters/6/term | exact | A*B | A*B | passed | ||
/fit/parameters/6/label | exact | A=a1, B=b2 | A=a1, B=b2 | passed | ||
/fit/parameters/6/estimate | tolerance | 0.80077784475231051 | 0.8007778447523114 | 8.86E-16 | 14 | passed |
/fit/parameters/6/standard_error | tolerance | 0.57547270221506819 | 0.5754727023663513 | 1.51E-10 | 9 | passed |
/fit/parameters/6/z_value | tolerance | 1.3915131711200444 | 1.391513170754238 | 3.66E-10 | 9 | passed |
/fit/parameters/6/p_value | tail_probability | 0.16406986845363233 | 0.16406986856448014 | 1.11E-10 | 9 | passed |
/fit/parameters/6/lower | tolerance | -0.32712792567516635 | -0.32712792597167495 | 2.97E-10 | 9 | passed |
/fit/parameters/6/upper | tolerance | 1.9286836151797875 | 1.9286836154762979 | 2.97E-10 | 9 | passed |
/fit/cells/0/observed | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/fit/cells/0/structural | exact | False | False | passed | ||
/fit/cells/0/expected | tolerance | 13.53211009174313 | 13.532110091743117 | 1.26E-14 | 15 | passed |
/fit/cells/0/residual | tolerance | 1.2145620359622387 | 1.2145620359622427 | 3.96E-15 | 14 | passed |
/fit/cells/0/adjusted_residual | tolerance | 2.042779800637152 | 2.042779800654703 | 1.76E-11 | 11 | passed |
/fit/cells/0/deviance_residual | tolerance | 1.1555299875538532 | 1.1555299875538554 | 2.19E-15 | 14 | passed |
/fit/cells/1/observed | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/fit/cells/1/structural | exact | False | False | passed | ||
/fit/cells/1/expected | tolerance | 11.46788990825689 | 11.46788990825688 | 9.18E-15 | 15 | passed |
/fit/cells/1/residual | tolerance | -1.3193520789603079 | -1.3193520789603057 | 2.19E-15 | 14 | passed |
/fit/cells/1/adjusted_residual | tolerance | -2.0427798006372817 | -2.042779800654707 | 1.74E-11 | 11 | passed |
/fit/cells/1/deviance_residual | tolerance | -1.4229577050451325 | -1.42295770504513 | 2.42E-15 | 14 | passed |
/fit/cells/2/observed | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/fit/cells/2/structural | exact | False | False | passed | ||
/fit/cells/2/expected | tolerance | 11.366972477064222 | 11.366972477064222 | 4.64E-16 | 16 | passed |
/fit/cells/2/residual | tolerance | 0.18775875142033249 | 0.1877587514203325 | 2.54E-18 | 16 | passed |
/fit/cells/2/adjusted_residual | tolerance | 0.30853209510144969 | 0.30853209510357643 | 2.13E-12 | 11 | passed |
/fit/cells/2/deviance_residual | tolerance | 0.18605526985409121 | 0.1860552698540912 | 2.31E-19 | 17 | passed |
/fit/cells/3/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/3/structural | exact | False | False | passed | ||
/fit/cells/3/expected | tolerance | 9.633027522935782 | 9.633027522935777 | 5.31E-15 | 15 | passed |
/fit/cells/3/residual | tolerance | -0.20395821019809099 | -0.20395821019808932 | 1.67E-15 | 14 | passed |
/fit/cells/3/adjusted_residual | tolerance | -0.30853209510146967 | -0.308532095103576 | 2.11E-12 | 11 | passed |
/fit/cells/3/deviance_residual | tolerance | -0.20625552433777888 | -0.20625552433777888 | 3.84E-18 | 16 | passed |
/fit/cells/4/observed | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/fit/cells/4/structural | exact | False | False | passed | ||
/fit/cells/4/expected | tolerance | 3.2477064220183474 | 3.247706422018348 | 4.05E-16 | 15 | passed |
/fit/cells/4/residual | tolerance | 1.5272367808333507 | 1.5272367808333502 | 4.62E-16 | 15 | passed |
/fit/cells/4/adjusted_residual | tolerance | 2.3196863032131882 | 2.319686303146562 | 6.66E-11 | 10 | passed |
/fit/cells/4/deviance_residual | tolerance | 1.3642353550314514 | 1.3642353550314512 | 1.87E-16 | 15 | passed |
/fit/cells/5/observed | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/fit/cells/5/structural | exact | False | False | passed | ||
/fit/cells/5/expected | tolerance | 2.7522935779816509 | 2.7522935779816504 | 4.81E-16 | 15 | passed |
/fit/cells/5/residual | tolerance | -1.6590037908279929 | -1.6590037908279927 | 2.47E-16 | 15 | passed |
/fit/cells/5/adjusted_residual | tolerance | -2.3196863032133228 | -2.31968630314656 | 6.68E-11 | 10 | passed |
/fit/cells/5/deviance_residual | tolerance | -2.3461856610173251 | -2.3461856610173246 | 4.80E-16 | 15 | passed |
/fit/cells/6/observed | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/fit/cells/6/structural | exact | False | False | passed | ||
/fit/cells/6/expected | tolerance | 11.366972477064227 | 11.36697247706421 | 1.61E-14 | 14 | passed |
/fit/cells/6/residual | tolerance | -0.40545005741492363 | -0.4054500574149192 | 4.45E-15 | 13 | passed |
/fit/cells/6/adjusted_residual | tolerance | -0.66625046623356976 | -0.6662504662381553 | 4.59E-12 | 11 | passed |
/fit/cells/6/deviance_residual | tolerance | -0.4140130746840992 | -0.4140130746840938 | 5.38E-15 | 13 | passed |
/fit/cells/7/observed | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/fit/cells/7/structural | exact | False | False | passed | ||
/fit/cells/7/expected | tolerance | 9.6330275229357856 | 9.633027522935773 | 1.25E-14 | 14 | passed |
/fit/cells/7/residual | tolerance | 0.44043149738428 | 0.4404314973842843 | 4.28E-15 | 14 | passed |
/fit/cells/7/adjusted_residual | tolerance | 0.66625046623360318 | 0.666250466238163 | 4.56E-12 | 11 | passed |
/fit/cells/7/deviance_residual | tolerance | 0.43058646883332752 | 0.430586468833328 | 4.98E-16 | 14 | passed |
/fit/cells/8/observed | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/fit/cells/8/structural | exact | False | False | passed | ||
/fit/cells/8/expected | tolerance | 11.908256880733948 | 11.908256880733921 | 2.69E-14 | 14 | passed |
/fit/cells/8/residual | tolerance | -1.1325542233003489 | -1.1325542233003425 | 6.40E-15 | 14 | passed |
/fit/cells/8/adjusted_residual | tolerance | -1.8717199672159517 | -1.871719967229611 | 1.37E-11 | 11 | passed |
/fit/cells/8/deviance_residual | tolerance | -1.2049341010142423 | -1.2049341010142356 | 6.71E-15 | 14 | passed |
/fit/cells/9/observed | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/cells/9/structural | exact | False | False | passed | ||
/fit/cells/9/expected | tolerance | 10.091743119266059 | 10.091743119266036 | 2.27E-14 | 14 | passed |
/fit/cells/9/residual | tolerance | 1.2302687922093418 | 1.2302687922093505 | 8.68E-15 | 14 | passed |
/fit/cells/9/adjusted_residual | tolerance | 1.8717199672160594 | 1.871719967229631 | 1.36E-11 | 11 | passed |
/fit/cells/9/deviance_residual | tolerance | 1.1614643017133335 | 1.1614643017133395 | 5.98E-15 | 14 | passed |
/fit/cells/10/observed | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/fit/cells/10/structural | exact | False | False | passed | ||
/fit/cells/10/expected | tolerance | 7.5779816513761427 | 7.577981651376139 | 3.59E-15 | 15 | passed |
/fit/cells/10/residual | tolerance | -0.93648979085397577 | -0.9364897908539745 | 1.22E-15 | 14 | passed |
/fit/cells/10/adjusted_residual | tolerance | -1.4810944017760885 | -1.4810944017824101 | 6.32E-12 | 11 | passed |
/fit/cells/10/deviance_residual | tolerance | -0.9989361912429392 | -0.9989361912429383 | 8.91E-16 | 15 | passed |
/fit/cells/11/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/11/structural | exact | False | False | passed | ||
/fit/cells/11/expected | tolerance | 6.4220183486238502 | 6.422018348623846 | 4.40E-15 | 15 | passed |
/fit/cells/11/residual | tolerance | 1.0172883030296764 | 1.0172883030296787 | 2.25E-15 | 14 | passed |
/fit/cells/11/adjusted_residual | tolerance | 1.4810944017761802 | 1.4810944017824195 | 6.24E-12 | 11 | passed |
/fit/cells/11/deviance_residual | tolerance | 0.95859007852312006 | 0.958590078523121 | 8.88E-16 | 15 | passed |
/fit/generators/0 | exact | A*B | A*B | passed | ||
/fit/generators/1 | exact | C | C | passed | ||
/reference_levels/0/1 | exact | a2 | a2 | passed | ||
/reference_levels/1/1 | exact | b3 | b3 | passed |
Convention
- glm(n ~ A*B + C, poisson) with contr.treatment(base = last level); the sampling zero at (a1, b3, c2) stays an observation and the fit is interior.
- log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).
- Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).
- The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
35 emit <- function(id, menu, kind, config, outputs, notes) {
36 write_expected("regression", id, list(
37 schema_version = "2.0.0", case_id = id, outputs = outputs,
38 expected_error = NULL, deferred_outputs = list(), generator_run = run))
39 write_case("regression", id, list(
40 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
41 entry_point = "tabelz.analysis.loglinear:compute_loglinear",
42 menu_items = list(menu), title = gsub("-", " ", id),
43 case_kind = kind,
44 dataset = list(path = "reference_data/datasets/REG_LOGLINEAR_01.json", sha256 = ""),
45 excluded_rows = list(), configuration = config, "repeat" = 1L,
46 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
47 oracle = list(
48 oracle_class = "independent_implementation",
49 source = "R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients",
50 citation = "R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).",
51 generator = list(path = "generators/r/regression_loglinear.R", sha256 = ""),
52 independent = TRUE,
53 convention_notes = c(
54 notes,
55 "log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).",
56 "Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).",
57 "The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).",
58 "Expected computed from the exported CSV."
59 )),
60 supported = TRUE, unsupported_reason = NULL,
61 requirement_ids = list(if (menu == "loglinearLogitMenuItem") "REQ-STAT-REG-LOGLINEAR-LOGIT-001" else "REQ-STAT-REG-LOGLINEAR-GENERAL-001"),
62 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
STAT REG LOGLINEAR GENERAL 002
Case STAT-REG-LOGLINEAR-GENERAL-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients
- Citation
- R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear.R · sha256 29efcb27edfe009b
- Dataset
- reference_data/datasets/REG_LOGLINEAR_01.json
Settings compared
coding= "first"conditional_test= "off"confidence_level= 0.9count= "n"factors= ["A", "B", "C"]sampling= "multinomial"terms= ["A*B", "C"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/rank | exact | 7 | 7 | 0.00E+2 | passed | |
/fit/allowable_cells | exact | 12 | 12 | 0.00E+2 | passed | |
/fit/structural_zero_cells | exact | 0 | 0 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 15.877386845036018 | 15.877386845036025 | 6.71E-15 | 15 | passed |
/fit/pearson | tolerance | 13.443947553011959 | 13.443947553011961 | 2.20E-15 | 15 | passed |
/fit/deviance_p | tail_probability | 0.0072029998775679201 | 0.007202999877567891 | 2.95E-17 | 14 | passed |
/fit/pearson_p | tail_probability | 0.019555348895106038 | 0.019555348895106035 | 3.39E-18 | 15 | passed |
/fit/log_likelihood | tolerance | -27.154314777158675 | -27.15431477715879 | 1.13E-13 | 14 | passed |
/fit/boundary | exact | False | False | passed | ||
/total | tolerance | 109 | 109.0 | 0.00E+2 | passed | |
/fit/parameters/0/term | exact | (intercept) | (intercept) | passed | ||
/fit/parameters/0/label | exact | passed | ||||
/fit/parameters/0/estimate | tolerance | 2.6050653865447764 | 2.605065386544777 | 4.18E-16 | 15 | passed |
/fit/parameters/0/standard_error | tolerance | 0.21857456534400613 | 0.21857456534502656 | 1.02E-12 | 11 | passed |
/fit/parameters/0/z_value | tolerance | 11.918428763405128 | 11.918428763349489 | 5.56E-11 | 11 | passed |
/fit/parameters/0/p_value | tail_probability | 9.4881035478281526e-33 | 9.488103554163704e-33 | 6.34E-42 | 9 | passed |
/fit/parameters/0/lower | tolerance | 2.2455422199793467 | 2.2455422199776685 | 1.68E-12 | 12 | passed |
/fit/parameters/0/upper | tolerance | 2.9645885531102061 | 2.964588553111885 | 1.68E-12 | 12 | passed |
/fit/parameters/1/term | exact | A | A | passed | ||
/fit/parameters/1/label | exact | A=a2 | A=a2 | passed | ||
/fit/parameters/1/estimate | tolerance | -0.17435338714477838 | -0.17435338714477877 | 3.91E-16 | 14 | passed |
/fit/parameters/1/standard_error | tolerance | 0.29600514796038202 | 0.2960051479603819 | 1.11E-16 | 15 | passed |
/fit/parameters/1/z_value | tolerance | -0.58902146920807685 | -0.5890214692080784 | 1.56E-15 | 14 | passed |
/fit/parameters/1/p_value | tail_probability | 0.55584687168852265 | 0.5558468716885216 | 1.00E-15 | 14 | passed |
/fit/parameters/1/lower | tolerance | -0.66123852836371966 | -0.6612385283637201 | 4.42E-16 | 15 | passed |
/fit/parameters/1/upper | tolerance | 0.31253175407416295 | 0.31253175407416256 | 3.90E-16 | 14 | passed |
/fit/parameters/2/term | exact | B | B | passed | ||
/fit/parameters/2/label | exact | B=b2 | B=b2 | passed | ||
/fit/parameters/2/estimate | tolerance | -0.17435338714477783 | -0.17435338714477777 | 5.83E-17 | 15 | passed |
/fit/parameters/2/standard_error | tolerance | 0.29600514796038202 | 0.29600514796038196 | 5.54E-17 | 15 | passed |
/fit/parameters/2/z_value | tolerance | -0.58902146920807497 | -0.5890214692080749 | 1.15E-16 | 15 | passed |
/fit/parameters/2/p_value | tail_probability | 0.55584687168852398 | 0.555846871688524 | 2.04E-19 | 18 | passed |
/fit/parameters/2/lower | tolerance | -0.66123852836371921 | -0.6612385283637192 | 3.49E-18 | 17 | passed |
/fit/parameters/2/upper | tolerance | 0.3125317540741635 | 0.31253175407416367 | 1.70E-16 | 15 | passed |
/fit/parameters/3/term | exact | B | B | passed | ||
/fit/parameters/3/label | exact | B=b3 | B=b3 | passed | ||
/fit/parameters/3/estimate | tolerance | -1.4271163556401456 | -1.4271163556401454 | 2.16E-16 | 15 | passed |
/fit/parameters/3/standard_error | tolerance | 0.45460605637468948 | 0.45460605656619485 | 1.92E-10 | 9 | passed |
/fit/parameters/3/z_value | tolerance | -3.1392374466386483 | -3.139237445316226 | 1.32E-9 | 9 | passed |
/fit/parameters/3/p_value | tail_probability | 0.0016938813132758416 | 0.0016938813209206208 | 7.64E-12 | 8 | passed |
/fit/parameters/3/lower | tolerance | -2.1748767763021588 | -2.174876776617157 | 3.15E-10 | 9 | passed |
/fit/parameters/3/upper | tolerance | -0.67935593497813251 | -0.6793559346631337 | 3.15E-10 | 9 | passed |
/fit/parameters/4/term | exact | C | C | passed | ||
/fit/parameters/4/label | exact | C=c2 | C=c2 | passed | ||
/fit/parameters/4/estimate | tolerance | -0.16551443847757336 | -0.16551443847757405 | 6.90E-16 | 14 | passed |
/fit/parameters/4/standard_error | tolerance | 0.19222162349810618 | 0.19222162350363423 | 5.53E-12 | 10 | passed |
/fit/parameters/4/z_value | tolerance | -0.86106045441450585 | -0.8610604543897464 | 2.48E-11 | 10 | passed |
/fit/parameters/4/p_value | tail_probability | 0.38920474791547116 | 0.389204747929107 | 1.36E-11 | 10 | passed |
/fit/parameters/4/lower | tolerance | -0.48169087306693348 | -0.4816908730760272 | 9.09E-12 | 10 | passed |
/fit/parameters/4/upper | tolerance | 0.15066199611178677 | 0.15066199612087908 | 9.09E-12 | 10 | passed |
/fit/parameters/5/term | exact | A*B | A*B | passed | ||
/fit/parameters/5/label | exact | A=a2, B=b2 | A=a2, B=b2 | passed | ||
/fit/parameters/5/estimate | tolerance | 0.22087340277967132 | 0.22087340277967066 | 6.62E-16 | 14 | passed |
/fit/parameters/5/standard_error | tolerance | 0.42507956983680217 | 0.4250795698368021 | 5.20E-17 | 15 | passed |
/fit/parameters/5/z_value | tolerance | 0.51960484213454372 | 0.5196048421345422 | 1.55E-15 | 14 | passed |
/fit/parameters/5/p_value | tail_probability | 0.60333902250048821 | 0.6033390225004892 | 9.98E-16 | 14 | passed |
/fit/parameters/5/lower | tolerance | -0.47832026940936406 | -0.47832026940936495 | 8.91E-16 | 14 | passed |
/fit/parameters/5/upper | tolerance | 0.92006707496870677 | 0.9200670749687063 | 4.48E-16 | 15 | passed |
/fit/parameters/6/term | exact | A*B | A*B | passed | ||
/fit/parameters/6/label | exact | A=a2, B=b3 | A=a2, B=b3 | passed | ||
/fit/parameters/6/estimate | tolerance | 1.0216512475319821 | 1.0216512475319817 | 4.34E-16 | 15 | passed |
/fit/parameters/6/standard_error | tolerance | 0.57071383857425995 | 0.5707138387268047 | 1.53E-10 | 9 | passed |
/fit/parameters/6/z_value | tolerance | 1.7901287448789402 | 1.7901287444004603 | 4.78E-10 | 9 | passed |
/fit/parameters/6/p_value | tail_probability | 0.073433216727359918 | 0.07343321680426272 | 7.69E-11 | 8 | passed |
/fit/parameters/6/lower | tolerance | 0.082910520201713966 | 0.08291051995079934 | 2.51E-10 | 8 | passed |
/fit/parameters/6/upper | tolerance | 1.9603919748622503 | 1.960391975113164 | 2.51E-10 | 9 | passed |
/fit/cells/0/observed | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/fit/cells/0/structural | exact | False | False | passed | ||
/fit/cells/0/expected | tolerance | 13.532110091743117 | 13.532110091743123 | 5.74E-15 | 15 | passed |
/fit/cells/0/residual | tolerance | 1.2145620359622427 | 1.2145620359622409 | 1.82E-15 | 14 | passed |
/fit/cells/0/adjusted_residual | tolerance | 2.0427798006371578 | 2.0427798006546993 | 1.75E-11 | 11 | passed |
/fit/cells/0/deviance_residual | tolerance | 1.1555299875538554 | 1.1555299875538554 | 1.33E-17 | 16 | passed |
/fit/cells/1/observed | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/fit/cells/1/structural | exact | False | False | passed | ||
/fit/cells/1/expected | tolerance | 11.467889908256881 | 11.467889908256875 | 5.51E-15 | 15 | passed |
/fit/cells/1/residual | tolerance | -1.3193520789603057 | -1.3193520789603044 | 1.32E-15 | 14 | passed |
/fit/cells/1/adjusted_residual | tolerance | -2.0427798006372786 | -2.042779800654701 | 1.74E-11 | 11 | passed |
/fit/cells/1/deviance_residual | tolerance | -1.4229577050451301 | -1.4229577050451288 | 1.35E-15 | 15 | passed |
/fit/cells/2/observed | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/fit/cells/2/structural | exact | False | False | passed | ||
/fit/cells/2/expected | tolerance | 11.366972477064216 | 11.366972477064222 | 5.54E-15 | 15 | passed |
/fit/cells/2/residual | tolerance | 0.1877587514203341 | 0.1877587514203325 | 1.61E-15 | 14 | passed |
/fit/cells/2/adjusted_residual | tolerance | 0.30853209510145219 | 0.30853209510357665 | 2.12E-12 | 11 | passed |
/fit/cells/2/deviance_residual | tolerance | 0.18605526985408941 | 0.1860552698540912 | 1.80E-15 | 14 | passed |
/fit/cells/3/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/3/structural | exact | False | False | passed | ||
/fit/cells/3/expected | tolerance | 9.6330275229357767 | 9.633027522935773 | 3.57E-15 | 15 | passed |
/fit/cells/3/residual | tolerance | -0.20395821019808932 | -0.2039582101980882 | 1.11E-15 | 14 | passed |
/fit/cells/3/adjusted_residual | tolerance | -0.30853209510146717 | -0.30853209510357404 | 2.11E-12 | 11 | passed |
/fit/cells/3/deviance_residual | tolerance | -0.20625552433777888 | -0.20625552433777727 | 1.61E-15 | 14 | passed |
/fit/cells/4/observed | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/fit/cells/4/structural | exact | False | False | passed | ||
/fit/cells/4/expected | tolerance | 3.2477064220183487 | 3.247706422018351 | 2.21E-15 | 15 | passed |
/fit/cells/4/residual | tolerance | 1.5272367808333496 | 1.5272367808333478 | 1.80E-15 | 14 | passed |
/fit/cells/4/adjusted_residual | tolerance | 2.319686303213186 | 2.319686303146558 | 6.66E-11 | 10 | passed |
/fit/cells/4/deviance_residual | tolerance | 1.3642353550314505 | 1.3642353550314492 | 1.29E-15 | 15 | passed |
/fit/cells/5/observed | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/fit/cells/5/structural | exact | False | False | passed | ||
/fit/cells/5/expected | tolerance | 2.7522935779816518 | 2.7522935779816518 | 4.90E-17 | 16 | passed |
/fit/cells/5/residual | tolerance | -1.6590037908279933 | -1.6590037908279933 | 1.88E-17 | 16 | passed |
/fit/cells/5/adjusted_residual | tolerance | -2.3196863032133237 | -2.3196863031465607 | 6.68E-11 | 10 | passed |
/fit/cells/5/deviance_residual | tolerance | -2.3461856610173251 | -2.346185661017325 | 3.63E-17 | 16 | passed |
/fit/cells/6/observed | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/fit/cells/6/structural | exact | False | False | passed | ||
/fit/cells/6/expected | tolerance | 11.366972477064211 | 11.36697247706421 | 1.22E-16 | 16 | passed |
/fit/cells/6/residual | tolerance | -0.40545005741491918 | -0.4054500574149192 | 4.94E-18 | 16 | passed |
/fit/cells/6/adjusted_residual | tolerance | -0.6662504662335621 | -0.6662504662381555 | 4.59E-12 | 11 | passed |
/fit/cells/6/deviance_residual | tolerance | -0.41401307468409382 | -0.4140130746840938 | 1.93E-18 | 17 | passed |
/fit/cells/7/observed | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/fit/cells/7/structural | exact | False | False | passed | ||
/fit/cells/7/expected | tolerance | 9.6330275229357731 | 9.633027522935764 | 8.85E-15 | 15 | passed |
/fit/cells/7/residual | tolerance | 0.44043149738428428 | 0.44043149738428733 | 3.05E-15 | 14 | passed |
/fit/cells/7/adjusted_residual | tolerance | 0.66625046623360984 | 0.6662504662381674 | 4.56E-12 | 11 | passed |
/fit/cells/7/deviance_residual | tolerance | 0.43058646883332802 | 0.4305864688333322 | 4.16E-15 | 14 | passed |
/fit/cells/8/observed | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/fit/cells/8/structural | exact | False | False | passed | ||
/fit/cells/8/expected | tolerance | 11.908256880733942 | 11.908256880733932 | 1.03E-14 | 15 | passed |
/fit/cells/8/residual | tolerance | -1.1325542233003476 | -1.132554223300345 | 2.66E-15 | 14 | passed |
/fit/cells/8/adjusted_residual | tolerance | -1.8717199672159488 | -1.8717199672296165 | 1.37E-11 | 11 | passed |
/fit/cells/8/deviance_residual | tolerance | -1.2049341010142411 | -1.2049341010142378 | 3.29E-15 | 14 | passed |
/fit/cells/9/observed | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/cells/9/structural | exact | False | False | passed | ||
/fit/cells/9/expected | tolerance | 10.091743119266054 | 10.091743119266036 | 1.77E-14 | 14 | passed |
/fit/cells/9/residual | tolerance | 1.2302687922093438 | 1.2302687922093505 | 6.68E-15 | 14 | passed |
/fit/cells/9/adjusted_residual | tolerance | 1.8717199672160634 | 1.8717199672296299 | 1.36E-11 | 11 | passed |
/fit/cells/9/deviance_residual | tolerance | 1.1614643017133335 | 1.1614643017133395 | 5.98E-15 | 14 | passed |
/fit/cells/10/observed | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/fit/cells/10/structural | exact | False | False | passed | ||
/fit/cells/10/expected | tolerance | 7.5779816513761453 | 7.577981651376145 | 2.23E-17 | 17 | passed |
/fit/cells/10/residual | tolerance | -0.93648979085397654 | -0.9364897908539765 | 4.76E-18 | 17 | passed |
/fit/cells/10/adjusted_residual | tolerance | -1.4810944017760894 | -1.481094401782414 | 6.32E-12 | 11 | passed |
/fit/cells/10/deviance_residual | tolerance | -0.99893619124294053 | -0.9989361912429405 | 8.92E-20 | 19 | passed |
/fit/cells/11/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/11/structural | exact | False | False | passed | ||
/fit/cells/11/expected | tolerance | 6.4220183486238547 | 6.42201834862385 | 4.46E-15 | 15 | passed |
/fit/cells/11/residual | tolerance | 1.0172883030296744 | 1.0172883030296764 | 2.03E-15 | 14 | passed |
/fit/cells/11/adjusted_residual | tolerance | 1.4810944017761776 | 1.4810944017824157 | 6.24E-12 | 11 | passed |
/fit/cells/11/deviance_residual | tolerance | 0.95859007852311728 | 0.9585900785231201 | 2.78E-15 | 14 | passed |
/reference_levels/0/1 | exact | a1 | a1 | passed | ||
/reference_levels/1/1 | exact | b1 | b1 | passed |
Convention
- Multinomial log-likelihood = Poisson kernel - N log N + lgamma(N + 1) with N the table total; first-level reference coding.
- log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).
- Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).
- The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
199 m <- loglinear(d, n ~ A * B + C, first)
200 rows <- parameter_table(m$fit, list("A", "B", "C", c("A", "B")), first)
201 emit("STAT-REG-LOGLINEAR-GENERAL-002", "loglinearGeneralMenuItem", "axis_coverage",
202 list(factors = list("A", "B", "C"), count = "n", terms = list("A*B", "C"),
203 sampling = "multinomial", coding = "first", confidence_level = 0.90,
204 conditional_test = "off"),
205 c(fit_outputs(m$fit, rows, 0.90, multinomial_loglik(m$fit)),
206 list("/reference_levels/0/1" = exact("a1", "reference of A"),
207 "/reference_levels/1/1" = exact("b1", "reference of B"))),
208 list("Multinomial log-likelihood = Poisson kernel - N log N + lgamma(N + 1) with N the table total; first-level reference coding."))
STAT REG LOGLINEAR GENERAL 003
Case STAT-REG-LOGLINEAR-GENERAL-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients
- Citation
- R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear.R · sha256 29efcb27edfe009b
- Dataset
- reference_data/datasets/REG_LOGLINEAR_01.json
Settings compared
coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"factors= ["A", "B", "C"]fixed_margins= ["A"]sampling= "product_multinomial"terms= ["B*C"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/rank | exact | 7 | 7 | 0.00E+2 | passed | |
/fit/allowable_cells | exact | 12 | 12 | 0.00E+2 | passed | |
/fit/structural_zero_cells | exact | 0 | 0 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 17.453578200435754 | 17.453578200435757 | 3.14E-15 | 15 | passed |
/fit/pearson | tolerance | 13.952469775753521 | 13.952469775753489 | 3.22E-14 | 14 | passed |
/fit/deviance_p | tail_probability | 0.0037152598330038723 | 0.0037152598330038667 | 5.62E-18 | 14 | passed |
/fit/pearson_p | tail_probability | 0.015914169883335893 | 0.015914169883336094 | 2.01E-16 | 13 | passed |
/fit/log_likelihood | tolerance | -25.369698375754297 | -25.369698375754012 | 2.85E-13 | 13 | passed |
/fit/boundary | exact | False | False | passed | ||
/total | tolerance | 109 | 109.0 | 0.00E+2 | passed | |
/fit/parameters/0/term | exact | (intercept) | (intercept) | passed | ||
/fit/parameters/0/label | exact | passed | ||||
/fit/parameters/0/estimate | tolerance | 1.5489279629416259 | 1.5489279629416277 | 1.81E-15 | 14 | passed |
/fit/parameters/0/standard_error | tolerance | 0.34565974323070731 | 0.3456597443059114 | 1.08E-9 | 8 | passed |
/fit/parameters/0/z_value | tolerance | 4.4810771091379555 | 4.481077095199189 | 1.39E-8 | 8 | passed |
/fit/parameters/0/p_value | tail_probability | 7.4267270779119837e-06 | 7.426727563017821e-06 | 4.85E-13 | 7 | passed |
/fit/parameters/0/lower | tolerance | 0.87144731530407704 | 0.8714473131967173 | 2.11E-9 | 8 | passed |
/fit/parameters/0/upper | tolerance | 2.2264086105791749 | 2.226408612686538 | 2.11E-9 | 9 | passed |
/fit/parameters/1/term | exact | A | A | passed | ||
/fit/parameters/1/label | exact | A=a1 | A=a1 | passed | ||
/fit/parameters/1/estimate | tolerance | -0.091807549253122359 | -0.09180754925312151 | 8.47E-16 | 14 | passed |
/fit/parameters/1/standard_error | tolerance | 0.19176712142517585 | 0.1917671214778277 | 5.27E-11 | 9 | passed |
/fit/parameters/1/z_value | tolerance | -0.47874499325445652 | -0.4787449931230072 | 1.31E-10 | 9 | passed |
/fit/parameters/1/p_value | tail_probability | 0.6321200530848794 | 0.6321200531784047 | 9.35E-11 | 9 | passed |
/fit/parameters/1/lower | tolerance | -0.46766420066538628 | -0.4676642007685813 | 1.03E-10 | 9 | passed |
/fit/parameters/1/upper | tolerance | 0.28404910215914159 | 0.28404910226233826 | 1.03E-10 | 9 | passed |
/fit/parameters/2/term | exact | B | B | passed | ||
/fit/parameters/2/label | exact | B=b1 | B=b1 | passed | ||
/fit/parameters/2/estimate | tolerance | 0.69314718055994462 | 0.6931471805599455 | 8.88E-16 | 14 | passed |
/fit/parameters/2/standard_error | tolerance | 0.40824828955909276 | 0.40824829046386235 | 9.05E-10 | 8 | passed |
/fit/parameters/2/z_value | tolerance | 1.6978569127834975 | 1.6978569090206688 | 3.76E-9 | 8 | passed |
/fit/parameters/2/p_value | tail_probability | 0.089534771167423921 | 0.08953477187778673 | 7.10E-10 | 8 | passed |
/fit/parameters/2/lower | tolerance | -0.10700476372595635 | -0.10700476549927151 | 1.77E-9 | 7 | passed |
/fit/parameters/2/upper | tolerance | 1.4932991248458456 | 1.4932991266191626 | 1.77E-9 | 8 | passed |
/fit/parameters/3/term | exact | B | B | passed | ||
/fit/parameters/3/label | exact | B=b2 | B=b2 | passed | ||
/fit/parameters/3/estimate | tolerance | 0.93826963859293055 | 0.9382696385929302 | 3.28E-16 | 15 | passed |
/fit/parameters/3/standard_error | tolerance | 0.39317854880694431 | 0.39317854974639177 | 9.39E-10 | 8 | passed |
/fit/parameters/3/z_value | tolerance | 2.3863703689837692 | 2.386370363281856 | 5.70E-9 | 8 | passed |
/fit/parameters/3/p_value | tail_probability | 0.017015604998574782 | 0.017015605262425605 | 2.64E-10 | 7 | passed |
/fit/parameters/3/lower | tolerance | 0.16765384343759604 | 0.16765384159631236 | 1.84E-9 | 7 | passed |
/fit/parameters/3/upper | tolerance | 1.7088854337482651 | 1.708885435589548 | 1.84E-9 | 8 | passed |
/fit/parameters/4/term | exact | C | C | passed | ||
/fit/parameters/4/label | exact | C=c1 | C=c1 | passed | ||
/fit/parameters/4/estimate | tolerance | 0.20067069546215113 | 0.20067069546215116 | 3.07E-17 | 15 | passed |
/fit/parameters/4/standard_error | tolerance | 0.44946657415369623 | 0.4494665749754941 | 8.22E-10 | 8 | passed |
/fit/parameters/4/z_value | tolerance | 0.44646411324356078 | 0.44646411242725265 | 8.16E-10 | 8 | passed |
/fit/parameters/4/p_value | tail_probability | 0.65526202972587788 | 0.6552620303154137 | 5.90E-10 | 9 | passed |
/fit/parameters/4/lower | tolerance | -0.68026760213369486 | -0.6802676037443891 | 1.61E-9 | 8 | passed |
/fit/parameters/4/upper | tolerance | 1.0816089930579971 | 1.0816089946686915 | 1.61E-9 | 8 | passed |
/fit/parameters/5/term | exact | B*C | B*C | passed | ||
/fit/parameters/5/label | exact | B=b1, C=c1 | B=b1, C=c1 | passed | ||
/fit/parameters/5/estimate | tolerance | 0.24116205681688935 | 0.2411620568168894 | 5.30E-17 | 15 | passed |
/fit/parameters/5/standard_error | tolerance | 0.54156259338261159 | 0.5415625940646588 | 6.82E-10 | 8 | passed |
/fit/parameters/5/z_value | tolerance | 0.44530781808726111 | 0.44530781752643783 | 5.61E-10 | 8 | passed |
/fit/parameters/5/p_value | tail_probability | 0.6560973187467104 | 0.6560973191519446 | 4.05E-10 | 9 | passed |
/fit/parameters/5/lower | tolerance | -0.82028112158713906 | -0.820281122923927 | 1.34E-9 | 8 | passed |
/fit/parameters/5/upper | tolerance | 1.3026052352209176 | 1.3026052365577057 | 1.34E-9 | 8 | passed |
/fit/parameters/6/term | exact | B*C | B*C | passed | ||
/fit/parameters/6/label | exact | B=b2, C=c1 | B=b2, C=c1 | passed | ||
/fit/parameters/6/estimate | tolerance | -0.34043263783731026 | -0.34043263783730937 | 8.89E-16 | 14 | passed |
/fit/parameters/6/standard_error | tolerance | 0.5435977024887283 | 0.543597703168222 | 6.79E-10 | 8 | passed |
/fit/parameters/6/z_value | tolerance | -0.62625841919258163 | -0.6262584184097609 | 7.83E-10 | 8 | passed |
/fit/parameters/6/p_value | tail_probability | 0.53114545490915621 | 0.5311454554225341 | 5.13E-10 | 9 | passed |
/fit/parameters/6/lower | tolerance | -1.405864556793937 | -1.4058645581257192 | 1.33E-9 | 9 | passed |
/fit/parameters/6/upper | tolerance | 0.72499928111931633 | 0.7249992824511006 | 1.33E-9 | 8 | passed |
/fit/cells/0/observed | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/fit/cells/0/structural | exact | False | False | passed | ||
/fit/cells/0/expected | tolerance | 13.357798165137631 | 13.357798165137678 | 4.75E-14 | 14 | passed |
/fit/cells/0/residual | tolerance | 1.2701545853289304 | 1.2701545853289151 | 1.53E-14 | 13 | passed |
/fit/cells/0/adjusted_residual | tolerance | 2.0375259141965509 | 2.037525914388357 | 1.92E-10 | 10 | passed |
/fit/cells/0/deviance_residual | tolerance | 1.2055567757462073 | 1.2055567757461956 | 1.17E-14 | 14 | passed |
/fit/cells/1/observed | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/fit/cells/1/structural | exact | False | False | passed | ||
/fit/cells/1/expected | tolerance | 8.5871559633027505 | 8.58715596330278 | 3.02E-14 | 14 | passed |
/fit/cells/1/residual | tolerance | -0.54162029550168522 | -0.5416202955016947 | 9.44E-15 | 13 | passed |
/fit/cells/1/adjusted_residual | tolerance | -0.81971579533464922 | -0.8197157953785666 | 4.39E-11 | 10 | passed |
/fit/cells/1/deviance_residual | tolerance | -0.55973895156725872 | -0.5597389515672686 | 9.89E-15 | 13 | passed |
/fit/cells/2/observed | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/fit/cells/2/structural | exact | False | False | passed | ||
/fit/cells/2/expected | tolerance | 9.541284403669728 | 9.541284403669756 | 2.84E-14 | 14 | passed |
/fit/cells/2/residual | tolerance | 0.79598498476881785 | 0.7959849847688075 | 1.03E-14 | 13 | passed |
/fit/cells/2/adjusted_residual | tolerance | 1.21814487439985 | 1.2181448744740775 | 7.42E-11 | 10 | passed |
/fit/cells/2/deviance_residual | tolerance | 0.76501880009635215 | 0.7650188000963423 | 9.88E-15 | 13 | passed |
/fit/cells/3/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/3/structural | exact | False | False | passed | ||
/fit/cells/3/expected | tolerance | 10.972477064220193 | 10.972477064220218 | 2.51E-14 | 14 | passed |
/fit/cells/3/residual | tolerance | -0.59546963619613547 | -0.5954696361961422 | 6.77E-15 | 13 | passed |
/fit/cells/3/adjusted_residual | tolerance | -0.92704211761337618 | -0.9270421176807597 | 6.74E-11 | 10 | passed |
/fit/cells/3/deviance_residual | tolerance | -0.61479718560393504 | -0.6147971856039419 | 6.88E-15 | 13 | passed |
/fit/cells/4/observed | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/fit/cells/4/structural | exact | False | False | passed | ||
/fit/cells/4/expected | tolerance | 5.2477064220183518 | 5.247706422018365 | 1.33E-14 | 14 | passed |
/fit/cells/4/residual | tolerance | 0.32839957697629241 | 0.32839957697628613 | 6.28E-15 | 13 | passed |
/fit/cells/4/adjusted_residual | tolerance | 0.47893725557804462 | 0.47893725559243994 | 1.44E-11 | 10 | passed |
/fit/cells/4/deviance_residual | tolerance | 0.32098779566442409 | 0.32098779566441854 | 5.55E-15 | 13 | passed |
/fit/cells/5/observed | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/fit/cells/5/structural | exact | False | False | passed | ||
/fit/cells/5/expected | tolerance | 4.2935779816513788 | 4.29357798165139 | 1.16E-14 | 14 | passed |
/fit/cells/5/residual | tolerance | -2.0720950706112347 | -2.0720950706112378 | 3.07E-15 | 14 | passed |
/fit/cells/5/adjusted_residual | tolerance | -2.9915670958774569 | -2.9915670950541213 | 8.23E-10 | 9 | passed |
/fit/cells/5/deviance_residual | tolerance | -2.9303849513848443 | -2.9303849513848483 | 4.04E-15 | 14 | passed |
/fit/cells/6/observed | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/fit/cells/6/structural | exact | False | False | passed | ||
/fit/cells/6/expected | tolerance | 14.642201834862396 | 14.642201834862435 | 3.92E-14 | 14 | passed |
/fit/cells/6/residual | tolerance | -1.2131676593527723 | -1.2131676593527807 | 8.40E-15 | 14 | passed |
/fit/cells/6/adjusted_residual | tolerance | -2.0375259141934263 | -2.0375259143884064 | 1.95E-10 | 10 | passed |
/fit/cells/6/deviance_residual | tolerance | -1.2876131460937652 | -1.2876131460937752 | 1.00E-14 | 14 | passed |
/fit/cells/7/observed | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/fit/cells/7/structural | exact | False | False | passed | ||
/fit/cells/7/expected | tolerance | 9.4128440366972406 | 9.412844036697265 | 2.48E-14 | 14 | passed |
/fit/cells/7/residual | tolerance | 0.51731988668259155 | 0.5173198866825827 | 8.89E-15 | 13 | passed |
/fit/cells/7/adjusted_residual | tolerance | 0.81971579533339167 | 0.8197157953785432 | 4.52E-11 | 10 | passed |
/fit/cells/7/deviance_residual | tolerance | 0.50371710108361711 | 0.5037171010836128 | 4.33E-15 | 14 | passed |
/fit/cells/8/observed | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/fit/cells/8/structural | exact | False | False | passed | ||
/fit/cells/8/expected | tolerance | 10.458715596330274 | 10.458715596330297 | 2.29E-14 | 14 | passed |
/fit/cells/8/residual | tolerance | -0.76027221568613812 | -0.7602722156861444 | 6.33E-15 | 14 | passed |
/fit/cells/8/adjusted_residual | tolerance | -1.2181448743979761 | -1.2181448744741041 | 7.61E-11 | 10 | passed |
/fit/cells/8/deviance_residual | tolerance | -0.79342631226067029 | -0.7934263122606758 | 5.55E-15 | 14 | passed |
/fit/cells/9/observed | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/cells/9/structural | exact | False | False | passed | ||
/fit/cells/9/expected | tolerance | 12.027522935779821 | 12.027522935779837 | 1.60E-14 | 14 | passed |
/fit/cells/9/residual | tolerance | 0.56875321563526282 | 0.5687532156352578 | 5.00E-15 | 14 | passed |
/fit/cells/9/adjusted_residual | tolerance | 0.92704211761194222 | 0.9270421176807336 | 6.88E-11 | 10 | passed |
/fit/cells/9/deviance_residual | tolerance | 0.55418251309410782 | 0.554182513094103 | 4.77E-15 | 14 | passed |
/fit/cells/10/observed | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/fit/cells/10/structural | exact | False | False | passed | ||
/fit/cells/10/expected | tolerance | 5.7522935779816518 | 5.7522935779816615 | 9.72E-15 | 14 | passed |
/fit/cells/10/residual | tolerance | -0.31366555751132813 | -0.3136655575113319 | 3.77E-15 | 13 | passed |
/fit/cells/10/adjusted_residual | tolerance | -0.47893725557730971 | -0.47893725559245676 | 1.51E-11 | 10 | passed |
/fit/cells/10/deviance_residual | tolerance | -0.32090449711173696 | -0.32090449711174146 | 4.50E-15 | 13 | passed |
/fit/cells/11/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/11/structural | exact | False | False | passed | ||
/fit/cells/11/expected | tolerance | 4.7064220183486247 | 4.706422018348633 | 8.02E-15 | 14 | passed |
/fit/cells/11/residual | tolerance | 1.9791281752676089 | 1.9791281752676035 | 5.36E-15 | 14 | passed |
/fit/cells/11/adjusted_residual | tolerance | 2.9915670958728495 | 2.9915670950541053 | 8.19E-10 | 9 | passed |
/fit/cells/11/deviance_residual | tolerance | 1.7556147344448696 | 1.7556147344448652 | 4.45E-15 | 14 | passed |
/fit/generators/0 | exact | B*C | B*C | passed | ||
/fit/generators/1 | exact | A | A | passed |
Convention
- Product-multinomial: the stratum factor A enters the generating class; log-likelihood adds lgamma(n_a + 1) - n_a log n_a per stratum.
- log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).
- Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).
- The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
211 m <- loglinear(d, n ~ B * C + A, last)
212 rows <- parameter_table(m$fit, list("A", "B", "C", c("B", "C")), last)
213 emit("STAT-REG-LOGLINEAR-GENERAL-003", "loglinearGeneralMenuItem", "axis_coverage",
214 list(factors = list("A", "B", "C"), count = "n", terms = list("B*C"),
215 sampling = "product_multinomial", fixed_margins = list("A"), coding = "last",
216 confidence_level = 0.95, conditional_test = "off"),
217 c(fit_outputs(m$fit, rows, 0.95, product_multinomial_loglik(m$fit, d$A)),
218 list("/fit/generators/0" = exact("B*C", "generating term"),
219 "/fit/generators/1" = exact("A", "the fixed stratum factor"))),
220 list("Product-multinomial: the stratum factor A enters the generating class; log-likelihood adds lgamma(n_a + 1) - n_a log n_a per stratum."))
STAT REG LOGLINEAR GENERAL 004
Case STAT-REG-LOGLINEAR-GENERAL-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients
- Citation
- R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear.R · sha256 29efcb27edfe009b
- Dataset
- reference_data/datasets/REG_LOGLINEAR_01.json
Settings compared
cell_structure= "weight"coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"factors= ["A", "B", "C"]intervals= "wald_and_profile"pseudocount= truereference_levels= ["B=b2"]sampling= "poisson"terms= ["A*B", "C"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/rank | exact | 7 | 7 | 0.00E+2 | passed | |
/fit/allowable_cells | exact | 12 | 12 | 0.00E+2 | passed | |
/fit/structural_zero_cells | exact | 0 | 0 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 13.319219826720399 | 13.319219826720396 | 3.38E-15 | 15 | passed |
/fit/pearson | tolerance | 12.253836838247977 | 12.253836838247956 | 2.09E-14 | 14 | passed |
/fit/deviance_p | tail_probability | 0.020564088589509227 | 0.020564088589509276 | 4.89E-17 | 14 | passed |
/fit/pearson_p | tail_probability | 0.031470398642175004 | 0.03147039864217529 | 2.85E-16 | 14 | passed |
/fit/log_likelihood | tolerance | -30.164942828811924 | -30.164942828812016 | 9.23E-14 | 14 | passed |
/fit/boundary | exact | False | False | passed | ||
/total | tolerance | 109 | 109.0 | 0.00E+2 | passed | |
/fit/parameters/0/term | exact | (intercept) | (intercept) | passed | ||
/fit/parameters/0/label | exact | passed | ||||
/fit/parameters/0/estimate | tolerance | 2.360854001118021 | 2.3608540011180223 | 1.35E-15 | 15 | passed |
/fit/parameters/0/standard_error | tolerance | 0.23162584748674583 | 0.23162584748674758 | 1.75E-15 | 14 | passed |
/fit/parameters/0/z_value | tolerance | 10.192532598302158 | 10.192532598302087 | 7.11E-14 | 14 | passed |
/fit/parameters/0/p_value | tail_probability | 2.1411235199461188e-24 | 2.1411235199476715e-24 | 1.55E-36 | 12 | passed |
/fit/parameters/0/lower | tolerance | 1.906875682155432 | 1.9068756821554298 | 2.20E-15 | 14 | passed |
/fit/parameters/0/upper | tolerance | 2.81483232008061 | 2.814832320080615 | 4.90E-15 | 14 | passed |
/fit/parameters/1/term | exact | A | A | passed | ||
/fit/parameters/1/label | exact | A=a1 | A=a1 | passed | ||
/fit/parameters/1/estimate | tolerance | -0.044451762570833747 | -0.04445176257083411 | 3.61E-16 | 14 | passed |
/fit/parameters/1/standard_error | tolerance | 0.29821603968282906 | 0.29821603968282906 | 6.13E-19 | 17 | passed |
/fit/parameters/1/z_value | tolerance | -0.14905892593205552 | -0.14905892593205672 | 1.20E-15 | 14 | passed |
/fit/parameters/1/p_value | tail_probability | 0.88150713609353493 | 0.8815071360935339 | 1.00E-15 | 14 | passed |
/fit/parameters/1/lower | tolerance | -0.62894445996134607 | -0.6289444599613467 | 6.66E-16 | 14 | passed |
/fit/parameters/1/upper | tolerance | 0.54004093481967863 | 0.5400409348196784 | 2.21E-16 | 15 | passed |
/fit/parameters/2/term | exact | B | B | passed | ||
/fit/parameters/2/label | exact | B=b1 | B=b1 | passed | ||
/fit/parameters/2/estimate | tolerance | -0.73759894313077934 | -0.7375989431307789 | 4.45E-16 | 15 | passed |
/fit/parameters/2/standard_error | tolerance | 0.298216039682829 | 0.29821603968282895 | 5.16E-17 | 15 | passed |
/fit/parameters/2/z_value | tolerance | -2.4733711302559747 | -2.4733711302559733 | 1.37E-15 | 15 | passed |
/fit/parameters/2/p_value | tail_probability | 0.013384506658157958 | 0.013384506658158006 | 4.84E-17 | 14 | passed |
/fit/parameters/2/lower | tolerance | -1.3220916405212915 | -1.3220916405212912 | 2.55E-16 | 15 | passed |
/fit/parameters/2/upper | tolerance | -0.1531062457402671 | -0.15310624574026654 | 5.56E-16 | 14 | passed |
/fit/parameters/3/term | exact | B | B | passed | ||
/fit/parameters/3/label | exact | B=b3 | B=b3 | passed | ||
/fit/parameters/3/estimate | tolerance | -0.83290912293510433 | -0.8329091229351042 | 1.12E-16 | 15 | passed |
/fit/parameters/3/standard_error | tolerance | 0.33188089359924278 | 0.3318808935992426 | 1.70E-16 | 15 | passed |
/fit/parameters/3/z_value | tolerance | -2.5096627705868171 | -2.509662770586818 | 8.70E-16 | 15 | passed |
/fit/parameters/3/p_value | tail_probability | 0.012084650692970239 | 0.012084650692970201 | 3.81E-17 | 14 | passed |
/fit/parameters/3/lower | tolerance | -1.4833837215465899 | -1.4833837215465895 | 4.16E-16 | 15 | passed |
/fit/parameters/3/upper | tolerance | -0.18243452432361884 | -0.18243452432361895 | 1.12E-16 | 15 | passed |
/fit/parameters/4/term | exact | C | C | passed | ||
/fit/parameters/4/label | exact | C=c1 | C=c1 | passed | ||
/fit/parameters/4/estimate | tolerance | 0.1568424714929699 | 0.1568424714929702 | 3.04E-16 | 14 | passed |
/fit/parameters/4/standard_error | tolerance | 0.18707473583133441 | 0.1870747358313419 | 7.49E-15 | 13 | passed |
/fit/parameters/4/z_value | tolerance | 0.83839472388392544 | 0.8383947238838935 | 3.20E-14 | 13 | passed |
/fit/parameters/4/p_value | tail_probability | 0.40180905168823505 | 0.4018090516882531 | 1.80E-14 | 13 | passed |
/fit/parameters/4/lower | tolerance | -0.20981727315379026 | -0.20981727315380472 | 1.45E-14 | 13 | passed |
/fit/parameters/4/upper | tolerance | 0.52350221613973003 | 0.5235022161397451 | 1.51E-14 | 13 | passed |
/fit/parameters/5/term | exact | A*B | A*B | passed | ||
/fit/parameters/5/label | exact | A=a1, B=b1 | A=a1, B=b1 | passed | ||
/fit/parameters/5/estimate | tolerance | 0.90465302779394519 | 0.9046530277939471 | 1.88E-15 | 14 | passed |
/fit/parameters/5/standard_error | tolerance | 0.41575099547709382 | 0.4157509954770938 | 9.73E-19 | 17 | passed |
/fit/parameters/5/z_value | tolerance | 2.1759491561909869 | 2.175949156190992 | 4.93E-15 | 14 | passed |
/fit/parameters/5/p_value | tail_probability | 0.029559062585162627 | 0.02955906258516227 | 3.57E-16 | 13 | passed |
/fit/parameters/5/lower | tolerance | 0.089796050122166626 | 0.08979605012216829 | 1.67E-15 | 13 | passed |
/fit/parameters/5/upper | tolerance | 1.7195100054657237 | 1.7195100054657257 | 2.04E-15 | 14 | passed |
/fit/parameters/6/term | exact | A*B | A*B | passed | ||
/fit/parameters/6/label | exact | A=a1, B=b3 | A=a1, B=b3 | passed | ||
/fit/parameters/6/estimate | tolerance | -0.31222318136789851 | -0.31222318136789795 | 5.59E-16 | 14 | passed |
/fit/parameters/6/standard_error | tolerance | 0.54631183022860652 | 0.5463118302287805 | 1.74E-13 | 12 | passed |
/fit/parameters/6/z_value | tolerance | -0.5715109285428569 | -0.5715109285426738 | 1.83E-13 | 12 | passed |
/fit/parameters/6/p_value | tail_probability | 0.56765335443436948 | 0.5676533544344935 | 1.24E-13 | 12 | passed |
/fit/parameters/6/lower | tolerance | -1.3829746929441273 | -1.3829746929444682 | 3.41E-13 | 12 | passed |
/fit/parameters/6/upper | tolerance | 0.75852833020833044 | 0.7585283302086723 | 3.42E-13 | 12 | passed |
/fit/cells/0/observed | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/fit/cells/0/structural | exact | False | False | passed | ||
/fit/cells/0/expected | tolerance | 14.017391304347822 | 14.017391304347871 | 4.93E-14 | 14 | passed |
/fit/cells/0/residual | tolerance | 1.1972841430655328 | 1.1972841430655172 | 1.56E-14 | 13 | passed |
/fit/cells/0/adjusted_residual | tolerance | 2.0047588204346773 | 2.0047588204346765 | 8.42E-16 | 15 | passed |
/fit/cells/0/deviance_residual | tolerance | 1.1407209526396065 | 1.1407209526395925 | 1.40E-14 | 13 | passed |
/fit/cells/1/observed | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/fit/cells/1/structural | exact | False | False | passed | ||
/fit/cells/1/expected | tolerance | 11.982608695652164 | 11.982608695652207 | 4.29E-14 | 14 | passed |
/fit/cells/1/residual | tolerance | -1.2949563829810757 | -1.2949563829810857 | 1.00E-14 | 14 | passed |
/fit/cells/1/adjusted_residual | tolerance | -2.0047588204346702 | -2.0047588204347093 | 3.91E-14 | 13 | passed |
/fit/cells/1/deviance_residual | tolerance | -1.3917319610050651 | -1.3917319610050767 | 1.16E-14 | 14 | passed |
/fit/cells/2/observed | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/fit/cells/2/structural | exact | False | False | passed | ||
/fit/cells/2/expected | tolerance | 11.860869565217389 | 11.860869565217405 | 1.55E-14 | 14 | passed |
/fit/cells/2/residual | tolerance | 0.18558002707474522 | 0.18558002707474044 | 4.78E-15 | 13 | passed |
/fit/cells/2/adjusted_residual | tolerance | 0.30398325778930724 | 0.3039832577893023 | 4.94E-15 | 13 | passed |
/fit/cells/2/deviance_residual | tolerance | 0.18394968642875209 | 0.1839496864287394 | 1.27E-14 | 13 | passed |
/fit/cells/3/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/3/structural | exact | False | False | passed | ||
/fit/cells/3/expected | tolerance | 10.139130434782606 | 10.139130434782615 | 9.00E-15 | 15 | passed |
/fit/cells/3/residual | tolerance | -0.20071930460795151 | -0.20071930460795423 | 2.72E-15 | 13 | passed |
/fit/cells/3/adjusted_residual | tolerance | -0.30398325778930452 | -0.30398325778931157 | 7.05E-15 | 13 | passed |
/fit/cells/3/deviance_residual | tolerance | -0.20288546200272842 | -0.2028854620027279 | 5.30E-16 | 14 | passed |
/fit/cells/4/observed | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/fit/cells/4/structural | exact | False | False | passed | ||
/fit/cells/4/expected | tolerance | 3.77391304347826 | 3.7739130434782666 | 6.62E-15 | 14 | passed |
/fit/cells/4/residual | tolerance | 1.40327814105904 | 1.4032781410590354 | 4.63E-15 | 14 | passed |
/fit/cells/4/adjusted_residual | tolerance | 2.133004580360176 | 2.1330045803600823 | 9.37E-14 | 13 | passed |
/fit/cells/4/deviance_residual | tolerance | 1.2711385101924175 | 1.2711385101924144 | 3.08E-15 | 14 | passed |
/fit/cells/5/observed | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/fit/cells/5/structural | exact | False | False | passed | ||
/fit/cells/5/expected | tolerance | 3.2260869565217383 | 3.2260869565217427 | 4.41E-15 | 14 | passed |
/fit/cells/5/residual | tolerance | -1.5177549927367275 | -1.5177549927367289 | 1.37E-15 | 15 | passed |
/fit/cells/5/adjusted_residual | tolerance | -2.1330045803601738 | -2.1330045803600894 | 8.44E-14 | 13 | passed |
/fit/cells/5/deviance_residual | tolerance | -1.8941374813458887 | -1.8941374813458907 | 1.96E-15 | 14 | passed |
/fit/cells/6/observed | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/fit/cells/6/structural | exact | False | False | passed | ||
/fit/cells/6/expected | tolerance | 11.860869565217383 | 11.86086956521741 | 2.69E-14 | 14 | passed |
/fit/cells/6/residual | tolerance | -0.39514658826118826 | -0.39514658826119553 | 7.27E-15 | 13 | passed |
/fit/cells/6/adjusted_residual | tolerance | -0.64725686862620546 | -0.6472568686262236 | 1.81E-14 | 13 | passed |
/fit/cells/6/deviance_residual | tolerance | -0.40308884879702322 | -0.4030888487970304 | 7.17E-15 | 13 | passed |
/fit/cells/7/observed | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/fit/cells/7/structural | exact | False | False | passed | ||
/fit/cells/7/expected | tolerance | 10.139130434782603 | 10.13913043478262 | 1.73E-14 | 14 | passed |
/fit/cells/7/residual | tolerance | 0.42738192069584613 | 0.42738192069584013 | 6.00E-15 | 13 | passed |
/fit/cells/7/adjusted_residual | tolerance | 0.64725686862621201 | 0.6472568686262092 | 2.77E-15 | 14 | passed |
/fit/cells/7/deviance_residual | tolerance | 0.41831949090570075 | 0.4183194909056949 | 5.83E-15 | 13 | passed |
/fit/cells/8/observed | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/fit/cells/8/structural | exact | False | False | passed | ||
/fit/cells/8/expected | tolerance | 12.399999999999995 | 12.400000000000016 | 2.13E-14 | 14 | passed |
/fit/cells/8/residual | tolerance | -1.1075255767817753 | -1.1075255767817802 | 4.91E-15 | 14 | passed |
/fit/cells/8/adjusted_residual | tolerance | -1.8239786743555648 | -1.823978674355593 | 2.82E-14 | 13 | passed |
/fit/cells/8/deviance_residual | tolerance | -1.1748552017375373 | -1.1748552017375427 | 5.35E-15 | 14 | passed |
/fit/cells/9/observed | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/cells/9/structural | exact | False | False | passed | ||
/fit/cells/9/expected | tolerance | 10.599999999999996 | 10.60000000000001 | 1.43E-14 | 14 | passed |
/fit/cells/9/residual | tolerance | 1.1978754778262062 | 1.197875477826201 | 5.13E-15 | 14 | passed |
/fit/cells/9/adjusted_residual | tolerance | 1.8239786743555682 | 1.82397867435558 | 1.17E-14 | 14 | passed |
/fit/cells/9/deviance_residual | tolerance | 1.1338186808069062 | 1.1338186808069015 | 4.69E-15 | 14 | passed |
/fit/cells/10/observed | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/fit/cells/10/structural | exact | False | False | passed | ||
/fit/cells/10/expected | tolerance | 8.0869565217391273 | 8.086956521739141 | 1.42E-14 | 14 | passed |
/fit/cells/10/residual | tolerance | -0.90969660853967738 | -0.9096966085396816 | 4.21E-15 | 14 | passed |
/fit/cells/10/adjusted_residual | tolerance | -1.43699905046902 | -1.4369990504690353 | 1.53E-14 | 13 | passed |
/fit/cells/10/deviance_residual | tolerance | -0.96610818362974726 | -0.9661081836297518 | 4.56E-15 | 14 | passed |
/fit/cells/11/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/11/structural | exact | False | False | passed | ||
/fit/cells/11/expected | tolerance | 6.9130434782608647 | 6.9130434782608745 | 9.81E-15 | 14 | passed |
/fit/cells/11/residual | tolerance | 0.98390798594266637 | 0.983907985942662 | 4.33E-15 | 14 | passed |
/fit/cells/11/adjusted_residual | tolerance | 1.4369990504690247 | 1.4369990504690264 | 1.73E-15 | 14 | passed |
/fit/cells/11/deviance_residual | tolerance | 0.93050598628627557 | 0.9305059862862713 | 4.22E-15 | 14 | passed |
/fit/parameters/1/profile_lower | tolerance | -0.63438998382583967 | -0.6343899838258399 | 2.17E-16 | 15 | passed |
/fit/parameters/1/profile_upper | tolerance | 0.54293433098566402 | 0.5429343309856525 | 1.16E-14 | 13 | passed |
/fit/parameters/4/profile_lower | tolerance | -0.20908774176712683 | -0.20908774176703862 | 8.82E-14 | 12 | passed |
/fit/parameters/4/profile_upper | tolerance | 0.52629155899336044 | 0.5262915589933583 | 2.11E-15 | 14 | passed |
/reference_levels/1/1 | exact | b2 | b2 | passed |
Convention
- Counts + 0.5 in every cell (named pseudocount analysis), offset log(weight) from the cell structure, B's reference recorded as b2 (A and C keep the last level).
- Profile limits for A [A=a1] and C [C=c1]: the constrained deviance rises by chi-square(1, 0.95) = 3.841; found by uniroot on refits with the parameter fixed through the offset (manual chapters/86 lines 202-212).
- log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).
- Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).
- The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
250 out[["/reference_levels/1/1"]] <- exact("b2", "recorded reference of B")
251 emit("STAT-REG-LOGLINEAR-GENERAL-004", "loglinearGeneralMenuItem", "axis_coverage",
252 list(factors = list("A", "B", "C"), count = "n", terms = list("A*B", "C"),
253 sampling = "poisson", coding = "last", confidence_level = 0.95,
254 cell_structure = "weight", pseudocount = TRUE, reference_levels = list("B=b2"),
255 intervals = "wald_and_profile", conditional_test = "off"),
256 out,
257 list("Counts + 0.5 in every cell (named pseudocount analysis), offset log(weight) from the cell structure, B's reference recorded as b2 (A and C keep the last level).",
258 "Profile limits for A [A=a1] and C [C=c1]: the constrained deviance rises by chi-square(1, 0.95) = 3.841; found by uniroot on refits with the parameter fixed through the offset (manual chapters/86 lines 202-212)."))
STAT REG LOGLINEAR GENERAL 005
Case STAT-REG-LOGLINEAR-GENERAL-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients
- Citation
- R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear.R · sha256 29efcb27edfe009b
- Dataset
- reference_data/datasets/REG_LOGLINEAR_01.json
Settings compared
coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"factors= ["A", "B", "C"]sampling= "poisson"structural_zeros= ["A=a1; B=b3; C=c2"]terms= ["A*B", "C"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/df | exact | 4 | 4 | 0.00E+2 | passed | |
/fit/rank | exact | 7 | 7 | 0.00E+2 | passed | |
/fit/allowable_cells | exact | 11 | 11 | 0.00E+2 | passed | |
/fit/structural_zero_cells | exact | 1 | 1 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 8.2161956387376485 | 8.216195638737645 | 3.59E-15 | 15 | passed |
/fit/pearson | tolerance | 8.0148318876092404 | 8.014831887609223 | 1.78E-14 | 14 | passed |
/fit/deviance_p | tail_probability | 0.083972095550700593 | 0.08397209555070069 | 9.70E-17 | 14 | passed |
/fit/pearson_p | tail_probability | 0.091036391897424199 | 0.09103639189742484 | 6.38E-16 | 14 | passed |
/fit/log_likelihood | tolerance | -26.589096172177822 | -26.589096172177832 | 1.05E-14 | 15 | passed |
/fit/boundary | exact | False | False | passed | ||
/total | tolerance | 109 | 109.0 | 0.00E+2 | passed | |
/fit/parameters/0/term | exact | (intercept) | (intercept) | passed | ||
/fit/parameters/0/label | exact | passed | ||||
/fit/parameters/0/estimate | tolerance | 1.9163513468137685 | 1.9163513468137703 | 1.78E-15 | 15 | passed |
/fit/parameters/0/standard_error | tolerance | 0.2858668108829302 | 0.28586681088313415 | 2.04E-13 | 12 | passed |
/fit/parameters/0/z_value | tolerance | 6.7036510495741446 | 6.703651049569368 | 4.78E-12 | 12 | passed |
/fit/parameters/0/p_value | tail_probability | 2.0327535981994157e-11 | 2.0327535982658884e-11 | 6.65E-22 | 10 | passed |
/fit/parameters/0/lower | tolerance | 1.3560626931079027 | 1.3560626931075046 | 3.98E-13 | 12 | passed |
/fit/parameters/0/upper | tolerance | 2.4766400005196343 | 2.476640000520036 | 4.02E-13 | 12 | passed |
/fit/parameters/1/term | exact | A | A | passed | ||
/fit/parameters/1/label | exact | A=a1 | A=a1 | passed | ||
/fit/parameters/1/estimate | tolerance | -0.1828607857096895 | -0.182860785709689 | 5.00E-16 | 14 | passed |
/fit/parameters/1/standard_error | tolerance | 0.49724684489636439 | 0.49724684489643717 | 7.28E-14 | 12 | passed |
/fit/parameters/1/z_value | tolerance | -0.36774649771342666 | -0.36774649771337187 | 5.48E-14 | 12 | passed |
/fit/parameters/1/p_value | tail_probability | 0.71306226615420187 | 0.7130622661542427 | 4.09E-14 | 13 | passed |
/fit/parameters/1/lower | tolerance | -1.1574466931327378 | -1.1574466931328802 | 1.42E-13 | 12 | passed |
/fit/parameters/1/upper | tolerance | 0.79172512171335896 | 0.7917251217135022 | 1.43E-13 | 12 | passed |
/fit/parameters/2/term | exact | B | B | passed | ||
/fit/parameters/2/label | exact | B=b1 | B=b1 | passed | ||
/fit/parameters/2/estimate | tolerance | 0.40546510810816461 | 0.4054651081081657 | 1.11E-15 | 14 | passed |
/fit/parameters/2/standard_error | tolerance | 0.34503277967113982 | 0.3450327796711767 | 3.69E-14 | 12 | passed |
/fit/parameters/2/z_value | tolerance | 1.1751495278060957 | 1.1751495278059734 | 1.22E-13 | 12 | passed |
/fit/parameters/2/p_value | tail_probability | 0.23993489875224561 | 0.23993489875229457 | 4.90E-14 | 12 | passed |
/fit/parameters/2/lower | tolerance | -0.27078671353301298 | -0.27078671353308426 | 7.13E-14 | 12 | passed |
/fit/parameters/2/upper | tolerance | 1.0817169297493421 | 1.0817169297494158 | 7.37E-14 | 13 | passed |
/fit/parameters/3/term | exact | B | B | passed | ||
/fit/parameters/3/label | exact | B=b2 | B=b2 | passed | ||
/fit/parameters/3/estimate | tolerance | 0.45198512374305777 | 0.4519851237430578 | 5.61E-17 | 15 | passed |
/fit/parameters/3/standard_error | tolerance | 0.34188172937886852 | 0.3418817293789135 | 4.50E-14 | 12 | passed |
/fit/parameters/3/z_value | tolerance | 1.3220511214922932 | 1.3220511214921193 | 1.74E-13 | 12 | passed |
/fit/parameters/3/p_value | tail_probability | 0.18615112838505177 | 0.1861511283851096 | 5.78E-14 | 12 | passed |
/fit/parameters/3/lower | tolerance | -0.21809075281179369 | -0.2180907528118819 | 8.82E-14 | 12 | passed |
/fit/parameters/3/upper | tolerance | 1.1220610002979092 | 1.1220610002979976 | 8.84E-14 | 13 | passed |
/fit/parameters/4/term | exact | C | C | passed | ||
/fit/parameters/4/label | exact | C=c1 | C=c1 | passed | ||
/fit/parameters/4/estimate | tolerance | 0.058268908123976296 | 0.05826890812397685 | 5.55E-16 | 14 | passed |
/fit/parameters/4/standard_error | tolerance | 0.19714949791467762 | 0.19714949791541894 | 7.41E-13 | 11 | passed |
/fit/parameters/4/z_value | tolerance | 0.29555696940802723 | 0.29555696940691867 | 1.11E-12 | 11 | passed |
/fit/parameters/4/p_value | tail_probability | 0.76756843956583809 | 0.7675684395666849 | 8.47E-13 | 11 | passed |
/fit/parameters/4/lower | tolerance | -0.32813700735894624 | -0.32813700736039875 | 1.45E-12 | 11 | passed |
/fit/parameters/4/upper | tolerance | 0.44467482360689881 | 0.4446748236083524 | 1.45E-12 | 11 | passed |
/fit/parameters/5/term | exact | A*B | A*B | passed | ||
/fit/parameters/5/label | exact | A=a1, B=b1 | A=a1, B=b1 | passed | ||
/fit/parameters/5/estimate | tolerance | 0.35721417285446844 | 0.357214172854467 | 1.45E-15 | 14 | passed |
/fit/parameters/5/standard_error | tolerance | 0.57868253159847605 | 0.5786825315995886 | 1.11E-12 | 11 | passed |
/fit/parameters/5/z_value | tolerance | 0.61728867444425406 | 0.6172886744430648 | 1.19E-12 | 11 | passed |
/fit/parameters/5/p_value | tail_probability | 0.53704433571379118 | 0.5370443357145755 | 7.84E-13 | 11 | passed |
/fit/parameters/5/lower | tolerance | -0.77698274756100605 | -0.7769827475631884 | 2.18E-12 | 11 | passed |
/fit/parameters/5/upper | tolerance | 1.4914110932699429 | 1.4914110932721223 | 2.18E-12 | 11 | passed |
/fit/parameters/6/term | exact | A*B | A*B | passed | ||
/fit/parameters/6/label | exact | A=a1, B=b2 | A=a1, B=b2 | passed | ||
/fit/parameters/6/estimate | tolerance | 0.13634077007479636 | 0.1363407700747956 | 7.74E-16 | 14 | passed |
/fit/parameters/6/standard_error | tolerance | 0.58337639464840196 | 0.5833763946484759 | 7.39E-14 | 12 | passed |
/fit/parameters/6/z_value | tolerance | 0.2337097820986882 | 0.23370978209865725 | 3.09E-14 | 12 | passed |
/fit/parameters/6/p_value | tail_probability | 0.81521029303015213 | 0.8152102930301761 | 2.40E-14 | 13 | passed |
/fit/parameters/6/lower | tolerance | -1.0070559528668965 | -1.0070559528670422 | 1.46E-13 | 12 | passed |
/fit/parameters/6/upper | tolerance | 1.2797374930164891 | 1.2797374930166334 | 1.44E-13 | 12 | passed |
/fit/cells/0/observed | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/fit/cells/0/structural | exact | False | False | passed | ||
/fit/cells/0/expected | tolerance | 12.864077669902933 | 12.864077669902962 | 2.85E-14 | 14 | passed |
/fit/cells/0/residual | tolerance | 1.4319541767258182 | 1.4319541767258086 | 9.60E-15 | 14 | passed |
/fit/cells/0/adjusted_residual | tolerance | 2.3617506401292037 | 2.36175064012165 | 7.55E-12 | 11 | passed |
/fit/cells/0/deviance_residual | tolerance | 1.3497198291508559 | 1.3497198291508472 | 8.69E-15 | 14 | passed |
/fit/cells/1/observed | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/fit/cells/1/structural | exact | False | False | passed | ||
/fit/cells/1/expected | tolerance | 12.135922330097099 | 12.13592233009712 | 2.12E-14 | 14 | passed |
/fit/cells/1/residual | tolerance | -1.4742870582410657 | -1.4742870582410703 | 4.61E-15 | 14 | passed |
/fit/cells/1/adjusted_residual | tolerance | -2.3617506401313415 | -2.361750640121686 | 9.66E-12 | 11 | passed |
/fit/cells/1/deviance_residual | tolerance | -1.6025632461886226 | -1.6025632461886283 | 5.73E-15 | 14 | passed |
/fit/cells/2/observed | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/fit/cells/2/structural | exact | False | False | passed | ||
/fit/cells/2/expected | tolerance | 10.805825242718452 | 10.805825242718477 | 2.49E-14 | 14 | passed |
/fit/cells/2/residual | tolerance | 0.36327784859400969 | 0.36327784859400175 | 7.94E-15 | 13 | passed |
/fit/cells/2/adjusted_residual | tolerance | 0.58436502272415491 | 0.584365022724964 | 8.09E-13 | 11 | passed |
/fit/cells/2/deviance_residual | tolerance | 0.35687724394682319 | 0.35687724394681947 | 3.72E-15 | 13 | passed |
/fit/cells/3/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/3/structural | exact | False | False | passed | ||
/fit/cells/3/expected | tolerance | 10.194174757281552 | 10.19417475728157 | 1.73E-14 | 14 | passed |
/fit/cells/3/residual | tolerance | -0.37401743675374111 | -0.37401743675374627 | 5.16E-15 | 13 | passed |
/fit/cells/3/adjusted_residual | tolerance | -0.58436502272468205 | -0.5843650227249876 | 3.06E-13 | 12 | passed |
/fit/cells/3/deviance_residual | tolerance | -0.38170108464642338 | -0.381701084646428 | 4.61E-15 | 13 | passed |
/fit/cells/4/observed | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/fit/cells/4/structural | exact | False | False | passed | ||
/fit/cells/4/expected | tolerance | 6.0000000000000009 | 6.000000000000019 | 1.78E-14 | 14 | passed |
/fit/cells/4/residual | tolerance | 0 | -7.61454375085889e-15 | 7.61E-15 | passed | |
/fit/cells/4/deviance_residual | tolerance | 0 | -0.0 | 0.00E+2 | passed | |
/fit/cells/5/observed | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/fit/cells/5/structural | exact | True | True | passed | ||
/fit/cells/6/observed | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/fit/cells/6/structural | exact | False | False | passed | ||
/fit/cells/6/expected | tolerance | 10.805825242718452 | 10.805825242718486 | 3.38E-14 | 14 | passed |
/fit/cells/6/residual | tolerance | -0.24513871083986297 | -0.24513871083987288 | 9.91E-15 | 13 | passed |
/fit/cells/6/adjusted_residual | tolerance | -0.39432761696020646 | -0.3943276169607776 | 5.71E-13 | 11 | passed |
/fit/cells/6/deviance_residual | tolerance | -0.2482842814187553 | -0.24828428141876066 | 5.36E-15 | 13 | passed |
/fit/cells/7/observed | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/fit/cells/7/structural | exact | False | False | passed | ||
/fit/cells/7/expected | tolerance | 10.194174757281552 | 10.194174757281578 | 2.62E-14 | 14 | passed |
/fit/cells/7/residual | tolerance | 0.25238575000455798 | 0.25238575000454927 | 8.71E-15 | 13 | passed |
/fit/cells/7/adjusted_residual | tolerance | 0.39432761696055946 | 0.3943276169607463 | 1.87E-13 | 12 | passed |
/fit/cells/7/deviance_residual | tolerance | 0.24916562332056774 | 0.24916562332055658 | 1.12E-14 | 13 | passed |
/fit/cells/8/observed | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/fit/cells/8/structural | exact | False | False | passed | ||
/fit/cells/8/expected | tolerance | 11.320388349514571 | 11.320388349514596 | 2.53E-14 | 14 | passed |
/fit/cells/8/residual | tolerance | -0.98686607224095824 | -0.9868660722409646 | 6.32E-15 | 14 | passed |
/fit/cells/8/adjusted_residual | tolerance | -1.5972317390169091 | -1.597231739019233 | 2.32E-12 | 11 | passed |
/fit/cells/8/deviance_residual | tolerance | -1.0421877503663506 | -1.0421877503663575 | 6.87E-15 | 14 | passed |
/fit/cells/9/observed | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/cells/9/structural | exact | False | False | passed | ||
/fit/cells/9/expected | tolerance | 10.679611650485437 | 10.679611650485457 | 2.00E-14 | 14 | passed |
/fit/cells/9/residual | tolerance | 1.016040807848144 | 1.016040807848137 | 6.89E-15 | 14 | passed |
/fit/cells/9/adjusted_residual | tolerance | 1.5972317390183413 | 1.5972317390192075 | 8.66E-13 | 12 | passed |
/fit/cells/9/deviance_residual | tolerance | 0.96923028976966152 | 0.9692302897696546 | 6.88E-15 | 14 | passed |
/fit/cells/10/observed | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/fit/cells/10/structural | exact | False | False | passed | ||
/fit/cells/10/expected | tolerance | 7.2038834951456314 | 7.203883495145649 | 1.78E-14 | 14 | passed |
/fit/cells/10/residual | tolerance | -0.82111746995073709 | -0.8211174699507428 | 5.66E-15 | 14 | passed |
/fit/cells/10/adjusted_residual | tolerance | -1.2678343420780387 | -1.2678343420793494 | 1.31E-12 | 11 | passed |
/fit/cells/10/deviance_residual | tolerance | -0.8694501511040289 | -0.8694501511040358 | 6.88E-15 | 14 | passed |
/fit/cells/11/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/11/structural | exact | False | False | passed | ||
/fit/cells/11/expected | tolerance | 6.7961165048543659 | 6.796116504854378 | 1.24E-14 | 14 | passed |
/fit/cells/11/residual | tolerance | 0.84539217729158089 | 0.8453921772915753 | 5.55E-15 | 14 | passed |
/fit/cells/11/adjusted_residual | tolerance | 1.2678343420791798 | 1.267834342079333 | 1.53E-13 | 12 | passed |
/fit/cells/11/deviance_residual | tolerance | 0.8049541347883431 | 0.8049541347883375 | 5.55E-15 | 14 | passed |
Convention
- The structural zero is dropped from the fit: 11 allowable cells, rank 7, df 4; every parameter stays estimable on the support (manual lines 178-183).
- log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).
- Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).
- The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
261 support <- !(d$A == "a1" & d$B == "b3" & d$C == "c2")
262 m <- loglinear(d[support, ], n ~ A * B + C, last)
263 rows <- parameter_table(m$fit, list("A", "B", "C", c("A", "B")), last)
264 emit("STAT-REG-LOGLINEAR-GENERAL-005", "loglinearGeneralMenuItem", "axis_coverage",
265 list(factors = list("A", "B", "C"), count = "n", terms = list("A*B", "C"),
266 sampling = "poisson", coding = "last", confidence_level = 0.95,
267 structural_zeros = list("A=a1; B=b3; C=c2"), conditional_test = "off"),
268 fit_outputs(m$fit, rows, 0.95, poisson_loglik(m$fit), support),
269 list("The structural zero is dropped from the fit: 11 allowable cells, rank 7, df 4; every parameter stays estimable on the support (manual lines 178-183)."))
STAT REG LOGLINEAR LOGIT 001
Case STAT-REG-LOGLINEAR-LOGIT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients
- Citation
- R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear.R · sha256 29efcb27edfe009b
- Dataset
- reference_data/datasets/REG_LOGLINEAR_01.json
Settings compared
coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"dependent= ["C"]factors= ["A", "B", "C"]sampling= "poisson"terms= ["A*C", "B*C"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/df | exact | 2 | 2 | 0.00E+2 | passed | |
/fit/rank | exact | 10 | 10 | 0.00E+2 | passed | |
/fit/allowable_cells | exact | 12 | 12 | 0.00E+2 | passed | |
/fit/structural_zero_cells | exact | 0 | 0 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 4.6061366037424687 | 4.606136603742476 | 7.10E-15 | 14 | passed |
/fit/pearson | tolerance | 3.1506949806367492 | 3.1506949806367497 | 4.87E-16 | 15 | passed |
/fit/deviance_p | tail_probability | 0.099951690784941899 | 0.09995169078494155 | 3.47E-16 | 14 | passed |
/fit/pearson_p | tail_probability | 0.20693563205734944 | 0.20693563205734938 | 5.65E-17 | 15 | passed |
/fit/log_likelihood | tolerance | -24.784066654680235 | -24.784066654680245 | 1.03E-14 | 15 | passed |
/fit/boundary | exact | False | False | passed | ||
/total | tolerance | 109 | 109.0 | 0.00E+2 | passed | |
/fit/parameters/0/term | exact | (intercept) | (intercept) | passed | ||
/fit/parameters/0/label | exact | passed | ||||
/fit/parameters/0/estimate | tolerance | 2.0149562651042121 | 2.0149562651042126 | 4.52E-16 | 15 | passed |
/fit/parameters/0/standard_error | tolerance | 0.34703969734283924 | 0.3470396973454464 | 2.61E-12 | 11 | passed |
/fit/parameters/0/z_value | tolerance | 5.8061261594336981 | 5.806126159390081 | 4.36E-11 | 11 | passed |
/fit/parameters/0/p_value | tail_probability | 6.3934794883663958e-09 | 6.393479490031075e-09 | 1.66E-18 | 9 | passed |
/fit/parameters/0/lower | tolerance | 1.3347709571065667 | 1.334770957101457 | 5.11E-12 | 11 | passed |
/fit/parameters/0/upper | tolerance | 2.6951415731018575 | 2.695141573106968 | 5.11E-12 | 11 | passed |
/fit/parameters/1/term | exact | A | A | passed | ||
/fit/parameters/1/label | exact | A=a1 | A=a1 | passed | ||
/fit/parameters/1/estimate | tolerance | -1.6097574223388402 | -1.6097574223388411 | 9.15E-16 | 15 | passed |
/fit/parameters/1/standard_error | tolerance | 0.57956421715282969 | 0.5795642171631338 | 1.03E-11 | 10 | passed |
/fit/parameters/1/z_value | tolerance | -2.7775307285997455 | -2.7775307285503654 | 4.94E-11 | 10 | passed |
/fit/parameters/1/p_value | tail_probability | 0.0054773660668778782 | 0.005477366067710156 | 8.32E-13 | 9 | passed |
/fit/parameters/1/lower | tolerance | -2.7456824146865371 | -2.7456824147067342 | 2.02E-11 | 11 | passed |
/fit/parameters/1/upper | tolerance | -0.47383242999114317 | -0.4738324299709482 | 2.02E-11 | 10 | passed |
/fit/parameters/2/term | exact | B | B | passed | ||
/fit/parameters/2/label | exact | B=b1 | B=b1 | passed | ||
/fit/parameters/2/estimate | tolerance | 0.42851089584205748 | 0.4285108958420576 | 1.13E-16 | 15 | passed |
/fit/parameters/2/standard_error | tolerance | 0.4336905709194096 | 0.43369057092174296 | 2.33E-12 | 11 | passed |
/fit/parameters/2/z_value | tolerance | 0.98805674961673395 | 0.9880567496114182 | 5.32E-12 | 11 | passed |
/fit/parameters/2/p_value | tail_probability | 0.323124855938828 | 0.32312485594143125 | 2.60E-12 | 11 | passed |
/fit/parameters/2/lower | tolerance | -0.42150700359459925 | -0.4215070035991726 | 4.57E-12 | 10 | passed |
/fit/parameters/2/upper | tolerance | 1.2785287952787141 | 1.2785287952832878 | 4.57E-12 | 11 | passed |
/fit/parameters/3/term | exact | B | B | passed | ||
/fit/parameters/3/label | exact | B=b2 | B=b2 | passed | ||
/fit/parameters/3/estimate | tolerance | 0.69220767631293056 | 0.6922076763129295 | 1.11E-15 | 14 | passed |
/fit/parameters/3/standard_error | tolerance | 0.41776066124204914 | 0.4177606612444069 | 2.36E-12 | 11 | passed |
/fit/parameters/3/z_value | tolerance | 1.6569479621535446 | 1.6569479621441903 | 9.35E-12 | 11 | passed |
/fit/parameters/3/p_value | tail_probability | 0.097529996359263099 | 0.0975299963611545 | 1.89E-12 | 10 | passed |
/fit/parameters/3/lower | tolerance | -0.12658817387912358 | -0.1265881738837461 | 4.62E-12 | 10 | passed |
/fit/parameters/3/upper | tolerance | 1.5110035265049846 | 1.511003526509605 | 4.62E-12 | 11 | passed |
/fit/parameters/4/term | exact | C | C | passed | ||
/fit/parameters/4/label | exact | C=c1 | C=c1 | passed | ||
/fit/parameters/4/estimate | tolerance | -0.14321552775860485 | -0.1432155277586054 | 5.60E-16 | 14 | passed |
/fit/parameters/4/standard_error | tolerance | 0.47684228834792652 | 0.4768422883508787 | 2.95E-12 | 11 | passed |
/fit/parameters/4/z_value | tolerance | -0.30034149918789937 | -0.3003414991860411 | 1.86E-12 | 11 | passed |
/fit/parameters/4/p_value | tail_probability | 0.76391668171162097 | 0.7639166817130382 | 1.42E-12 | 11 | passed |
/fit/parameters/4/lower | tolerance | -1.0778092392262042 | -1.0778092392319911 | 5.79E-12 | 11 | passed |
/fit/parameters/4/upper | tolerance | 0.79137818370899438 | 0.7913781837147802 | 5.79E-12 | 11 | passed |
/fit/parameters/5/term | exact | A*B | A*B | passed | ||
/fit/parameters/5/label | exact | A=a1, B=b1 | A=a1, B=b1 | passed | ||
/fit/parameters/5/estimate | tolerance | 1.0361075988416657 | 1.036107598841666 | 2.22E-16 | 15 | passed |
/fit/parameters/5/standard_error | tolerance | 0.59400572780485028 | 0.5940057278128442 | 7.99E-12 | 10 | passed |
/fit/parameters/5/z_value | tolerance | 1.7442720673260239 | 1.7442720673025505 | 2.35E-11 | 10 | passed |
/fit/parameters/5/p_value | tail_probability | 0.081111659931701663 | 0.08111165993579289 | 4.09E-12 | 10 | passed |
/fit/parameters/5/lower | tolerance | -0.12812223426634306 | -0.12812223428201097 | 1.57E-11 | 9 | passed |
/fit/parameters/5/upper | tolerance | 2.2003374319496745 | 2.200337431965343 | 1.57E-11 | 11 | passed |
/fit/parameters/6/term | exact | A*B | A*B | passed | ||
/fit/parameters/6/label | exact | A=a1, B=b2 | A=a1, B=b2 | passed | ||
/fit/parameters/6/estimate | tolerance | 0.98369464542716734 | 0.983694645427168 | 6.62E-16 | 15 | passed |
/fit/parameters/6/standard_error | tolerance | 0.60504453901173849 | 0.6050445390200234 | 8.28E-12 | 10 | passed |
/fit/parameters/6/z_value | tolerance | 1.6258218726077662 | 1.6258218725855047 | 2.23E-11 | 10 | passed |
/fit/parameters/6/p_value | tail_probability | 0.10398755397090591 | 0.10398755397564302 | 4.74E-12 | 10 | passed |
/fit/parameters/6/lower | tolerance | -0.20217086007847951 | -0.2021708600947174 | 1.62E-11 | 10 | passed |
/fit/parameters/6/upper | tolerance | 2.1695601509328144 | 2.1695601509490534 | 1.62E-11 | 11 | passed |
/fit/parameters/7/term | exact | A*C | A*C | passed | ||
/fit/parameters/7/label | exact | A=a1, C=c1 | A=a1, C=c1 | passed | ||
/fit/parameters/7/estimate | tolerance | 1.2421828211311612 | 1.2421828211311616 | 4.30E-16 | 15 | passed |
/fit/parameters/7/standard_error | tolerance | 0.41594782025619265 | 0.41594782025813204 | 1.94E-12 | 11 | passed |
/fit/parameters/7/z_value | tolerance | 2.9863909861724238 | 2.9863909861585003 | 1.39E-11 | 11 | passed |
/fit/parameters/7/p_value | tail_probability | 0.0028229146573063111 | 0.002822914657434855 | 1.29E-13 | 10 | passed |
/fit/parameters/7/lower | tolerance | 0.4269400739810838 | 0.42694007397728295 | 3.80E-12 | 11 | passed |
/fit/parameters/7/upper | tolerance | 2.0574255682812383 | 2.05742556828504 | 3.80E-12 | 11 | passed |
/fit/parameters/8/term | exact | B*C | B*C | passed | ||
/fit/parameters/8/label | exact | B=b1, C=c1 | B=b1, C=c1 | passed | ||
/fit/parameters/8/estimate | tolerance | -0.050317456917490816 | -0.050317456917491815 | 9.99E-16 | 13 | passed |
/fit/parameters/8/standard_error | tolerance | 0.57153359942795701 | 0.5715335994322976 | 4.34E-12 | 11 | passed |
/fit/parameters/8/z_value | tolerance | -0.088039368057893919 | -0.08803936805722704 | 6.67E-13 | 11 | passed |
/fit/parameters/8/p_value | tail_probability | 0.92984538642110226 | 0.9298453864216323 | 5.30E-13 | 12 | passed |
/fit/parameters/8/lower | tolerance | -1.1705027277508284 | -1.170502727759337 | 8.51E-12 | 11 | passed |
/fit/parameters/8/upper | tolerance | 1.0698678139158466 | 1.0698678139243534 | 8.51E-12 | 11 | passed |
/fit/parameters/9/term | exact | B*C | B*C | passed | ||
/fit/parameters/9/label | exact | B=b2, C=c1 | B=b2, C=c1 | passed | ||
/fit/parameters/9/estimate | tolerance | -0.61614177748740528 | -0.6161417774874052 | 1.07E-16 | 15 | passed |
/fit/parameters/9/standard_error | tolerance | 0.57615630844047705 | 0.5761563084449849 | 4.51E-12 | 11 | passed |
/fit/parameters/9/z_value | tolerance | -1.0694003839950303 | -1.0694003839866633 | 8.37E-12 | 11 | passed |
/fit/parameters/9/p_value | tail_probability | 0.28488929437492289 | 0.2848892943786915 | 3.77E-12 | 10 | passed |
/fit/parameters/9/lower | tolerance | -1.745387391496291 | -1.7453873915051261 | 8.84E-12 | 11 | passed |
/fit/parameters/9/upper | tolerance | 0.51310383652148028 | 0.5131038365303158 | 8.84E-12 | 10 | passed |
/fit/cells/0/observed | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/fit/cells/0/structural | exact | False | False | passed | ||
/fit/cells/0/expected | tolerance | 18.512888661248205 | 18.51288866124818 | 2.50E-14 | 14 | passed |
/fit/cells/0/residual | tolerance | -0.11920267552505996 | -0.11920267552505427 | 5.69E-15 | 13 | passed |
/fit/cells/0/adjusted_residual | tolerance | -0.43066374589324136 | -0.4306637458952073 | 1.97E-12 | 11 | passed |
/fit/cells/0/deviance_residual | tolerance | -0.11975953493796322 | -0.11975953493796229 | 9.28E-16 | 14 | passed |
/fit/cells/1/observed | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/fit/cells/1/structural | exact | False | False | passed | ||
/fit/cells/1/expected | tolerance | 6.4871113387517756 | 6.487111338751775 | 8.97E-16 | 15 | passed |
/fit/cells/1/residual | tolerance | 0.20137122964884555 | 0.20137122964884593 | 3.84E-16 | 14 | passed |
/fit/cells/1/adjusted_residual | tolerance | 0.43066374589474848 | 0.4306637458952343 | 4.86E-13 | 11 | passed |
/fit/cells/1/deviance_residual | tolerance | 0.19880150902496913 | 0.19880150902497193 | 2.80E-15 | 13 | passed |
/fit/cells/2/observed | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/fit/cells/2/structural | exact | False | False | passed | ||
/fit/cells/2/expected | tolerance | 12.986711993905791 | 12.98671199390578 | 1.05E-14 | 15 | passed |
/fit/cells/2/residual | tolerance | -0.27380463939262156 | -0.27380463939261873 | 2.83E-15 | 13 | passed |
/fit/cells/2/adjusted_residual | tolerance | -0.83132462103370519 | -0.8313246210376452 | 3.94E-12 | 11 | passed |
/fit/cells/2/deviance_residual | tolerance | -0.27738646929634997 | -0.27738646929634836 | 1.61E-15 | 14 | passed |
/fit/cells/3/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/3/structural | exact | False | False | passed | ||
/fit/cells/3/expected | tolerance | 8.0132880060942 | 8.013288006094193 | 7.11E-15 | 15 | passed |
/fit/cells/3/residual | tolerance | 0.34856600689159756 | 0.3485660068916002 | 2.66E-15 | 14 | passed |
/fit/cells/3/adjusted_residual | tolerance | 0.83132462103628579 | 0.8313246210376656 | 1.38E-12 | 11 | passed |
/fit/cells/3/deviance_residual | tolerance | 0.34175640907215138 | 0.34175640907215205 | 6.65E-16 | 14 | passed |
/fit/cells/4/observed | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/fit/cells/4/structural | exact | False | False | passed | ||
/fit/cells/4/expected | tolerance | 4.5003993448459845 | 4.500399344845983 | 1.80E-15 | 15 | passed |
/fit/cells/4/residual | tolerance | 0.70688716316716194 | 0.7068871631671627 | 7.73E-16 | 14 | passed |
/fit/cells/4/adjusted_residual | tolerance | 1.7610436500422131 | 1.7610436500431357 | 9.23E-13 | 12 | passed |
/fit/cells/4/deviance_residual | tolerance | 0.67224897677385231 | 0.672248976773854 | 1.67E-15 | 14 | passed |
/fit/cells/5/observed | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/fit/cells/5/structural | exact | False | False | passed | ||
/fit/cells/5/expected | tolerance | 1.4996006551540169 | 1.4996006551540162 | 7.07E-16 | 15 | passed |
/fit/cells/5/residual | tolerance | -1.224581828688478 | -1.2245818286884778 | 2.42E-16 | 15 | passed |
/fit/cells/5/adjusted_residual | tolerance | -1.7610436500704356 | -1.7610436500431357 | 2.73E-11 | 10 | passed |
/fit/cells/5/deviance_residual | tolerance | -1.7318202303668917 | -1.7318202303668913 | 4.44E-16 | 15 | passed |
/fit/cells/6/observed | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/fit/cells/6/structural | exact | False | False | passed | ||
/fit/cells/6/expected | tolerance | 9.4871113387517809 | 9.487111338751767 | 1.42E-14 | 14 | passed |
/fit/cells/6/residual | tolerance | 0.16651604961790265 | 0.1665160496179074 | 4.74E-15 | 13 | passed |
/fit/cells/6/adjusted_residual | tolerance | 0.43066374589432821 | 0.4306637458952407 | 9.12E-13 | 11 | passed |
/fit/cells/6/deviance_residual | tolerance | 0.16504851402236201 | 0.16504851402237813 | 1.61E-14 | 13 | passed |
/fit/cells/7/observed | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/fit/cells/7/structural | exact | False | False | passed | ||
/fit/cells/7/expected | tolerance | 11.512888661248214 | 11.512888661248219 | 5.08E-15 | 15 | passed |
/fit/cells/7/residual | tolerance | -0.15115793336323219 | -0.15115793336323374 | 1.55E-15 | 13 | passed |
/fit/cells/7/adjusted_residual | tolerance | -0.43066374589305817 | -0.4306637458952279 | 2.17E-12 | 11 | passed |
/fit/cells/7/deviance_residual | tolerance | -0.15230161930408551 | -0.15230161930408698 | 1.47E-15 | 14 | passed |
/fit/cells/8/observed | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/fit/cells/8/structural | exact | False | False | passed | ||
/fit/cells/8/expected | tolerance | 7.0132880060942044 | 7.0132880060941964 | 7.95E-15 | 14 | passed |
/fit/cells/8/residual | tolerance | 0.37258860648020869 | 0.3725886064802119 | 3.22E-15 | 14 | passed |
/fit/cells/8/adjusted_residual | tolerance | 0.83132462103656968 | 0.8313246210376615 | 1.09E-12 | 11 | passed |
/fit/cells/8/deviance_residual | tolerance | 0.36432746304343216 | 0.36432746304343583 | 3.67E-15 | 13 | passed |
/fit/cells/9/observed | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/cells/9/structural | exact | False | False | passed | ||
/fit/cells/9/expected | tolerance | 14.986711993905804 | 14.98671199390579 | 1.47E-14 | 15 | passed |
/fit/cells/9/residual | tolerance | -0.25488086162173729 | -0.25488086162173373 | 3.56E-15 | 13 | passed |
/fit/cells/9/adjusted_residual | tolerance | -0.83132462103382854 | -0.8313246210376496 | 3.82E-12 | 11 | passed |
/fit/cells/9/deviance_residual | tolerance | -0.25775736140573008 | -0.2577573614057262 | 3.89E-15 | 13 | passed |
/fit/cells/10/observed | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/fit/cells/10/structural | exact | False | False | passed | ||
/fit/cells/10/expected | tolerance | 6.4996006551540129 | 6.499600655154013 | 3.74E-17 | 17 | passed |
/fit/cells/10/residual | tolerance | -0.58820983887710521 | -0.5882098388771052 | 3.34E-18 | 17 | passed |
/fit/cells/10/adjusted_residual | tolerance | -1.7610436499981927 | -1.7610436500431346 | 4.49E-11 | 10 | passed |
/fit/cells/10/deviance_residual | tolerance | -0.61332948827930844 | -0.6133294882793084 | 3.49E-18 | 17 | passed |
/fit/cells/11/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/11/structural | exact | False | False | passed | ||
/fit/cells/11/expected | tolerance | 7.5003993448459818 | 7.5003993448459845 | 2.67E-15 | 15 | passed |
/fit/cells/11/residual | tolerance | 0.54756215983720835 | 0.5475621598372072 | 1.11E-15 | 14 | passed |
/fit/cells/11/adjusted_residual | tolerance | 1.7610436500151445 | 1.7610436500431494 | 2.80E-11 | 10 | passed |
/fit/cells/11/deviance_residual | tolerance | 0.53068663999397325 | 0.5306866399939716 | 1.66E-15 | 14 | passed |
/logit/0/logit | exact | log(C=c1 / C=c2) | log(C=c1 / C=c2) | passed | ||
/logit/0/term | exact | (intercept) | (intercept) | passed | ||
/logit/0/estimate | tolerance | -0.14321552775860485 | -0.1432155277586054 | 5.60E-16 | 14 | passed |
/logit/0/standard_error | tolerance | 0.47684228834792652 | 0.4768422883508787 | 2.95E-12 | 11 | passed |
/logit/1/logit | exact | log(C=c1 / C=c2) | log(C=c1 / C=c2) | passed | ||
/logit/1/term | exact | A | A | passed | ||
/logit/1/estimate | tolerance | 1.2421828211311612 | 1.2421828211311616 | 4.30E-16 | 15 | passed |
/logit/1/standard_error | tolerance | 0.41594782025619265 | 0.41594782025813204 | 1.94E-12 | 11 | passed |
/logit/2/logit | exact | log(C=c1 / C=c2) | log(C=c1 / C=c2) | passed | ||
/logit/2/term | exact | B | B | passed | ||
/logit/2/estimate | tolerance | -0.050317456917490816 | -0.050317456917491815 | 9.99E-16 | 13 | passed |
/logit/2/standard_error | tolerance | 0.57153359942795701 | 0.5715335994322976 | 4.34E-12 | 11 | passed |
/logit/3/logit | exact | log(C=c1 / C=c2) | log(C=c1 / C=c2) | passed | ||
/logit/3/term | exact | B | B | passed | ||
/logit/3/estimate | tolerance | -0.61614177748740528 | -0.6161417774874052 | 1.07E-16 | 15 | passed |
/logit/3/standard_error | tolerance | 0.57615630844047705 | 0.5761563084449849 | 4.51E-12 | 11 | passed |
/joint/total_association | tolerance | 11.271250241293561 | 11.271250241293545 | 1.56E-14 | 14 | passed |
/joint/total_df | exact | 3 | 3 | 0.00E+2 | passed | |
/joint/partition/0/added | exact | A | A | passed | ||
/joint/partition/0/lr_chi_square | tolerance | 9.2863804238094403 | 9.28638042380944 | 1.24E-17 | 17 | passed |
/joint/partition/0/df | exact | 1 | 1 | 0.00E+2 | passed | |
/joint/partition/0/p_value | tail_probability | 0.0023086387997466929 | 0.002308638799746694 | 8.92E-19 | 15 | passed |
/joint/partition/1/added | exact | B | B | passed | ||
/joint/partition/1/lr_chi_square | tolerance | 1.9848698174841211 | 1.984869817484105 | 1.60E-14 | 14 | passed |
/joint/partition/1/df | exact | 2 | 2 | 0.00E+2 | passed | |
/joint/partition/1/p_value | tail_probability | 0.37067303629359344 | 0.37067303629359644 | 3.00E-15 | 14 | passed |
Convention
- glm(n ~ A*B + C + A:C + B:C, poisson): the logit parameters for log(C=c1/C=c2) are the loglinear parameters of C, A*C and B*C; the sequential association partition adds A*C then B*C to the baseline A*B + C (chapters/106-loglinear-extensions.tex:74-118).
- log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).
- Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).
- The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
35 emit <- function(id, menu, kind, config, outputs, notes) {
36 write_expected("regression", id, list(
37 schema_version = "2.0.0", case_id = id, outputs = outputs,
38 expected_error = NULL, deferred_outputs = list(), generator_run = run))
39 write_case("regression", id, list(
40 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
41 entry_point = "tabelz.analysis.loglinear:compute_loglinear",
42 menu_items = list(menu), title = gsub("-", " ", id),
43 case_kind = kind,
44 dataset = list(path = "reference_data/datasets/REG_LOGLINEAR_01.json", sha256 = ""),
45 excluded_rows = list(), configuration = config, "repeat" = 1L,
46 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
47 oracle = list(
48 oracle_class = "independent_implementation",
49 source = "R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients",
50 citation = "R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).",
51 generator = list(path = "generators/r/regression_loglinear.R", sha256 = ""),
52 independent = TRUE,
53 convention_notes = c(
54 notes,
55 "log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).",
56 "Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).",
57 "The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).",
58 "Expected computed from the exported CSV."
59 )),
60 supported = TRUE, unsupported_reason = NULL,
61 requirement_ids = list(if (menu == "loglinearLogitMenuItem") "REQ-STAT-REG-LOGLINEAR-LOGIT-001" else "REQ-STAT-REG-LOGLINEAR-GENERAL-001"),
62 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
STAT REG LOGLINEAR LOGIT 002
Case STAT-REG-LOGLINEAR-LOGIT-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::glm(family = poisson) on the cell table with contr.treatment at the declared reference; rstandard/residuals for adjusted and deviance residuals; profile limits by uniroot on the constrained deviance; logit contrasts from the Poisson coefficients
- Citation
- R Core Team, stats package help: glm, rstandard.glm, residuals.glm, uniroot; Agresti (2013) Categorical Data Analysis, ch. 9 (loglinear models, sampling schemes) and 10 (logit-loglinear equivalence).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear.R · sha256 29efcb27edfe009b
- Dataset
- reference_data/datasets/REG_LOGLINEAR_01.json
Settings compared
coding= "first"conditional_test= "off"confidence_level= 0.95count= "n"dependent= ["C"]factors= ["A", "B", "C"]sampling= "multinomial"terms= ["A*C"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/df | exact | 4 | 4 | 0.00E+2 | passed | |
/fit/rank | exact | 8 | 8 | 0.00E+2 | passed | |
/fit/allowable_cells | exact | 12 | 12 | 0.00E+2 | passed | |
/fit/structural_zero_cells | exact | 0 | 0 | 0.00E+2 | passed | |
/fit/deviance | tolerance | 6.591006421226588 | 6.5910064212265835 | 4.47E-15 | 15 | passed |
/fit/pearson | tolerance | 4.9284096721692636 | 4.928409672169257 | 6.19E-15 | 14 | passed |
/fit/deviance_p | tail_probability | 0.15914580250162011 | 0.1591458025016204 | 2.77E-16 | 14 | passed |
/fit/pearson_p | tail_probability | 0.29472230224414636 | 0.2947223022441469 | 5.56E-16 | 14 | passed |
/fit/log_likelihood | tolerance | -22.511124565254022 | -22.51112456525385 | 1.71E-13 | 14 | passed |
/fit/boundary | exact | False | False | passed | ||
/total | tolerance | 109 | 109.0 | 0.00E+2 | passed | |
/fit/parameters/0/term | exact | (intercept) | (intercept) | passed | ||
/fit/parameters/0/label | exact | passed | ||||
/fit/parameters/0/estimate | tolerance | 2.8511510447428816 | 2.8511510447428856 | 4.01E-15 | 14 | passed |
/fit/parameters/0/standard_error | tolerance | 0.22033385701477592 | 0.22033385701477756 | 1.64E-15 | 14 | passed |
/fit/parameters/0/z_value | tolerance | 12.94014040044549 | 12.940140400445411 | 7.85E-14 | 14 | passed |
/fit/parameters/0/p_value | tail_probability | 2.671408502104514e-38 | 2.671408502107246e-38 | 2.73E-50 | 11 | passed |
/fit/parameters/0/lower | tolerance | 2.4193046204191231 | 2.4193046204191235 | 4.30E-16 | 15 | passed |
/fit/parameters/0/upper | tolerance | 3.2829974690666401 | 3.2829974690666477 | 7.59E-15 | 14 | passed |
/fit/parameters/1/term | exact | A | A | passed | ||
/fit/parameters/1/label | exact | A=a2 | A=a2 | passed | ||
/fit/parameters/1/estimate | tolerance | -0.71418565892485986 | -0.7141856589248626 | 2.77E-15 | 14 | passed |
/fit/parameters/1/standard_error | tolerance | 0.34942875867120271 | 0.349428758671204 | 1.28E-15 | 14 | passed |
/fit/parameters/1/z_value | tolerance | -2.0438662851928497 | -2.04386628519285 | 4.85E-16 | 15 | passed |
/fit/parameters/1/p_value | tail_probability | 0.040966758633807915 | 0.040966758633807845 | 6.96E-17 | 14 | passed |
/fit/parameters/1/lower | tolerance | -1.3990534410829552 | -1.3990534410829607 | 5.50E-15 | 14 | passed |
/fit/parameters/1/upper | tolerance | -0.029317876766764561 | -0.029317876766764672 | 1.11E-16 | 14 | passed |
/fit/parameters/2/term | exact | B | B | passed | ||
/fit/parameters/2/label | exact | B=b2 | B=b2 | passed | ||
/fit/parameters/2/estimate | tolerance | -0.17435338714477694 | -0.17435338714477977 | 2.83E-15 | 13 | passed |
/fit/parameters/2/standard_error | tolerance | 0.29600514796038174 | 0.29600514796038185 | 1.14E-16 | 15 | passed |
/fit/parameters/2/z_value | tolerance | -0.58902146920807252 | -0.5890214692080818 | 9.33E-15 | 13 | passed |
/fit/parameters/2/p_value | tail_probability | 0.55584687168852565 | 0.5558468716885192 | 6.44E-15 | 13 | passed |
/fit/parameters/2/lower | tolerance | -0.75451281638557477 | -0.754512816385578 | 3.22E-15 | 14 | passed |
/fit/parameters/2/upper | tolerance | 0.40580604209602095 | 0.40580604209601845 | 2.50E-15 | 14 | passed |
/fit/parameters/3/term | exact | B | B | passed | ||
/fit/parameters/3/label | exact | B=b3 | B=b3 | passed | ||
/fit/parameters/3/estimate | tolerance | -1.4271163556401445 | -1.4271163556401458 | 1.33E-15 | 15 | passed |
/fit/parameters/3/standard_error | tolerance | 0.45460605656606057 | 0.4546060565661946 | 1.34E-13 | 12 | passed |
/fit/parameters/3/z_value | tolerance | -3.1392374453171517 | -3.139237445316229 | 9.23E-13 | 12 | passed |
/fit/parameters/3/p_value | tail_probability | 0.0016938813209152717 | 0.0016938813209206034 | 5.33E-15 | 11 | passed |
/fit/parameters/3/lower | tolerance | -2.3181278536634018 | -2.3181278536636656 | 2.64E-13 | 12 | passed |
/fit/parameters/3/upper | tolerance | -0.53610485761688742 | -0.5361048576166259 | 2.62E-13 | 12 | passed |
/fit/parameters/4/term | exact | C | C | passed | ||
/fit/parameters/4/label | exact | C=c2 | C=c2 | passed | ||
/fit/parameters/4/estimate | tolerance | -0.81093021621632722 | -0.8109302162163297 | 2.44E-15 | 14 | passed |
/fit/parameters/4/standard_error | tolerance | 0.30046260628865257 | 0.3004626062886657 | 1.32E-14 | 13 | passed |
/fit/parameters/4/z_value | tolerance | -2.698938900361104 | -2.698938900360994 | 1.10E-13 | 13 | passed |
/fit/parameters/4/p_value | tail_probability | 0.0069560946123602523 | 0.00695609461236255 | 2.30E-15 | 12 | passed |
/fit/parameters/4/lower | tolerance | -1.3998261032431241 | -1.3998261032431523 | 2.82E-14 | 13 | passed |
/fit/parameters/4/upper | tolerance | -0.22203432918953037 | -0.22203432918950694 | 2.34E-14 | 12 | passed |
/fit/parameters/5/term | exact | A*B | A*B | passed | ||
/fit/parameters/5/label | exact | A=a2, B=b2 | A=a2, B=b2 | passed | ||
/fit/parameters/5/estimate | tolerance | 0.22087340277966994 | 0.22087340277967218 | 2.24E-15 | 13 | passed |
/fit/parameters/5/standard_error | tolerance | 0.42507956983680173 | 0.42507956983680195 | 2.22E-16 | 15 | passed |
/fit/parameters/5/z_value | tolerance | 0.51960484213454095 | 0.5196048421345459 | 4.99E-15 | 14 | passed |
/fit/parameters/5/p_value | tail_probability | 0.6033390225004901 | 0.6033390225004865 | 3.56E-15 | 14 | passed |
/fit/parameters/5/lower | tolerance | -0.61226724466423998 | -0.6122672446642383 | 1.66E-15 | 14 | passed |
/fit/parameters/5/upper | tolerance | 1.05401405022358 | 1.0540140502235826 | 2.63E-15 | 14 | passed |
/fit/parameters/6/term | exact | A*B | A*B | passed | ||
/fit/parameters/6/label | exact | A=a2, B=b3 | A=a2, B=b3 | passed | ||
/fit/parameters/6/estimate | tolerance | 1.0216512475319806 | 1.0216512475319834 | 2.84E-15 | 14 | passed |
/fit/parameters/6/standard_error | tolerance | 0.57071383872669779 | 0.5707138387268045 | 1.07E-13 | 12 | passed |
/fit/parameters/6/z_value | tolerance | 1.7901287444007936 | 1.790128744400464 | 3.29E-13 | 12 | passed |
/fit/parameters/6/p_value | tail_probability | 0.073433216804209181 | 0.07343321680426214 | 5.30E-14 | 12 | passed |
/fit/parameters/6/lower | tolerance | -0.096927321850947656 | -0.09692732185115416 | 2.07E-13 | 11 | passed |
/fit/parameters/6/upper | tolerance | 2.1402298169149088 | 2.140229816915121 | 2.12E-13 | 13 | passed |
/fit/parameters/7/term | exact | A*C | A*C | passed | ||
/fit/parameters/7/label | exact | A=a2, C=c2 | A=a2, C=c2 | passed | ||
/fit/parameters/7/estimate | tolerance | 1.2017965249033389 | 1.2017965249033418 | 2.87E-15 | 14 | passed |
/fit/parameters/7/standard_error | tolerance | 0.40394034628050873 | 0.4039403462805186 | 9.88E-15 | 13 | passed |
/fit/parameters/7/z_value | tolerance | 2.9751831822928971 | 2.975183182292832 | 6.52E-14 | 13 | passed |
/fit/parameters/7/p_value | tail_probability | 0.0029281363712989196 | 0.0029281363712995415 | 6.22E-16 | 12 | passed |
/fit/parameters/7/lower | tolerance | 0.41008799429090392 | 0.41008799429088727 | 1.67E-14 | 13 | passed |
/fit/parameters/7/upper | tolerance | 1.9935050555157738 | 1.9935050555157963 | 2.25E-14 | 13 | passed |
/fit/cells/0/observed | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/fit/cells/0/structural | exact | False | False | passed | ||
/fit/cells/0/expected | tolerance | 17.307692307692278 | 17.307692307692346 | 6.77E-14 | 14 | passed |
/fit/cells/0/residual | tolerance | 0.16641005886757598 | 0.1664100588675594 | 1.66E-14 | 13 | passed |
/fit/cells/0/adjusted_residual | tolerance | 0.41633319989322759 | 0.4163331998932035 | 2.41E-14 | 13 | passed |
/fit/cells/0/deviance_residual | tolerance | 0.16531874939868613 | 0.16531874939867605 | 1.01E-14 | 13 | passed |
/fit/cells/1/observed | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/fit/cells/1/structural | exact | False | False | passed | ||
/fit/cells/1/expected | tolerance | 7.6923076923076925 | 7.692307692307702 | 9.78E-15 | 14 | passed |
/fit/cells/1/residual | tolerance | -0.24961508830135318 | -0.24961508830135656 | 3.38E-15 | 13 | passed |
/fit/cells/1/adjusted_residual | tolerance | -0.41633319989321094 | -0.4163331998932326 | 2.16E-14 | 13 | passed |
/fit/cells/1/deviance_residual | tolerance | -0.25350714391907564 | -0.25350714391907697 | 1.33E-15 | 14 | passed |
/fit/cells/2/observed | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/fit/cells/2/structural | exact | False | False | passed | ||
/fit/cells/2/expected | tolerance | 14.538461538461522 | 14.538461538461542 | 1.99E-14 | 14 | passed |
/fit/cells/2/residual | tolerance | -0.66575028593567875 | -0.6657502859356835 | 4.78E-15 | 14 | passed |
/fit/cells/2/adjusted_residual | tolerance | -1.5544396553385154 | -1.5544396553385722 | 5.68E-14 | 13 | passed |
/fit/cells/2/deviance_residual | tolerance | -0.68668689333679878 | -0.686686893336804 | 5.21E-15 | 14 | passed |
/fit/cells/3/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/3/structural | exact | False | False | passed | ||
/fit/cells/3/expected | tolerance | 6.4615384615384643 | 6.461538461538457 | 7.07E-15 | 14 | passed |
/fit/cells/3/residual | tolerance | 0.99862542890352268 | 0.998625428903526 | 3.33E-15 | 14 | passed |
/fit/cells/3/adjusted_residual | tolerance | 1.5544396553385245 | 1.5544396553385729 | 4.84E-14 | 13 | passed |
/fit/cells/3/deviance_residual | tolerance | 0.94207503430294093 | 0.9420750343029424 | 1.44E-15 | 14 | passed |
/fit/cells/4/observed | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/fit/cells/4/structural | exact | False | False | passed | ||
/fit/cells/4/expected | tolerance | 4.1538461538461515 | 4.153846153846163 | 1.16E-14 | 14 | passed |
/fit/cells/4/residual | tolerance | 0.90582162731567806 | 0.9058216273156711 | 7.00E-15 | 14 | passed |
/fit/cells/4/adjusted_residual | tolerance | 1.7362294645649354 | 1.7362294645648515 | 8.39E-14 | 13 | passed |
/fit/cells/4/deviance_residual | tolerance | 0.84875772114079651 | 0.8487577211407907 | 5.78E-15 | 14 | passed |
/fit/cells/5/observed | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/fit/cells/5/structural | exact | False | False | passed | ||
/fit/cells/5/expected | tolerance | 1.846153846153848 | 1.8461538461538485 | 4.77E-16 | 15 | passed |
/fit/cells/5/residual | tolerance | -1.3587324409735158 | -1.3587324409735158 | 4.62E-17 | 16 | passed |
/fit/cells/5/adjusted_residual | tolerance | -1.7362294645649374 | -1.7362294645648635 | 7.39E-14 | 13 | passed |
/fit/cells/5/deviance_residual | tolerance | -1.9215378456610466 | -1.9215378456610468 | 1.95E-16 | 15 | passed |
/fit/cells/6/observed | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/fit/cells/6/structural | exact | False | False | passed | ||
/fit/cells/6/expected | tolerance | 8.4736842105263115 | 8.473684210526319 | 7.09E-15 | 15 | passed |
/fit/cells/6/residual | tolerance | 0.52433428893327405 | 0.5243342889332715 | 2.55E-15 | 14 | passed |
/fit/cells/6/adjusted_residual | tolerance | 0.8542645925907193 | 0.8542645925907155 | 3.78E-15 | 14 | passed |
/fit/cells/6/deviance_residual | tolerance | 0.50966907358902735 | 0.509669073589023 | 4.32E-15 | 14 | passed |
/fit/cells/7/observed | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/fit/cells/7/structural | exact | False | False | passed | ||
/fit/cells/7/expected | tolerance | 12.52631578947368 | 12.52631578947369 | 1.03E-14 | 15 | passed |
/fit/cells/7/residual | tolerance | -0.43125358551541532 | -0.4312535855154182 | 2.88E-15 | 14 | passed |
/fit/cells/7/adjusted_residual | tolerance | -0.85426459259071441 | -0.8542645925907204 | 6.00E-15 | 14 | passed |
/fit/cells/7/deviance_residual | tolerance | -0.44048870746111735 | -0.4404887074611199 | 2.55E-15 | 14 | passed |
/fit/cells/8/observed | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/fit/cells/8/structural | exact | False | False | passed | ||
/fit/cells/8/expected | tolerance | 8.8771929824561369 | 8.87719298245614 | 3.51E-15 | 15 | passed |
/fit/cells/8/residual | tolerance | -0.29441322739314013 | -0.29441322739314124 | 1.11E-15 | 14 | passed |
/fit/cells/8/adjusted_residual | tolerance | -0.48647294600317692 | -0.48647294600317836 | 1.44E-15 | 14 | passed |
/fit/cells/8/deviance_residual | tolerance | -0.29947321840693619 | -0.2994732184069381 | 1.89E-15 | 14 | passed |
/fit/cells/9/observed | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/cells/9/structural | exact | False | False | passed | ||
/fit/cells/9/expected | tolerance | 13.122807017543851 | 13.122807017543863 | 1.21E-14 | 15 | passed |
/fit/cells/9/residual | tolerance | 0.24214849689644677 | 0.24214849689644322 | 3.55E-15 | 13 | passed |
/fit/cells/9/adjusted_residual | tolerance | 0.48647294600318397 | 0.4864729460031777 | 6.27E-15 | 13 | passed |
/fit/cells/9/deviance_residual | tolerance | 0.23952323560983149 | 0.23952323560983474 | 3.25E-15 | 13 | passed |
/fit/cells/10/observed | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/fit/cells/10/structural | exact | False | False | passed | ||
/fit/cells/10/expected | tolerance | 5.6491228070175428 | 5.649122807017558 | 1.51E-14 | 14 | passed |
/fit/cells/10/residual | tolerance | -0.27310921904406743 | -0.27310921904407337 | 5.94E-15 | 13 | passed |
/fit/cells/10/adjusted_residual | tolerance | -0.40713414780260815 | -0.40713414780261703 | 8.88E-15 | 13 | passed |
/fit/cells/10/deviance_residual | tolerance | -0.27860718095108344 | -0.2786071809510902 | 6.78E-15 | 13 | passed |
/fit/cells/11/observed | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/fit/cells/11/structural | exact | False | False | passed | ||
/fit/cells/11/expected | tolerance | 8.3508771929824555 | 8.35087719298248 | 2.48E-14 | 14 | passed |
/fit/cells/11/residual | tolerance | 0.22462641188255081 | 0.22462641188254184 | 8.97E-15 | 13 | passed |
/fit/cells/11/adjusted_residual | tolerance | 0.40713414780260887 | 0.40713414780259316 | 1.57E-14 | 13 | passed |
/fit/cells/11/deviance_residual | tolerance | 0.22180672413884364 | 0.22180672413883112 | 1.25E-14 | 13 | passed |
/logit/0/logit | exact | log(C=c2 / C=c1) | log(C=c2 / C=c1) | passed | ||
/logit/0/estimate | tolerance | -0.81093021621632722 | -0.8109302162163297 | 2.44E-15 | 14 | passed |
/logit/0/standard_error | tolerance | 0.30046260628865257 | 0.3004626062886657 | 1.32E-14 | 13 | passed |
/logit/1/logit | exact | log(C=c2 / C=c1) | log(C=c2 / C=c1) | passed | ||
/logit/1/estimate | tolerance | 1.2017965249033389 | 1.2017965249033418 | 2.87E-15 | 14 | passed |
/logit/1/standard_error | tolerance | 0.40394034628050873 | 0.4039403462805186 | 9.88E-15 | 13 | passed |
Convention
- glm(n ~ A*B + C + A:C, poisson) with first-level references; the fitted counts are those of the multinomial model and the logit is log(C=c2 / C=c1).
- log mu_c = o_c + x_c' lambda over the allowable cells in reference coding (last level by default); G^2 and X^2 on df = allowable cells - rank; the Poisson, multinomial and product-multinomial fitted counts coincide and each scheme's own log-likelihood is reported (docs/manual/chapters/86-regression-and-count-models.tex:171-197).
- Adjusted residual (y - mu)/sqrt(mu (1 - h)) with the Poisson leverage (R rstandard type pearson); deviance residual sign(y - mu) sqrt(d_c).
- The logit model fixes the explanatory factors' interaction; each logit parameter equals the loglinear parameter whose term contains the dependent factor (manual lines 193-197; chapters/106-loglinear-extensions.tex:74-118).
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
320 emit("STAT-REG-LOGLINEAR-LOGIT-002", "loglinearLogitMenuItem", "axis_coverage",
321 list(factors = list("A", "B", "C"), count = "n", dependent = list("C"),
322 terms = list("A*C"), sampling = "multinomial", coding = "first",
323 confidence_level = 0.95, conditional_test = "off"),
324 out,
325 list("glm(n ~ A*B + C + A:C, poisson) with first-level references; the fitted counts are those of the multinomial model and the logit is log(C=c2 / C=c1)."))
STAT REG LOGLINEAR SELECTION 001
Case STAT-REG-LOGLINEAR-SELECTION-001 · status: passed
Reference
- Evidence type
- R
- Source
- Base R implementation of hierarchical backward elimination over stats::glm(family = poisson) fits of each generating class; stats::pchisq
- Citation
- R Core Team, stats package help: glm, pchisq; Agresti (2013) Categorical Data Analysis, section 9.4 (hierarchical loglinear model selection by likelihood-ratio comparisons).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear_selection.R · sha256 0288dc1141c43c92
- Dataset
- reference_data/datasets/REG_LOGLINEAR_02.json
Settings compared
alpha= 0.05coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"factors= ["A", "B", "C"]highest_order_only= falsesampling= "poisson"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/final/deviance | tolerance | 0.28052006952224084 | 0.28052006952224434 | 3.50E-15 | 13 | passed |
/final/df | exact | 4 | 4 | 0.00E+2 | passed | |
/final/deviance_p | tail_probability | 0.99103671421156425 | 0.991036714211564 | 2.21E-16 | 15 | passed |
/final/boundary | exact | False | False | passed | ||
/final/generators/0 | exact | A*B | A*B | passed | ||
/final/generators/1 | exact | A*C | A*C | passed | ||
/steps/0/step | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/0/model/0 | exact | A*B*C | A*B*C | passed | ||
/steps/0/removed | exact | A*B*C | A*B*C | passed | ||
/steps/0/candidates/0/term | exact | A*B*C | A*B*C | passed | ||
/steps/0/candidates/0/order | exact | 3 | 3 | 0.00E+2 | passed | |
/steps/0/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/0/candidates/0/lr_chi_square | tolerance | 0.25926639706703114 | 0.2592663970670338 | 2.66E-15 | 13 | passed |
/steps/0/candidates/0/p_value | tail_probability | 0.87841757669049492 | 0.8784175766904936 | 1.34E-15 | 14 | passed |
/steps/1/step | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/model/0 | exact | A*B | A*B | passed | ||
/steps/1/model/1 | exact | A*C | A*C | passed | ||
/steps/1/model/2 | exact | B*C | B*C | passed | ||
/steps/1/removed | exact | B*C | B*C | passed | ||
/steps/1/candidates/0/term | exact | A*B | A*B | passed | ||
/steps/1/candidates/0/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/0/lr_chi_square | tolerance | 35.606099614410169 | 35.60609961441016 | 6.75E-15 | 15 | passed |
/steps/1/candidates/0/p_value | tail_probability | 1.8545293361962089e-08 | 1.8545293361962152e-08 | 6.27E-23 | 14 | passed |
/steps/1/candidates/1/term | exact | A*C | A*C | passed | ||
/steps/1/candidates/1/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/1/candidates/1/lr_chi_square | tolerance | 10.980247717241989 | 10.980247717241992 | 3.33E-15 | 15 | passed |
/steps/1/candidates/1/p_value | tail_probability | 0.00092088119902911884 | 0.0009208811990291165 | 2.39E-18 | 14 | passed |
/steps/1/candidates/2/term | exact | B*C | B*C | passed | ||
/steps/1/candidates/2/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/2/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/2/lr_chi_square | tolerance | 0.021253672455205042 | 0.021253672455213868 | 8.83E-15 | 12 | passed |
/steps/1/candidates/2/p_value | tail_probability | 0.98942942911260756 | 0.9894294291126031 | 4.44E-15 | 14 | passed |
/steps/2/step | exact | 3 | 3 | 0.00E+2 | passed | |
/steps/2/model/0 | exact | A*B | A*B | passed | ||
/steps/2/model/1 | exact | A*C | A*C | passed | ||
/steps/2/candidates/0/term | exact | A*B | A*B | passed | ||
/steps/2/candidates/0/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/0/lr_chi_square | tolerance | 38.272312746871712 | 38.272312746871705 | 6.74E-15 | 15 | passed |
/steps/2/candidates/0/p_value | tail_probability | 4.8895949292945122e-09 | 4.889594929294536e-09 | 2.40E-23 | 14 | passed |
/steps/2/candidates/1/term | exact | A*C | A*C | passed | ||
/steps/2/candidates/1/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/2/candidates/1/lr_chi_square | tolerance | 13.646460849703535 | 13.646460849703528 | 6.76E-15 | 15 | passed |
/steps/2/candidates/1/p_value | tail_probability | 0.00022065684375480255 | 0.00022065684375480358 | 1.03E-18 | 14 | passed |
Convention
- Alpha 0.05 from the saturated A*B*C model; expected path: remove A*B*C, then B*C, then stop with A*B; A*C.
- Backward elimination from the saturated model: each maximal term whose removal keeps the model hierarchical (and that is not inside a term fixed by the sampling design) is tested by G^2(reduced) - G^2(current) on the df difference; the candidate with the largest p above alpha is removed, ties going to the higher-order term and then the term earlier in table order; the search stops when no candidate exceeds alpha (docs/manual/chapters/86-regression-and-count-models.tex:193-197).
- Candidates are listed by order (highest first) and then table order; df and deviances come from Poisson fits on the full positive table, so every fit is interior and the chi-square reference applies.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
34 emit <- function(id, kind, config, outputs, notes) {
35 write_expected("regression", id, list(
36 schema_version = "2.0.0", case_id = id, outputs = outputs,
37 expected_error = NULL, deferred_outputs = list(), generator_run = run))
38 write_case("regression", id, list(
39 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
40 entry_point = "tabelz.analysis.loglinear_selection:compute_loglinear_selection",
41 menu_items = list("loglinearSelectionMenuItem"), title = gsub("-", " ", id),
42 case_kind = kind,
43 dataset = list(path = "reference_data/datasets/REG_LOGLINEAR_02.json", sha256 = ""),
44 excluded_rows = list(), configuration = config, "repeat" = 1L,
45 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
46 oracle = list(
47 oracle_class = "independent_implementation",
48 source = "Base R implementation of hierarchical backward elimination over stats::glm(family = poisson) fits of each generating class; stats::pchisq",
49 citation = "R Core Team, stats package help: glm, pchisq; Agresti (2013) Categorical Data Analysis, section 9.4 (hierarchical loglinear model selection by likelihood-ratio comparisons).",
50 generator = list(path = "generators/r/regression_loglinear_selection.R", sha256 = ""),
51 independent = TRUE,
52 convention_notes = c(
53 notes,
54 "Backward elimination from the saturated model: each maximal term whose removal keeps the model hierarchical (and that is not inside a term fixed by the sampling design) is tested by G^2(reduced) - G^2(current) on the df difference; the candidate with the largest p above alpha is removed, ties going to the higher-order term and then the term earlier in table order; the search stops when no candidate exceeds alpha (docs/manual/chapters/86-regression-and-count-models.tex:193-197).",
55 "Candidates are listed by order (highest first) and then table order; df and deviances come from Poisson fits on the full positive table, so every fit is interior and the chi-square reference applies.",
56 "Expected computed from the exported CSV."
57 )),
58 supported = TRUE, unsupported_reason = NULL,
59 requirement_ids = list("REQ-STAT-REG-LOGLINEAR-SELECTION-001"),
60 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
STAT REG LOGLINEAR SELECTION 002
Case STAT-REG-LOGLINEAR-SELECTION-002 · status: passed
Reference
- Evidence type
- R
- Source
- Base R implementation of hierarchical backward elimination over stats::glm(family = poisson) fits of each generating class; stats::pchisq
- Citation
- R Core Team, stats package help: glm, pchisq; Agresti (2013) Categorical Data Analysis, section 9.4 (hierarchical loglinear model selection by likelihood-ratio comparisons).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear_selection.R · sha256 0288dc1141c43c92
- Dataset
- reference_data/datasets/REG_LOGLINEAR_02.json
Settings compared
alpha= 0.3coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"factors= ["A", "B", "C"]highest_order_only= falsesampling= "poisson"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/final/deviance | tolerance | 0.28052006952224084 | 0.28052006952224434 | 3.50E-15 | 13 | passed |
/final/df | exact | 4 | 4 | 0.00E+2 | passed | |
/final/deviance_p | tail_probability | 0.99103671421156425 | 0.991036714211564 | 2.21E-16 | 15 | passed |
/final/boundary | exact | False | False | passed | ||
/final/generators/0 | exact | A*B | A*B | passed | ||
/final/generators/1 | exact | A*C | A*C | passed | ||
/steps/0/step | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/0/model/0 | exact | A*B*C | A*B*C | passed | ||
/steps/0/removed | exact | A*B*C | A*B*C | passed | ||
/steps/0/candidates/0/term | exact | A*B*C | A*B*C | passed | ||
/steps/0/candidates/0/order | exact | 3 | 3 | 0.00E+2 | passed | |
/steps/0/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/0/candidates/0/lr_chi_square | tolerance | 0.25926639706703114 | 0.2592663970670338 | 2.66E-15 | 13 | passed |
/steps/0/candidates/0/p_value | tail_probability | 0.87841757669049492 | 0.8784175766904936 | 1.34E-15 | 14 | passed |
/steps/1/step | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/model/0 | exact | A*B | A*B | passed | ||
/steps/1/model/1 | exact | A*C | A*C | passed | ||
/steps/1/model/2 | exact | B*C | B*C | passed | ||
/steps/1/removed | exact | B*C | B*C | passed | ||
/steps/1/candidates/0/term | exact | A*B | A*B | passed | ||
/steps/1/candidates/0/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/0/lr_chi_square | tolerance | 35.606099614410169 | 35.60609961441016 | 6.75E-15 | 15 | passed |
/steps/1/candidates/0/p_value | tail_probability | 1.8545293361962089e-08 | 1.8545293361962152e-08 | 6.27E-23 | 14 | passed |
/steps/1/candidates/1/term | exact | A*C | A*C | passed | ||
/steps/1/candidates/1/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/1/candidates/1/lr_chi_square | tolerance | 10.980247717241989 | 10.980247717241992 | 3.33E-15 | 15 | passed |
/steps/1/candidates/1/p_value | tail_probability | 0.00092088119902911884 | 0.0009208811990291165 | 2.39E-18 | 14 | passed |
/steps/1/candidates/2/term | exact | B*C | B*C | passed | ||
/steps/1/candidates/2/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/2/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/2/lr_chi_square | tolerance | 0.021253672455205042 | 0.021253672455213868 | 8.83E-15 | 12 | passed |
/steps/1/candidates/2/p_value | tail_probability | 0.98942942911260756 | 0.9894294291126031 | 4.44E-15 | 14 | passed |
/steps/2/step | exact | 3 | 3 | 0.00E+2 | passed | |
/steps/2/model/0 | exact | A*B | A*B | passed | ||
/steps/2/model/1 | exact | A*C | A*C | passed | ||
/steps/2/candidates/0/term | exact | A*B | A*B | passed | ||
/steps/2/candidates/0/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/0/lr_chi_square | tolerance | 38.272312746871712 | 38.272312746871705 | 6.74E-15 | 15 | passed |
/steps/2/candidates/0/p_value | tail_probability | 4.8895949292945122e-09 | 4.889594929294536e-09 | 2.40E-23 | 14 | passed |
/steps/2/candidates/1/term | exact | A*C | A*C | passed | ||
/steps/2/candidates/1/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/2/candidates/1/lr_chi_square | tolerance | 13.646460849703535 | 13.646460849703528 | 6.76E-15 | 15 | passed |
/steps/2/candidates/1/p_value | tail_probability | 0.00022065684375480255 | 0.00022065684375480358 | 1.03E-18 | 14 | passed |
Convention
- Alpha 0.30: a candidate is removed only when its likelihood-ratio p exceeds 0.30.
- Backward elimination from the saturated model: each maximal term whose removal keeps the model hierarchical (and that is not inside a term fixed by the sampling design) is tested by G^2(reduced) - G^2(current) on the df difference; the candidate with the largest p above alpha is removed, ties going to the higher-order term and then the term earlier in table order; the search stops when no candidate exceeds alpha (docs/manual/chapters/86-regression-and-count-models.tex:193-197).
- Candidates are listed by order (highest first) and then table order; df and deviances come from Poisson fits on the full positive table, so every fit is interior and the chi-square reference applies.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
158 r <- backward(list(), 0.30)
159 emit("STAT-REG-LOGLINEAR-SELECTION-002", "axis_coverage", c(common, list(alpha = 0.30, highest_order_only = FALSE)),
160 selection_outputs(r),
161 list("Alpha 0.30: a candidate is removed only when its likelihood-ratio p exceeds 0.30."))
STAT REG LOGLINEAR SELECTION 003
Case STAT-REG-LOGLINEAR-SELECTION-003 · status: passed
Reference
- Evidence type
- R
- Source
- Base R implementation of hierarchical backward elimination over stats::glm(family = poisson) fits of each generating class; stats::pchisq
- Citation
- R Core Team, stats package help: glm, pchisq; Agresti (2013) Categorical Data Analysis, section 9.4 (hierarchical loglinear model selection by likelihood-ratio comparisons).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear_selection.R · sha256 0288dc1141c43c92
- Dataset
- reference_data/datasets/REG_LOGLINEAR_02.json
Settings compared
alpha= 0.05coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"factors= ["A", "B", "C"]highest_order_only= truesampling= "poisson"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/final/deviance | tolerance | 0.28052006952224084 | 0.28052006952224434 | 3.50E-15 | 13 | passed |
/final/df | exact | 4 | 4 | 0.00E+2 | passed | |
/final/deviance_p | tail_probability | 0.99103671421156425 | 0.991036714211564 | 2.21E-16 | 15 | passed |
/final/boundary | exact | False | False | passed | ||
/final/generators/0 | exact | A*B | A*B | passed | ||
/final/generators/1 | exact | A*C | A*C | passed | ||
/steps/0/step | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/0/model/0 | exact | A*B*C | A*B*C | passed | ||
/steps/0/removed | exact | A*B*C | A*B*C | passed | ||
/steps/0/candidates/0/term | exact | A*B*C | A*B*C | passed | ||
/steps/0/candidates/0/order | exact | 3 | 3 | 0.00E+2 | passed | |
/steps/0/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/0/candidates/0/lr_chi_square | tolerance | 0.25926639706703114 | 0.2592663970670338 | 2.66E-15 | 13 | passed |
/steps/0/candidates/0/p_value | tail_probability | 0.87841757669049492 | 0.8784175766904936 | 1.34E-15 | 14 | passed |
/steps/1/step | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/model/0 | exact | A*B | A*B | passed | ||
/steps/1/model/1 | exact | A*C | A*C | passed | ||
/steps/1/model/2 | exact | B*C | B*C | passed | ||
/steps/1/removed | exact | B*C | B*C | passed | ||
/steps/1/candidates/0/term | exact | A*B | A*B | passed | ||
/steps/1/candidates/0/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/0/lr_chi_square | tolerance | 35.606099614410169 | 35.60609961441016 | 6.75E-15 | 15 | passed |
/steps/1/candidates/0/p_value | tail_probability | 1.8545293361962089e-08 | 1.8545293361962152e-08 | 6.27E-23 | 14 | passed |
/steps/1/candidates/1/term | exact | A*C | A*C | passed | ||
/steps/1/candidates/1/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/1/candidates/1/lr_chi_square | tolerance | 10.980247717241989 | 10.980247717241992 | 3.33E-15 | 15 | passed |
/steps/1/candidates/1/p_value | tail_probability | 0.00092088119902911884 | 0.0009208811990291165 | 2.39E-18 | 14 | passed |
/steps/1/candidates/2/term | exact | B*C | B*C | passed | ||
/steps/1/candidates/2/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/2/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/2/lr_chi_square | tolerance | 0.021253672455205042 | 0.021253672455213868 | 8.83E-15 | 12 | passed |
/steps/1/candidates/2/p_value | tail_probability | 0.98942942911260756 | 0.9894294291126031 | 4.44E-15 | 14 | passed |
/steps/2/step | exact | 3 | 3 | 0.00E+2 | passed | |
/steps/2/model/0 | exact | A*B | A*B | passed | ||
/steps/2/model/1 | exact | A*C | A*C | passed | ||
/steps/2/candidates/0/term | exact | A*B | A*B | passed | ||
/steps/2/candidates/0/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/0/lr_chi_square | tolerance | 38.272312746871712 | 38.272312746871705 | 6.74E-15 | 15 | passed |
/steps/2/candidates/0/p_value | tail_probability | 4.8895949292945122e-09 | 4.889594929294536e-09 | 2.40E-23 | 14 | passed |
/steps/2/candidates/1/term | exact | A*C | A*C | passed | ||
/steps/2/candidates/1/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/2/candidates/1/lr_chi_square | tolerance | 13.646460849703535 | 13.646460849703528 | 6.76E-15 | 15 | passed |
/steps/2/candidates/1/p_value | tail_probability | 0.00022065684375480255 | 0.00022065684375480358 | 1.03E-18 | 14 | passed |
Convention
- highest_order_only: at each step only terms of the highest order present are candidates.
- Backward elimination from the saturated model: each maximal term whose removal keeps the model hierarchical (and that is not inside a term fixed by the sampling design) is tested by G^2(reduced) - G^2(current) on the df difference; the candidate with the largest p above alpha is removed, ties going to the higher-order term and then the term earlier in table order; the search stops when no candidate exceeds alpha (docs/manual/chapters/86-regression-and-count-models.tex:193-197).
- Candidates are listed by order (highest first) and then table order; df and deviances come from Poisson fits on the full positive table, so every fit is interior and the chi-square reference applies.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
164 r <- backward(list(), 0.05, highest_only = TRUE)
165 emit("STAT-REG-LOGLINEAR-SELECTION-003", "axis_coverage", c(common, list(alpha = 0.05, highest_order_only = TRUE)),
166 selection_outputs(r),
167 list("highest_order_only: at each step only terms of the highest order present are candidates."))
STAT REG LOGLINEAR SELECTION 004
Case STAT-REG-LOGLINEAR-SELECTION-004 · status: passed
Reference
- Evidence type
- R
- Source
- Base R implementation of hierarchical backward elimination over stats::glm(family = poisson) fits of each generating class; stats::pchisq
- Citation
- R Core Team, stats package help: glm, pchisq; Agresti (2013) Categorical Data Analysis, section 9.4 (hierarchical loglinear model selection by likelihood-ratio comparisons).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_loglinear_selection.R · sha256 0288dc1141c43c92
- Dataset
- reference_data/datasets/REG_LOGLINEAR_02.json
Settings compared
alpha= 0.05coding= "last"conditional_test= "off"confidence_level= 0.95count= "n"factors= ["A", "B", "C"]fixed_margins= ["A", "B"]highest_order_only= falsesampling= "product_multinomial"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/final/deviance | tolerance | 0.28052006952224084 | 0.28052006952224434 | 3.50E-15 | 13 | passed |
/final/df | exact | 4 | 4 | 0.00E+2 | passed | |
/final/deviance_p | tail_probability | 0.99103671421156425 | 0.991036714211564 | 2.21E-16 | 15 | passed |
/final/boundary | exact | False | False | passed | ||
/final/generators/0 | exact | A*B | A*B | passed | ||
/final/generators/1 | exact | A*C | A*C | passed | ||
/steps/0/step | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/0/model/0 | exact | A*B*C | A*B*C | passed | ||
/steps/0/removed | exact | A*B*C | A*B*C | passed | ||
/steps/0/candidates/0/term | exact | A*B*C | A*B*C | passed | ||
/steps/0/candidates/0/order | exact | 3 | 3 | 0.00E+2 | passed | |
/steps/0/candidates/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/0/candidates/0/lr_chi_square | tolerance | 0.25926639706703114 | 0.2592663970670338 | 2.66E-15 | 13 | passed |
/steps/0/candidates/0/p_value | tail_probability | 0.87841757669049492 | 0.8784175766904936 | 1.34E-15 | 14 | passed |
/steps/1/step | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/model/0 | exact | A*B | A*B | passed | ||
/steps/1/model/1 | exact | A*C | A*C | passed | ||
/steps/1/model/2 | exact | B*C | B*C | passed | ||
/steps/1/removed | exact | B*C | B*C | passed | ||
/steps/1/candidates/0/term | exact | A*C | A*C | passed | ||
/steps/1/candidates/0/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/0/df | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/1/candidates/0/lr_chi_square | tolerance | 10.980247717241989 | 10.980247717241992 | 3.33E-15 | 15 | passed |
/steps/1/candidates/0/p_value | tail_probability | 0.00092088119902911884 | 0.0009208811990291165 | 2.39E-18 | 14 | passed |
/steps/1/candidates/1/term | exact | B*C | B*C | passed | ||
/steps/1/candidates/1/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/1/df | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/1/candidates/1/lr_chi_square | tolerance | 0.021253672455205042 | 0.021253672455213868 | 8.83E-15 | 12 | passed |
/steps/1/candidates/1/p_value | tail_probability | 0.98942942911260756 | 0.9894294291126031 | 4.44E-15 | 14 | passed |
/steps/2/step | exact | 3 | 3 | 0.00E+2 | passed | |
/steps/2/model/0 | exact | A*B | A*B | passed | ||
/steps/2/model/1 | exact | A*C | A*C | passed | ||
/steps/2/candidates/0/term | exact | A*C | A*C | passed | ||
/steps/2/candidates/0/order | exact | 2 | 2 | 0.00E+2 | passed | |
/steps/2/candidates/0/df | exact | 1 | 1 | 0.00E+2 | passed | |
/steps/2/candidates/0/lr_chi_square | tolerance | 13.646460849703535 | 13.646460849703528 | 6.76E-15 | 15 | passed |
/steps/2/candidates/0/p_value | tail_probability | 0.00022065684375480255 | 0.00022065684375480358 | 1.03E-18 | 14 | passed |
Convention
- Product-multinomial with A, B totals fixed: A*B and its subterms are never candidates; the Poisson fitted counts and G^2 are unchanged.
- Backward elimination from the saturated model: each maximal term whose removal keeps the model hierarchical (and that is not inside a term fixed by the sampling design) is tested by G^2(reduced) - G^2(current) on the df difference; the candidate with the largest p above alpha is removed, ties going to the higher-order term and then the term earlier in table order; the search stops when no candidate exceeds alpha (docs/manual/chapters/86-regression-and-count-models.tex:193-197).
- Candidates are listed by order (highest first) and then table order; df and deviances come from Poisson fits on the full positive table, so every fit is interior and the chi-square reference applies.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
170 r <- backward(list(c("A", "B")), 0.05)
171 emit("STAT-REG-LOGLINEAR-SELECTION-004", "axis_coverage",
172 list(factors = list("A", "B", "C"), count = "n", sampling = "product_multinomial",
173 fixed_margins = list("A", "B"), coding = "last", confidence_level = 0.95,
174 conditional_test = "off", alpha = 0.05, highest_order_only = FALSE),
175 selection_outputs(r),
176 list("Product-multinomial with A, B totals fixed: A*B and its subterms are never candidates; the Poisson fitted counts and G^2 are unchanged."))
No missing values bypass imputation and give the ordinary OLS fit
Case STAT-REG-MI-NOMISS-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand calculation
- Citation
- Least-squares normal equations; predictive mean matching donor rule
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/REG_MI_COMPLETE.json
Settings compared
analysis= {"model": "ols", "outcome": "y", "predictors": ["x"]}confidence_level= 0.95imputations= 2seed= 20260923sweeps= 40variables= [{"column": "y", "kind": "numeric"}, {"column": "x", "kind": "numeric"}]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/mode | exact | no_missing | no_missing | passed | ||
/terms/[term=Intercept]/estimate | tolerance | 2.2 | 2.1999999999999984 | 1.60E-15 | 15 | passed |
/terms/[term=x]/estimate | tolerance | 0.6 | 0.6000000000000004 | 4.22E-16 | 15 | passed |
/terms/[term=x]/std_error | tolerance | 0.28284271247461901 | 0.28284271247461895 | 5.86E-17 | 15 | passed |
/terms/[term=Intercept]/std_error | tolerance | 0.93808315196468595 | 0.9380831519646856 | 3.37E-16 | 15 | passed |
/terms/[term=x]/df | tolerance | 3 | 3.0 | 0.00E+2 | 15 | passed |
/terms/[term=x]/between_variance | tolerance | 0 | 0.0 | 0.00E+2 | 15 | passed |
Convention
- x = 1..5, y = 2, 4, 5, 4, 5: Sxx = 10, Sxy = 6, RSS = 2.4 by hand.
- The ordinary analysis uses its own residual df, not Barnard-Rubin.
Predictive mean matching copies an observed donor value
Case STAT-REG-MI-PMM-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand calculation
- Citation
- Least-squares normal equations; predictive mean matching donor rule
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/REG_MI_CONSTANT.json
Settings compared
config= {"variables": [{"column": "y", "kind": "numeric"}, {"column": "x", "kind": "numeric"}], "analysis": {"model": "ols", "outcome": "y", "predictors": ["x"]}, "imputations": 2, "sweeps": 40, "seed": 20260923, "confidence_level": 0.95}imputation= 2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/1/x | tolerance | 2 | 2 | 0.00E+2 | 15 | passed |
/4/x | tolerance | 2 | 2 | 0.00E+2 | 15 | passed |
/0/x | tolerance | 2 | 2 | 0.00E+2 | 15 | passed |
/5/y | tolerance | 6 | 6 | 0.00E+2 | 15 | passed |
Convention
- With zero residual variance the coefficient draw is degenerate and the donor value is the only observed value, so the completed cells are exactly 2.
Replaying the completed-dataset operation recreates the recorded table
Case STAT-REG-MI-TABLE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Hand calculation
- Citation
- Least-squares normal equations; predictive mean matching donor rule
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/REG_MI_AUXILIARY.json
Settings compared
config= {"variables": [{"column": "y", "kind": "numeric"}, {"column": "x", "kind": "numeric"}, {"column": "z", "kind": "numeric"}], "analysis": {"model": "ols", "outcome": "y", "predictors": ["z"]}, "imputations": 2, "sweeps": 40, "seed": 20260923, "confidence_level": 0.95}imputation= 1
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/frame/1/x | tolerance | 2 | 2 | 0.00E+2 | 15 | passed |
/frame/4/x | tolerance | 2 | 2 | 0.00E+2 | 15 | passed |
/frame/3/x | tolerance | 2 | 2 | 0.00E+2 | 15 | passed |
/frame/4/z | tolerance | 5 | 5 | 0.00E+2 | 15 | passed |
/row_ids_unique | exact | True | True | passed |
Convention
- Replay verifies the recorded fingerprint of the imputed cells before returning.
Regression setting STAT-REG-MISSING-EFFECTS-001
Case STAT-REG-MISSING-EFFECTS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations | exact | 68 | 68 | 0.00E+2 | passed | |
/residual_variance | tolerance | 0.23979370253309201 | 0.23979370253309196 | 5.31E-17 | 15 | passed |
Convention
- Missing selected values are omitted listwise after active exclusions.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
168 effects_pop <- stats::lm(y ~ x + group, data = linear_pop)
169 emit("STAT-REG-MISSING-EFFECTS-001", "tabelz.executor.linear_effects",
170 "linearEffectsMenuItem", "missing_excluded",
171 list(response_column = "y", factor_columns = list("group"), covariate_columns = list("x")),
172 list("/observations" = exact(nrow(linear_pop), "retained effects rows"),
173 "/residual_variance" = tol(summary(effects_pop)$sigma^2, "retained effects residual variance")),
174 list("Missing selected values are omitted listwise after active exclusions."),
175 dataset = "REG_MISSING", excluded = list(2L, 7L))
Regression setting STAT-REG-MISSING-GENERAL-001
Case STAT-REG-MISSING-GENERAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"test_type= "III"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations | exact | 68 | 68 | 0.00E+2 | passed | |
/residual_variance | tolerance | 0.23979370253309196 | 0.23979370253309198 | 2.47E-17 | 15 | passed |
Convention
- Missing selected values are omitted listwise after active exclusions.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
157 linear_pop <- remaining[stats::complete.cases(remaining[c("y", "x", "group")]), , drop = FALSE]
158 general_pop <- stats::lm(y ~ x + group, data = linear_pop,
159 contrasts = list(group = stats::contr.sum(3)))
160 emit("STAT-REG-MISSING-GENERAL-001", "tabelz.executor.general_linear",
161 "generalLinearMenuItem", "missing_excluded",
162 list(response_column = "y", factor_columns = list("group"),
163 covariate_columns = list("x"), test_type = "III"),
164 list("/observations" = exact(nrow(linear_pop), "retained general-linear rows"),
165 "/residual_variance" = tol(summary(general_pop)$sigma^2, "retained GLM residual variance")),
166 list("Missing selected values are omitted listwise after active exclusions."),
167 dataset = "REG_MISSING", excluded = list(2L, 7L))
Regression setting STAT-REG-MISSING-NB-001
Case STAT-REG-MISSING-NB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
count= "nb_count"exposure= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 68 | 68 | 0.00E+2 | passed | |
/coefficients/1/coefficient | tolerance | 0.16041111698946656 | 0.16041111698949295 | 2.64E-14 | 12 | passed |
Convention
- Two active exclusions are applied before complete-case NB2 fitting.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
146 nb_pop <- remaining[stats::complete.cases(remaining[c("nb_count", "x", "exposure")]), , drop = FALSE]
147 nb_pop_fit <- MASS::glm.nb(nb_count ~ x + offset(log(exposure)), data = nb_pop,
148 control = stats::glm.control(maxit = 1000, epsilon = 1e-12))
149 emit("STAT-REG-MISSING-NB-001", "tabelz.analysis.negative_binomial:compute_negative_binomial",
150 "nbRegressionMenuItem", "missing_excluded",
151 list(count = "nb_count", predictors = list("x"), exposure = "exposure"),
152 list("/n" = exact(nrow(nb_pop), "retained NB2 rows"),
153 "/coefficients/1/coefficient" = tol(coef(nb_pop_fit)[["x"]], "retained NB2 slope")),
154 list("Two active exclusions are applied before complete-case NB2 fitting."),
155 dataset = "REG_MISSING", excluded = list(2L, 7L))
Small-sample boundary STAT-REG-MIXED-MIN-001
Case STAT-REG-MIXED-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/MASS/pls/stats
- Citation
- R nlme::lme, MASS::lda, pls::plsr and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_b.R · sha256 e3e09e1965800ae1
- Dataset
- reference_data/datasets/REG_MIN_MIXED.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/analyzed_count | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Two groups have two complete observations each, meeting the random-intercept minimum.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
22 types <- c(distance="Float64",age="Float64",subject="String",sex="String",
23 time="Int64",age_sq="Float64")
24 four <- orth[c(1L,2L,5L,6L),]
25 export_dataset(four,"REG_MIN_MIXED","Two repeated subjects with two observations each",
26 "R nlme random-intercept small-sample boundary",
27 "Derived from R nlme::Orthodont; retain attribution.",types)
28 m <- read_dataset("REG_MIN_MIXED")
29 fit <- nlme::lme(distance~age,random=~1|subject,data=m,method="REML",
30 control=nlme::lmeControl(opt="optim"))
31 emit("STAT-REG-MIXED-MIN-001","tabelz.executor.mixed_models","mixedModelsMenuItem",
32 "REG_MIN_MIXED",
33 list(response_column="distance",group_column="subject",
34 fixed_numeric_columns=list("age"),estimation="reml"),
35 list("/coefficients/1/estimate"=list(comparison = "tolerance", value = "0", absolute_tolerance = "1e-12", relative_tolerance = "0",
36 rationale = paste("Exactly zero by the design's symmetry; any implementation returns rounding",
37 "noise of order 1e-15, so an absolute 1e-12 replaces a relative tier that",
38 "cannot compare with zero. R gives", format(nlme::fixef(fit)[["age"]], digits = 17))),
39 "/analyzed_count"=exact(nrow(m),"four analyzed rows")),
40 c("Two groups have two complete observations each, meeting the random-intercept minimum."))
Regression II STAT-REG-MIXED-ML-001
Case STAT-REG-MIXED-ML-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats
- Citation
- R nlme::Orthodont, nlme::lme, plm::plm, stats::nls/lm/step documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_core.R · sha256 b7543c65b2778e63
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
estimation= "ml"fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.66018518518518554 | 0.6601851851851851 | 4.43E-16 | 15 | passed |
Convention
- R nlme maximum likelihood selected explicitly; compare only fixed slope.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
60 mixed_ml <- nlme::lme(distance ~ age, random = ~1 | subject, data = d,
61 method = "ML", control = nlme::lmeControl(opt = "optim"))
62 emit("STAT-REG-MIXED-ML-001", "tabelz.executor.mixed_models",
63 "mixedModelsMenuItem", "REG_ORTHODONT",
64 list(response_column = "distance", group_column = "subject",
65 fixed_numeric_columns = list("age"), estimation = "ml"),
66 list("/coefficients/1/estimate" = tol(nlme::fixef(mixed_ml)[["age"]], "ML age slope")),
67 list("R nlme maximum likelihood selected explicitly; compare only fixed slope."),
68 kind = "nominal")
Regression II STAT-REG-MIXED-REML-001
Case STAT-REG-MIXED-REML-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats
- Citation
- R nlme::Orthodont, nlme::lme, plm::plm, stats::nls/lm/step documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_core.R · sha256 b7543c65b2778e63
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.66018518518518543 | 0.660185185185185 | 4.44E-16 | 15 | passed |
/analyzed_count | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- R nlme random intercept; REML is the manual default. No fallback estimator.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
50 mixed <- nlme::lme(distance ~ age, random = ~1 | subject, data = d,
51 method = "REML", control = nlme::lmeControl(opt = "optim"))
52 emit("STAT-REG-MIXED-REML-001", "tabelz.executor.mixed_models",
53 "mixedModelsMenuItem", "REG_ORTHODONT",
54 list(response_column = "distance", group_column = "subject",
55 fixed_numeric_columns = list("age"), estimation = "reml"),
56 list("/coefficients/1/estimate" = tol(nlme::fixef(mixed)[["age"]], "REML age slope"),
57 "/analyzed_count" = exact(nrow(d), "complete repeated-measures rows")),
58 list("R nlme random intercept; REML is the manual default. No fallback estimator."))
Regression II STAT-REG-MIXED-STRUCT-SLOPE-001
Case STAT-REG-MIXED-STRUCT-SLOPE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats
- Citation
- R nlme::Orthodont, nlme::lme, plm::plm, stats::nls/lm/step documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_core.R · sha256 b7543c65b2778e63
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"model_mode= "random_slope"random_slope_column= "age"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.66018518518518521 | 0.6601851851851852 | 1.79E-18 | 17 | passed |
Convention
- R nlme correlated random intercept and age slope per subject, REML.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
70 random_slope <- nlme::lme(distance ~ age, random = ~age | subject, data = d,
71 method = "REML", control = nlme::lmeControl(opt = "optim"))
72 emit("STAT-REG-MIXED-STRUCT-SLOPE-001", "tabelz.executor.mixed_model_structures",
73 "mixedModelStructuresMenuItem", "REG_ORTHODONT",
74 list(response_column = "distance", fixed_numeric_columns = list("age"),
75 model_mode = "random_slope", group_column = "subject",
76 random_slope_column = "age", estimation = "reml"),
77 list("/coefficients/1/estimate" = tol(nlme::fixef(random_slope)[["age"]],
78 "random-slope fixed age effect")),
79 list("R nlme correlated random intercept and age slope per subject, REML."))
Regression edge STAT-REG-MIXED-UNBALANCED-001
Case STAT-REG-MIXED-UNBALANCED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/rpart
- Citation
- R nlme::lme, plm::plm, stats::nls/lm/step, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_a.R · sha256 b8ea61b61080b6f8
- Dataset
- reference_data/datasets/REG_EDGE_MIXED_UNBALANCED.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.18118811890615069 | 0.18118811886524047 | 4.09E-11 | 9 | passed |
/analyzed_count | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- One group is exactly at the two-observation minimum while the other has three rows.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
31 fit <- lme4::lmer(distance~age+(1|subject),data=u,REML=TRUE,
32 control=lme4::lmerControl(optCtrl=list(ftol_abs=1e-15,xtol_abs=1e-15),
33 check.conv.singular="ignore"))
34 emit("STAT-REG-MIXED-UNBALANCED-001","tabelz.executor.mixed_models","mixedModelsMenuItem",
35 "REG_EDGE_MIXED_UNBALANCED",
36 list(response_column="distance",group_column="subject",
37 fixed_numeric_columns=list("age"),estimation="reml"),
38 list("/coefficients/1/estimate"=tol(lme4::fixef(fit)[["age"]],"REML fixed age slope (lme4, converged)"),
39 "/analyzed_count"=exact(as.integer(nrow(u)),"five complete rows")),
40 c("One group is exactly at the two-observation minimum while the other has three rows."))
STAT REG NB 001
Case STAT-REG-NB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
count= "nb_count"exposure= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 0.18885301091697257 | 0.1888530109169838 | 1.12E-14 | 13 | passed |
/alpha | tolerance | 0.2172532280580998 | 0.217253228055847 | 2.25E-12 | 10 | passed |
Convention
- MASS glm.nb theta is inverse of Tabelz NB2 alpha; offset is log exposure.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
124 nb_entry <- "tabelz.analysis.negative_binomial:compute_negative_binomial"
125 nb_fit <- MASS::glm.nb(nb_count ~ x + offset(log(exposure)), data = d,
126 control = stats::glm.control(maxit = 1000, epsilon = 1e-12))
127 emit("STAT-REG-NB-001", nb_entry, "nbRegressionMenuItem", "nominal",
128 list(count = "nb_count", predictors = list("x"), exposure = "exposure"),
129 list("/coefficients/1/coefficient" = tol(coef(nb_fit)[["x"]], "NB2 log-rate slope"),
130 "/alpha" = tol(1 / nb_fit$theta, "NB2 dispersion alpha")),
131 list("MASS glm.nb theta is inverse of Tabelz NB2 alpha; offset is log exposure."))
STAT REG NOMINAL 001
Case STAT-REG-NOMINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
outcome_column= "nominal"predictors= ["x"]reference_value= "A"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | 8.9213382441815576e-05 | 8.921330315026448e-05 | 7.93E-11 | 6 | passed |
Convention
- R nnet multinom uses A as first factor level and reference; tight convergence.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
105 nominal_entry <- "tabelz.analysis.nominal_logistic:compute_nominal_logistic_regression"
106 d$nominal_factor <- factor(d$nominal, levels = c("A", "B", "C"))
107 nominal_fit <- nnet::multinom(nominal_factor ~ x, data = d, trace = FALSE,
108 maxit = 1000, reltol = 1e-15)
109 emit("STAT-REG-NOMINAL-001", nominal_entry, "nominalRegressionMenuItem", "nominal",
110 list(outcome_column = "nominal", reference_value = "A", predictors = list("x")),
111 list("/coefficients/0/coefficient" = tol(coef(nominal_fit)["B", "(Intercept)"],
112 "B vs A intercept")),
113 list("R nnet multinom uses A as first factor level and reference; tight convergence."))
Regression edge STAT-REG-NONLINEAR-BOUND-001
Case STAT-REG-NONLINEAR-BOUND-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/rpart
- Citation
- R nlme::lme, plm::plm, stats::nls/lm/step, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_a.R · sha256 b8ea61b61080b6f8
- Dataset
- reference_data/datasets/REG_EDGE_DECAY_BOUND.json
Settings compared
curve= "exponential_decay"parameters= [{"name": "a", "start": 9.5, "lower": 0, "upper": 10}, {"name": "k", "start": 0.8, "lower": 0.01, "upper": 3}, {"name": "c", "start": 1, "lower": 0, "upper": 5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/estimates/0 | tolerance | 10 | 9.999999999848912 | 1.51E-10 | 10 | passed |
/eligible_count | exact | 12 | 12 | 0.00E+2 | passed |
Convention
- True amplitude equals upper bound 10; R port and Tabelz use original response scale.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
56 curve <- data.frame(x=seq(0,5,length.out=12L))
57 curve$y <- 1+10*exp(-0.8*curve$x)
58 export_dataset(curve,"REG_EDGE_DECAY_BOUND","Exact exponential decay with amplitude at upper bound",
59 "R nls port bound-active fit",
60 "Constructed validation data; no third-party license.",
61 c(x="Float64",y="Float64"))
62 c <- read_dataset("REG_EDGE_DECAY_BOUND")
63 fit <- stats::nls(y~c0+a*exp(-k*x),data=c,
64 start=list(a=9.5,k=0.8,c0=1),algorithm="port",
65 lower=c(a=0,k=0.01,c0=0),upper=c(a=10,k=3,c0=5),
66 control=stats::nls.control(maxiter=1000,tol=1e-12))
67 emit("STAT-REG-NONLINEAR-BOUND-001","tabelz.executor.nonlinear_regression",
68 "nonlinearRegressionMenuItem","REG_EDGE_DECAY_BOUND",
69 list(x_column="x",response="y",curve="exponential_decay",
70 parameters=list(list(name="a",start=9.5,lower=0,upper=10),
71 list(name="k",start=0.8,lower=0.01,upper=3),
72 list(name="c",start=1,lower=0,upper=5))),
73 list("/artifact/estimates/0"=tol(coef(fit)[["a"]],"bound-active amplitude"),
74 "/eligible_count"=exact(as.integer(nrow(c)),"all twelve rows eligible")),
75 c("True amplitude equals upper bound 10; R port and Tabelz use original response scale."))
Regression II STAT-REG-NONLINEAR-DECAY-001
Case STAT-REG-NONLINEAR-DECAY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats
- Citation
- R nlme::Orthodont, nlme::lme, plm::plm, stats::nls/lm/step documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_core.R · sha256 b7543c65b2778e63
- Dataset
- reference_data/datasets/REG_DECAY.json
Settings compared
curve= "exponential_decay"parameters= [{"name": "a", "start": 4, "lower": 0, "upper": 10}, {"name": "k", "start": 0.8, "lower": 0.01, "upper": 3}, {"name": "c", "start": 1, "lower": 0, "upper": 5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/estimates/0 | tolerance | 4.0126115382909759 | 4.012611538326385 | 3.54E-11 | 11 | passed |
/artifact/estimates/1 | tolerance | 0.81258824513649197 | 0.8125882455563592 | 4.20E-10 | 9 | passed |
Convention
- R nls port bounds match the manual's strictly positive rate and original-response-scale loss.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
91 decay <- stats::nls(y ~ c + a * exp(-k * x), data = curve_data,
92 start = list(a = 4, k = 0.8, c = 1),
93 algorithm = "port", lower = c(a = 0, k = 0.01, c = 0),
94 upper = c(a = 10, k = 3, c = 5),
95 control = stats::nls.control(maxiter = 1000, tol = 1e-12))
96 emit("STAT-REG-NONLINEAR-DECAY-001", "tabelz.executor.nonlinear_regression",
97 "nonlinearRegressionMenuItem", "REG_DECAY",
98 list(x_column = "x", response = "y", curve = "exponential_decay",
99 parameters = list(list(name = "a", start = 4, lower = 0, upper = 10),
100 list(name = "k", start = 0.8, lower = 0.01, upper = 3),
101 list(name = "c", start = 1, lower = 0, upper = 5))),
102 list("/artifact/estimates/0" = tol(coef(decay)[["a"]], "decay amplitude"),
103 "/artifact/estimates/1" = tol(coef(decay)[["k"]], "decay rate")),
104 list("R nls port bounds match the manual's strictly positive rate and original-response-scale loss."))
Small-sample boundary STAT-REG-NONLINEAR-MIN-001
Case STAT-REG-NONLINEAR-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, plm, rpart
- Citation
- R stats::nls/lm, plm::plm, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_a.R · sha256 e69dea823e2a8f59
- Dataset
- reference_data/datasets/REG_MIN_DECAY.json
Settings compared
curve= "exponential_decay"parameters= [{"name": "a", "start": 4, "lower": 0, "upper": 10}, {"name": "k", "start": 0.8, "lower": 0.01, "upper": 3}, {"name": "c", "start": 1, "lower": 0, "upper": 5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/estimates/0 | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/eligible_count | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Four observations identify a three-parameter exponential-decay curve; R port uses matching bounds.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
35 curve <- data.frame(x=c(0,1,2,3))
36 curve$y <- 1+4*exp(-0.8*curve$x)
37 export_dataset(curve,"REG_MIN_DECAY","Four exact exponential-decay observations",
38 "R nls port three-parameter small-sample boundary",
39 "Constructed validation data; no third-party license.",
40 c(x="Float64",y="Float64"))
41 c <- read_dataset("REG_MIN_DECAY")
42 fit <- stats::nls(y~c0+a*exp(-k*x),data=c,start=list(a=4,k=0.8,c0=1),
43 algorithm="port",lower=c(a=0,k=0.01,c0=0),
44 upper=c(a=10,k=3,c0=5),
45 control=stats::nls.control(maxiter=1000,tol=1e-12))
46 emit("STAT-REG-NONLINEAR-MIN-001","tabelz.executor.nonlinear_regression",
47 "nonlinearRegressionMenuItem","REG_MIN_DECAY",
48 list(x_column="x",response="y",curve="exponential_decay",
49 parameters=list(list(name="a",start=4,lower=0,upper=10),
50 list(name="k",start=0.8,lower=0.01,upper=3),
51 list(name="c",start=1,lower=0,upper=5))),
52 list("/artifact/estimates/0"=tol(coef(fit)[["a"]],"exact decay amplitude","1e-6"),
53 "/eligible_count"=exact(nrow(c),"all four fit rows")),
54 c("Four observations identify a three-parameter exponential-decay curve; R port uses matching bounds."))
Regression setting STAT-REG-NUMERIC-BINARY-001
Case STAT-REG-NUMERIC-BINARY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.9event_value= "event"outcome_column= "binary"predictors= ["x"]threshold= 0.3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/accuracy | tolerance | 0.93055555555555558 | 0.9305555555555556 | 2.27E-19 | 18 | passed |
/coefficients/1/odds_ratio_ci_lower | tolerance | 0.6681074619659817 | 0.6681074619659815 | 2.25E-16 | 15 | passed |
Convention
- Threshold 0.3 changes only classification; Wald interval uses z[0.95].
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
50 binary <- stats::glm(I(binary == "event") ~ x, family = stats::binomial(), data = d)
51 binary_p <- as.vector(stats::predict(binary, type = "response"))
52 binary_actual <- d$binary == "event"
53 binary_estimate <- coef(binary)[["x"]]
54 binary_se <- summary(binary)$coefficients["x", "Std. Error"]
55 emit("STAT-REG-NUMERIC-BINARY-001",
56 "tabelz.analysis.logistic_regression:compute_binary_logistic_regression",
57 "logisticRegressionMenuItem", "axis_coverage",
58 list(outcome_column = "binary", event_value = "event", predictors = list("x"),
59 threshold = 0.3, confidence_level = 0.9),
60 list("/accuracy" = tol(mean((binary_p >= 0.3) == binary_actual), "0.3-threshold accuracy"),
61 "/coefficients/1/odds_ratio_ci_lower" = tol(exp(binary_estimate -
62 stats::qnorm(0.95) * binary_se), "90 percent Wald OR lower")),
63 list("Threshold 0.3 changes only classification; Wald interval uses z[0.95]."))
Regression setting STAT-REG-NUMERIC-EFFECTS-CONFIDENCE-001
Case STAT-REG-NUMERIC-EFFECTS-CONFIDENCE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.9covariate_columns= ["x"]factor_columns= ["group"]max_rows= 100response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Manual chapter 07: individual 95% t intervals; a 90% request must be refused.
- Until 2026-09-25 this case wrongly expected a 90% interval; -095-001 checks the 95% interval.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
324 emit("STAT-REG-NUMERIC-EFFECTS-CONFIDENCE-001", effects_entry, "linearEffectsMenuItem",
325 "invalid_input",
326 list(response_column = "y", factor_columns = list("group"),
327 covariate_columns = list("x"), confidence_level = 0.9, max_rows = 100L),
328 structure(list(), names = character()),
329 list("Manual chapter 07: individual 95% t intervals; a 90% request must be refused.",
330 "Until 2026-09-25 this case wrongly expected a 90% interval; -095-001 checks the 95% interval."),
331 error = list(error_class = "ValidationError", message_contains = "fixed at 95%"))
Regression setting STAT-REG-NUMERIC-EFFECTS-CONFIDENCE-095-001
Case STAT-REG-NUMERIC-EFFECTS-CONFIDENCE-095-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.95covariate_columns= ["x"]factor_columns= ["group"]max_rows= 100response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/adjusted_means/0/lower | tolerance | 2.6747655185408963 | 2.674765518540895 | 1.35E-15 | 15 | passed |
Convention
- Individual t interval from R predict.lm fit and se.fit at complete-case mean x.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
332 emit("STAT-REG-NUMERIC-EFFECTS-CONFIDENCE-095-001", effects_entry, "linearEffectsMenuItem",
333 "axis_coverage",
334 list(response_column = "y", factor_columns = list("group"),
335 covariate_columns = list("x"), confidence_level = 0.95, max_rows = 100L),
336 list("/adjusted_means/0/lower" = tol(effects_ci, "95 percent effects mean A lower")),
337 list("Individual t interval from R predict.lm fit and se.fit at complete-case mean x."))
Regression completion STAT-REG-NUMERIC-EFFECTS-MAXROWS-001
Case STAT-REG-NUMERIC-EFFECTS-MAXROWS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fit
- Citation
- R stats::glm/lm and car::Anova help pages; Tabelz manual chapters 07 and 08
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_lastmile.R · sha256 512832af1db86a5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]max_rows= 100response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations | exact | 72 | 72 | 0.00E+2 | passed | |
/residual_variance | tolerance | 0.23796443428945271 | 0.2379644342894525 | 2.18E-16 | 15 | passed |
Convention
- Manual fixes individual intervals at 95%; max_rows=100 is the valid non-default numeric setting.
- The fit uses only the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
71 effects_fit <- stats::lm(y ~ group + x, data = d)
72 emit("STAT-REG-NUMERIC-EFFECTS-MAXROWS-001", "tabelz.executor.linear_effects",
73 "linearEffectsMenuItem", "axis_coverage", "REG_CORE",
74 list(response_column = "y", factor_columns = list("group"),
75 covariate_columns = list("x"), max_rows = 100L),
76 list("/observations" = exact(nrow(d), "72 below explicit row cap 100"),
77 "/residual_variance" = tol(summary(effects_fit)$sigma^2,
78 "linear-effects residual variance")),
79 list("Manual fixes individual intervals at 95%; max_rows=100 is the valid non-default numeric setting."))
Fit axis STAT-REG-NUMERIC-FIT-ALPHA-001
Case STAT-REG-NUMERIC-FIT-ALPHA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
alpha_level= 0.1x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/lower_ci | tolerance | 1.340468143356099 | 1.3404681433560992 | 2.07E-16 | 15 | passed |
Convention
- The manual passes alpha=1-confidence to the OLS t interval; 0.1 gives 90 percent.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
132 alpha_fit <- stats::lm(y ~ x + z, data = d)
133 ci <- stats::confint(alpha_fit, level = 0.9)
134 emit("STAT-REG-NUMERIC-FIT-ALPHA-001", fit_entry, "REG_CORE",
135 list(y_columns = list("y"), x_columns = list("x", "z"), alpha_level = 0.1),
136 list("/responses/0/parameters/1/lower_ci" = tol(ci["x", 1], "90 percent x lower CI")),
137 list("The manual passes alpha=1-confidence to the OLS t interval; 0.1 gives 90 percent."),
138 kind = "axis_coverage")
Fit axis STAT-REG-NUMERIC-FIT-DEGREE3-001
Case STAT-REG-NUMERIC-FIT-DEGREE3-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
degree= 3model_type= "polynomial"x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/3/estimate | tolerance | 0.0054971828906514838 | 0.005497182890651998 | 5.14E-16 | 13 | passed |
Convention
- Non-default polynomial degree three, with powers x, x-squared and x-cubed.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
72 poly3 <- stats::lm(y ~ x + I(x^2) + I(x^3), data = p)
73 emit("STAT-REG-NUMERIC-FIT-DEGREE3-001", fit_entry, "REG_POSITIVE",
74 list(y_columns = list("y"), x_columns = list("x"), model_type = "polynomial", degree = 3L),
75 list("/responses/0/parameters/3/estimate" = tol(coef(poly3)[[4]], "cubic coefficient")),
76 list("Non-default polynomial degree three, with powers x, x-squared and x-cubed."),
77 kind = "axis_coverage")
Fit axis STAT-REG-NUMERIC-FIT-HOLDOUT-001
Case STAT-REG-NUMERIC-FIT-HOLDOUT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R lm and matrix algebra
- Citation
- R stats::lm, sandwich::vcovHC documentation; Tabelz manual chapter 07
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, sandwich 3.1.3, jsonlite 2.0.0
- Reference script
- generators/r/regression_fit_axes.R · sha256 2e4f649c93f83e5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
split_percent= 80x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/training_observations | exact | 57 | 57 | 0.00E+2 | passed |
Convention
- The holdout split is Python-seeded; only its deterministic training count is referenceable in R.
- All numeric references use re-read exported CSV values.
Reference code
The lines of the reference script that produce this case's expected values.
140 emit("STAT-REG-NUMERIC-FIT-HOLDOUT-001", fit_entry, "REG_CORE",
141 list(y_columns = list("y"), x_columns = list("x", "z"), split_percent = 80L),
142 list("/responses/0/training_observations" = exact(floor(0.8 * nrow(d)),
143 "80 percent training share")),
144 list("The holdout split is Python-seeded; only its deterministic training count is referenceable in R."),
145 kind = "axis_coverage",
146 deferred = list(list(path = "/responses/0/parameters/1/estimate",
147 reason = "Python's seeded row split is not the same as an R RNG split.")))
Regression setting STAT-REG-NUMERIC-GENERAL-CONFIDENCE-001
Case STAT-REG-NUMERIC-GENERAL-CONFIDENCE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.9covariate_columns= ["x"]factor_columns= ["group"]max_rows= 100response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Manual chapter 08: individual 95% t intervals; a 90% request must be refused.
- Until 2026-09-25 this case wrongly expected a 90% interval; -095-001 checks the 95% interval.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
306 emit("STAT-REG-NUMERIC-GENERAL-CONFIDENCE-001", general_entry, "generalLinearMenuItem",
307 "invalid_input", config_general_conf, structure(list(), names = character()),
308 list("Manual chapter 08: individual 95% t intervals; a 90% request must be refused.",
309 "Until 2026-09-25 this case wrongly expected a 90% interval; -095-001 checks the 95% interval."),
310 error = list(error_class = "ValidationError", message_contains = "fixed at 95%"))
Regression setting STAT-REG-NUMERIC-GENERAL-CONFIDENCE-095-001
Case STAT-REG-NUMERIC-GENERAL-CONFIDENCE-095-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.95covariate_columns= ["x"]factor_columns= ["group"]max_rows= 100response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/adjusted_means/0/lower | tolerance | 2.6747655185408958 | 2.674765518540896 | 3.67E-17 | 16 | passed |
Convention
- Individual t interval from R predict.lm fit and se.fit at complete-case mean x; no simultaneous adjustment.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
311 config_general_conf$confidence_level <- 0.95
312 emit("STAT-REG-NUMERIC-GENERAL-CONFIDENCE-095-001", general_entry, "generalLinearMenuItem",
313 "axis_coverage", config_general_conf,
314 list("/adjusted_means/0/lower" = tol(general_ci, "95 percent adjusted mean A lower")),
315 list("Individual t interval from R predict.lm fit and se.fit at complete-case mean x; no simultaneous adjustment."))
Regression completion STAT-REG-NUMERIC-GENERAL-MAXROWS-001
Case STAT-REG-NUMERIC-GENERAL-MAXROWS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fit
- Citation
- R stats::glm/lm and car::Anova help pages; Tabelz manual chapters 07 and 08
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_lastmile.R · sha256 512832af1db86a5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]max_rows= 100response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations | exact | 72 | 72 | 0.00E+2 | passed | |
/residual_variance | tolerance | 0.23796443428945255 | 0.23796443428945255 | 2.28E-18 | 17 | passed |
Convention
- Manual fixes individual intervals at 95%; max_rows=100 is the valid non-default numeric setting.
- The fit uses only the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
59 general_entry <- "tabelz.executor.general_linear"
60 general_fit <- stats::lm(y ~ group + x, data = d,
61 contrasts = list(group = stats::contr.sum(3)))
62 emit("STAT-REG-NUMERIC-GENERAL-MAXROWS-001", general_entry,
63 "generalLinearMenuItem", "axis_coverage", "REG_CORE",
64 list(response_column = "y", factor_columns = list("group"),
65 covariate_columns = list("x"), max_rows = 100L),
66 list("/observations" = exact(nrow(d), "72 below explicit row cap 100"),
67 "/residual_variance" = tol(summary(general_fit)$sigma^2,
68 "general-linear residual variance")),
69 list("Manual fixes individual intervals at 95%; max_rows=100 is the valid non-default numeric setting."))
Regression setting STAT-REG-NUMERIC-NB-001
Case STAT-REG-NUMERIC-NB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.9count= "nb_count"exposure= "exposure"max_rows= 100predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/rate_ratio_ci_lower | tolerance | 1.1018805768325608 | 1.101880576832774 | 2.13E-13 | 12 | passed |
Convention
- MASS theta=1/alpha; confidence 0.9 and row cap 100 are explicit.
- Issue #11 ruling: joint observed-information SE from the analytic NB2 Hessian; until 2026-09-25 this case used glm.nb's conditional expected-information SE.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
133 nb_se <- sqrt(diag(nb_joint_covariance(nb)))[["x"]]
134 stopifnot(abs(nb_se - 0.05583151840027438) < 1e-12)
135 emit("STAT-REG-NUMERIC-NB-001", "tabelz.analysis.negative_binomial:compute_negative_binomial",
136 "nbRegressionMenuItem", "axis_coverage",
137 list(count = "nb_count", predictors = list("x"), exposure = "exposure",
138 confidence_level = 0.9, max_rows = 100L),
139 list("/coefficients/1/rate_ratio_ci_lower" = tol(exp(coef(nb)[["x"]] -
140 stats::qnorm(0.95) * nb_se), "90 percent NB2 Wald rate-ratio lower, joint observed information")),
141 list("MASS theta=1/alpha; confidence 0.9 and row cap 100 are explicit.",
142 "Issue #11 ruling: joint observed-information SE from the analytic NB2 Hessian; until 2026-09-25 this case used glm.nb's conditional expected-information SE."))
Regression setting STAT-REG-NUMERIC-NOMINAL-001
Case STAT-REG-NUMERIC-NOMINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.9outcome_column= "nominal"predictors= ["x"]reference_value= "C"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/rrr_ci_lower | tolerance | 0.72194831528281311 | 0.7219483170221362 | 1.74E-9 | 8 | passed |
Convention
- R first level C is explicit reference; numeric confidence setting is non-default.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
79 nom <- d
80 nom$response <- factor(nom$nominal, levels = c("C", "A", "B"))
81 nom_fit <- nnet::multinom(response ~ x, data = nom, trace = FALSE,
82 maxit = 1000, reltol = 1e-15)
83 nom_se <- summary(nom_fit)$standard.errors["A", "x"]
84 emit("STAT-REG-NUMERIC-NOMINAL-001",
85 "tabelz.analysis.nominal_logistic:compute_nominal_logistic_regression",
86 "nominalRegressionMenuItem", "axis_coverage",
87 list(outcome_column = "nominal", reference_value = "C", predictors = list("x"),
88 confidence_level = 0.9),
89 list("/coefficients/1/rrr_ci_lower" = tol(exp(coef(nom_fit)["A", "x"] -
90 stats::qnorm(0.95) * nom_se), "A-vs-C 90 percent Wald RRR lower")),
91 list("R first level C is explicit reference; numeric confidence setting is non-default."))
Regression setting STAT-REG-NUMERIC-ORDINAL-001
Case STAT-REG-NUMERIC-ORDINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.9level_order= ["low", "middle", "high"]outcome_column= "ordinal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/odds_ratio_ci_lower | tolerance | 0.82751214414796526 | 0.827512250559546 | 1.06E-7 | 6 | passed |
Convention
- MASS polr uses the manual's positive-at-higher-level slope sign.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
65 ord <- d
66 ord$response <- ordered(ord$ordinal, levels = c("low", "middle", "high"))
67 ord_fit <- MASS::polr(response ~ x, data = ord, method = "logistic", Hess = TRUE,
68 control = list(maxit = 1000, reltol = 1e-15))
69 ord_se <- summary(ord_fit)$coefficients["x", "Std. Error"]
70 emit("STAT-REG-NUMERIC-ORDINAL-001",
71 "tabelz.analysis.ordinal_logistic:compute_ordinal_logistic_regression",
72 "ordinalRegressionMenuItem", "axis_coverage",
73 list(outcome_column = "ordinal", predictors = list("x"),
74 level_order = list("low", "middle", "high"), confidence_level = 0.9),
75 list("/coefficients/0/odds_ratio_ci_lower" = tol(exp(coef(ord_fit)[["x"]] -
76 stats::qnorm(0.95) * ord_se), "90 percent ordered-logit Wald OR lower")),
77 list("MASS polr uses the manual's positive-at-higher-level slope sign."))
Regression setting STAT-REG-NUMERIC-POISSON-001
Case STAT-REG-NUMERIC-POISSON-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
confidence_level= 0.9count_column= "count"exposure_column= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/rate_ratio_ci_lower | tolerance | 1.1050049502302077 | 1.1050051844018285 | 2.34E-7 | 6 | passed |
Convention
- Poisson uses a log-exposure offset and a Wald rather than profile-likelihood interval.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
93 pois <- stats::glm(count ~ x + offset(log(exposure)), data = d,
94 family = stats::poisson())
95 pois_se <- summary(pois)$coefficients["x", "Std. Error"]
96 emit("STAT-REG-NUMERIC-POISSON-001",
97 "tabelz.analysis.poisson_regression:compute_poisson_regression",
98 "poissonRegressionMenuItem", "axis_coverage",
99 list(count_column = "count", predictors = list("x"), exposure_column = "exposure",
100 confidence_level = 0.9),
101 list("/coefficients/1/rate_ratio_ci_lower" = tol(exp(coef(pois)[["x"]] -
102 stats::qnorm(0.95) * pois_se), "90 percent Poisson Wald rate-ratio lower")),
103 list("Poisson uses a log-exposure offset and a Wald rather than profile-likelihood interval."))
Regression setting STAT-REG-NUMERIC-VIF-DEGREE3-001
Case STAT-REG-NUMERIC-VIF-DEGREE3-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_POSITIVE.json
Settings compared
degree= 3interactions= falsemissing= "drop"model_type= "polynomial"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 478.08473800010495 | 478.084738000087 | 1.80E-11 | 13 | passed |
Convention
- R auxiliary OLS conditions x on z, x^2, z^2, x^3 and z^3.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
211 positive <- read_dataset("REG_POSITIVE")
212 poly3_design <- data.frame(x = positive$x, z = positive$z,
213 x2 = positive$x^2, z2 = positive$z^2,
214 x3 = positive$x^3, z3 = positive$z^3)
215 poly3_vif <- 1 / (1 - summary(stats::lm(x ~ z + x2 + z2 + x3 + z3,
216 data = poly3_design))$r.squared)
217 emit("STAT-REG-NUMERIC-VIF-DEGREE3-001", vif_entry, "fitYByXMenuItem", "axis_coverage",
218 list(y_columns = list("y"), x_columns = list("x", "z"), missing = "drop",
219 model_type = "polynomial", degree = 3L, interactions = FALSE,
220 split_percent = 100L),
221 list("/0" = tol(poly3_vif, "cubic-design x VIF")),
222 list("R auxiliary OLS conditions x on z, x^2, z^2, x^3 and z^3."),
223 dataset = "REG_POSITIVE")
Regression setting STAT-REG-NUMERIC-VIF-HOLDOUT-001
Case STAT-REG-NUMERIC-VIF-HOLDOUT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "linear"split_percent= 80x_columns= ["x"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed |
Convention
- For one selected X, the auxiliary regression has no other predictors, so VIF=1 under any training-row split.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
205 vif_entry <- "tabelz.analysis.fit_y_by_x:compute_fit_vif"
206 emit("STAT-REG-NUMERIC-VIF-HOLDOUT-001", vif_entry, "fitYByXMenuItem", "axis_coverage",
207 list(y_columns = list("y"), x_columns = list("x"), missing = "drop",
208 model_type = "linear", degree = 2L, interactions = FALSE, split_percent = 80L),
209 list("/0" = tol(1, "single-predictor VIF invariant", "1e-9")),
210 list("For one selected X, the auxiliary regression has no other predictors, so VIF=1 under any training-row split."))
STAT REG OLS 001
Case STAT-REG-OLS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/parameters/1/estimate | tolerance | 1.398762625407082 | 1.3987626254070822 | 1.83E-16 | 15 | passed |
/responses/0/metrics/sse | tolerance | 15.715641043747024 | 15.715641043747024 | 4.69E-16 | 16 | passed |
Convention
- Classical OLS with intercept; R lm coefficients and residual sum of squares.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
67 fit <- stats::lm(y ~ x + z, data = d)
68 fit_entry <- "tabelz.analysis.fit_y_by_x:compute_fits"
69 fit_menu <- "fitYByXMenuItem"
70 emit("STAT-REG-OLS-001", fit_entry, fit_menu, "nominal",
71 list(y_columns = list("y"), x_columns = list("x", "z")),
72 list("/responses/0/parameters/1/estimate" = tol(coef(fit)[["x"]], "OLS x slope", "1e-9"),
73 "/responses/0/metrics/sse" = tol(sum(resid(fit)^2), "OLS SSE", "1e-9")),
74 list("Classical OLS with intercept; R lm coefficients and residual sum of squares."))
STAT REG ORDINAL 001
Case STAT-REG-ORDINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
level_order= ["low", "middle", "high"]outcome_column= "ordinal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | 0.037942551798623013 | 0.03794256442013401 | 1.26E-8 | 6 | passed |
Convention
- MASS polr convention logit P(Y <= k) = zeta[k] - eta; positive x slope raises higher-level odds.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
95 ordinal_entry <- "tabelz.analysis.ordinal_logistic:compute_ordinal_logistic_regression"
96 d$ordinal_ordered <- ordered(d$ordinal, levels = c("low", "middle", "high"))
97 ordinal_fit <- MASS::polr(ordinal_ordered ~ x, data = d, method = "logistic",
98 Hess = TRUE, control = list(maxit = 1000, reltol = 1e-15))
99 emit("STAT-REG-ORDINAL-001", ordinal_entry, "ordinalRegressionMenuItem", "nominal",
100 list(outcome_column = "ordinal", predictors = list("x"),
101 level_order = list("low", "middle", "high")),
102 list("/coefficients/0/coefficient" = tol(coef(ordinal_fit)[["x"]], "proportional-odds slope")),
103 list("MASS polr convention logit P(Y <= k) = zeta[k] - eta; positive x slope raises higher-level odds."))
Regression II STAT-REG-PANEL-001
Case STAT-REG-PANEL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats
- Citation
- R nlme::Orthodont, nlme::lme, plm::plm, stats::nls/lm/step documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_core.R · sha256 b7543c65b2778e63
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
entity_column= "subject"predictor_columns= ["age"]response_column= "distance"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/estimate | tolerance | 0.6601851851851851 | 0.6601851851851851 | 2.81E-18 | 17 | passed |
/observations | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- R plm within estimator uses entity demeaning; slope does not depend on covariance correction.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
81 panel <- plm::plm(distance ~ age, data = d, index = c("subject", "time"),
82 model = "within", effect = "individual")
83 emit("STAT-REG-PANEL-001", "tabelz.executor.panel_fixed_effects",
84 "panelFixedEffectsMenuItem", "REG_ORTHODONT",
85 list(response_column = "distance", predictor_columns = list("age"),
86 entity_column = "subject", time_column = "time"),
87 list("/coefficients/0/estimate" = tol(coef(panel)[["age"]], "within-entity age slope", "1e-9"),
88 "/observations" = exact(nrow(d), "balanced complete panel rows")),
89 list("R plm within estimator uses entity demeaning; slope does not depend on covariance correction."))
Small-sample boundary STAT-REG-PANEL-MIN-001
Case STAT-REG-PANEL-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, plm, rpart
- Citation
- R stats::nls/lm, plm::plm, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_a.R · sha256 e69dea823e2a8f59
- Dataset
- reference_data/datasets/REG_MIN_PANEL.json
Settings compared
entity_column= "entity"predictor_columns= ["x"]response_column= "y"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/estimate | tolerance | 2.5 | 2.4999999999999996 | 4.44E-16 | 15 | passed |
/observations | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Two retained entities have two time points each; plm removes entity means.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
21 panel <- data.frame(y=c(1,3,2,5),x=c(1,2,1,2),entity=c("A","A","B","B"),
22 time=c(1L,2L,1L,2L))
23 export_dataset(panel,"REG_MIN_PANEL","Two entities each observed twice",
24 "R plm within-estimator small-panel boundary",
25 "Constructed validation data; no third-party license.",
26 c(y="Float64",x="Float64",entity="String",time="Int64"))
27 p <- read_dataset("REG_MIN_PANEL")
28 fit <- plm::plm(y~x,data=p,index=c("entity","time"),model="within",effect="individual")
29 emit("STAT-REG-PANEL-MIN-001","tabelz.executor.panel_fixed_effects","panelFixedEffectsMenuItem",
30 "REG_MIN_PANEL",list(response_column="y",predictor_columns=list("x"),
31 entity_column="entity",time_column="time"),
32 list("/coefficients/0/estimate"=tol(coef(fit)[["x"]],"within slope for two two-period entities"),
33 "/observations"=exact(nrow(p),"all four panel rows")),
34 c("Two retained entities have two time points each; plm removes entity means."))
Regression edge STAT-REG-PANEL-SINGLETON-CORRECTED-001
Case STAT-REG-PANEL-SINGLETON-CORRECTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R plm::plm and analytic singleton partition
- Citation
- Tabelz manual regression model design conditions; R stats/plm references
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_b.R · sha256 4a5d01b584989ad6
- Dataset
- reference_data/datasets/REG_EDGE_PANEL_SINGLETON.json
Settings compared
entity_column= "entity"predictor_columns= ["x"]response_column= "y"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/estimate | tolerance | 2.5 | 2.4999999999999996 | 4.44E-16 | 15 | passed |
/observations | exact | 4 | 4 | 0.00E+2 | passed | |
/singleton_observation_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- The manual excludes singleton C from the within fit and reports it separately.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
87 p <- read_dataset("REG_EDGE_PANEL_SINGLETON")
88 fit <- plm::plm(y~x,data=p,index=c("entity","time"),model="within",effect="individual")
89 emit("STAT-REG-PANEL-SINGLETON-CORRECTED-001","STAT-REG-PANEL-001",
90 "REG_EDGE_PANEL_SINGLETON",
91 list(response_column="y",predictor_columns=list("x"),entity_column="entity",
92 time_column="time"),
93 outputs=list("/coefficients/0/estimate"=tol(coef(fit)[["x"]],"R within slope after singleton removal"),
94 "/observations"=exact(4L,"two retained two-period entities"),
95 "/singleton_observation_count"=exact(1L,"one singleton source row")),
96 note="The manual excludes singleton C from the within fit and reports it separately.",
97 source="R plm::plm and analytic singleton partition")
STAT REG PENALIZED LOGISTIC 001
Case STAT-REG-PENALIZED-LOGISTIC-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Base R Newton minimisation of the contracted elastic-net objective on a table whose split and folds are determined by class counts alone
- Citation
- Zou & Hastie (2005) Regularization and variable selection via the elastic net, JRSS-B 67, 301-320; Hastie, Tibshirani & Friedman (2009) ESL section 18.4.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_penalized_logistic.R · sha256 aab20acf7da335c9
- Dataset
- reference_data/datasets/REG_ENET_01.json
Settings compared
event= "fail"independence_declared= truenumeric_predictors= ["load"]response= "outcome"seed= 20260923threshold= 0.5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/analyzed_count | exact | 24 | 24 | 0.00E+2 | passed | |
/train_events | exact | 10 | 10 | 0.00E+2 | passed | |
/train_non_events | exact | 10 | 10 | 0.00E+2 | passed | |
/test_events | exact | 2 | 2 | 0.00E+2 | passed | |
/test_non_events | exact | 2 | 2 | 0.00E+2 | passed | |
/train_prevalence | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/baseline_cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/selected_lambda | tolerance | 0.0001 | 0.0001 | 4.79E-21 | 16 | passed |
/selected_rho | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/final_objective | tolerance | 0.0010210290370309433 | 0.0010210290370309433 | 1.95E-20 | 16 | passed |
/final_converged | exact | True | True | passed | ||
/coefficients/0/term | exact | Intercept | Intercept | passed | ||
/coefficients/0/fitted_scale | tolerance | 0 | 2.710089127613145e-13 | 2.71E-13 | passed | |
/coefficients/0/raw_scale | tolerance | -70.611842813478702 | -70.61184277857011 | 3.49E-8 | 9 | passed |
/coefficients/1/term | exact | load | load | passed | ||
/coefficients/1/fitted_scale | tolerance | 9.2102403669754285 | 9.210240362422223 | 4.55E-9 | 9 | passed |
/coefficients/1/raw_scale | tolerance | 6.1401602446502856 | 6.140160241614815 | 3.04E-9 | 9 | passed |
/coefficients/1/status | exact | estimated | estimated | passed | ||
/artifact/numeric/0/mean | tolerance | 11.5 | 11.5 | 0.00E+1 | passed | |
/artifact/numeric/0/sd | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/evaluation/test_count | exact | 4 | 4 | 0.00E+2 | passed | |
/evaluation/model/log_loss | tolerance | 0.00010000500033340042 | 0.000100005000788721 | 4.55E-13 | 8 | passed |
/evaluation/model/brier | tolerance | 1.0000000000010001e-08 | 1.0000000091063576e-08 | 9.11E-17 | 8 | passed |
/evaluation/model/auc | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/evaluation/baseline/log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/evaluation/baseline/brier | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/evaluation/confusion/true_positive | exact | 2 | 2 | 0.00E+2 | passed | |
/evaluation/confusion/false_positive | exact | 0 | 0 | 0.00E+2 | passed | |
/evaluation/confusion/true_negative | exact | 2 | 2 | 0.00E+2 | passed | |
/evaluation/confusion/false_negative | exact | 0 | 0 | 0.00E+2 | passed | |
/candidates/0/lam | tolerance | 0.0001 | 0.0001 | 4.79E-21 | 16 | passed |
/candidates/0/rho | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/candidates/0/eligible | exact | True | True | passed | ||
/candidates/0/cv_log_loss | tolerance | 0.00072338263163511602 | 0.0007233826316360449 | 9.29E-16 | 11 | passed |
/candidates/1/lam | tolerance | 0.0001 | 0.0001 | 4.79E-21 | 16 | passed |
/candidates/1/rho | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/candidates/1/eligible | exact | True | True | passed | ||
/candidates/1/cv_log_loss | tolerance | 0.00058361815738598667 | 0.0005836181573874562 | 1.47E-15 | 11 | passed |
/candidates/2/lam | tolerance | 0.0001 | 0.0001 | 4.79E-21 | 16 | passed |
/candidates/2/rho | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/2/eligible | exact | True | True | passed | ||
/candidates/2/cv_log_loss | tolerance | 0.00043687739306530108 | 0.0004368773930680976 | 2.80E-15 | 11 | passed |
/candidates/3/lam | tolerance | 0.0001 | 0.0001 | 4.79E-21 | 16 | passed |
/candidates/3/rho | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/candidates/3/eligible | exact | True | True | passed | ||
/candidates/3/cv_log_loss | tolerance | 0.00027959022451083118 | 0.0002795902245196465 | 8.82E-15 | 10 | passed |
/candidates/4/lam | tolerance | 0.0001 | 0.0001 | 4.79E-21 | 16 | passed |
/candidates/4/rho | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/4/eligible | exact | True | True | passed | ||
/candidates/4/cv_log_loss | tolerance | 0.00010000500033340025 | 0.00010000500078872092 | 4.55E-13 | 8 | passed |
/candidates/5/lam | tolerance | 0.001 | 0.001 | 2.08E-20 | 16 | passed |
/candidates/5/rho | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/candidates/5/eligible | exact | True | True | passed | ||
/candidates/5/cv_log_loss | tolerance | 0.0052589899299477858 | 0.0052589899299479 | 1.15E-16 | 13 | passed |
/candidates/6/lam | tolerance | 0.001 | 0.001 | 2.08E-20 | 16 | passed |
/candidates/6/rho | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/candidates/6/eligible | exact | True | True | passed | ||
/candidates/6/cv_log_loss | tolerance | 0.0043380210387863726 | 0.004338021038786631 | 2.58E-16 | 13 | passed |
/candidates/7/lam | tolerance | 0.001 | 0.001 | 2.08E-20 | 16 | passed |
/candidates/7/rho | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/7/eligible | exact | True | True | passed | ||
/candidates/7/cv_log_loss | tolerance | 0.0033536338945336663 | 0.0033536338945352575 | 1.59E-15 | 12 | passed |
/candidates/8/lam | tolerance | 0.001 | 0.001 | 2.08E-20 | 16 | passed |
/candidates/8/rho | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/candidates/8/eligible | exact | True | True | passed | ||
/candidates/8/cv_log_loss | tolerance | 0.0022738673006909818 | 0.0022738673007071386 | 1.62E-14 | 11 | passed |
/candidates/9/lam | tolerance | 0.001 | 0.001 | 2.08E-20 | 16 | passed |
/candidates/9/rho | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/9/eligible | exact | True | True | passed | ||
/candidates/9/cv_log_loss | tolerance | 0.0010005003335835268 | 0.0010005003378019178 | 4.22E-12 | 8 | passed |
/candidates/10/lam | tolerance | 0.01 | 0.01 | 2.08E-19 | 16 | passed |
/candidates/10/rho | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/candidates/10/eligible | exact | True | True | passed | ||
/candidates/10/cv_log_loss | tolerance | 0.03416995022965709 | 0.03416995024124546 | 1.16E-11 | 9 | passed |
/candidates/11/lam | tolerance | 0.01 | 0.01 | 2.08E-19 | 16 | passed |
/candidates/11/rho | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/candidates/11/eligible | exact | True | True | passed | ||
/candidates/11/cv_log_loss | tolerance | 0.029292849287803242 | 0.029292849362266542 | 7.45E-11 | 8 | passed |
/candidates/12/lam | tolerance | 0.01 | 0.01 | 2.08E-19 | 16 | passed |
/candidates/12/rho | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/12/eligible | exact | True | True | passed | ||
/candidates/12/cv_log_loss | tolerance | 0.023893989121192352 | 0.023893989121192415 | 6.26E-17 | 14 | passed |
/candidates/13/lam | tolerance | 0.01 | 0.01 | 2.08E-19 | 16 | passed |
/candidates/13/rho | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/candidates/13/eligible | exact | True | True | passed | ||
/candidates/13/cv_log_loss | tolerance | 0.017716929710392473 | 0.017716929710394628 | 2.15E-15 | 12 | passed |
/candidates/14/lam | tolerance | 0.01 | 0.01 | 2.08E-19 | 16 | passed |
/candidates/14/rho | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/14/eligible | exact | True | True | passed | ||
/candidates/14/cv_log_loss | tolerance | 0.010050335853501416 | 0.010050335871621989 | 1.81E-11 | 8 | passed |
/candidates/15/lam | tolerance | 0.10000000000000001 | 0.1 | 4.45E-18 | 16 | passed |
/candidates/15/rho | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/candidates/15/eligible | exact | True | True | passed | ||
/candidates/15/cv_log_loss | tolerance | 0.17835019352534356 | 0.17835019352643033 | 1.09E-12 | 11 | passed |
/candidates/16/lam | tolerance | 0.10000000000000001 | 0.1 | 4.45E-18 | 16 | passed |
/candidates/16/rho | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/candidates/16/eligible | exact | True | True | passed | ||
/candidates/16/cv_log_loss | tolerance | 0.16631245697444616 | 0.1663124569996962 | 2.53E-11 | 9 | passed |
/candidates/17/lam | tolerance | 0.10000000000000001 | 0.1 | 4.45E-18 | 16 | passed |
/candidates/17/rho | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/17/eligible | exact | True | True | passed | ||
/candidates/17/cv_log_loss | tolerance | 0.15145149339227434 | 0.15145149339227432 | 2.33E-17 | 15 | passed |
/candidates/18/lam | tolerance | 0.10000000000000001 | 0.1 | 4.45E-18 | 16 | passed |
/candidates/18/rho | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/candidates/18/eligible | exact | True | True | passed | ||
/candidates/18/cv_log_loss | tolerance | 0.13227516573994291 | 0.13227516573994336 | 4.47E-16 | 14 | passed |
/candidates/19/lam | tolerance | 0.10000000000000001 | 0.1 | 4.45E-18 | 16 | passed |
/candidates/19/rho | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/19/eligible | exact | True | True | passed | ||
/candidates/19/cv_log_loss | tolerance | 0.10536051565782631 | 0.10536051566091217 | 3.09E-12 | 10 | passed |
/candidates/20/lam | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/20/rho | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/candidates/20/eligible | exact | True | True | passed | ||
/candidates/20/cv_log_loss | tolerance | 0.51259074324244169 | 0.5125907432424417 | 3.18E-18 | 17 | passed |
/candidates/21/lam | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/21/rho | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/candidates/21/eligible | exact | True | True | passed | ||
/candidates/21/cv_log_loss | tolerance | 0.5757972469581093 | 0.5757972469581093 | 1.09E-18 | 17 | passed |
/candidates/22/lam | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/22/rho | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/22/eligible | exact | True | True | passed | ||
/candidates/22/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/23/lam | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/23/rho | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/candidates/23/eligible | exact | True | True | passed | ||
/candidates/23/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/24/lam | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/24/rho | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/24/eligible | exact | True | True | passed | ||
/candidates/24/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/25/lam | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/candidates/25/rho | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/candidates/25/eligible | exact | True | True | passed | ||
/candidates/25/cv_log_loss | tolerance | 0.66905423411036558 | 0.6690542341103656 | 4.54E-18 | 17 | passed |
/candidates/26/lam | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/candidates/26/rho | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/candidates/26/eligible | exact | True | True | passed | ||
/candidates/26/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/27/lam | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/candidates/27/rho | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/27/eligible | exact | True | True | passed | ||
/candidates/27/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/28/lam | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/candidates/28/rho | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/candidates/28/eligible | exact | True | True | passed | ||
/candidates/28/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/29/lam | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/candidates/29/rho | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/29/eligible | exact | True | True | passed | ||
/candidates/29/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/30/lam | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/candidates/30/rho | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/candidates/30/eligible | exact | True | True | passed | ||
/candidates/30/cv_log_loss | tolerance | 0.69065652439122727 | 0.6906565243912274 | 1.08E-16 | 15 | passed |
/candidates/31/lam | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/candidates/31/rho | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/candidates/31/eligible | exact | True | True | passed | ||
/candidates/31/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/32/lam | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/candidates/32/rho | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/candidates/32/eligible | exact | True | True | passed | ||
/candidates/32/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/33/lam | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/candidates/33/rho | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/candidates/33/eligible | exact | True | True | passed | ||
/candidates/33/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
/candidates/34/lam | tolerance | 100 | 100.0 | 0.00E+2 | passed | |
/candidates/34/rho | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/candidates/34/eligible | exact | True | True | passed | ||
/candidates/34/cv_log_loss | tolerance | 0.69314718055994529 | 0.6931471805599453 | 3.77E-18 | 17 | passed |
Convention
- Objective (1/n) sum {log(1 + e^eta_i) - y_i eta_i} + lambda {(1 - rho)/2 ||beta||^2 + rho ||beta||_1}, unpenalized intercept, grid lambda in {1e-4, ..., 100} x rho in {0, 0.25, 0.5, 0.75, 1}; a stratified 20% test sample first, then five stratified folds select the lowest pooled log loss with near-ties (1e-12 relative) preferring the larger lambda then larger rho (docs/manual/chapters/76-forest-penalty-quantiles.tex:72-105).
- Numeric predictors are median-imputed (no missing values here) and standardized as z = ((x - median) - mean(x - median)) / population SD on the fitting rows; raw coefficient = beta / sd, raw intercept = b0 - beta * mean / sd.
- Within each outcome class every row has the same load, so the seeded choice of which rows are reserved or fold-assigned cannot change any fit: per class floor(0.2 * 12) = 2 test rows and 10 training rows; StratifiedKFold's allocation puts 2 rows of each class into every validation fold (per-class fold counts follow from the class counts alone), so every fold fits the same 8 + 8 design. The oracle therefore depends on those count rules (split and fold labels recorded by HypoNum in split_procedure), not on the random generator.
- Beta >= 0 at every optimum because the event class has the larger load; the soft-threshold condition |dL/dbeta(b0*, 0)| <= lambda rho gives beta = 0, otherwise damped Newton on the smooth branch to gradient 1e-14.
- Test ROC AUC is 1 when beta > 0 (every fail probability exceeds every pass probability), the baseline test log loss is log 2 and its Brier score 0.25 at training prevalence 1/2.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
180 id <- "STAT-REG-PENALIZED-LOGISTIC-001"
Regression edge STAT-REG-PLS-CONSTANT-001
Case STAT-REG-PLS-CONSTANT-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic design condition
- Citation
- Tabelz manual regression model design conditions; R stats/plm references
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_b.R · sha256 4a5d01b584989ad6
- Dataset
- reference_data/datasets/REG_EDGE_PLS_CONSTANT.json
Settings compared
cv_folds= 2predictors= ["x"]response= "y"scale= falseseed= 0test_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A constant predictor has zero variance in every training split, so no PLS component exists.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
75 pls_data <- read_dataset("REG_MIN_PLS")
76 pls_data$x <- rep(7,nrow(pls_data))
77 export_dataset(pls_data,"REG_EDGE_PLS_CONSTANT","Zero-variance PLS predictor",
78 "Analytic positive training-variance requirement",
79 "Constructed validation data; no third-party license.",
80 c(x="Float64",y="Float64"))
81 emit("STAT-REG-PLS-CONSTANT-001","STAT-REG-PLS-FIT-001",
82 "REG_EDGE_PLS_CONSTANT",
83 list(response="y",predictors=list("x"),scale=FALSE,cv_folds=2L,
84 test_fraction=0.25,seed=0L),
85 error=err("ValueError","positive training variance"),
86 note="A constant predictor has zero variance in every training split, so no PLS component exists.")
Regression II STAT-REG-PLS-FIT-001
Case STAT-REG-PLS-FIT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_PLS.json
Settings compared
cv_folds= 3predictors= ["x"]response= "y"scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/training_metrics/row_count | exact | 23 | 23 | 0.00E+2 | passed |
Convention
- R pls::plsr reference is full-population; NumPy random split prevents coefficient comparison.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
164 pls_fit <- pls::plsr(y ~ x, data = pls_data, ncomp = 1L, validation = "none", scale = FALSE)
165 pls_slope <- as.double(stats::coef(pls_fit, ncomp = 1L))[1L]
166 pls_mean_x <- mean(pls_data$x)
167 pls_mean_y <- mean(pls_data$y)
168 pls_art <- list(response = "y", predictors = list("x"), imputation = "drop", scale = FALSE,
169 component_count = 1L, imputation_values = list(NULL),
170 x_means = list(pls_mean_x), coefficients = list(pls_slope),
171 intercept = pls_mean_y)
172 emit("STAT-REG-PLS-FIT-001", "tabelz.analysis.partial_least_squares:compute_partial_least_squares",
173 "partialLeastSquaresMenuItem", "REG_PLS",
174 list(response = "y", predictors = list("x"), scale = FALSE, cv_folds = 3L),
175 list("/source_count" = exact(as.integer(nrow(pls_data)), "complete PLS population"),
176 "/training_metrics/row_count" = exact(23L, "three-quarter training share")),
177 list("R pls::plsr reference is full-population; NumPy random split prevents coefficient comparison."),
178 kind = "determinism", deferred = list(list(path = "/artifact/coefficients",
179 reason = "PLS training split and cross-validation folds are NumPy-specific.")),
180 repeat_count = 2L)
Small-sample boundary STAT-REG-PLS-MIN-001
Case STAT-REG-PLS-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/MASS/pls/stats
- Citation
- R nlme::lme, MASS::lda, pls::plsr and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_b.R · sha256 e3e09e1965800ae1
- Dataset
- reference_data/datasets/REG_MIN_PLS.json
Settings compared
cv_folds= 2predictors= ["x"]response= "y"scale= falseseed= 0test_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Two-fold CV has six training rows; R full-sample plsr confirms one-component estimability.
- NumPy holdout and fold assignments are not reproduced by R.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
85 pls_data <- read_dataset("REG_PLS")[seq_len(8L),]
86 export_dataset(pls_data,"REG_MIN_PLS","Eight-row one-predictor PLS design",
87 "R pls plsr small training/CV boundary",
88 "Constructed validation data; no third-party license.",
89 c(x="Float64",y="Float64"))
90 pls_data <- read_dataset("REG_MIN_PLS")
91 fit <- pls::plsr(y~x,data=pls_data,ncomp=1L,validation="none",scale=FALSE)
92 emit("STAT-REG-PLS-MIN-001",
93 "tabelz.analysis.partial_least_squares:compute_partial_least_squares",
94 "partialLeastSquaresMenuItem","REG_MIN_PLS",
95 list(response="y",predictors=list("x"),scale=FALSE,cv_folds=2L,
96 test_fraction=0.25,seed=0L),
97 list("/source_count"=exact(nrow(pls_data),"eight usable PLS rows")),
98 c("Two-fold CV has six training rows; R full-sample plsr confirms one-component estimability.",
99 "NumPy holdout and fold assignments are not reproduced by R."),
100 deferred=list(list(path="/artifact/coefficients",
101 reason="NumPy split and CV folds cannot be independently replayed in R.")))
Regression II STAT-REG-PLS-SCORE-001
Case STAT-REG-PLS-SCORE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_PLS.json
Settings compared
artifact= {"response": "y", "predictors": ["x"], "imputation": "drop", "scale": false, "component_count": 1, "imputation_values": [null], "x_means": [15.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/predicted | tolerance | 5.0083606987632487 | 5.008360698763212 | 3.64E-14 | 14 | passed |
/29/predicted | tolerance | 62.992572802424334 | 62.99257280242439 | 5.69E-14 | 15 | passed |
/0/row_id | exact | STAT-REG-PLS-SCORE-001:0 | STAT-REG-PLS-SCORE-001:0 | passed |
Convention
- One-component PLS1 original-unit coefficient and centered intercept from R pls::plsr.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
181 pls_pred <- as.double(stats::predict(pls_fit, newdata = pls_data, ncomp = 1L)) 182 pls_score_id <- "STAT-REG-PLS-SCORE-001"
Retained scoring boundary STAT-REG-PLS-SCORE-CENTER-001
Case STAT-REG-PLS-SCORE-CENTER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls and analytic retained tree
- Citation
- R MASS::lda, pls::plsr and rpart::rpart documentation; Tabelz retained-artifact contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_boundaries.R · sha256 9a546ee72b8c92a9
- Dataset
- reference_data/datasets/REG_SCORE_BOUND_PLS.json
Settings compared
artifact= {"response": "y", "predictors": ["x"], "imputation": "drop", "scale": false, "component_count": 1, "imputation_values": [null], "x_means": [15.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/predicted | tolerance | 34.000466750593802 | 34.0004667505938 | 3.65E-16 | 16 | passed |
Convention
- The retained one-component PLS artifact applies intercept + coefficient*(x-x_mean).
- The missing row is not imputed under drop mode.
- R re-reads the exported CSV.
Reference code
Whole script generators/r/regression_advanced_score_boundaries.R
Corrected retained scoring boundary STAT-REG-PLS-SCORE-CENTER-CORRECTED-001
Case STAT-REG-PLS-SCORE-CENTER-CORRECTED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls or strict scoring contract
- Citation
- R MASS::lda, pls::plsr and Tabelz manual retained-scoring semantics
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_corrections.R · sha256 8c11616dfc0c8448
- Dataset
- reference_data/datasets/REG_SCORE_CENTER_PLS.json
Settings compared
artifact= {"response": "y", "predictors": ["x"], "imputation": "drop", "scale": false, "component_count": 1, "imputation_values": [null], "x_means": [15.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/predicted | tolerance | 34.000466750593802 | 34.0004667505938 | 3.65E-16 | 16 | passed |
Convention
- A one-row, fully observed scoring table tests the retained centered intercept.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
50 emit("STAT-REG-PLS-SCORE-CENTER-CORRECTED-001",
51 "STAT-REG-PLS-SCORE-001","REG_SCORE_CENTER_PLS",
52 list("/0/predicted"=tol(pls_cfg$artifact$intercept,
53 "At retained x_mean, centered PLS prediction equals intercept")),
54 NULL,"A one-row, fully observed scoring table tests the retained centered intercept.")Whole script generators/r/regression_advanced_score_corrections.R
Retained scoring boundary STAT-REG-PLS-SCORE-MISSING-001
Case STAT-REG-PLS-SCORE-MISSING-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls and analytic retained tree
- Citation
- R MASS::lda, pls::plsr and rpart::rpart documentation; Tabelz retained-artifact contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_boundaries.R · sha256 9a546ee72b8c92a9
- Dataset
- reference_data/datasets/REG_SCORE_BOUND_PLS.json
Settings compared
artifact= {"response": "y", "predictors": ["x"], "imputation": "drop", "scale": false, "component_count": 1, "imputation_values": [null], "x_means": [15.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/1/predicted | absent | None | passed |
Convention
- The retained one-component PLS artifact applies intercept + coefficient*(x-x_mean).
- The missing row is not imputed under drop mode.
- R re-reads the exported CSV.
Reference code
Whole script generators/r/regression_advanced_score_boundaries.R
True minimum sample STAT-REG-PLS-TRUE-MIN-001
Case STAT-REG-PLS-TRUE-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats/rpart/pls and analytic sample conditions
- Citation
- R stats::lm, rpart::rpart, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_true_min.R · sha256 f10363ad1ec76730
- Dataset
- reference_data/datasets/REG_TRUE_MIN_PLS.json
Settings compared
cv_folds= 2predictors= ["x"]response= "y"scale= falseseed= 0test_fraction= 0.2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- Four training rows leave two rows per two-fold training partition, enough for one component.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
37 pls_data <- read_dataset("REG_PLS")[1:5,]
38 export_dataset(pls_data,"REG_TRUE_MIN_PLS","Five-row one-predictor PLS CV design",
39 "R pls plsr estimability with one component",
40 "Constructed validation data; no third-party license.",
41 c(x="Float64",y="Float64"))
42 pls_data <- read_dataset("REG_TRUE_MIN_PLS")
43 fit <- pls::plsr(y~x,data=pls_data,ncomp=1L,validation="none",scale=FALSE)
44 emit("STAT-REG-PLS-TRUE-MIN-001","STAT-REG-PLS-FIT-001",
45 "REG_TRUE_MIN_PLS",
46 list(response="y",predictors=list("x"),scale=FALSE,cv_folds=2L,
47 test_fraction=0.2,seed=0L),
48 list("/source_count"=exact(as.integer(nrow(pls_data)),"five analyzed rows")),
49 "Four training rows leave two rows per two-fold training partition, enough for one component.",
50 deferred=list(list(path="/artifact/coefficients",
51 reason="NumPy holdout and CV fold identities are not replayable in R.")))
STAT REG POISSON 001
Case STAT-REG-POISSON-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
count_column= "count"exposure_column= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 0.185193666890311 | 0.1851936668767073 | 1.36E-11 | 10 | passed |
/deviance | tolerance | 87.68671615819575 | 87.68671615819576 | 1.46E-14 | 15 | passed |
Convention
- Exposure enters only as log offset; glm Poisson uses log link.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
115 poisson_entry <- "tabelz.analysis.poisson_regression:compute_poisson_regression"
116 poisson_fit <- stats::glm(count ~ x + offset(log(exposure)),
117 family = stats::poisson(), data = d)
118 emit("STAT-REG-POISSON-001", poisson_entry, "poissonRegressionMenuItem", "nominal",
119 list(count_column = "count", predictors = list("x"), exposure_column = "exposure"),
120 list("/coefficients/1/coefficient" = tol(coef(poisson_fit)[["x"]], "Poisson log-rate slope"),
121 "/deviance" = tol(stats::deviance(poisson_fit), "Poisson deviance")),
122 list("Exposure enters only as log offset; glm Poisson uses log link."))
Regression II population STAT-REG-POP-ADV-DA-001
Case STAT-REG-POP-ADV-DA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_DISCRIMINANT_MISSING.json
Settings compared
imputation= "drop"model= "lda"predictors= ["x"]prior_mode= "equal"response= "class"standardize= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_predictor_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Class and predictor missing in different rows; original row 3 excluded.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
163 da_config <- list(response = "class", predictors = list("x"), model = "lda",
164 imputation = "drop", standardize = FALSE, prior_mode = "equal")
165 emit("STAT-REG-POP-ADV-DA-001", "STAT-REG-DISCRIMINANT-LDA-001",
166 "REG_DISCRIMINANT_MISSING", da_config,
167 list("/source_count" = exact(as.integer(nrow(da)), "source class rows"),
168 "/excluded_count" = exact(1L, "excluded row"),
169 "/missing_response_count" = exact(1L, "missing class"),
170 "/incomplete_predictor_count" = exact(1L, "missing x")),
171 list("Class and predictor missing in different rows; original row 3 excluded."),
172 excluded = list(2L),
173 deferred = list(list(path = "/artifact/class_means",
174 reason = "NumPy stratified train split cannot be reproduced with R RNG.")))
Regression II population STAT-REG-POP-ADV-MIXED-001
Case STAT-REG-POP-ADV-MIXED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_ORTHODONT_MISSING.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.67109049381460972 | 0.6710904938955704 | 8.10E-11 | 9 | passed |
/analyzed_count | exact | 105 | 105 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Drop missing distance/age in different subjects, then source row 9; REML.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
60 orth_keep <- orth[-9L, , drop = FALSE]
61 orth_fit <- orth_keep[stats::complete.cases(orth_keep[c("distance", "age", "subject")]),,
62 drop = FALSE]
63 random_intercept <- nlme::lme(distance ~ age, random = ~1 | subject, data = orth_fit,
64 method = "REML", control = nlme::lmeControl(opt = "optim"))
65 emit("STAT-REG-POP-ADV-MIXED-001", "STAT-REG-MIXED-REML-001",
66 "REG_ORTHODONT_MISSING", list(response_column = "distance", group_column = "subject",
67 fixed_numeric_columns = list("age"), estimation = "reml"),
68 list("/coefficients/1/estimate" = tol(nlme::fixef(random_intercept)[["age"]],
69 "R lme REML after omissions"),
70 "/analyzed_count" = exact(as.integer(nrow(orth_fit)), "complete nonexcluded rows"),
71 "/excluded_count" = exact(1L, "explicitly excluded source row")),
72 list("Drop missing distance/age in different subjects, then source row 9; REML."),
73 excluded = list(8L))
Regression II population STAT-REG-POP-ADV-NONLINEAR-001
Case STAT-REG-POP-ADV-NONLINEAR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_DECAY_MISSING.json
Settings compared
curve= "exponential_decay"parameters= [{"name": "a", "start": 4, "lower": 0, "upper": 10}, {"name": "k", "start": 0.8, "lower": 0.01, "upper": 3}, {"name": "c", "start": 1, "lower": 0, "upper": 5}]response= "y"x_column= "x"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/estimates/0 | tolerance | 3.9605299863580901 | 3.960529986417557 | 5.95E-11 | 10 | passed |
/artifact/estimates/1 | tolerance | 0.79633080989055749 | 0.7963308099491827 | 5.86E-11 | 10 | passed |
Convention
- R nls port on complete nonexcluded rows; missing rows 1/2, excluded row 3.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
104 decay_keep <- decay[-3L, , drop = FALSE]
105 decay_fit <- decay_keep[stats::complete.cases(decay_keep[c("x", "y")]), , drop = FALSE]
106 nls_fit <- stats::nls(y ~ c + a * exp(-k * x), data = decay_fit,
107 start = list(a = 4, k = 0.8, c = 1), algorithm = "port",
108 lower = c(a = 0, k = 0.01, c = 0),
109 upper = c(a = 10, k = 3, c = 5),
110 control = stats::nls.control(maxiter = 1000, tol = 1e-12))
111 emit("STAT-REG-POP-ADV-NONLINEAR-001", "STAT-REG-NONLINEAR-DECAY-001",
112 "REG_DECAY_MISSING",
113 list(x_column = "x", response = "y", curve = "exponential_decay",
114 parameters = list(list(name = "a", start = 4, lower = 0, upper = 10),
115 list(name = "k", start = 0.8, lower = 0.01, upper = 3),
116 list(name = "c", start = 1, lower = 0, upper = 5))),
117 list("/artifact/estimates/0" = tol(coef(nls_fit)[["a"]], "R nls amplitude"),
118 "/artifact/estimates/1" = tol(coef(nls_fit)[["k"]], "R nls rate")),
119 list("R nls port on complete nonexcluded rows; missing rows 1/2, excluded row 3."),
120 excluded = list(2L))
Regression II population STAT-REG-POP-ADV-PANEL-001
Case STAT-REG-POP-ADV-PANEL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_ORTHODONT_MISSING.json
Settings compared
entity_column= "subject"predictor_columns= ["age"]response_column= "distance"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/estimate | tolerance | 0.66865079365079361 | 0.6686507936507938 | 2.19E-16 | 15 | passed |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- R plm within estimator on complete nonexcluded rows.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
92 panel <- plm::plm(distance ~ age, data = orth_fit,
93 index = c("subject", "time"), model = "within", effect = "individual")
94 emit("STAT-REG-POP-ADV-PANEL-001", "STAT-REG-PANEL-001",
95 "REG_ORTHODONT_MISSING",
96 list(response_column = "distance", predictor_columns = list("age"),
97 entity_column = "subject", time_column = "time"),
98 list("/coefficients/0/estimate" = tol(coef(panel)[["age"]],
99 "R plm within slope", "1e-9"),
100 "/excluded_count" = exact(1L, "explicitly excluded source row")),
101 list("R plm within estimator on complete nonexcluded rows."),
102 excluded = list(8L))
Regression II population STAT-REG-POP-ADV-PLS-001
Case STAT-REG-POP-ADV-PLS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_PLS_MISSING.json
Settings compared
cv_folds= 3imputation= "drop"predictors= ["x"]response= "y"scale= false
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_predictor_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- R complete cases after original row 3 exclusion; split moments deferred.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
176 emit("STAT-REG-POP-ADV-PLS-001", "STAT-REG-PLS-FIT-001",
177 "REG_PLS_MISSING", list(response = "y", predictors = list("x"),
178 imputation = "drop", scale = FALSE, cv_folds = 3L),
179 list("/source_count" = exact(as.integer(nrow(pls_data)), "source PLS rows"),
180 "/excluded_count" = exact(1L, "excluded row"),
181 "/missing_response_count" = exact(1L, "missing response"),
182 "/incomplete_predictor_count" = exact(1L, "missing predictor")),
183 list("R complete cases after original row 3 exclusion; split moments deferred."),
184 excluded = list(2L),
185 deferred = list(list(path = "/artifact/coefficients",
186 reason = "NumPy split and selected component count cannot be reproduced with R RNG.")))
Regression II population STAT-REG-POP-ADV-SELECTION-001
Case STAT-REG-POP-ADV-SELECTION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_ORTHODONT_MISSING.json
Settings compared
candidate_predictors= ["age"]response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 0.68652387327086217 | 0.6865238732708618 | 3.30E-16 | 15 | passed |
/n | exact | 105 | 105 | 0.00E+2 | passed | |
/dropped | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- R lm on complete rows after original row 9 is excluded; one predictor wins.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
200 selection_clean <- orth_fit
201 selection_ref <- stats::lm(distance ~ age, data = selection_clean)
202 emit("STAT-REG-POP-ADV-SELECTION-001", "STAT-REG-SELECTION-001",
203 "REG_ORTHODONT_MISSING", list(response = "distance",
204 candidate_predictors = list("age")),
205 list("/coefficients/1/coefficient" = tol(coef(selection_ref)[["age"]],
206 "complete-case OLS slope", "1e-9"),
207 "/n" = exact(as.integer(nrow(selection_clean)), "complete nonexcluded rows"),
208 "/dropped" = exact(2L, "two missing rows after exclusion")),
209 list("R lm on complete rows after original row 9 is excluded; one predictor wins."),
210 excluded = list(8L))
Regression II population STAT-REG-POP-ADV-STRUCT-001
Case STAT-REG-POP-ADV-STRUCT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_ORTHODONT_MISSING.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"model_mode= "random_slope"random_slope_column= "age"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.6811365379048353 | 0.68113649406668 | 4.38E-8 | 7 | passed |
/analyzed_count | exact | 105 | 105 | 0.00E+2 | passed |
Convention
- Subject random slope plus intercept; omit original rows 1, 5, 9.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
77 random_slope <- lme4::lmer(distance ~ age + (age | subject), data = orth_fit, REML = TRUE,
78 control = lme4::lmerControl(
79 optCtrl = list(ftol_abs = 1e-15, xtol_abs = 1e-15),
80 check.conv.singular = "ignore"))
81 emit("STAT-REG-POP-ADV-STRUCT-001", "STAT-REG-MIXED-STRUCT-SLOPE-001",
82 "REG_ORTHODONT_MISSING",
83 list(response_column = "distance", fixed_numeric_columns = list("age"),
84 model_mode = "random_slope", group_column = "subject",
85 random_slope_column = "age", estimation = "reml"),
86 list("/coefficients/1/estimate" = tol(lme4::fixef(random_slope)[["age"]],
87 "R random-slope age effect (lme4, converged)"),
88 "/analyzed_count" = exact(as.integer(nrow(orth_fit)), "complete nonexcluded rows")),
89 list("Subject random slope plus intercept; omit original rows 1, 5, 9."),
90 excluded = list(8L))
Regression II population STAT-REG-POP-ADV-TREE-CLASS-001
Case STAT-REG-POP-ADV-TREE-CLASS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_TREE_MISSING.json
Settings compared
cv_folds= 2max_depth= 1min_samples_leaf= 1numeric_predictors= ["x"]positive_class= "B"response= "class"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/threshold/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/source_count | exact | 40 | 40 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_predictor_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Omit source class row 1, x row 2 and excluded row 4; leaves remain pure.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
122 tree_class <- tree[-4L, , drop = FALSE]
123 tree_class_fit <- tree_class[stats::complete.cases(tree_class[c("x", "class")]),,
124 drop = FALSE]
125 rpart_class <- rpart::rpart(class ~ x, data = tree_class_fit, method = "class",
126 control = rpart::rpart.control(cp = 0, xval = 0,
127 minsplit = 2, minbucket = 1,
128 maxdepth = 1))
129 stopifnot(nrow(rpart_class$frame) == 3L)
130 emit("STAT-REG-POP-ADV-TREE-CLASS-001", "STAT-REG-TREE-CLASS-001",
131 "REG_TREE_MISSING", list(response = "class", numeric_predictors = list("x"),
132 positive_class = "B", cv_folds = 2L,
133 max_depth = 1L, min_samples_leaf = 1L),
134 list("/artifact/threshold/0" = tol(rpart_class$splits[1L, "index"],
135 "unique split despite omissions", "1e-12"),
136 "/source_count" = exact(as.integer(nrow(tree)), "source row count"),
137 "/excluded_count" = exact(1L, "excluded row"),
138 "/missing_response_count" = exact(1L, "missing class label"),
139 "/incomplete_predictor_count" = exact(1L, "missing numeric predictor")),
140 list("Omit source class row 1, x row 2 and excluded row 4; leaves remain pure."),
141 excluded = list(3L))
Regression II population STAT-REG-POP-ADV-TREE-REG-001
Case STAT-REG-POP-ADV-TREE-REG-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_TREE_MISSING.json
Settings compared
cv_folds= 2depth_grid= [1]max_depth= 1min_leaf_grid= [1]numeric_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/threshold/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/source_count | exact | 40 | 40 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_numeric_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Omit source x row 2, y row 3 and excluded row 4; leaves remain pure.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
143 tree_reg <- tree[-4L, , drop = FALSE]
144 tree_reg_fit <- tree_reg[stats::complete.cases(tree_reg[c("x", "y")]),, drop = FALSE]
145 rpart_reg <- rpart::rpart(y ~ x, data = tree_reg_fit, method = "anova",
146 control = rpart::rpart.control(cp = 0, xval = 0,
147 minsplit = 2, minbucket = 1,
148 maxdepth = 1))
149 stopifnot(nrow(rpart_reg$frame) == 3L)
150 emit("STAT-REG-POP-ADV-TREE-REG-001", "STAT-REG-TREE-REG-001",
151 "REG_TREE_MISSING", list(response = "y", numeric_predictors = list("x"),
152 cv_folds = 2L, max_depth = 1L,
153 depth_grid = list(1L), min_leaf_grid = list(1L)),
154 list("/artifact/threshold/0" = tol(rpart_reg$splits[1L, "index"],
155 "unique regression split", "1e-12"),
156 "/source_count" = exact(as.integer(nrow(tree)), "source row count"),
157 "/excluded_count" = exact(1L, "excluded row"),
158 "/missing_response_count" = exact(1L, "missing numeric response"),
159 "/incomplete_numeric_count" = exact(1L, "missing numeric predictor")),
160 list("Omit source x row 2, y row 3 and excluded row 4; leaves remain pure."),
161 excluded = list(3L))
Regression II population STAT-REG-POP-ADV-VALIDATED-001
Case STAT-REG-POP-ADV-VALIDATED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/rpart/MASS/pls
- Citation
- R nlme::lme, plm::plm, rpart::rpart, MASS::lda, pls::plsr, stats::nls/lm
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_population.R · sha256 c1c329b2471524f0
- Dataset
- reference_data/datasets/REG_PLS_MISSING.json
Settings compared
algorithm= "ols"cv_folds= 3imputation= "drop"numeric_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_response_count | exact | 1 | 1 | 0.00E+2 | passed | |
/incomplete_numeric_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Complete-case OLS after excluding original row 3; split coefficients deferred.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
188 emit("STAT-REG-POP-ADV-VALIDATED-001", "STAT-REG-VALIDATED-COUNT-001",
189 "REG_PLS_MISSING", list(response = "y", numeric_predictors = list("x"),
190 algorithm = "ols", imputation = "drop", cv_folds = 3L),
191 list("/source_count" = exact(as.integer(nrow(pls_data)), "source regression rows"),
192 "/excluded_count" = exact(1L, "excluded row"),
193 "/missing_response_count" = exact(1L, "missing response"),
194 "/incomplete_numeric_count" = exact(1L, "missing predictor")),
195 list("Complete-case OLS after excluding original row 3; split coefficients deferred."),
196 excluded = list(2L),
197 deferred = list(list(path = "/recipe/coefficients",
198 reason = "No explicit split assignment; NumPy chooses training identities.")))
Missing and excluded STAT-REG-POP-BINARY-001
Case STAT-REG-POP-BINARY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 68 | 68 | 0.00E+2 | passed | |
/coefficients/1/coefficient | tolerance | 0.020439704750281642 | 0.02043970475028173 | 8.66E-17 | 14 | passed |
Convention
- Event is explicit; no imputation of missing outcome or predictor.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
68 binary_data <- kept[stats::complete.cases(kept[c("binary", "x")]), , drop = FALSE]
69 binary_fit <- stats::glm(I(binary == "event") ~ x, data = binary_data,
70 family = stats::binomial())
71 emit("STAT-REG-POP-BINARY-001",
72 "tabelz.analysis.logistic_regression:compute_binary_logistic_regression",
73 "logisticRegressionMenuItem", "missing_excluded",
74 list(outcome_column = "binary", event_value = "event", predictors = list("x")),
75 list("/n" = exact(nrow(binary_data), "complete non-excluded binary rows"),
76 "/coefficients/1/coefficient" = tol(coef(binary_fit)[["x"]], "binary slope")),
77 list("Event is explicit; no imputation of missing outcome or predictor."))
Missing and excluded STAT-REG-POP-EFFECTS-001
Case STAT-REG-POP-EFFECTS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations | exact | 68 | 68 | 0.00E+2 | passed | |
/retained_row_ids | sequence | ['STAT-REG-POP-EFFECTS-001:0', 'STAT-REG-POP-EFFECTS-001:1', | ['STAT-REG-POP-EFFECTS-001:0', 'STAT-REG-POP-EFFECTS-001:1', | passed | ||
/residual_variance | tolerance | 0.23979370253309201 | 0.23979370253309196 | 5.31E-17 | 15 | passed |
Convention
- Linear effects treatment contrasts; first alphabetical level reference.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
140 effects_fit <- stats::lm(y ~ x + group, data = linear_data)
141 emit("STAT-REG-POP-EFFECTS-001", "tabelz.executor.linear_effects",
142 "linearEffectsMenuItem", "row_alignment",
143 list(response_column = "y", factor_columns = list("group"),
144 covariate_columns = list("x")),
145 list("/observations" = exact(nrow(linear_data), "complete non-excluded effects rows"),
146 "/retained_row_ids" = seq_ids("STAT-REG-POP-EFFECTS-001", linear_indexes),
147 "/residual_variance" = tol(summary(effects_fit)$sigma^2, "effects residual variance")),
148 list("Linear effects treatment contrasts; first alphabetical level reference."))
Missing and excluded STAT-REG-POP-GENERAL-001
Case STAT-REG-POP-GENERAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
covariate_columns= ["x"]factor_columns= ["group"]response_column= "y"test_type= "III"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/observations | exact | 68 | 68 | 0.00E+2 | passed | |
/retained_row_ids | sequence | ['STAT-REG-POP-GENERAL-001:0', 'STAT-REG-POP-GENERAL-001:1', | ['STAT-REG-POP-GENERAL-001:0', 'STAT-REG-POP-GENERAL-001:1', | passed | ||
/residual_variance | tolerance | 0.23979370253309196 | 0.23979370253309198 | 2.47E-17 | 15 | passed |
Convention
- General linear precision weights absent; sum contrasts per manual.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
127 linear_data <- kept[stats::complete.cases(kept[c("y", "x", "group")]), , drop = FALSE]
128 linear_fit <- stats::lm(y ~ x + group, data = linear_data,
129 contrasts = list(group = stats::contr.sum(3)))
130 linear_indexes <- as.integer(rownames(linear_data))
131 emit("STAT-REG-POP-GENERAL-001", "tabelz.executor.general_linear",
132 "generalLinearMenuItem", "row_alignment",
133 list(response_column = "y", factor_columns = list("group"),
134 covariate_columns = list("x"), test_type = "III"),
135 list("/observations" = exact(nrow(linear_data), "complete non-excluded GLM rows"),
136 "/retained_row_ids" = seq_ids("STAT-REG-POP-GENERAL-001", linear_indexes),
137 "/residual_variance" = tol(summary(linear_fit)$sigma^2, "GLM residual variance")),
138 list("General linear precision weights absent; sum contrasts per manual."))
Missing and excluded STAT-REG-POP-NB-001
Case STAT-REG-POP-NB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
count= "nb_count"exposure= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 68 | 68 | 0.00E+2 | passed | |
/analyzed_row_ids | sequence | ['STAT-REG-POP-NB-001:0', 'STAT-REG-POP-NB-001:1', 'STAT-REG | ['STAT-REG-POP-NB-001:0', 'STAT-REG-POP-NB-001:1', 'STAT-REG | passed | ||
/coefficients/1/coefficient | tolerance | 0.16041111698946656 | 0.16041111698949295 | 2.64E-14 | 12 | passed |
Convention
- An explicit row-ID sequence checks population and prediction alignment.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
115 nb_data <- kept[stats::complete.cases(kept[c("nb_count", "x", "exposure")]), , drop = FALSE]
116 nb_fit <- MASS::glm.nb(nb_count ~ x + offset(log(exposure)), data = nb_data,
117 control = stats::glm.control(maxit = 1000, epsilon = 1e-12))
118 nb_indexes <- as.integer(rownames(nb_data))
119 emit("STAT-REG-POP-NB-001", "tabelz.analysis.negative_binomial:compute_negative_binomial",
120 "nbRegressionMenuItem", "row_alignment",
121 list(count = "nb_count", predictors = list("x"), exposure = "exposure"),
122 list("/n" = exact(nrow(nb_data), "complete non-excluded NB2 rows"),
123 "/analyzed_row_ids" = seq_ids("STAT-REG-POP-NB-001", nb_indexes),
124 "/coefficients/1/coefficient" = tol(coef(nb_fit)[["x"]], "NB2 slope")),
125 list("An explicit row-ID sequence checks population and prediction alignment."))
Missing and excluded STAT-REG-POP-NOMINAL-001
Case STAT-REG-POP-NOMINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
outcome_column= "nominal"predictors= ["x"]reference_value= "A"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 68 | 68 | 0.00E+2 | passed | |
/coefficients/1/coefficient | tolerance | -0.012377674727291463 | -0.012377674626761473 | 1.01E-10 | 8 | passed |
Convention
- R multinom reference A and tight convergence.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
92 nom_data <- kept[stats::complete.cases(kept[c("nominal", "x")]), , drop = FALSE]
93 nom_data$response <- factor(nom_data$nominal, levels = c("A", "B", "C"))
94 nom_fit <- nnet::multinom(response ~ x, data = nom_data, trace = FALSE,
95 maxit = 1000, reltol = 1e-15)
96 emit("STAT-REG-POP-NOMINAL-001",
97 "tabelz.analysis.nominal_logistic:compute_nominal_logistic_regression",
98 "nominalRegressionMenuItem", "missing_excluded",
99 list(outcome_column = "nominal", reference_value = "A", predictors = list("x")),
100 list("/n" = exact(nrow(nom_data), "complete non-excluded nominal rows"),
101 "/coefficients/1/coefficient" = tol(coef(nom_fit)["B", "x"], "B versus A x slope")),
102 list("R multinom reference A and tight convergence."))
Missing and excluded STAT-REG-POP-OLS-001
Case STAT-REG-POP-OLS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/observations | exact | 68 | 68 | 0.00E+2 | passed | |
/responses/0/parameters/1/estimate | tolerance | 1.4122591480108972 | 1.412259148010898 | 7.13E-16 | 15 | passed |
Convention
- Listwise OLS after population exclusion.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
50 fit_rows <- which(stats::complete.cases(kept[c("y", "x", "z")]))
51 fit_data <- kept[fit_rows, , drop = FALSE]
52 fit <- stats::lm(y ~ x + z, data = fit_data)
53 emit("STAT-REG-POP-OLS-001", "tabelz.analysis.fit_y_by_x:compute_fits",
54 "fitYByXMenuItem", "missing_excluded",
55 list(y_columns = list("y"), x_columns = list("x", "z")),
56 list("/responses/0/observations" = exact(nrow(fit_data), "complete, non-excluded rows"),
57 "/responses/0/parameters/1/estimate" = tol(coef(fit)[["x"]], "x slope")),
58 list("Listwise OLS after population exclusion."))
Missing and excluded STAT-REG-POP-ORDINAL-001
Case STAT-REG-POP-ORDINAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
level_order= ["low", "middle", "high"]outcome_column= "ordinal"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 68 | 68 | 0.00E+2 | passed | |
/coefficients/0/coefficient | tolerance | 0.072461436156306763 | 0.07246145211210003 | 1.60E-8 | 6 | passed |
Convention
- Low-to-high outcome order is explicit in R and Tabelz.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
79 ord_data <- kept[stats::complete.cases(kept[c("ordinal", "x")]), , drop = FALSE]
80 ord_data$response <- ordered(ord_data$ordinal, levels = c("low", "middle", "high"))
81 ord_fit <- MASS::polr(response ~ x, data = ord_data, method = "logistic", Hess = TRUE,
82 control = list(maxit = 1000, reltol = 1e-15))
83 emit("STAT-REG-POP-ORDINAL-001",
84 "tabelz.analysis.ordinal_logistic:compute_ordinal_logistic_regression",
85 "ordinalRegressionMenuItem", "missing_excluded",
86 list(outcome_column = "ordinal", predictors = list("x"),
87 level_order = list("low", "middle", "high")),
88 list("/n" = exact(nrow(ord_data), "complete non-excluded ordinal rows"),
89 "/coefficients/0/coefficient" = tol(coef(ord_fit)[["x"]], "ordered slope")),
90 list("Low-to-high outcome order is explicit in R and Tabelz."))
Missing and excluded STAT-REG-POP-POISSON-001
Case STAT-REG-POP-POISSON-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
count_column= "count"exposure_column= "exposure"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 68 | 68 | 0.00E+2 | passed | |
/coefficients/1/coefficient | tolerance | 0.200648227560661 | 0.20064822754014394 | 2.05E-11 | 9 | passed |
Convention
- Positive exposure enters as log offset.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
104 pois_data <- kept[stats::complete.cases(kept[c("count", "x", "exposure")]), , drop = FALSE]
105 pois_fit <- stats::glm(count ~ x + offset(log(exposure)), data = pois_data,
106 family = stats::poisson())
107 emit("STAT-REG-POP-POISSON-001",
108 "tabelz.analysis.poisson_regression:compute_poisson_regression",
109 "poissonRegressionMenuItem", "missing_excluded",
110 list(count_column = "count", predictors = list("x"), exposure_column = "exposure"),
111 list("/n" = exact(nrow(pois_data), "complete non-excluded Poisson rows"),
112 "/coefficients/1/coefficient" = tol(coef(pois_fit)[["x"]], "Poisson rate slope")),
113 list("Positive exposure enters as log offset."))
Missing and excluded STAT-REG-POP-VIF-001
Case STAT-REG-POP-VIF-001 · status: passed
Reference
- Evidence type
- R
- Source
- R complete-case models
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_population.R · sha256 d1c98b1023443b9f
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.0009858715668083 | 1.000985871566808 | 2.28E-16 | 15 | passed |
Convention
- VIF uses the same complete design rows as the OLS fit.
- R removes zero-based excluded rows 2 and 7 first, then selected-field missing rows.
- All estimates are computed from the re-read REG_MISSING CSV.
Reference code
The lines of the reference script that produce this case's expected values.
60 vif <- 1 / (1 - summary(stats::lm(x ~ z, data = fit_data))$r.squared)
61 emit("STAT-REG-POP-VIF-001", "tabelz.analysis.fit_y_by_x:compute_fit_vif",
62 "fitYByXMenuItem", "missing_excluded",
63 list(y_columns = list("y"), x_columns = list("x", "z"), missing = "drop",
64 model_type = "linear", degree = 2L, interactions = FALSE, split_percent = 100L),
65 list("/0" = tol(vif, "x variance inflation", "1e-9")),
66 list("VIF uses the same complete design rows as the OLS fit."))
STAT REG QUANTILE REGRESSION 001
Case STAT-REG-QUANTILE-REGRESSION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R quantreg::rq(method = 'br') and the check loss sum rho_tau(y - X beta); base R sort() for the intercept-only order statistic
- Citation
- Koenker, R. (2005) Quantile Regression, CUP; quantreg package help: rq, rq.fit.br.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, quantreg 6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_quantile.R · sha256 9b1ef07b4d0ba8ce
- Dataset
- reference_data/datasets/REG_QUANT_01.json
Settings compared
confidence_level= 0.95dependence= "independent"held_out_evaluation= falsenumeric_predictors= ["x1", "x2"]quantiles= [0.5]response= "y"seed= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit_rows | exact | 30 | 30 | 0.00E+2 | passed | |
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/incomplete_count | exact | 0 | 0 | 0.00E+2 | passed | |
/crossing_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/fits/0/quantile | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/fits/0/check_loss | tolerance | 16.126224245012803 | 16.126224245012807 | 4.05E-15 | 15 | passed |
/fits/0/tail_information | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/fits/0/interval_status | exact | available | available | passed | ||
/fits/0/resamples | exact | 999 | 999 | 0.00E+2 | passed | |
/fits/0/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/fits/0/coefficients/0/estimate | tolerance | 1.453588794108075 | 1.453588794108078 | 3.06E-15 | 14 | passed |
/fits/0/coefficients/1/term | exact | x1 | x1 | passed | ||
/fits/0/coefficients/1/estimate | tolerance | 0.57579213124738249 | 0.5757921312473819 | 5.57E-16 | 15 | passed |
/fits/0/coefficients/2/term | exact | x2 | x2 | passed | ||
/fits/0/coefficients/2/estimate | tolerance | -1.0945152954491282 | -1.0945152954491282 | 2.17E-17 | 16 | passed |
Convention
- Median regression on x1 and x2; rq(tau = 0.5).
- Check loss rho_tau(u) = u (tau - 1(u < 0)) with an intercept, no weights, complete cases (docs/manual/chapters/76-forest-penalty-quantiles.tex:121-146); categorical predictors are reference-cell indicators with the first sorted level as reference, as in rq's default treatment contrasts.
- Intercept-only fits report the declared lower empirical quantile y_(ceil(n tau)) and, when n tau is an integer, the minimizing interval [y_(n tau), y_(n tau + 1)] as the sensitivity range (manual lines 133-146).
- Uniqueness of each compared vertex was checked in R by agreement of the simplex (br) and interior-point (fn) solutions to 1e-5.
- Bootstrap percentile intervals (999 NumPy-seeded resamples), the held-out split and the near-optimal sensitivity probes are not reproduced in R; only the interval status rule min(n tau, n(1 - tau)) >= 10 is checked.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
32 emit <- function(id, kind, config, outputs, notes) {
33 write_expected("regression", id, list(
34 schema_version = "2.0.0", case_id = id, outputs = outputs,
35 expected_error = NULL, deferred_outputs = list(), generator_run = run))
36 write_case("regression", id, list(
37 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
38 entry_point = "tabelz.analysis.quantile_regression:compute_quantile_regression",
39 menu_items = list("quantileRegressionMenuItem"), title = gsub("-", " ", id),
40 case_kind = kind,
41 dataset = list(path = "reference_data/datasets/REG_QUANT_01.json", sha256 = ""),
42 excluded_rows = list(), configuration = config, "repeat" = 1L,
43 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
44 oracle = list(
45 oracle_class = "independent_implementation",
46 source = "R quantreg::rq(method = 'br') and the check loss sum rho_tau(y - X beta); base R sort() for the intercept-only order statistic",
47 citation = "Koenker, R. (2005) Quantile Regression, CUP; quantreg package help: rq, rq.fit.br.",
48 generator = list(path = "generators/r/regression_quantile.R", sha256 = ""),
49 independent = TRUE,
50 convention_notes = c(
51 notes,
52 "Check loss rho_tau(u) = u (tau - 1(u < 0)) with an intercept, no weights, complete cases (docs/manual/chapters/76-forest-penalty-quantiles.tex:121-146); categorical predictors are reference-cell indicators with the first sorted level as reference, as in rq's default treatment contrasts.",
53 "Intercept-only fits report the declared lower empirical quantile y_(ceil(n tau)) and, when n tau is an integer, the minimizing interval [y_(n tau), y_(n tau + 1)] as the sensitivity range (manual lines 133-146).",
54 "Uniqueness of each compared vertex was checked in R by agreement of the simplex (br) and interior-point (fn) solutions to 1e-5.",
55 "Bootstrap percentile intervals (999 NumPy-seeded resamples), the held-out split and the near-optimal sensitivity probes are not reproduced in R; only the interval status rule min(n tau, n(1 - tau)) >= 10 is checked.",
56 "Expected computed from the exported CSV."
57 )),
58 supported = TRUE, unsupported_reason = NULL,
59 requirement_ids = list("REQ-STAT-REG-QUANTILE-REGRESSION-001"),
60 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
STAT REG QUANTILE REGRESSION 002
Case STAT-REG-QUANTILE-REGRESSION-002 · status: passed
Reference
- Evidence type
- R
- Source
- R quantreg::rq(method = 'br') and the check loss sum rho_tau(y - X beta); base R sort() for the intercept-only order statistic
- Citation
- Koenker, R. (2005) Quantile Regression, CUP; quantreg package help: rq, rq.fit.br.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, quantreg 6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_quantile.R · sha256 9b1ef07b4d0ba8ce
- Dataset
- reference_data/datasets/REG_QUANT_01.json
Settings compared
confidence_level= 0.9dependence= "independent"held_out_evaluation= falsenumeric_predictors= ["x1", "x2"]quantiles= [0.75, 0.25]response= "y"seed= 3
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit_rows | exact | 30 | 30 | 0.00E+2 | passed | |
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/incomplete_count | exact | 0 | 0 | 0.00E+2 | passed | |
/fits/0/quantile | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/fits/0/check_loss | tolerance | 11.999458759040589 | 11.999458759040598 | 9.11E-15 | 15 | passed |
/fits/0/tail_information | tolerance | 7.5 | 7.5 | 0.00E+1 | passed | |
/fits/0/interval_status | exact | tail_withheld | tail_withheld | passed | ||
/fits/0/resamples | exact | 0 | 0 | 0.00E+2 | passed | |
/fits/0/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/fits/0/coefficients/0/estimate | tolerance | 1.5177304842022892 | 1.517730484202296 | 6.86E-15 | 14 | passed |
/fits/0/coefficients/1/term | exact | x1 | x1 | passed | ||
/fits/0/coefficients/1/estimate | tolerance | 0.36061928973846524 | 0.3606192897384655 | 2.80E-16 | 15 | passed |
/fits/0/coefficients/2/term | exact | x2 | x2 | passed | ||
/fits/0/coefficients/2/estimate | tolerance | -1.0963790036147474 | -1.0963790036147503 | 2.87E-15 | 14 | passed |
/fits/1/quantile | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/fits/1/check_loss | tolerance | 12.524460279065663 | 12.524460279065668 | 4.83E-15 | 15 | passed |
/fits/1/tail_information | tolerance | 7.5 | 7.5 | 0.00E+1 | passed | |
/fits/1/interval_status | exact | tail_withheld | tail_withheld | passed | ||
/fits/1/resamples | exact | 0 | 0 | 0.00E+2 | passed | |
/fits/1/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/fits/1/coefficients/0/estimate | tolerance | 3.3656172826224071 | 3.3656172826224076 | 4.58E-16 | 15 | passed |
/fits/1/coefficients/1/term | exact | x1 | x1 | passed | ||
/fits/1/coefficients/1/estimate | tolerance | 0.36132417446500142 | 0.36132417446500076 | 6.62E-16 | 14 | passed |
/fits/1/coefficients/2/term | exact | x2 | x2 | passed | ||
/fits/1/coefficients/2/estimate | tolerance | -1.0671678966335363 | -1.0671678966335367 | 4.28E-16 | 15 | passed |
/quantiles/0 | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/quantiles/1 | tolerance | 0.75 | 0.75 | 0.00E+0 | passed |
Convention
- Quantiles 0.75 and 0.25 are fitted separately (rq per tau) and reported in increasing order; both tails have min(n tau, n(1 - tau)) = 7.5 < 10 so intervals are withheld.
- Check loss rho_tau(u) = u (tau - 1(u < 0)) with an intercept, no weights, complete cases (docs/manual/chapters/76-forest-penalty-quantiles.tex:121-146); categorical predictors are reference-cell indicators with the first sorted level as reference, as in rq's default treatment contrasts.
- Intercept-only fits report the declared lower empirical quantile y_(ceil(n tau)) and, when n tau is an integer, the minimizing interval [y_(n tau), y_(n tau + 1)] as the sensitivity range (manual lines 133-146).
- Uniqueness of each compared vertex was checked in R by agreement of the simplex (br) and interior-point (fn) solutions to 1e-5.
- Bootstrap percentile intervals (999 NumPy-seeded resamples), the held-out split and the near-optimal sensitivity probes are not reproduced in R; only the interval status rule min(n tau, n(1 - tau)) >= 10 is checked.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
111 out <- c(fit_outputs(0L, 0.25, y ~ x1 + x2, c("(Intercept)", "x1", "x2"), FALSE),
112 fit_outputs(1L, 0.75, y ~ x1 + x2, c("(Intercept)", "x1", "x2"), FALSE))
113 out[["/quantiles/0"]] <- tol(0.25, "sorted quantiles", "1e-12")
114 out[["/quantiles/1"]] <- tol(0.75, "sorted quantiles", "1e-12")
115 emit("STAT-REG-QUANTILE-REGRESSION-002", "axis_coverage",
116 list(response = "y", numeric_predictors = list("x1", "x2"), quantiles = list(0.75, 0.25),
117 confidence_level = 0.90, dependence = "independent", held_out_evaluation = FALSE,
118 seed = 3L),
119 c(common[c("/fit_rows", "/source_count", "/excluded_count", "/incomplete_count")], out),
120 list("Quantiles 0.75 and 0.25 are fitted separately (rq per tau) and reported in increasing order; both tails have min(n tau, n(1 - tau)) = 7.5 < 10 so intervals are withheld."))
STAT REG QUANTILE REGRESSION 003
Case STAT-REG-QUANTILE-REGRESSION-003 · status: passed
Reference
- Evidence type
- R
- Source
- R quantreg::rq(method = 'br') and the check loss sum rho_tau(y - X beta); base R sort() for the intercept-only order statistic
- Citation
- Koenker, R. (2005) Quantile Regression, CUP; quantreg package help: rq, rq.fit.br.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, quantreg 6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_quantile.R · sha256 9b1ef07b4d0ba8ce
- Dataset
- reference_data/datasets/REG_QUANT_01.json
Settings compared
categorical_predictors= ["g"]confidence_level= 0.95dependence= "independent"held_out_evaluation= falsenumeric_predictors= ["x1"]quantiles= [0.5]response= "y"seed= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit_rows | exact | 30 | 30 | 0.00E+2 | passed | |
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/incomplete_count | exact | 0 | 0 | 0.00E+2 | passed | |
/crossing_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/fits/0/quantile | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/fits/0/check_loss | tolerance | 24.140335219617356 | 24.14033521961735 | 7.37E-15 | 15 | passed |
/fits/0/tail_information | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/fits/0/interval_status | exact | available | available | passed | ||
/fits/0/resamples | exact | 999 | 999 | 0.00E+2 | passed | |
/fits/0/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/fits/0/coefficients/0/estimate | tolerance | -1.3289517650229055 | -1.3289517650229055 | 3.76E-17 | 16 | passed |
/fits/0/coefficients/1/term | exact | x1 | x1 | passed | ||
/fits/0/coefficients/1/estimate | tolerance | 0.59714362705470236 | 0.5971436270547023 | 1.07E-16 | 15 | passed |
/fits/0/coefficients/2/term | exact | g=B (vs A) | g=B (vs A) | passed | ||
/fits/0/coefficients/2/estimate | tolerance | 1.123724063594719 | 1.1237240635947192 | 2.14E-16 | 15 | passed |
/fits/0/coefficients/3/term | exact | g=C (vs A) | g=C (vs A) | passed | ||
/fits/0/coefficients/3/estimate | tolerance | -1.2135289679331718 | -1.213528967933171 | 6.90E-16 | 15 | passed |
Convention
- rq(y ~ x1 + g) with R's default treatment contrasts (first sorted level A as reference).
- Check loss rho_tau(u) = u (tau - 1(u < 0)) with an intercept, no weights, complete cases (docs/manual/chapters/76-forest-penalty-quantiles.tex:121-146); categorical predictors are reference-cell indicators with the first sorted level as reference, as in rq's default treatment contrasts.
- Intercept-only fits report the declared lower empirical quantile y_(ceil(n tau)) and, when n tau is an integer, the minimizing interval [y_(n tau), y_(n tau + 1)] as the sensitivity range (manual lines 133-146).
- Uniqueness of each compared vertex was checked in R by agreement of the simplex (br) and interior-point (fn) solutions to 1e-5.
- Bootstrap percentile intervals (999 NumPy-seeded resamples), the held-out split and the near-optimal sensitivity probes are not reproduced in R; only the interval status rule min(n tau, n(1 - tau)) >= 10 is checked.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
123 emit("STAT-REG-QUANTILE-REGRESSION-003", "axis_coverage",
124 list(response = "y", numeric_predictors = list("x1"), categorical_predictors = list("g"),
125 quantiles = list(0.5), confidence_level = 0.95, dependence = "independent",
126 held_out_evaluation = FALSE, seed = 0L),
127 c(common, fit_outputs(0L, 0.5, y ~ x1 + g, c("(Intercept)", "x1", "g=B (vs A)", "g=C (vs A)"), TRUE)),
128 list("rq(y ~ x1 + g) with R's default treatment contrasts (first sorted level A as reference)."))
STAT REG QUANTILE REGRESSION 004
Case STAT-REG-QUANTILE-REGRESSION-004 · status: passed
Reference
- Evidence type
- R
- Source
- R quantreg::rq(method = 'br') and the check loss sum rho_tau(y - X beta); base R sort() for the intercept-only order statistic
- Citation
- Koenker, R. (2005) Quantile Regression, CUP; quantreg package help: rq, rq.fit.br.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, quantreg 6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_quantile.R · sha256 9b1ef07b4d0ba8ce
- Dataset
- reference_data/datasets/REG_QUANT_01.json
Settings compared
confidence_level= 0.95dependence= "independent"held_out_evaluation= falsequantiles= [0.5]response= "y"seed= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit_rows | exact | 30 | 30 | 0.00E+2 | passed | |
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/incomplete_count | exact | 0 | 0 | 0.00E+2 | passed | |
/crossing_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/fits/0/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/fits/0/coefficients/0/estimate | tolerance | 1.3360000000000001 | 1.336 | 2.36E-17 | 16 | passed |
/fits/0/coefficients/0/range_low | tolerance | 1.3360000000000001 | 1.336 | 2.36E-17 | 16 | passed |
/fits/0/coefficients/0/range_high | tolerance | 1.7070000000000001 | 1.707 | 2.72E-17 | 16 | passed |
/fits/0/coefficients/0/ambiguous | exact | True | True | passed | ||
/fits/0/check_loss | tolerance | 30.548999999999999 | 30.549 | 4.88E-16 | 16 | passed |
/fits/0/interval_status | exact | available | available | passed | ||
/fits/0/tail_information | tolerance | 15 | 15.0 | 0.00E+2 | passed |
Convention
- Intercept-only median: n tau = 15 is an integer and y_(15) < y_(16), so the declared estimate is y_(15) and every value up to y_(16) minimizes the loss (analytic, base R sort).
- Check loss rho_tau(u) = u (tau - 1(u < 0)) with an intercept, no weights, complete cases (docs/manual/chapters/76-forest-penalty-quantiles.tex:121-146); categorical predictors are reference-cell indicators with the first sorted level as reference, as in rq's default treatment contrasts.
- Intercept-only fits report the declared lower empirical quantile y_(ceil(n tau)) and, when n tau is an integer, the minimizing interval [y_(n tau), y_(n tau + 1)] as the sensitivity range (manual lines 133-146).
- Uniqueness of each compared vertex was checked in R by agreement of the simplex (br) and interior-point (fn) solutions to 1e-5.
- Bootstrap percentile intervals (999 NumPy-seeded resamples), the held-out split and the near-optimal sensitivity probes are not reproduced in R; only the interval status rule min(n tau, n(1 - tau)) >= 10 is checked.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
131 sorted <- sort(d$y)
132 estimate <- sorted[[15]]
133 stopifnot(sorted[[16]] > estimate)
134 emit("STAT-REG-QUANTILE-REGRESSION-004", "axis_coverage",
135 list(response = "y", quantiles = list(0.5), confidence_level = 0.95,
136 dependence = "independent", held_out_evaluation = FALSE, seed = 0L),
137 c(common,
138 list("/fits/0/coefficients/0/term" = exact("(Intercept)", "term label"),
139 "/fits/0/coefficients/0/estimate" = tol(estimate, "order statistic y_(15) = y_(ceil(30 * 0.5))", "1e-12"),
140 "/fits/0/coefficients/0/range_low" = tol(estimate, "lower end of the minimizing interval", "1e-12"),
141 "/fits/0/coefficients/0/range_high" = tol(sorted[[16]], "upper end of the minimizing interval y_(16)", "1e-12"),
142 "/fits/0/coefficients/0/ambiguous" = exact(TRUE, "an interval of minimizers is flagged ambiguous"),
143 "/fits/0/check_loss" = tol(check_loss(d$y, rep(estimate, n), 0.5), "check loss of the median", "1e-12"),
144 "/fits/0/interval_status" = exact("available", "15 >= 10 tail rows"),
145 "/fits/0/tail_information" = tol(15, "min(n tau, n (1 - tau))", "1e-12"))),
146 list("Intercept-only median: n tau = 15 is an integer and y_(15) < y_(16), so the declared estimate is y_(15) and every value up to y_(16) minimizes the loss (analytic, base R sort)."))
QUEST root split between two point-mass classes, no pruning
Case STAT-REG-QUEST-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Loh and Shih (1997) split rule evaluated by hand for two point-mass classes
- Citation
- Loh and Shih (1997) Split selection methods for classification trees, Statistica Sinica 7, 815-840, Algorithm 1 (equal-variance case).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_quest.R · sha256 8069251c8d3970f1
- Dataset
- reference_data/datasets/REG_QUEST.json
Settings compared
max_depth= 5min_child= 1min_parent= 2predictors= ["vibration"]prune= falsetarget= "class"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 21 | 21 | 0.00E+2 | passed | |
/test_rows | exact | 9 | 9 | 0.00E+2 | passed | |
/missing_target | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/classes | sequence | ['high', 'low'] | ['high', 'low'] | passed | ||
/grown_leaves | exact | 2 | 2 | 0.00E+2 | passed | |
/training_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/training_rows_routed | exact | 0 | 0 | 0.00E+2 | passed | |
/test_rows_routed | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/n | exact | 21 | 21 | 0.00E+2 | passed | |
/nodes/0/split/predictor | exact | vibration | vibration | passed | ||
/nodes/0/split/kind | exact | numeric | numeric | passed | ||
/nodes/0/split/stage | exact | bonferroni | bonferroni | passed | ||
/nodes/0/split/threshold | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/nodes/0/split/method | exact | linear | linear | passed | ||
/nodes/0/split/superclasses/0/0 | exact | low | low | passed | ||
/nodes/0/split/superclasses/1/0 | exact | high | high | passed | ||
/nodes/0/split/missing_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/tests/0/predictor | exact | vibration | vibration | passed | ||
/nodes/0/tests/0/test | exact | F | F | passed | ||
/nodes/0/tests/0/p_value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/nodes/0/tests/0/rows | exact | 21 | 21 | 0.00E+2 | passed | |
/nodes/1/stop_reason | exact | pure node | pure node | passed | ||
/nodes/2/stop_reason | exact | pure node | pure node | passed | ||
/nodes/1/prediction | exact | low | low | passed | ||
/nodes/2/prediction | exact | high | high | passed | ||
/selected_alpha | absent | None | passed | |||
/cv_folds_used | absent | None | passed |
Convention
- Analytic oracle: vibration is 1 for every low and 3 for every high row, so for any training subset holding both classes the ANOVA within-class sum of squares is 0 (p = 0, Bonferroni stage), superclass A is the low class (smaller mean) and B the high class, both variances are 0 so the equal-variance rule gives d = (1 + 3)/2 - 0 = 2 for any prior ratio, the children are pure, and no training or held-out row is misclassified.
- Minimum parent 2 and child 1 so the 21-row root may split whatever the class balance of the subset; pruning off.
- Expected computed from the exported CSV.
- docs/manual/chapters/104-tree-extensions.tex:70-76: QUEST separates choosing a predictor from choosing its binary split.
- docs/manual/chapters/104-tree-extensions.tex:79-86: numeric predictors receive class-mean ANOVA tests; the smallest first-pass p is selected if below alpha/K.
- docs/manual/chapters/104-tree-extensions.tex:91-97: the split compares the two prior-weighted normal densities; equal variances use the linear discriminant rule.
- docs/manual/chapters/104-tree-extensions.tex:106-110: minimum parent 20, child 7 and depth 5 are adjustable defaults; priors can follow training frequencies or be equal.
- docs/manual/chapters/104-tree-extensions.tex:118-123: a seeded split reserves 30% of rows; turning pruning off is an explicit choice.
Reference code
The lines of the reference script that produce this case's expected values.
27 emit <- function(id, title, kind, configuration, outputs, notes) {
28 expected <- list(schema_version = "2.0.0", case_id = id, outputs = outputs,
29 expected_error = NULL, deferred_outputs = list(), generator_run = run)
30 write_expected("regression", id, expected)
31 case <- list(
32 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
33 entry_point = "tabelz.analysis.quest:compute_quest",
34 menu_items = list("questMenuItem"), title = title, case_kind = kind,
35 dataset = list(path = "reference_data/datasets/REG_QUEST.json", sha256 = ""),
36 excluded_rows = list(), configuration = configuration, "repeat" = 1L,
37 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"),
38 sha256 = ""),
39 oracle = list(oracle_class = "analytic",
40 source = "Loh and Shih (1997) split rule evaluated by hand for two point-mass classes",
41 citation = "Loh and Shih (1997) Split selection methods for classification trees, Statistica Sinica 7, 815-840, Algorithm 1 (equal-variance case).",
42 generator = list(path = "generators/r/regression_quest.R", sha256 = ""),
43 independent = TRUE,
44 convention_notes = c(notes, "Expected computed from the exported CSV.", manual)),
45 supported = TRUE, unsupported_reason = NULL,
46 requirement_ids = list("REQ-STAT-REG-QUEST-001"), risk_ids = list("RISK-REFERENCE-001"),
47 review_reference = NULL
48 )
49 write_case("regression", id, case)
QUEST root split with equal priors
Case STAT-REG-QUEST-EQUAL-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Loh and Shih (1997) split rule evaluated by hand for two point-mass classes
- Citation
- Loh and Shih (1997) Split selection methods for classification trees, Statistica Sinica 7, 815-840, Algorithm 1 (equal-variance case).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_quest.R · sha256 8069251c8d3970f1
- Dataset
- reference_data/datasets/REG_QUEST.json
Settings compared
max_depth= 5min_child= 1min_parent= 2predictors= ["vibration"]priors= "equal"prune= falsetarget= "class"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 21 | 21 | 0.00E+2 | passed | |
/test_rows | exact | 9 | 9 | 0.00E+2 | passed | |
/missing_target | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/classes | sequence | ['high', 'low'] | ['high', 'low'] | passed | ||
/grown_leaves | exact | 2 | 2 | 0.00E+2 | passed | |
/training_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/training_rows_routed | exact | 0 | 0 | 0.00E+2 | passed | |
/test_rows_routed | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/n | exact | 21 | 21 | 0.00E+2 | passed | |
/nodes/0/split/predictor | exact | vibration | vibration | passed | ||
/nodes/0/split/kind | exact | numeric | numeric | passed | ||
/nodes/0/split/stage | exact | bonferroni | bonferroni | passed | ||
/nodes/0/split/threshold | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/nodes/0/split/method | exact | linear | linear | passed | ||
/nodes/0/split/superclasses/0/0 | exact | low | low | passed | ||
/nodes/0/split/superclasses/1/0 | exact | high | high | passed | ||
/nodes/0/split/missing_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/tests/0/predictor | exact | vibration | vibration | passed | ||
/nodes/0/tests/0/test | exact | F | F | passed | ||
/nodes/0/tests/0/p_value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/nodes/0/tests/0/rows | exact | 21 | 21 | 0.00E+2 | passed | |
/nodes/1/stop_reason | exact | pure node | pure node | passed | ||
/nodes/2/stop_reason | exact | pure node | pure node | passed | ||
/nodes/1/prediction | exact | low | low | passed | ||
/nodes/2/prediction | exact | high | high | passed |
Convention
- Analytic oracle: vibration is 1 for every low and 3 for every high row, so for any training subset holding both classes the ANOVA within-class sum of squares is 0 (p = 0, Bonferroni stage), superclass A is the low class (smaller mean) and B the high class, both variances are 0 so the equal-variance rule gives d = (1 + 3)/2 - 0 = 2 for any prior ratio, the children are pure, and no training or held-out row is misclassified.
- Equal priors change the prior ratio in the linear rule, whose variance factor is 0 here, so the threshold stays 2.
- Expected computed from the exported CSV.
- docs/manual/chapters/104-tree-extensions.tex:70-76: QUEST separates choosing a predictor from choosing its binary split.
- docs/manual/chapters/104-tree-extensions.tex:79-86: numeric predictors receive class-mean ANOVA tests; the smallest first-pass p is selected if below alpha/K.
- docs/manual/chapters/104-tree-extensions.tex:91-97: the split compares the two prior-weighted normal densities; equal variances use the linear discriminant rule.
- docs/manual/chapters/104-tree-extensions.tex:106-110: minimum parent 20, child 7 and depth 5 are adjustable defaults; priors can follow training frequencies or be equal.
- docs/manual/chapters/104-tree-extensions.tex:118-123: a seeded split reserves 30% of rows; turning pruning off is an explicit choice.
Reference code
The lines of the reference script that produce this case's expected values.
114 emit("STAT-REG-QUEST-EQUAL-001", "QUEST root split with equal priors", "axis_coverage",
115 list(target = "class", predictors = list("vibration"), min_parent = 2L, min_child = 1L,
116 max_depth = 5L, prune = FALSE, priors = "equal"),
117 root_outputs(),
118 list(invariance, "Equal priors change the prior ratio in the linear rule, whose variance factor is 0 here, so the threshold stays 2."))
QUEST root split kept by cost-complexity pruning
Case STAT-REG-QUEST-PRUNED-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Loh and Shih (1997) split rule evaluated by hand for two point-mass classes
- Citation
- Loh and Shih (1997) Split selection methods for classification trees, Statistica Sinica 7, 815-840, Algorithm 1 (equal-variance case).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_quest.R · sha256 8069251c8d3970f1
- Dataset
- reference_data/datasets/REG_QUEST.json
Settings compared
cv_folds= 5max_depth= 5min_child= 1min_parent= 2predictors= ["vibration"]prune= truetarget= "class"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/training_rows | exact | 21 | 21 | 0.00E+2 | passed | |
/test_rows | exact | 9 | 9 | 0.00E+2 | passed | |
/missing_target | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/classes | sequence | ['high', 'low'] | ['high', 'low'] | passed | ||
/grown_leaves | exact | 2 | 2 | 0.00E+2 | passed | |
/training_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/test_error | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/training_rows_routed | exact | 0 | 0 | 0.00E+2 | passed | |
/test_rows_routed | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/n | exact | 21 | 21 | 0.00E+2 | passed | |
/nodes/0/split/predictor | exact | vibration | vibration | passed | ||
/nodes/0/split/kind | exact | numeric | numeric | passed | ||
/nodes/0/split/stage | exact | bonferroni | bonferroni | passed | ||
/nodes/0/split/threshold | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/nodes/0/split/method | exact | linear | linear | passed | ||
/nodes/0/split/superclasses/0/0 | exact | low | low | passed | ||
/nodes/0/split/superclasses/1/0 | exact | high | high | passed | ||
/nodes/0/split/missing_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/nodes/0/tests/0/predictor | exact | vibration | vibration | passed | ||
/nodes/0/tests/0/test | exact | F | F | passed | ||
/nodes/0/tests/0/p_value | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/nodes/0/tests/0/rows | exact | 21 | 21 | 0.00E+2 | passed | |
/nodes/1/stop_reason | exact | pure node | pure node | passed | ||
/nodes/2/stop_reason | exact | pure node | pure node | passed | ||
/nodes/1/prediction | exact | low | low | passed | ||
/nodes/2/prediction | exact | high | high | passed | ||
/cv_folds_used | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- Analytic oracle: vibration is 1 for every low and 3 for every high row, so for any training subset holding both classes the ANOVA within-class sum of squares is 0 (p = 0, Bonferroni stage), superclass A is the low class (smaller mean) and B the high class, both variances are 0 so the equal-variance rule gives d = (1 + 3)/2 - 0 = 2 for any prior ratio, the children are pure, and no training or held-out row is misclassified.
- Cross-validated pruning with the 1-SE rule keeps the split: the two-leaf tree has cross-validated error 0 (every fold refits the same midpoint rule) and the root alone misclassifies the minority class, so the smallest tree within one SE of the minimum is the two-leaf tree.
- Expected computed from the exported CSV.
- docs/manual/chapters/104-tree-extensions.tex:70-76: QUEST separates choosing a predictor from choosing its binary split.
- docs/manual/chapters/104-tree-extensions.tex:79-86: numeric predictors receive class-mean ANOVA tests; the smallest first-pass p is selected if below alpha/K.
- docs/manual/chapters/104-tree-extensions.tex:91-97: the split compares the two prior-weighted normal densities; equal variances use the linear discriminant rule.
- docs/manual/chapters/104-tree-extensions.tex:106-110: minimum parent 20, child 7 and depth 5 are adjustable defaults; priors can follow training frequencies or be equal.
- docs/manual/chapters/104-tree-extensions.tex:118-123: a seeded split reserves 30% of rows; turning pruning off is an explicit choice.
Reference code
The lines of the reference script that produce this case's expected values.
120 emit("STAT-REG-QUEST-PRUNED-001", "QUEST root split kept by cost-complexity pruning", "axis_coverage",
121 list(target = "class", predictors = list("vibration"), min_parent = 2L, min_child = 1L,
122 max_depth = 5L, prune = TRUE, cv_folds = 5L),
123 c(root_outputs(), list("/cv_folds_used" = exact(5L, "five folds requested on 21 training rows"))),
124 list(invariance, "Cross-validated pruning with the 1-SE rule keeps the split: the two-leaf tree has cross-validated error 0 (every fold refits the same midpoint rule) and the root alone misclassifies the minority class, so the smallest tree within one SE of the minimum is the two-leaf tree."))
Blockwise regression enter all with casewise table
Case STAT-REG-REGRESSION-BLOCKS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm and step
- Citation
- R Core Team, stats package help: lm, anova.lm, confint.lm, step, AIC, BIC, rstandard, rstudent, hatvalues, cooks.distance, dfbetas; Belsley, Kuh and Welsch (1980), Regression Diagnostics, ch. 3.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_blocks.R · sha256 86184660dac4e79f
- Dataset
- reference_data/datasets/REG_BLOCKS.json
Settings compared
blocks= [["x1", "x2"], ["x3", "x4"]]casewise= "all"casewise_threshold= 3confidence_level= 0.95criterion= "aic"method= "enter"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/models/0/r_squared | tolerance | 0.89860540286782831 | 0.8986054028678283 | 3.23E-18 | 17 | passed |
/models/0/adjusted_r_squared | tolerance | 0.88846594315461114 | 0.8884659431546111 | 2.56E-18 | 17 | passed |
/models/0/standard_error | tolerance | 0.79278391963209549 | 0.7927839196320953 | 2.21E-16 | 15 | passed |
/models/0/df2 | exact | 20 | 20 | 0.00E+2 | passed | |
/models/0/residual_ss | tolerance | 12.570126864544575 | 12.570126864544568 | 7.38E-15 | 15 | passed |
/models/0/regression_ss | tolerance | 111.40222689074416 | 111.40222689074417 | 1.42E-14 | 15 | passed |
/models/0/f_value | tolerance | 88.624584374694265 | 88.62458437469431 | 4.31E-14 | 15 | passed |
/models/0/p_value | tail_probability | 1.148545328910703e-10 | 1.1485453289106956e-10 | 7.37E-25 | 14 | passed |
/models/0/durbin_watson | tolerance | 2.7168680656281303 | 2.7168680656281303 | 2.43E-17 | 17 | passed |
/models/0/r_squared_change | tolerance | 0.89860540286782831 | 0.8986054028678283 | 3.23E-18 | 17 | passed |
/models/0/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/models/0/f_change | tolerance | 88.624584374694265 | 88.62458437469427 | 4.21E-16 | 17 | passed |
/models/0/p_change | tail_probability | 1.148545328910703e-10 | 1.1485453289107003e-10 | 2.72E-25 | 14 | passed |
/models/0/predictors | set | ['x1', 'x2'] | ['x1', 'x2'] | passed | ||
/models/1/r_squared | tolerance | 0.97240803475507431 | 0.9724080347550743 | 3.08E-18 | 17 | passed |
/models/1/adjusted_r_squared | tolerance | 0.9662764869228686 | 0.9662764869228686 | 4.88E-18 | 17 | passed |
/models/1/standard_error | tolerance | 0.43593073329420107 | 0.43593073329420123 | 1.64E-16 | 15 | passed |
/models/1/df2 | exact | 18 | 18 | 0.00E+2 | passed | |
/models/1/residual_ss | tolerance | 3.4206408761475577 | 3.4206408761475604 | 2.71E-15 | 15 | passed |
/models/1/regression_ss | tolerance | 120.55171287914118 | 120.55171287914118 | 2.16E-15 | 16 | passed |
/models/1/f_value | tolerance | 158.59095637280046 | 158.59095637280035 | 1.11E-13 | 15 | passed |
/models/1/p_value | tail_probability | 9.0390504021975662e-14 | 9.039050402197648e-14 | 8.21E-28 | 14 | passed |
/models/1/durbin_watson | tolerance | 2.8539534427862687 | 2.8539534427862683 | 4.20E-16 | 15 | passed |
/models/1/r_squared_change | tolerance | 0.073802631887246006 | 0.073802631887246 | 3.15E-19 | 17 | passed |
/models/1/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/models/1/f_change | tolerance | 24.073083634641392 | 24.07308363464137 | 2.10E-14 | 15 | passed |
/models/1/p_change | tail_probability | 8.1829591465124059e-06 | 8.182959146512443e-06 | 3.73E-20 | 14 | passed |
/models/1/predictors | set | ['x1', 'x2', 'x3', 'x4'] | ['x1', 'x2', 'x3', 'x4'] | passed | ||
/models/1/coefficients/0/estimate | tolerance | 1.9827753406073705 | 1.9827753406073705 | 1.55E-17 | 17 | passed |
/models/1/coefficients/0/standard_error | tolerance | 0.13679445702121606 | 0.1367944570212161 | 3.26E-17 | 15 | passed |
/models/1/coefficients/0/t_value | tolerance | 14.494559090942207 | 14.494559090942206 | 1.49E-15 | 15 | passed |
/models/1/coefficients/0/p_value | tail_probability | 2.2842318698562376e-11 | 2.284231869856236e-11 | 1.63E-26 | 15 | passed |
/models/1/coefficients/0/lower | tolerance | 1.6953808508686923 | 1.695380850868692 | 2.42E-16 | 15 | passed |
/models/1/coefficients/0/upper | tolerance | 2.2701698303460489 | 2.270169830346049 | 1.15E-17 | 17 | passed |
/models/1/coefficients/1/estimate | tolerance | 1.5399751487627418 | 1.5399751487627407 | 1.14E-15 | 15 | passed |
/models/1/coefficients/1/standard_error | tolerance | 0.066407580512640896 | 0.0664075805126409 | 2.13E-19 | 17 | passed |
/models/1/coefficients/1/t_value | tolerance | 23.189749376121338 | 23.189749376121323 | 1.46E-14 | 15 | passed |
/models/1/coefficients/1/p_value | tail_probability | 7.3813486664787184e-15 | 7.381348666478785e-15 | 6.62E-29 | 14 | passed |
/models/1/coefficients/1/lower | tolerance | 1.4004579992246533 | 1.4004579992246522 | 1.11E-15 | 15 | passed |
/models/1/coefficients/1/upper | tolerance | 1.6794922983008302 | 1.6794922983008291 | 1.07E-15 | 15 | passed |
/models/1/coefficients/1/standardized | tolerance | 0.91792397201128406 | 0.9179239720112835 | 5.53E-16 | 15 | passed |
/models/1/coefficients/1/zero_order | tolerance | 0.9198692305114855 | 0.9198692305114855 | 2.79E-18 | 17 | passed |
/models/1/coefficients/1/partial | tolerance | 0.98367280112214928 | 0.9836728011221495 | 2.18E-16 | 15 | passed |
/models/1/coefficients/1/part | tolerance | 0.90792739355023666 | 0.9079273935502364 | 2.21E-16 | 15 | passed |
/models/1/coefficients/1/tolerance | tolerance | 0.97833775935608003 | 0.97833775935608 | 2.17E-18 | 17 | passed |
/models/1/coefficients/1/vif | tolerance | 1.0221418834515572 | 1.0221418834515572 | 9.38E-18 | 17 | passed |
/models/1/coefficients/2/estimate | tolerance | -0.72143265472075979 | -0.7214326547207593 | 4.42E-16 | 15 | passed |
/models/1/coefficients/2/standard_error | tolerance | 0.11667615916663307 | 0.11667615916663308 | 1.38E-17 | 15 | passed |
/models/1/coefficients/2/t_value | tolerance | -6.183205376947944 | -6.18320537694794 | 4.41E-15 | 15 | passed |
/models/1/coefficients/2/p_value | tail_probability | 7.7610299092293112e-06 | 7.761029909229387e-06 | 7.62E-20 | 14 | passed |
/models/1/coefficients/2/lower | tolerance | -0.96656016908461062 | -0.9665601690846102 | 4.43E-16 | 15 | passed |
/models/1/coefficients/2/upper | tolerance | -0.47630514035690896 | -0.47630514035690846 | 4.97E-16 | 14 | passed |
/models/1/coefficients/2/standardized | tolerance | -0.24376812595595629 | -0.24376812595595615 | 1.40E-16 | 15 | passed |
/models/1/coefficients/2/zero_order | tolerance | -0.31369485297341543 | -0.3136948529734154 | 5.77E-17 | 15 | passed |
/models/1/coefficients/2/partial | tolerance | -0.82455911297364481 | -0.8245591129736447 | 1.07E-16 | 15 | passed |
/models/1/coefficients/2/part | tolerance | -0.24208547710562292 | -0.24208547710562278 | 1.38E-16 | 15 | passed |
/models/1/coefficients/2/tolerance | tolerance | 0.98624232379795174 | 0.9862423237979515 | 2.26E-16 | 15 | passed |
/models/1/coefficients/2/vif | tolerance | 1.0139495901464342 | 1.0139495901464344 | 1.76E-16 | 15 | passed |
/models/1/coefficients/3/estimate | tolerance | 1.1220605688995833 | 1.1220605688995833 | 2.28E-17 | 16 | passed |
/models/1/coefficients/3/standard_error | tolerance | 0.1617122967845519 | 0.16171229678455198 | 8.43E-17 | 15 | passed |
/models/1/coefficients/3/t_value | tolerance | 6.9386224251981057 | 6.938622425198102 | 3.57E-15 | 15 | passed |
/models/1/coefficients/3/p_value | tail_probability | 1.7476517496610364e-06 | 1.747651749661046e-06 | 9.50E-21 | 14 | passed |
/models/1/coefficients/3/lower | tolerance | 0.78231564040691826 | 0.782315640406918 | 2.26E-16 | 15 | passed |
/models/1/coefficients/3/upper | tolerance | 1.4618054973922483 | 1.4618054973922485 | 2.21E-16 | 15 | passed |
/models/1/coefficients/3/standardized | tolerance | 0.27628213141358848 | 0.2762821314135885 | 3.15E-18 | 16 | passed |
/models/1/coefficients/3/zero_order | tolerance | 0.20374089467559878 | 0.20374089467559878 | 2.91E-18 | 16 | passed |
/models/1/coefficients/3/partial | tolerance | 0.85315206894761164 | 0.8531520689476113 | 3.32E-16 | 15 | passed |
/models/1/coefficients/3/part | tolerance | 0.27166164114849189 | 0.27166164114849184 | 5.08E-17 | 15 | passed |
/models/1/coefficients/3/tolerance | tolerance | 0.96683206302399771 | 0.9668320630239979 | 2.24E-16 | 15 | passed |
/models/1/coefficients/3/vif | tolerance | 1.0343057892311325 | 1.0343057892311323 | 2.45E-16 | 15 | passed |
/models/1/coefficients/4/estimate | tolerance | -0.27315446256399445 | -0.2731544625639946 | 1.66E-16 | 15 | passed |
/models/1/coefficients/4/standard_error | tolerance | 0.22641259168598163 | 0.2264125916859818 | 1.66E-16 | 15 | passed |
/models/1/coefficients/4/t_value | tolerance | -1.2064455449670419 | -1.2064455449670417 | 1.95E-16 | 15 | passed |
/models/1/coefficients/4/p_value | tail_probability | 0.24326357903401713 | 0.24326357903401724 | 1.11E-16 | 15 | passed |
/models/1/coefficients/4/lower | tolerance | -0.74882966662516814 | -0.7488296666251686 | 4.48E-16 | 15 | passed |
/models/1/coefficients/4/upper | tolerance | 0.20252074149717919 | 0.2025207414971794 | 2.23E-16 | 14 | passed |
/models/1/coefficients/4/standardized | tolerance | -0.048199735544381943 | -0.048199735544381964 | 2.06E-17 | 15 | passed |
/models/1/coefficients/4/zero_order | tolerance | 0.097941577108646219 | 0.09794157710864632 | 9.71E-17 | 15 | passed |
/models/1/coefficients/4/partial | tolerance | -0.27351831016121358 | -0.2735183101612133 | 2.73E-16 | 15 | passed |
/models/1/coefficients/4/part | tolerance | -0.047234876985351462 | -0.04723487698535143 | 3.45E-17 | 15 | passed |
/models/1/coefficients/4/tolerance | tolerance | 0.96036487269361881 | 0.9603648726936188 | 4.15E-19 | 18 | passed |
/models/1/coefficients/4/vif | tolerance | 1.0412709048751576 | 1.0412709048751576 | 1.02E-17 | 17 | passed |
/models/1/collinearity/0/dimension | exact | 1 | 1 | 0.00E+2 | passed | |
/models/1/collinearity/0/eigenvalue | tolerance | 2.3695261828284324 | 2.3695261828284324 | 1.46E-17 | 17 | passed |
/models/1/collinearity/0/condition_index | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/models/1/collinearity/1/dimension | exact | 2 | 2 | 0.00E+2 | passed | |
/models/1/collinearity/1/eigenvalue | tolerance | 1.0412209295193513 | 1.04122092951935 | 1.33E-15 | 14 | passed |
/models/1/collinearity/1/condition_index | tolerance | 1.5085486180703642 | 1.508548618070365 | 9.10E-16 | 15 | passed |
/models/1/collinearity/2/dimension | exact | 3 | 3 | 0.00E+2 | passed | |
/models/1/collinearity/2/eigenvalue | tolerance | 0.75272812482352858 | 0.7527281248235284 | 2.25E-16 | 15 | passed |
/models/1/collinearity/2/condition_index | tolerance | 1.7742372146644796 | 1.7742372146644798 | 2.11E-16 | 15 | passed |
/models/1/collinearity/3/dimension | exact | 4 | 4 | 0.00E+2 | passed | |
/models/1/collinearity/3/eigenvalue | tolerance | 0.52436215622964311 | 0.5243621562296433 | 2.18E-16 | 15 | passed |
/models/1/collinearity/3/condition_index | tolerance | 2.1257641844108526 | 2.125764184410852 | 4.69E-16 | 15 | passed |
/models/1/collinearity/4/dimension | exact | 5 | 5 | 0.00E+2 | passed | |
/models/1/collinearity/4/eigenvalue | tolerance | 0.3121626065990486 | 0.3121626065990486 | 2.36E-18 | 17 | passed |
/models/1/collinearity/4/condition_index | tolerance | 2.7551187141757008 | 2.7551187141757008 | 4.41E-17 | 16 | passed |
/casewise/0/observed | tolerance | -0.21069097886642679 | -0.2106909788664268 | 2.40E-18 | 16 | passed |
/casewise/0/predicted | tolerance | -0.12356514775308289 | -0.1235651477530801 | 2.79E-15 | 13 | passed |
/casewise/0/residual | tolerance | -0.087125831113343905 | -0.0871258311133467 | 2.79E-15 | 13 | passed |
/casewise/0/standardized_residual | tolerance | -0.19986163961177841 | -0.19986163961178474 | 6.33E-15 | 13 | passed |
/casewise/0/studentized_residual | tolerance | -0.23290413679985744 | -0.23290413679985592 | 1.52E-15 | 14 | passed |
/casewise/0/deleted_studentized_residual | tolerance | -0.22668395849222167 | -0.22668395849222023 | 1.44E-15 | 14 | passed |
/casewise/0/leverage | tolerance | 0.26361575709542151 | 0.2636157570954214 | 1.11E-16 | 15 | passed |
/casewise/0/cooks_distance | tolerance | 0.003883750117676344 | 0.003883750117676292 | 5.21E-17 | 13 | passed |
/casewise/0/dfbetas/0 | tolerance | 0.00039681580329777787 | 0.0003968158032977149 | 6.30E-17 | 12 | passed |
/casewise/0/dfbetas/1 | tolerance | 0.068477574534437688 | 0.06847757453443726 | 4.30E-16 | 14 | passed |
/casewise/0/dfbetas/2 | tolerance | -0.028332668196641663 | -0.028332668196641434 | 2.29E-16 | 14 | passed |
/casewise/0/dfbetas/3 | tolerance | -0.085376857530706077 | -0.08537685753070547 | 6.11E-16 | 14 | passed |
/casewise/0/dfbetas/4 | tolerance | 0.035529177240499234 | 0.035529177240499005 | 2.29E-16 | 14 | passed |
/casewise/1/observed | tolerance | -0.81604839374920402 | -0.816048393749204 | 4.82E-18 | 17 | passed |
/casewise/1/predicted | tolerance | -1.1730252071763674 | -1.1730252071763667 | 6.87E-16 | 15 | passed |
/casewise/1/residual | tolerance | 0.35697681342716342 | 0.3569768134271627 | 7.22E-16 | 14 | passed |
/casewise/1/standardized_residual | tolerance | 0.81888425422450495 | 0.818884254224503 | 2.00E-15 | 14 | passed |
/casewise/1/studentized_residual | tolerance | 0.89338414629334062 | 0.893384146293348 | 7.33E-15 | 14 | passed |
/casewise/1/deleted_studentized_residual | tolerance | 0.8881267223036069 | 0.8881267223036146 | 7.66E-15 | 14 | passed |
/casewise/1/leverage | tolerance | 0.15982731469731545 | 0.15982731469731543 | 2.43E-17 | 15 | passed |
/casewise/1/cooks_distance | tolerance | 0.030366093366984575 | 0.030366093366985064 | 4.89E-16 | 13 | passed |
/casewise/1/dfbetas/0 | tolerance | 0.24283676951712513 | 0.24283676951712713 | 2.00E-15 | 14 | passed |
/casewise/1/dfbetas/1 | tolerance | -0.2807445538058298 | -0.2807445538058321 | 2.28E-15 | 14 | passed |
/casewise/1/dfbetas/2 | tolerance | 0.03629690258941172 | 0.036296902589412025 | 3.05E-16 | 14 | passed |
/casewise/1/dfbetas/3 | tolerance | -0.12280507298380892 | -0.12280507298380985 | 9.34E-16 | 14 | passed |
/casewise/1/dfbetas/4 | tolerance | -0.078792508864626576 | -0.07879250886462723 | 6.52E-16 | 14 | passed |
/casewise/4/observed | tolerance | 0.78519807213529547 | 0.7851980721352955 | 3.81E-18 | 17 | passed |
/casewise/4/predicted | tolerance | 0.82937580853441883 | 0.8293758085344202 | 1.34E-15 | 14 | passed |
/casewise/4/residual | tolerance | -0.044177736399123327 | -0.0441777363991247 | 1.37E-15 | 13 | passed |
/casewise/4/standardized_residual | tolerance | -0.10134118341527584 | -0.10134118341527895 | 3.11E-15 | 13 | passed |
/casewise/4/studentized_residual | tolerance | -0.12379589786241581 | -0.12379589786241649 | 6.77E-16 | 14 | passed |
/casewise/4/deleted_studentized_residual | tolerance | -0.12035923612338065 | -0.12035923612338131 | 6.63E-16 | 14 | passed |
/casewise/4/leverage | tolerance | 0.32986942243819944 | 0.32986942243819944 | 4.43E-18 | 16 | passed |
/casewise/4/cooks_distance | tolerance | 0.0015087772565002494 | 0.0015087772565002663 | 1.69E-17 | 13 | passed |
/casewise/4/dfbetas/0 | tolerance | -0.067837757478916252 | -0.06783775747891661 | 3.61E-16 | 14 | passed |
/casewise/4/dfbetas/1 | tolerance | 0.034422742158682684 | 0.034422742158682844 | 1.60E-16 | 14 | passed |
/casewise/4/dfbetas/2 | tolerance | 0.058107594923335899 | 0.0581075949233362 | 2.99E-16 | 14 | passed |
/casewise/4/dfbetas/3 | tolerance | 0.011240189168159786 | 0.011240189168159845 | 5.88E-17 | 14 | passed |
/casewise/4/dfbetas/4 | tolerance | 0.039881547113384028 | 0.039881547113384264 | 2.36E-16 | 14 | passed |
/casewise/10/observed | tolerance | 2.5858007091127839 | 2.585800709112784 | 2.39E-17 | 17 | passed |
/casewise/10/predicted | tolerance | 2.221698325718052 | 2.221698325718052 | 3.61E-17 | 16 | passed |
/casewise/10/residual | tolerance | 0.364102383394732 | 0.3641023833947319 | 1.12E-16 | 15 | passed |
/casewise/10/standardized_residual | tolerance | 0.83522990141877995 | 0.8352299014187794 | 5.53E-16 | 15 | passed |
/casewise/10/studentized_residual | tolerance | 0.91553221458907275 | 0.9155322145890705 | 2.22E-15 | 14 | passed |
/casewise/10/deleted_studentized_residual | tolerance | 0.91120619369475497 | 0.9112061936947526 | 2.33E-15 | 14 | passed |
/casewise/10/leverage | tolerance | 0.16772891419656616 | 0.16772891419656616 | 1.03E-18 | 17 | passed |
/casewise/10/cooks_distance | tolerance | 0.033784724742811009 | 0.033784724742810836 | 1.73E-16 | 14 | passed |
/casewise/10/dfbetas/0 | tolerance | 0.36850260452044559 | 0.36850260452044464 | 9.47E-16 | 14 | passed |
/casewise/10/dfbetas/1 | tolerance | -0.004592300234572735 | -0.004592300234572666 | 6.93E-17 | 13 | passed |
/casewise/10/dfbetas/2 | tolerance | -0.13253234281647136 | -0.13253234281647094 | 4.16E-16 | 14 | passed |
/casewise/10/dfbetas/3 | tolerance | -0.089617569520224066 | -0.08961756952022377 | 2.91E-16 | 14 | passed |
/casewise/10/dfbetas/4 | tolerance | -0.29826067979237059 | -0.2982606797923698 | 7.81E-16 | 14 | passed |
/casewise/22/observed | tolerance | 5.5912229655643095 | 5.5912229655643095 | 3.27E-17 | 17 | passed |
/casewise/22/predicted | tolerance | 5.3365364798382444 | 5.336536479838244 | 1.78E-17 | 17 | passed |
/casewise/22/residual | tolerance | 0.25468648572606495 | 0.2546864857260651 | 1.65E-16 | 15 | passed |
/casewise/22/standardized_residual | tolerance | 0.58423613265684127 | 0.5842361326568415 | 2.19E-16 | 15 | passed |
/casewise/22/studentized_residual | tolerance | 0.65030994470999093 | 0.6503099447099888 | 2.11E-15 | 14 | passed |
/casewise/22/deleted_studentized_residual | tolerance | 0.63954525585439792 | 0.6395452558543958 | 2.11E-15 | 14 | passed |
/casewise/22/leverage | tolerance | 0.19288385474039513 | 0.19288385474039507 | 5.79E-17 | 15 | passed |
/casewise/22/cooks_distance | tolerance | 0.020212993127687283 | 0.020212993127687148 | 1.35E-16 | 14 | passed |
/casewise/22/dfbetas/0 | tolerance | 0.14837893312966827 | 0.14837893312966785 | 4.20E-16 | 14 | passed |
/casewise/22/dfbetas/1 | tolerance | 0.24356118583916675 | 0.24356118583916586 | 8.89E-16 | 14 | passed |
/casewise/22/dfbetas/2 | tolerance | 0.039022778327092868 | 0.039022778327092694 | 1.74E-16 | 14 | passed |
/casewise/22/dfbetas/3 | tolerance | -0.054013342288140136 | -0.05401334228813992 | 2.15E-16 | 14 | passed |
/casewise/22/dfbetas/4 | tolerance | -0.1153840245752258 | -0.11538402457522542 | 3.75E-16 | 14 | passed |
/n | exact | 23 | 23 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Enter all: model 1 = x1 + x2, model 2 adds x3 + x4; the casewise table lists every row in retained order (index 0 is the first complete row).
- Every model is lm() on the rows complete on y and every block's predictor (listwise over all blocks, 23 of 24 rows).
- R-squared change F from anova(model k-1, model k); overall F and p from summary.lm; coefficient intervals from confint.
- Durbin-Watson = sum(diff(e)^2) / sum(e^2) of the residuals in row order; VIF = 1 / (1 - R^2 of each predictor on the others); partial r = cor of the residuals of y and x_j on the other predictors; part r = cor(y, residual of x_j on the others).
- Collinearity: singular values of the design (intercept included) with each column scaled to unit length, no centering; eigenvalue = singular value squared; condition index = sqrt(max eigenvalue / eigenvalue).
- Casewise: standardized residual e / s; studentized = rstandard; deleted studentized = rstudent; leverage = hatvalues; Cook's distance = cooks.distance; DFBETAS = dfbetas.
- docs/manual/chapters/86-regression-and-count-models.tex:9-14: 'fits cumulative blocks on one common complete-case population. ... selection uses Gaussian AIC or BIC, including the error-variance parameter.'
- docs/manual/chapters/86-regression-and-count-models.tex:16-19: the change statistic F=[dR^2/(p_k-p_{k-1})]/[(1-R_k^2)/(n-p_k)]
- docs/manual/chapters/86-regression-and-count-models.tex:24-26: 'Collinearity diagnostics include the intercept in an uncentred design with columns scaled to unit length.'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
50 emit <- function(id, title, kind, config, outputs, notes) {
51 write_expected("regression", id, list(
52 schema_version = "2.0.0", case_id = id, outputs = outputs, expected_error = NULL,
53 deferred_outputs = list(), generator_run = run))
54 write_case("regression", id, list(
55 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
56 entry_point = entry, menu_items = list(menu), title = title, case_kind = kind,
57 dataset = list(path = "reference_data/datasets/REG_BLOCKS.json", sha256 = ""),
58 excluded_rows = list(), configuration = config, "repeat" = 1L,
59 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
60 oracle = list(oracle_class = "independent_implementation", source = "R 4.6.1 stats::lm and step",
61 citation = "R Core Team, stats package help: lm, anova.lm, confint.lm, step, AIC, BIC, rstandard, rstudent, hatvalues, cooks.distance, dfbetas; Belsley, Kuh and Welsch (1980), Regression Diagnostics, ch. 3.",
62 generator = list(path = "generators/r/regression_blocks.R", sha256 = ""),
63 independent = TRUE,
64 convention_notes = c(notes, notes_common, "Expected computed from the exported CSV.")),
65 supported = TRUE, unsupported_reason = NULL,
66 requirement_ids = list("REQ-STAT-REG-REGRESSION-BLOCKS-001"),
67 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
Blockwise regression forward AIC
Case STAT-REG-REGRESSION-BLOCKS-002 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm and step
- Citation
- R Core Team, stats package help: lm, anova.lm, confint.lm, step, AIC, BIC, rstandard, rstudent, hatvalues, cooks.distance, dfbetas; Belsley, Kuh and Welsch (1980), Regression Diagnostics, ch. 3.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_blocks.R · sha256 86184660dac4e79f
- Dataset
- reference_data/datasets/REG_BLOCKS.json
Settings compared
blocks= [["x1", "x2"], ["x3", "x4", "x5"]]casewise= "none"casewise_threshold= 3confidence_level= 0.95criterion= "aic"method= "forward"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/models/0/r_squared | tolerance | 0.89860540286782831 | 0.8986054028678283 | 3.23E-18 | 17 | passed |
/models/0/adjusted_r_squared | tolerance | 0.88846594315461114 | 0.8884659431546111 | 2.56E-18 | 17 | passed |
/models/0/standard_error | tolerance | 0.79278391963209549 | 0.7927839196320953 | 2.21E-16 | 15 | passed |
/models/0/df2 | exact | 20 | 20 | 0.00E+2 | passed | |
/models/0/residual_ss | tolerance | 12.570126864544575 | 12.570126864544568 | 7.38E-15 | 15 | passed |
/models/0/regression_ss | tolerance | 111.40222689074416 | 111.40222689074417 | 1.42E-14 | 15 | passed |
/models/0/f_value | tolerance | 88.624584374694265 | 88.62458437469431 | 4.31E-14 | 15 | passed |
/models/0/p_value | tail_probability | 1.148545328910703e-10 | 1.1485453289106956e-10 | 7.37E-25 | 14 | passed |
/models/0/durbin_watson | tolerance | 2.7168680656281303 | 2.7168680656281303 | 2.43E-17 | 17 | passed |
/models/0/r_squared_change | tolerance | 0.89860540286782831 | 0.8986054028678283 | 3.23E-18 | 17 | passed |
/models/0/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/models/0/f_change | tolerance | 88.624584374694265 | 88.62458437469427 | 4.21E-16 | 17 | passed |
/models/0/p_change | tail_probability | 1.148545328910703e-10 | 1.1485453289107003e-10 | 2.72E-25 | 14 | passed |
/models/0/predictors | set | ['x1', 'x2'] | ['x1', 'x2'] | passed | ||
/models/1/r_squared | tolerance | 0.97017690115125299 | 0.970176901151253 | 5.52E-19 | 18 | passed |
/models/1/adjusted_r_squared | tolerance | 0.96546799080671397 | 0.965467990806714 | 1.53E-18 | 17 | passed |
/models/1/standard_error | tolerance | 0.44112534085568267 | 0.4411253408556828 | 1.09E-16 | 15 | passed |
/models/1/df2 | exact | 19 | 19 | 0.00E+2 | passed | |
/models/1/residual_ss | tolerance | 3.6972397605558025 | 3.6972397605558034 | 8.90E-16 | 15 | passed |
/models/1/regression_ss | tolerance | 120.27511399473293 | 120.27511399473293 | 3.52E-15 | 16 | passed |
/models/1/f_value | tolerance | 206.03002184494426 | 206.03002184494423 | 3.02E-14 | 15 | passed |
/models/1/p_value | tail_probability | 1.1486630672467477e-14 | 1.1486630672467534e-14 | 5.72E-29 | 14 | passed |
/models/1/durbin_watson | tolerance | 2.7963053183803055 | 2.796305318380305 | 4.51E-16 | 15 | passed |
/models/1/r_squared_change | tolerance | 0.071571498283424684 | 0.07157149828342468 | 2.16E-19 | 17 | passed |
/models/1/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/models/1/f_change | tolerance | 45.597490531813243 | 45.597490531813136 | 1.07E-13 | 14 | passed |
/models/1/p_change | tail_probability | 1.8851110917256922e-06 | 1.8851110917257178e-06 | 2.56E-20 | 13 | passed |
/models/1/predictors | set | ['x1', 'x2', 'x3'] | ['x1', 'x2', 'x3'] | passed | ||
/models/1/entered | set | ['x3'] | ['x3'] | passed | ||
/models/1/selection/0/criterion | tolerance | 59.375237210552065 | 59.375237210552044 | 2.14E-14 | 15 | passed |
/models/1/selection/0/action | exact | start | start | passed | ||
/models/1/selection/1/action | exact | add | add | passed | ||
/models/1/selection/1/predictor | exact | x3 | x3 | passed | ||
/models/1/selection/1/criterion | tolerance | 33.229295764503213 | 33.22929576450322 | 7.31E-15 | 15 | passed |
Convention
- step(direction = 'forward', k = 2) from y ~ x1 + x2 with scope x3 + x4 + x5; the reported criterion is AIC() of the fitted lm, which differs from extractAIC by a constant and selects the same moves.
- Every model is lm() on the rows complete on y and every block's predictor (listwise over all blocks, 23 of 24 rows).
- R-squared change F from anova(model k-1, model k); overall F and p from summary.lm; coefficient intervals from confint.
- Durbin-Watson = sum(diff(e)^2) / sum(e^2) of the residuals in row order; VIF = 1 / (1 - R^2 of each predictor on the others); partial r = cor of the residuals of y and x_j on the other predictors; part r = cor(y, residual of x_j on the others).
- Collinearity: singular values of the design (intercept included) with each column scaled to unit length, no centering; eigenvalue = singular value squared; condition index = sqrt(max eigenvalue / eigenvalue).
- Casewise: standardized residual e / s; studentized = rstandard; deleted studentized = rstudent; leverage = hatvalues; Cook's distance = cooks.distance; DFBETAS = dfbetas.
- docs/manual/chapters/86-regression-and-count-models.tex:9-14: 'fits cumulative blocks on one common complete-case population. ... selection uses Gaussian AIC or BIC, including the error-variance parameter.'
- docs/manual/chapters/86-regression-and-count-models.tex:16-19: the change statistic F=[dR^2/(p_k-p_{k-1})]/[(1-R_k^2)/(n-p_k)]
- docs/manual/chapters/86-regression-and-count-models.tex:24-26: 'Collinearity diagnostics include the intercept in an uncentred design with columns scaled to unit length.'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
187 forced <- stats::lm(y ~ x1 + x2, data = cc)
188 fwd <- stats::step(forced, scope = list(lower = ~ x1 + x2, upper = ~ x1 + x2 + x3 + x4 + x5),
189 direction = "forward", k = 2, trace = 0)
190 chosen_fwd <- setdiff(attr(stats::terms(fwd), "term.labels"), c("x1", "x2"))
191 outputs <- c(model_outputs(0, c("x1", "x2"), NULL, with_coefficients = FALSE),
192 model_outputs(1, c("x1", "x2", chosen_fwd), c("x1", "x2"), with_coefficients = FALSE))
193 outputs[["/models/1/entered"]] <- setof(chosen_fwd, "predictors step() adds by AIC")
194 outputs[["/models/1/selection/0/criterion"]] <- tol(stats::AIC(forced), "AIC of the forced model (R's AIC with the variance counted)")
195 outputs[["/models/1/selection/0/action"]] <- list(comparison = "exact", value = "start", rationale = "the first move records the forced model")
196 first_added <- sub("^[+] ", "", as.character(fwd$anova$Step[2]))
197 stopifnot(length(chosen_fwd) >= 1, first_added %in% chosen_fwd)
198 outputs[["/models/1/selection/1/action"]] <- list(comparison = "exact", value = "add", rationale = "forward entry adds")
199 outputs[["/models/1/selection/1/predictor"]] <- list(comparison = "exact", value = first_added, rationale = "the first predictor step() adds")
200 outputs[["/models/1/selection/1/criterion"]] <- tol(stats::AIC(fit_of(c("x1", "x2", first_added))), "AIC after the first addition")
201 emit("STAT-REG-REGRESSION-BLOCKS-002", "Blockwise regression forward AIC", "axis_coverage",
202 list(response = "y", blocks = list(list("x1", "x2"), list("x3", "x4", "x5")), method = "forward",
203 criterion = "aic", confidence_level = 0.95, casewise = "none", casewise_threshold = 3.0),
204 outputs, "step(direction = 'forward', k = 2) from y ~ x1 + x2 with scope x3 + x4 + x5; the reported criterion is AIC() of the fitted lm, which differs from extractAIC by a constant and selects the same moves.")
Blockwise regression backward BIC
Case STAT-REG-REGRESSION-BLOCKS-003 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm and step
- Citation
- R Core Team, stats package help: lm, anova.lm, confint.lm, step, AIC, BIC, rstandard, rstudent, hatvalues, cooks.distance, dfbetas; Belsley, Kuh and Welsch (1980), Regression Diagnostics, ch. 3.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_blocks.R · sha256 86184660dac4e79f
- Dataset
- reference_data/datasets/REG_BLOCKS.json
Settings compared
blocks= [["x1", "x2"], ["x3", "x4", "x5"]]casewise= "none"casewise_threshold= 3confidence_level= 0.95criterion= "bic"method= "backward"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/models/0/r_squared | tolerance | 0.89860540286782831 | 0.8986054028678283 | 3.23E-18 | 17 | passed |
/models/0/adjusted_r_squared | tolerance | 0.88846594315461114 | 0.8884659431546111 | 2.56E-18 | 17 | passed |
/models/0/standard_error | tolerance | 0.79278391963209549 | 0.7927839196320953 | 2.21E-16 | 15 | passed |
/models/0/df2 | exact | 20 | 20 | 0.00E+2 | passed | |
/models/0/residual_ss | tolerance | 12.570126864544575 | 12.570126864544568 | 7.38E-15 | 15 | passed |
/models/0/regression_ss | tolerance | 111.40222689074416 | 111.40222689074417 | 1.42E-14 | 15 | passed |
/models/0/f_value | tolerance | 88.624584374694265 | 88.62458437469431 | 4.31E-14 | 15 | passed |
/models/0/p_value | tail_probability | 1.148545328910703e-10 | 1.1485453289106956e-10 | 7.37E-25 | 14 | passed |
/models/0/durbin_watson | tolerance | 2.7168680656281303 | 2.7168680656281303 | 2.43E-17 | 17 | passed |
/models/0/r_squared_change | tolerance | 0.89860540286782831 | 0.8986054028678283 | 3.23E-18 | 17 | passed |
/models/0/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/models/0/f_change | tolerance | 88.624584374694265 | 88.62458437469427 | 4.21E-16 | 17 | passed |
/models/0/p_change | tail_probability | 1.148545328910703e-10 | 1.1485453289107003e-10 | 2.72E-25 | 14 | passed |
/models/0/predictors | set | ['x1', 'x2'] | ['x1', 'x2'] | passed | ||
/models/1/r_squared | tolerance | 0.97017690115125299 | 0.970176901151253 | 5.52E-19 | 18 | passed |
/models/1/adjusted_r_squared | tolerance | 0.96546799080671397 | 0.965467990806714 | 1.53E-18 | 17 | passed |
/models/1/standard_error | tolerance | 0.44112534085568267 | 0.4411253408556828 | 1.09E-16 | 15 | passed |
/models/1/df2 | exact | 19 | 19 | 0.00E+2 | passed | |
/models/1/residual_ss | tolerance | 3.6972397605558025 | 3.6972397605558034 | 8.90E-16 | 15 | passed |
/models/1/regression_ss | tolerance | 120.27511399473293 | 120.27511399473293 | 3.52E-15 | 16 | passed |
/models/1/f_value | tolerance | 206.03002184494426 | 206.03002184494423 | 3.02E-14 | 15 | passed |
/models/1/p_value | tail_probability | 1.1486630672467477e-14 | 1.1486630672467534e-14 | 5.72E-29 | 14 | passed |
/models/1/durbin_watson | tolerance | 2.7963053183803055 | 2.796305318380305 | 4.51E-16 | 15 | passed |
/models/1/r_squared_change | tolerance | 0.071571498283424684 | 0.07157149828342468 | 2.16E-19 | 17 | passed |
/models/1/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/models/1/f_change | tolerance | 45.597490531813243 | 45.597490531813136 | 1.07E-13 | 14 | passed |
/models/1/p_change | tail_probability | 1.8851110917256922e-06 | 1.8851110917257178e-06 | 2.56E-20 | 13 | passed |
/models/1/predictors | set | ['x1', 'x2', 'x3'] | ['x1', 'x2', 'x3'] | passed | ||
/models/1/entered | set | ['x3'] | ['x3'] | passed | ||
/models/1/selection/0/criterion | tolerance | 43.221935309368689 | 43.22193530936872 | 2.85E-14 | 15 | passed |
Convention
- step(direction = 'backward', k = log(n)) from the full model with x1 + x2 forced; the start criterion is BIC() of the full block-2 model.
- Every model is lm() on the rows complete on y and every block's predictor (listwise over all blocks, 23 of 24 rows).
- R-squared change F from anova(model k-1, model k); overall F and p from summary.lm; coefficient intervals from confint.
- Durbin-Watson = sum(diff(e)^2) / sum(e^2) of the residuals in row order; VIF = 1 / (1 - R^2 of each predictor on the others); partial r = cor of the residuals of y and x_j on the other predictors; part r = cor(y, residual of x_j on the others).
- Collinearity: singular values of the design (intercept included) with each column scaled to unit length, no centering; eigenvalue = singular value squared; condition index = sqrt(max eigenvalue / eigenvalue).
- Casewise: standardized residual e / s; studentized = rstandard; deleted studentized = rstudent; leverage = hatvalues; Cook's distance = cooks.distance; DFBETAS = dfbetas.
- docs/manual/chapters/86-regression-and-count-models.tex:9-14: 'fits cumulative blocks on one common complete-case population. ... selection uses Gaussian AIC or BIC, including the error-variance parameter.'
- docs/manual/chapters/86-regression-and-count-models.tex:16-19: the change statistic F=[dR^2/(p_k-p_{k-1})]/[(1-R_k^2)/(n-p_k)]
- docs/manual/chapters/86-regression-and-count-models.tex:24-26: 'Collinearity diagnostics include the intercept in an uncentred design with columns scaled to unit length.'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
207 full <- stats::lm(y ~ x1 + x2 + x3 + x4 + x5, data = cc)
208 bwd <- stats::step(full, scope = list(lower = ~ x1 + x2, upper = ~ x1 + x2 + x3 + x4 + x5),
209 direction = "backward", k = log(n_complete), trace = 0)
210 chosen_bwd <- setdiff(attr(stats::terms(bwd), "term.labels"), c("x1", "x2"))
211 outputs <- c(model_outputs(0, c("x1", "x2"), NULL, with_coefficients = FALSE),
212 model_outputs(1, c("x1", "x2", chosen_bwd), c("x1", "x2"), with_coefficients = FALSE))
213 outputs[["/models/1/entered"]] <- setof(chosen_bwd, "predictors step() keeps by BIC")
214 outputs[["/models/1/selection/0/criterion"]] <- tol(stats::BIC(full), "BIC of the full model (R's BIC with the variance counted)")
215 emit("STAT-REG-REGRESSION-BLOCKS-003", "Blockwise regression backward BIC", "axis_coverage",
216 list(response = "y", blocks = list(list("x1", "x2"), list("x3", "x4", "x5")), method = "backward",
217 criterion = "bic", confidence_level = 0.95, casewise = "none", casewise_threshold = 3.0),
218 outputs, "step(direction = 'backward', k = log(n)) from the full model with x1 + x2 forced; the start criterion is BIC() of the full block-2 model.")
Blockwise regression stepwise AIC 90 percent outliers
Case STAT-REG-REGRESSION-BLOCKS-004 · status: passed
Reference
- Evidence type
- R
- Source
- R 4.6.1 stats::lm and step
- Citation
- R Core Team, stats package help: lm, anova.lm, confint.lm, step, AIC, BIC, rstandard, rstudent, hatvalues, cooks.distance, dfbetas; Belsley, Kuh and Welsch (1980), Regression Diagnostics, ch. 3.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_blocks.R · sha256 86184660dac4e79f
- Dataset
- reference_data/datasets/REG_BLOCKS.json
Settings compared
blocks= [["x1", "x2"], ["x3", "x4", "x5"]]casewise= "outliers"casewise_threshold= 1.5confidence_level= 0.9criterion= "aic"method= "stepwise"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/models/0/r_squared | tolerance | 0.89860540286782831 | 0.8986054028678283 | 3.23E-18 | 17 | passed |
/models/0/adjusted_r_squared | tolerance | 0.88846594315461114 | 0.8884659431546111 | 2.56E-18 | 17 | passed |
/models/0/standard_error | tolerance | 0.79278391963209549 | 0.7927839196320953 | 2.21E-16 | 15 | passed |
/models/0/df2 | exact | 20 | 20 | 0.00E+2 | passed | |
/models/0/residual_ss | tolerance | 12.570126864544575 | 12.570126864544568 | 7.38E-15 | 15 | passed |
/models/0/regression_ss | tolerance | 111.40222689074416 | 111.40222689074417 | 1.42E-14 | 15 | passed |
/models/0/f_value | tolerance | 88.624584374694265 | 88.62458437469431 | 4.31E-14 | 15 | passed |
/models/0/p_value | tail_probability | 1.148545328910703e-10 | 1.1485453289106956e-10 | 7.37E-25 | 14 | passed |
/models/0/durbin_watson | tolerance | 2.7168680656281303 | 2.7168680656281303 | 2.43E-17 | 17 | passed |
/models/0/r_squared_change | tolerance | 0.89860540286782831 | 0.8986054028678283 | 3.23E-18 | 17 | passed |
/models/0/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/models/0/f_change | tolerance | 88.624584374694265 | 88.62458437469427 | 4.21E-16 | 17 | passed |
/models/0/p_change | tail_probability | 1.148545328910703e-10 | 1.1485453289107003e-10 | 2.72E-25 | 14 | passed |
/models/0/predictors | set | ['x1', 'x2'] | ['x1', 'x2'] | passed | ||
/models/0/coefficients/0/estimate | tolerance | 2.4201267383580896 | 2.420126738358089 | 4.87E-16 | 15 | passed |
/models/0/coefficients/0/standard_error | tolerance | 0.19012712705453957 | 0.1901271270545395 | 7.91E-17 | 15 | passed |
/models/0/coefficients/0/t_value | tolerance | 12.728992310833455 | 12.728992310833458 | 3.39E-15 | 15 | passed |
/models/0/coefficients/0/p_value | tail_probability | 4.7621401128199224e-11 | 4.76214011281992e-11 | 2.58E-26 | 15 | passed |
/models/0/coefficients/0/lower | tolerance | 2.0922110138530066 | 2.0922110138530066 | 3.74E-17 | 16 | passed |
/models/0/coefficients/0/upper | tolerance | 2.7480424628631721 | 2.7480424628631717 | 4.36E-16 | 15 | passed |
/models/0/coefficients/1/estimate | tolerance | 1.5072963294269275 | 1.5072963294269264 | 1.13E-15 | 15 | passed |
/models/0/coefficients/1/standard_error | tolerance | 0.11997521076455737 | 0.1199752107645573 | 6.48E-17 | 15 | passed |
/models/0/coefficients/1/t_value | tolerance | 12.563398053827028 | 12.563398053827024 | 3.99E-15 | 15 | passed |
/models/0/coefficients/1/p_value | tail_probability | 6.0181899344203938e-11 | 6.018189934420422e-11 | 2.84E-25 | 14 | passed |
/models/0/coefficients/1/lower | tolerance | 1.3003728947230289 | 1.300372894723028 | 9.28E-16 | 15 | passed |
/models/0/coefficients/1/upper | tolerance | 1.7142197641308259 | 1.7142197641308248 | 1.13E-15 | 15 | passed |
/models/0/coefficients/1/standardized | tolerance | 0.89844529946941232 | 0.8984452994694115 | 7.80E-16 | 15 | passed |
/models/0/coefficients/1/zero_order | tolerance | 0.9198692305114855 | 0.9198692305114855 | 2.79E-18 | 17 | passed |
/models/0/coefficients/1/partial | tolerance | 0.94209272913849562 | 0.9420927291384956 | 1.48E-18 | 17 | passed |
/models/0/coefficients/1/part | tolerance | 0.89453951398795983 | 0.8945395139879596 | 2.19E-16 | 15 | passed |
/models/0/coefficients/1/tolerance | tolerance | 0.99132435613129866 | 0.9913243561312987 | 3.74E-18 | 17 | passed |
/models/0/coefficients/1/vif | tolerance | 1.0087515693678288 | 1.0087515693678288 | 3.75E-17 | 16 | passed |
/models/0/coefficients/2/estimate | tolerance | -0.68071791648298607 | -0.6807179164829859 | 2.18E-16 | 15 | passed |
/models/0/coefficients/2/standard_error | tolerance | 0.21164275124525442 | 0.21164275124525433 | 8.53E-17 | 15 | passed |
/models/0/coefficients/2/t_value | tolerance | -3.2163535603171267 | -3.216353560317127 | 4.58E-16 | 15 | passed |
/models/0/coefficients/2/p_value | tail_probability | 0.0043314143575092093 | 0.004331414357509205 | 4.32E-18 | 15 | passed |
/models/0/coefficients/2/lower | tolerance | -1.0457420305376226 | -1.045742030537622 | 6.64E-16 | 15 | passed |
/models/0/coefficients/2/upper | tolerance | -0.31569380242834966 | -0.31569380242834966 | 3.11E-18 | 17 | passed |
/models/0/coefficients/2/standardized | tolerance | -0.23001083984745457 | -0.23001083984745455 | 2.43E-17 | 15 | passed |
/models/0/coefficients/2/zero_order | tolerance | -0.31369485297341543 | -0.3136948529734154 | 5.77E-17 | 15 | passed |
/models/0/coefficients/2/partial | tolerance | -0.58387611718549526 | -0.5838761171854954 | 1.09E-16 | 15 | passed |
/models/0/coefficients/2/part | tolerance | -0.22901092032048578 | -0.22901092032048576 | 2.42E-17 | 15 | passed |
/models/0/coefficients/2/tolerance | tolerance | 0.99132435613129866 | 0.9913243561312984 | 2.26E-16 | 15 | passed |
/models/0/coefficients/2/vif | tolerance | 1.0087515693678288 | 1.008751569367829 | 2.60E-16 | 15 | passed |
/models/0/collinearity/0/dimension | exact | 1 | 1 | 0.00E+2 | passed | |
/models/0/collinearity/0/eigenvalue | tolerance | 1.4849147504245228 | 1.4849147504245221 | 6.55E-16 | 15 | passed |
/models/0/collinearity/0/condition_index | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/models/0/collinearity/1/dimension | exact | 2 | 2 | 0.00E+2 | passed | |
/models/0/collinearity/1/eigenvalue | tolerance | 1.0131141735127105 | 1.0131141735127105 | 8.08E-18 | 17 | passed |
/models/0/collinearity/1/condition_index | tolerance | 1.2106582477945231 | 1.210658247794523 | 1.87E-16 | 15 | passed |
/models/0/collinearity/2/dimension | exact | 3 | 3 | 0.00E+2 | passed | |
/models/0/collinearity/2/eigenvalue | tolerance | 0.50197107606276836 | 0.5019710760627688 | 4.46E-16 | 15 | passed |
/models/0/collinearity/2/condition_index | tolerance | 1.7199325430860226 | 1.7199325430860215 | 1.10E-15 | 15 | passed |
/models/1/r_squared | tolerance | 0.97017690115125299 | 0.970176901151253 | 5.52E-19 | 18 | passed |
/models/1/adjusted_r_squared | tolerance | 0.96546799080671397 | 0.965467990806714 | 1.53E-18 | 17 | passed |
/models/1/standard_error | tolerance | 0.44112534085568267 | 0.4411253408556828 | 1.09E-16 | 15 | passed |
/models/1/df2 | exact | 19 | 19 | 0.00E+2 | passed | |
/models/1/residual_ss | tolerance | 3.6972397605558025 | 3.6972397605558034 | 8.90E-16 | 15 | passed |
/models/1/regression_ss | tolerance | 120.27511399473293 | 120.27511399473293 | 3.52E-15 | 16 | passed |
/models/1/f_value | tolerance | 206.03002184494426 | 206.03002184494423 | 3.02E-14 | 15 | passed |
/models/1/p_value | tail_probability | 1.1486630672467477e-14 | 1.1486630672467534e-14 | 5.72E-29 | 14 | passed |
/models/1/durbin_watson | tolerance | 2.7963053183803055 | 2.796305318380305 | 4.51E-16 | 15 | passed |
/models/1/r_squared_change | tolerance | 0.071571498283424684 | 0.07157149828342468 | 2.16E-19 | 17 | passed |
/models/1/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/models/1/f_change | tolerance | 45.597490531813243 | 45.597490531813136 | 1.07E-13 | 14 | passed |
/models/1/p_change | tail_probability | 1.8851110917256922e-06 | 1.8851110917257178e-06 | 2.56E-20 | 13 | passed |
/models/1/predictors | set | ['x1', 'x2', 'x3'] | ['x1', 'x2', 'x3'] | passed | ||
/models/1/coefficients/0/estimate | tolerance | 1.9226624709837599 | 1.9226624709837599 | 3.63E-17 | 16 | passed |
/models/1/coefficients/0/standard_error | tolerance | 0.12891529827629583 | 0.1289152982762958 | 2.67E-17 | 15 | passed |
/models/1/coefficients/0/t_value | tolerance | 14.914152910409761 | 14.914152910409763 | 2.21E-15 | 15 | passed |
/models/1/coefficients/0/p_value | tail_probability | 6.0884761849485466e-12 | 6.088476184948554e-12 | 7.27E-27 | 14 | passed |
/models/1/coefficients/0/lower | tolerance | 1.6997507988271525 | 1.6997507988271527 | 2.42E-16 | 15 | passed |
/models/1/coefficients/0/upper | tolerance | 2.145574143140367 | 2.145574143140367 | 1.50E-17 | 17 | passed |
/models/1/coefficients/1/estimate | tolerance | 1.5318994062577307 | 1.5318994062577298 | 8.99E-16 | 15 | passed |
/models/1/coefficients/1/standard_error | tolerance | 0.066856643819942066 | 0.06685664381994205 | 1.39E-17 | 15 | passed |
/models/1/coefficients/1/t_value | tolerance | 22.913196336678723 | 22.913196336678713 | 1.04E-14 | 15 | passed |
/models/1/coefficients/1/p_value | tail_probability | 2.6526790729496149e-15 | 2.652679072949644e-15 | 2.92E-29 | 13 | passed |
/models/1/coefficients/1/lower | tolerance | 1.4162953897604715 | 1.4162953897604706 | 8.53E-16 | 15 | passed |
/models/1/coefficients/1/upper | tolerance | 1.6475034227549898 | 1.647503422754989 | 8.45E-16 | 15 | passed |
/models/1/coefficients/1/standardized | tolerance | 0.91311031145117971 | 0.9131103114511792 | 5.53E-16 | 15 | passed |
/models/1/coefficients/1/zero_order | tolerance | 0.9198692305114855 | 0.9198692305114855 | 2.79E-18 | 17 | passed |
/models/1/coefficients/1/partial | tolerance | 0.98238203596766394 | 0.9823820359676642 | 2.18E-16 | 15 | passed |
/models/1/coefficients/1/part | tolerance | 0.90778971914962514 | 0.9077897191496255 | 3.34E-16 | 15 | passed |
/models/1/coefficients/1/tolerance | tolerance | 0.98838017491420405 | 0.988380174914204 | 3.97E-18 | 17 | passed |
/models/1/coefficients/1/vif | tolerance | 1.0117564327783128 | 1.0117564327783128 | 4.19E-17 | 16 | passed |
/models/1/coefficients/2/estimate | tolerance | -0.71313718804413928 | -0.7131371880441388 | 4.43E-16 | 15 | passed |
/models/1/coefficients/2/standard_error | tolerance | 0.11786128808408582 | 0.11786128808408583 | 1.01E-17 | 16 | passed |
/models/1/coefficients/2/t_value | tolerance | -6.0506481783515342 | -6.05064817835153 | 4.41E-15 | 15 | passed |
/models/1/coefficients/2/p_value | tail_probability | 8.0652344809386006e-06 | 8.065234480938704e-06 | 1.03E-19 | 13 | passed |
/models/1/coefficients/2/lower | tolerance | -0.91693500847850462 | -0.9169350084785041 | 5.54E-16 | 15 | passed |
/models/1/coefficients/2/upper | tolerance | -0.50933936760977394 | -0.5093393676097736 | 3.32E-16 | 15 | passed |
/models/1/coefficients/2/standardized | tolerance | -0.24096513339323042 | -0.24096513339323028 | 1.40E-16 | 15 | passed |
/models/1/coefficients/2/zero_order | tolerance | -0.31369485297341543 | -0.3136948529734154 | 5.77E-17 | 15 | passed |
/models/1/coefficients/2/partial | tolerance | -0.81137965315309635 | -0.8113796531530963 | 2.60E-18 | 17 | passed |
/models/1/coefficients/2/part | tolerance | -0.23971846309833097 | -0.23971846309833097 | 4.99E-18 | 16 | passed |
/models/1/coefficients/2/tolerance | tolerance | 0.98967945812879299 | 0.9896794581287928 | 2.24E-16 | 15 | passed |
/models/1/coefficients/2/vif | tolerance | 1.010428166197084 | 1.0104281661970842 | 1.99E-16 | 15 | passed |
/models/1/coefficients/3/estimate | tolerance | 1.0892764256481933 | 1.0892764256481926 | 6.97E-16 | 15 | passed |
/models/1/coefficients/3/standard_error | tolerance | 0.16131235582328349 | 0.1613123558232835 | 2.46E-18 | 16 | passed |
/models/1/coefficients/3/t_value | tolerance | 6.7525913938141704 | 6.752591393814166 | 4.45E-15 | 15 | passed |
/models/1/coefficients/3/p_value | tail_probability | 1.8851110917256994e-06 | 1.8851110917257148e-06 | 1.54E-20 | 14 | passed |
/models/1/coefficients/3/lower | tolerance | 0.81034593829034351 | 0.8103459382903431 | 4.39E-16 | 15 | passed |
/models/1/coefficients/3/upper | tolerance | 1.368206913006043 | 1.3682069130060421 | 8.64E-16 | 15 | passed |
/models/1/coefficients/3/standardized | tolerance | 0.268209774871423 | 0.2682097748714229 | 1.10E-16 | 15 | passed |
/models/1/coefficients/3/zero_order | tolerance | 0.20374089467559878 | 0.20374089467559878 | 2.91E-18 | 16 | passed |
/models/1/coefficients/3/partial | tolerance | 0.84016125067018588 | 0.8401612506701854 | 4.47E-16 | 15 | passed |
/models/1/coefficients/3/part | tolerance | 0.26752849994612671 | 0.26752849994612665 | 5.78E-17 | 15 | passed |
/models/1/coefficients/3/tolerance | tolerance | 0.99492628724360865 | 0.9949262872436087 | 3.55E-18 | 17 | passed |
/models/1/coefficients/3/vif | tolerance | 1.0050995865939454 | 1.0050995865939454 | 1.78E-17 | 16 | passed |
/models/1/collinearity/0/dimension | exact | 1 | 1 | 0.00E+2 | passed | |
/models/1/collinearity/0/eigenvalue | tolerance | 1.9781582946826017 | 1.9781582946826017 | 3.66E-17 | 16 | passed |
/models/1/collinearity/0/condition_index | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/models/1/collinearity/1/dimension | exact | 2 | 2 | 0.00E+2 | passed | |
/models/1/collinearity/1/eigenvalue | tolerance | 1.0132679132476894 | 1.0132679132476894 | 1.09E-17 | 16 | passed |
/models/1/collinearity/1/condition_index | tolerance | 1.3972315242418103 | 1.3972315242418103 | 3.48E-18 | 17 | passed |
/models/1/collinearity/2/dimension | exact | 3 | 3 | 0.00E+2 | passed | |
/models/1/collinearity/2/eigenvalue | tolerance | 0.67519566812234677 | 0.6751956681223471 | 3.34E-16 | 15 | passed |
/models/1/collinearity/2/condition_index | tolerance | 1.711652887493599 | 1.7116528874935986 | 4.37E-16 | 15 | passed |
/models/1/collinearity/3/dimension | exact | 4 | 4 | 0.00E+2 | passed | |
/models/1/collinearity/3/eigenvalue | tolerance | 0.33337812394735933 | 0.33337812394735933 | 1.69E-18 | 17 | passed |
/models/1/collinearity/3/condition_index | tolerance | 2.435914112784586 | 2.435914112784586 | 2.75E-17 | 16 | passed |
/models/1/entered | set | ['x3'] | ['x3'] | passed | ||
/casewise_truncated | exact | False | False | passed | ||
/casewise/0/observed | tolerance | -2.0459930473501053 | -2.0459930473501053 | 4.27E-17 | 16 | passed |
/casewise/0/standardized_residual | tolerance | -1.594846084387211 | -1.594846084387216 | 5.09E-15 | 14 | passed |
/casewise/1/observed | tolerance | 2.9701231279456342 | 2.9701231279456337 | 4.88E-16 | 15 | passed |
/casewise/1/standardized_residual | tolerance | 1.5574240605724019 | 1.5574240605724 | 2.00E-15 | 14 | passed |
/casewise/2/observed | tolerance | 4.7267157802765825 | 4.7267157802765825 | 4.30E-17 | 17 | passed |
/casewise/2/standardized_residual | tolerance | 1.5678273416260073 | 1.5678273416260087 | 1.37E-15 | 15 | passed |
/casewise/3 | absent | None | passed |
Convention
- step(direction = 'both', k = 2) from y ~ x1 + x2; confint(level = 0.90); the casewise table lists rows with |e / s| > 1.5 in retained order.
- Every model is lm() on the rows complete on y and every block's predictor (listwise over all blocks, 23 of 24 rows).
- R-squared change F from anova(model k-1, model k); overall F and p from summary.lm; coefficient intervals from confint.
- Durbin-Watson = sum(diff(e)^2) / sum(e^2) of the residuals in row order; VIF = 1 / (1 - R^2 of each predictor on the others); partial r = cor of the residuals of y and x_j on the other predictors; part r = cor(y, residual of x_j on the others).
- Collinearity: singular values of the design (intercept included) with each column scaled to unit length, no centering; eigenvalue = singular value squared; condition index = sqrt(max eigenvalue / eigenvalue).
- Casewise: standardized residual e / s; studentized = rstandard; deleted studentized = rstudent; leverage = hatvalues; Cook's distance = cooks.distance; DFBETAS = dfbetas.
- docs/manual/chapters/86-regression-and-count-models.tex:9-14: 'fits cumulative blocks on one common complete-case population. ... selection uses Gaussian AIC or BIC, including the error-variance parameter.'
- docs/manual/chapters/86-regression-and-count-models.tex:16-19: the change statistic F=[dR^2/(p_k-p_{k-1})]/[(1-R_k^2)/(n-p_k)]
- docs/manual/chapters/86-regression-and-count-models.tex:24-26: 'Collinearity diagnostics include the intercept in an uncentred design with columns scaled to unit length.'
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
235 outputs[[paste0("/casewise/", length(flagged))]] <- list(comparison = "absent", rationale = paste("exactly", length(flagged), "rows exceed |e / s| > 1.5"))
236 emit("STAT-REG-REGRESSION-BLOCKS-004", "Blockwise regression stepwise AIC 90 percent outliers", "axis_coverage",
237 list(response = "y", blocks = list(list("x1", "x2"), list("x3", "x4", "x5")), method = "stepwise",
238 criterion = "aic", confidence_level = 0.90, casewise = "outliers", casewise_threshold = 1.5),
239 outputs, "step(direction = 'both', k = 2) from y ~ x1 + x2; confint(level = 0.90); the casewise table lists rows with |e / s| > 1.5 in retained order.")
Independent equal-variance REML repeated-measures model reproduces OLS
Case STAT-REG-REPCOV-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Closed-form OLS and balanced-design variance-component algebra
- Citation
- Searle, Casella and McCulloch (1992), Variance Components; Satterthwaite (1946)
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/REG_REPCOV_OLS.json
Settings compared
confidence_level= 0.95contrasts= []estimation= "reml"fixed_categorical_columns= []fixed_numeric_columns= ["x"]max_rows= 20000occasion_column= "time"occasion_spacing= nullrandom_intercept= falsereduced_fixed_columns= nullresidual_structure= "independent"response_column= "y"subject_column= "subject"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/[term=Intercept]/estimate | tolerance | 3.979740491625036 | 3.9797404916250336 | 2.37E-15 | 15 | passed |
/coefficients/[term=Intercept]/std_error | tolerance | 0.2027757067198798 | 0.2027757026984497 | 4.02E-9 | 7 | passed |
/coefficients/[term=Intercept]/df | tolerance | 26.0 | 26.000000000000018 | 1.78E-14 | 15 | passed |
/coefficients/[term=x]/estimate | tolerance | 0.8096940621578729 | 0.8096940621578743 | 1.42E-15 | 14 | passed |
/coefficients/[term=x]/std_error | tolerance | 0.1744733853069714 | 0.17447338184683045 | 3.46E-9 | 7 | passed |
/coefficients/[term=x]/df | tolerance | 26.0 | 26.00000000000003 | 2.84E-14 | 14 | passed |
/variance_parameters/[name=Residual variance]/estimate | tolerance | 1.0745292642696656 | 1.074529221649725 | 4.26E-8 | 7 | passed |
Convention
- With V = sigma2 I, REML gives sigma2 = RSS/(N-p) and the Satterthwaite df is exactly N-p.
Balanced random-intercept Satterthwaite df equal the classical stratum df
Case STAT-REG-REPCOV-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Closed-form OLS and balanced-design variance-component algebra
- Citation
- Searle, Casella and McCulloch (1992), Variance Components; Satterthwaite (1946)
- Reference software
- not recorded
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/REG_REPCOV_BALANCED.json
Settings compared
confidence_level= 0.95contrasts= []estimation= "reml"fixed_categorical_columns= []fixed_numeric_columns= ["arm", "w"]max_rows= 20000occasion_column= "time"occasion_spacing= nullrandom_intercept= truereduced_fixed_columns= nullresidual_structure= "independent"response_column= "y"subject_column= "subject"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/[term=arm]/estimate | tolerance | 0.6777291250000002 | 0.6777291250000003 | 6.54E-17 | 16 | passed |
/coefficients/[term=w]/estimate | tolerance | 0.3775396583333336 | 0.3775396583333334 | 1.83E-16 | 15 | passed |
/coefficients/[term=arm]/df | tolerance | 10.0 | 9.999999999999941 | 5.86E-14 | 14 | passed |
/coefficients/[term=w]/df | tolerance | 35.0 | 35.000000000000064 | 6.39E-14 | 14 | passed |
Convention
- Balanced complete data: the between-subject contrast lives in the subject stratum (df = 12 - 2) and the within-subject slope in the residual stratum (df = 48 - 12 - 1).
Regression II complete row alignment STAT-REG-ROWS-ADV-DA-LDA-001
Case STAT-REG-ROWS-ADV-DA-LDA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_rows.R · sha256 504917bf3c718b60
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "lda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:0 | STAT-REG-ROWS-ADV-DA-LDA-001:0 | passed | ||
/0/predicted | exact | A | A | passed | ||
/0/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/1/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:1 | STAT-REG-ROWS-ADV-DA-LDA-001:1 | passed | ||
/1/predicted | exact | A | A | passed | ||
/1/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/2/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:2 | STAT-REG-ROWS-ADV-DA-LDA-001:2 | passed | ||
/2/predicted | exact | A | A | passed | ||
/2/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/3/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:3 | STAT-REG-ROWS-ADV-DA-LDA-001:3 | passed | ||
/3/predicted | exact | A | A | passed | ||
/3/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/4/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:4 | STAT-REG-ROWS-ADV-DA-LDA-001:4 | passed | ||
/4/predicted | exact | A | A | passed | ||
/4/probabilities/0 | tolerance | 0.99998329857815205 | 0.999983298578152 | 3.31E-18 | 17 | passed |
/5/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:5 | STAT-REG-ROWS-ADV-DA-LDA-001:5 | passed | ||
/5/predicted | exact | A | A | passed | ||
/5/probabilities/0 | tolerance | 0.99998329857815205 | 0.999983298578152 | 3.31E-18 | 17 | passed |
/6/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:6 | STAT-REG-ROWS-ADV-DA-LDA-001:6 | passed | ||
/6/predicted | exact | A | A | passed | ||
/6/probabilities/0 | tolerance | 0.99998329857815205 | 0.999983298578152 | 3.31E-18 | 17 | passed |
/7/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:7 | STAT-REG-ROWS-ADV-DA-LDA-001:7 | passed | ||
/7/predicted | exact | A | A | passed | ||
/7/probabilities/0 | tolerance | 0.99998329857815205 | 0.999983298578152 | 3.31E-18 | 17 | passed |
/8/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:8 | STAT-REG-ROWS-ADV-DA-LDA-001:8 | passed | ||
/8/predicted | exact | A | A | passed | ||
/8/probabilities/0 | tolerance | 0.99592986228410396 | 0.995929862284104 | 1.66E-18 | 17 | passed |
/9/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:9 | STAT-REG-ROWS-ADV-DA-LDA-001:9 | passed | ||
/9/predicted | exact | A | A | passed | ||
/9/probabilities/0 | tolerance | 0.99592986228410396 | 0.995929862284104 | 1.66E-18 | 17 | passed |
/10/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:10 | STAT-REG-ROWS-ADV-DA-LDA-001:10 | passed | ||
/10/predicted | exact | A | A | passed | ||
/10/probabilities/0 | tolerance | 0.99592986228410396 | 0.995929862284104 | 1.66E-18 | 17 | passed |
/11/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:11 | STAT-REG-ROWS-ADV-DA-LDA-001:11 | passed | ||
/11/predicted | exact | A | A | passed | ||
/11/probabilities/0 | tolerance | 0.99592986228410396 | 0.995929862284104 | 1.66E-18 | 17 | passed |
/12/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:12 | STAT-REG-ROWS-ADV-DA-LDA-001:12 | passed | ||
/12/predicted | exact | B | B | passed | ||
/12/probabilities/0 | tolerance | 0.0040701377158961164 | 0.004070137715896116 | 6.56E-21 | 17 | passed |
/13/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:13 | STAT-REG-ROWS-ADV-DA-LDA-001:13 | passed | ||
/13/predicted | exact | B | B | passed | ||
/13/probabilities/0 | tolerance | 0.0040701377158961164 | 0.004070137715896116 | 6.56E-21 | 17 | passed |
/14/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:14 | STAT-REG-ROWS-ADV-DA-LDA-001:14 | passed | ||
/14/predicted | exact | B | B | passed | ||
/14/probabilities/0 | tolerance | 0.0040701377158961164 | 0.004070137715896116 | 6.56E-21 | 17 | passed |
/15/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:15 | STAT-REG-ROWS-ADV-DA-LDA-001:15 | passed | ||
/15/predicted | exact | B | B | passed | ||
/15/probabilities/0 | tolerance | 0.0040701377158961164 | 0.004070137715896116 | 6.56E-21 | 17 | passed |
/16/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:16 | STAT-REG-ROWS-ADV-DA-LDA-001:16 | passed | ||
/16/predicted | exact | B | B | passed | ||
/16/probabilities/0 | tolerance | 1.6701421848095093e-05 | 1.6701421848095093e-05 | 4.88E-22 | 16 | passed |
/17/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:17 | STAT-REG-ROWS-ADV-DA-LDA-001:17 | passed | ||
/17/predicted | exact | B | B | passed | ||
/17/probabilities/0 | tolerance | 1.6701421848095093e-05 | 1.6701421848095093e-05 | 4.88E-22 | 16 | passed |
/18/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:18 | STAT-REG-ROWS-ADV-DA-LDA-001:18 | passed | ||
/18/predicted | exact | B | B | passed | ||
/18/probabilities/0 | tolerance | 1.6701421848095093e-05 | 1.6701421848095093e-05 | 4.88E-22 | 16 | passed |
/19/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:19 | STAT-REG-ROWS-ADV-DA-LDA-001:19 | passed | ||
/19/predicted | exact | B | B | passed | ||
/19/probabilities/0 | tolerance | 1.6701421848095093e-05 | 1.6701421848095093e-05 | 4.88E-22 | 16 | passed |
/20/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:20 | STAT-REG-ROWS-ADV-DA-LDA-001:20 | passed | ||
/20/predicted | exact | B | B | passed | ||
/20/probabilities/0 | tolerance | 6.8256029104462388e-08 | 6.825602910446239e-08 | 1.61E-25 | 17 | passed |
/21/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:21 | STAT-REG-ROWS-ADV-DA-LDA-001:21 | passed | ||
/21/predicted | exact | B | B | passed | ||
/21/probabilities/0 | tolerance | 6.8256029104462388e-08 | 6.825602910446239e-08 | 1.61E-25 | 17 | passed |
/22/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:22 | STAT-REG-ROWS-ADV-DA-LDA-001:22 | passed | ||
/22/predicted | exact | B | B | passed | ||
/22/probabilities/0 | tolerance | 6.8256029104462388e-08 | 6.825602910446239e-08 | 1.61E-25 | 17 | passed |
/23/row_id | exact | STAT-REG-ROWS-ADV-DA-LDA-001:23 | STAT-REG-ROWS-ADV-DA-LDA-001:23 | passed | ||
/23/predicted | exact | B | B | passed | ||
/23/probabilities/0 | tolerance | 6.8256029104462388e-08 | 6.825602910446239e-08 | 1.61E-25 | 17 | passed |
Convention
- MASS lda whole-table scoring, including ordered probabilities.
- R re-reads exported CSV.
Reference code
Regression II complete row alignment STAT-REG-ROWS-ADV-DA-QDA-001
Case STAT-REG-ROWS-ADV-DA-QDA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_rows.R · sha256 504917bf3c718b60
- Dataset
- reference_data/datasets/REG_DISCRIMINANT.json
Settings compared
artifact= {"response": "class", "predictors": ["x"], "model": "qda", "imputation": "drop", "standardize": false, "class_order": ["A", "B"], "priors": [0.5, 0.5], "imputation_values": [null], "transform_means": [0], "transform_scales": [1], "class_means": [[-2], [2]], "covariance": [[0.727272727272727]], "class_covariances": [[[0.727272727272727]], [[0.727272727272727]]]}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:0 | STAT-REG-ROWS-ADV-DA-QDA-001:0 | passed | ||
/0/predicted | exact | A | A | passed | ||
/0/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/1/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:1 | STAT-REG-ROWS-ADV-DA-QDA-001:1 | passed | ||
/1/predicted | exact | A | A | passed | ||
/1/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/2/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:2 | STAT-REG-ROWS-ADV-DA-QDA-001:2 | passed | ||
/2/predicted | exact | A | A | passed | ||
/2/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/3/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:3 | STAT-REG-ROWS-ADV-DA-QDA-001:3 | passed | ||
/3/predicted | exact | A | A | passed | ||
/3/probabilities/0 | tolerance | 0.99999993174397095 | 0.999999931743971 | 1.03E-18 | 17 | passed |
/4/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:4 | STAT-REG-ROWS-ADV-DA-QDA-001:4 | passed | ||
/4/predicted | exact | A | A | passed | ||
/4/probabilities/0 | tolerance | 0.99998329857815205 | 0.999983298578152 | 3.31E-18 | 17 | passed |
/5/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:5 | STAT-REG-ROWS-ADV-DA-QDA-001:5 | passed | ||
/5/predicted | exact | A | A | passed | ||
/5/probabilities/0 | tolerance | 0.99998329857815205 | 0.999983298578152 | 3.31E-18 | 17 | passed |
/6/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:6 | STAT-REG-ROWS-ADV-DA-QDA-001:6 | passed | ||
/6/predicted | exact | A | A | passed | ||
/6/probabilities/0 | tolerance | 0.99998329857815205 | 0.999983298578152 | 3.31E-18 | 17 | passed |
/7/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:7 | STAT-REG-ROWS-ADV-DA-QDA-001:7 | passed | ||
/7/predicted | exact | A | A | passed | ||
/7/probabilities/0 | tolerance | 0.99998329857815205 | 0.999983298578152 | 3.31E-18 | 17 | passed |
/8/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:8 | STAT-REG-ROWS-ADV-DA-QDA-001:8 | passed | ||
/8/predicted | exact | A | A | passed | ||
/8/probabilities/0 | tolerance | 0.99592986228410396 | 0.995929862284104 | 1.66E-18 | 17 | passed |
/9/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:9 | STAT-REG-ROWS-ADV-DA-QDA-001:9 | passed | ||
/9/predicted | exact | A | A | passed | ||
/9/probabilities/0 | tolerance | 0.99592986228410396 | 0.995929862284104 | 1.66E-18 | 17 | passed |
/10/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:10 | STAT-REG-ROWS-ADV-DA-QDA-001:10 | passed | ||
/10/predicted | exact | A | A | passed | ||
/10/probabilities/0 | tolerance | 0.99592986228410396 | 0.995929862284104 | 1.66E-18 | 17 | passed |
/11/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:11 | STAT-REG-ROWS-ADV-DA-QDA-001:11 | passed | ||
/11/predicted | exact | A | A | passed | ||
/11/probabilities/0 | tolerance | 0.99592986228410396 | 0.995929862284104 | 1.66E-18 | 17 | passed |
/12/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:12 | STAT-REG-ROWS-ADV-DA-QDA-001:12 | passed | ||
/12/predicted | exact | B | B | passed | ||
/12/probabilities/0 | tolerance | 0.0040701377158961268 | 0.004070137715896116 | 1.04E-17 | 14 | passed |
/13/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:13 | STAT-REG-ROWS-ADV-DA-QDA-001:13 | passed | ||
/13/predicted | exact | B | B | passed | ||
/13/probabilities/0 | tolerance | 0.0040701377158961268 | 0.004070137715896116 | 1.04E-17 | 14 | passed |
/14/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:14 | STAT-REG-ROWS-ADV-DA-QDA-001:14 | passed | ||
/14/predicted | exact | B | B | passed | ||
/14/probabilities/0 | tolerance | 0.0040701377158961268 | 0.004070137715896116 | 1.04E-17 | 14 | passed |
/15/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:15 | STAT-REG-ROWS-ADV-DA-QDA-001:15 | passed | ||
/15/predicted | exact | B | B | passed | ||
/15/probabilities/0 | tolerance | 0.0040701377158961268 | 0.004070137715896116 | 1.04E-17 | 14 | passed |
/16/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:16 | STAT-REG-ROWS-ADV-DA-QDA-001:16 | passed | ||
/16/predicted | exact | B | B | passed | ||
/16/probabilities/0 | tolerance | 1.6701421848095181e-05 | 1.6701421848095093e-05 | 8.85E-20 | 14 | passed |
/17/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:17 | STAT-REG-ROWS-ADV-DA-QDA-001:17 | passed | ||
/17/predicted | exact | B | B | passed | ||
/17/probabilities/0 | tolerance | 1.6701421848095181e-05 | 1.6701421848095093e-05 | 8.85E-20 | 14 | passed |
/18/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:18 | STAT-REG-ROWS-ADV-DA-QDA-001:18 | passed | ||
/18/predicted | exact | B | B | passed | ||
/18/probabilities/0 | tolerance | 1.6701421848095181e-05 | 1.6701421848095093e-05 | 8.85E-20 | 14 | passed |
/19/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:19 | STAT-REG-ROWS-ADV-DA-QDA-001:19 | passed | ||
/19/predicted | exact | B | B | passed | ||
/19/probabilities/0 | tolerance | 1.6701421848095181e-05 | 1.6701421848095093e-05 | 8.85E-20 | 14 | passed |
/20/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:20 | STAT-REG-ROWS-ADV-DA-QDA-001:20 | passed | ||
/20/predicted | exact | B | B | passed | ||
/20/probabilities/0 | tolerance | 6.8256029104462878e-08 | 6.825602910446264e-08 | 2.38E-22 | 14 | passed |
/21/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:21 | STAT-REG-ROWS-ADV-DA-QDA-001:21 | passed | ||
/21/predicted | exact | B | B | passed | ||
/21/probabilities/0 | tolerance | 6.8256029104462878e-08 | 6.825602910446264e-08 | 2.38E-22 | 14 | passed |
/22/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:22 | STAT-REG-ROWS-ADV-DA-QDA-001:22 | passed | ||
/22/predicted | exact | B | B | passed | ||
/22/probabilities/0 | tolerance | 6.8256029104462878e-08 | 6.825602910446264e-08 | 2.38E-22 | 14 | passed |
/23/row_id | exact | STAT-REG-ROWS-ADV-DA-QDA-001:23 | STAT-REG-ROWS-ADV-DA-QDA-001:23 | passed | ||
/23/predicted | exact | B | B | passed | ||
/23/probabilities/0 | tolerance | 6.8256029104462878e-08 | 6.825602910446264e-08 | 2.38E-22 | 14 | passed |
Convention
- MASS qda whole-table scoring, including ordered probabilities.
- R re-reads exported CSV.
Reference code
Regression II complete row alignment STAT-REG-ROWS-ADV-PLS-001
Case STAT-REG-ROWS-ADV-PLS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_rows.R · sha256 504917bf3c718b60
- Dataset
- reference_data/datasets/REG_PLS.json
Settings compared
artifact= {"response": "y", "predictors": ["x"], "imputation": "drop", "scale": false, "component_count": 1, "imputation_values": [null], "x_means": [15.5], "coefficients": [1.99945558978142], "intercept": 34.0004667505938}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:0 | STAT-REG-ROWS-ADV-PLS-001:0 | passed | ||
/0/predicted | tolerance | 5.0083606987632487 | 5.008360698763212 | 3.64E-14 | 14 | passed |
/1/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:1 | STAT-REG-ROWS-ADV-PLS-001:1 | passed | ||
/1/predicted | tolerance | 7.0078162885446655 | 7.007816288544632 | 3.37E-14 | 14 | passed |
/2/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:2 | STAT-REG-ROWS-ADV-PLS-001:2 | passed | ||
/2/predicted | tolerance | 9.0072718783260814 | 9.007271878326051 | 3.01E-14 | 14 | passed |
/3/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:3 | STAT-REG-ROWS-ADV-PLS-001:3 | passed | ||
/3/predicted | tolerance | 11.006727468107499 | 11.006727468107474 | 2.47E-14 | 14 | passed |
/4/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:4 | STAT-REG-ROWS-ADV-PLS-001:4 | passed | ||
/4/predicted | tolerance | 13.006183057888915 | 13.006183057888894 | 2.13E-14 | 14 | passed |
/5/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:5 | STAT-REG-ROWS-ADV-PLS-001:5 | passed | ||
/5/predicted | tolerance | 15.005638647670331 | 15.005638647670313 | 1.78E-14 | 14 | passed |
/6/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:6 | STAT-REG-ROWS-ADV-PLS-001:6 | passed | ||
/6/predicted | tolerance | 17.00509423745175 | 17.005094237451733 | 1.73E-14 | 14 | passed |
/7/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:7 | STAT-REG-ROWS-ADV-PLS-001:7 | passed | ||
/7/predicted | tolerance | 19.004549827233163 | 19.004549827233152 | 1.09E-14 | 15 | passed |
/8/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:8 | STAT-REG-ROWS-ADV-PLS-001:8 | passed | ||
/8/predicted | tolerance | 21.004005417014582 | 21.00400541701457 | 1.04E-14 | 15 | passed |
/9/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:9 | STAT-REG-ROWS-ADV-PLS-001:9 | passed | ||
/9/predicted | tolerance | 23.003461006795998 | 23.003461006795995 | 3.41E-15 | 15 | passed |
/10/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:10 | STAT-REG-ROWS-ADV-PLS-001:10 | passed | ||
/10/predicted | tolerance | 25.002916596577414 | 25.002916596577414 | 5.45E-17 | 17 | passed |
/11/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:11 | STAT-REG-ROWS-ADV-PLS-001:11 | passed | ||
/11/predicted | tolerance | 27.00237218635883 | 27.002372186358834 | 3.52E-15 | 15 | passed |
/12/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:12 | STAT-REG-ROWS-ADV-PLS-001:12 | passed | ||
/12/predicted | tolerance | 29.001827776140246 | 29.001827776140253 | 6.98E-15 | 15 | passed |
/13/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:13 | STAT-REG-ROWS-ADV-PLS-001:13 | passed | ||
/13/predicted | tolerance | 31.001283365921665 | 31.001283365921672 | 7.44E-15 | 15 | passed |
/14/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:14 | STAT-REG-ROWS-ADV-PLS-001:14 | passed | ||
/14/predicted | tolerance | 33.000738955703085 | 33.00073895570309 | 6.90E-15 | 15 | passed |
/15/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:15 | STAT-REG-ROWS-ADV-PLS-001:15 | passed | ||
/15/predicted | tolerance | 35.000194545484497 | 35.00019454548451 | 1.44E-14 | 15 | passed |
/16/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:16 | STAT-REG-ROWS-ADV-PLS-001:16 | passed | ||
/16/predicted | tolerance | 36.99965013526591 | 36.99965013526593 | 2.08E-14 | 15 | passed |
/17/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:17 | STAT-REG-ROWS-ADV-PLS-001:17 | passed | ||
/17/predicted | tolerance | 38.999105725047329 | 38.99910572504735 | 2.13E-14 | 15 | passed |
/18/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:18 | STAT-REG-ROWS-ADV-PLS-001:18 | passed | ||
/18/predicted | tolerance | 40.998561314828748 | 40.99856131482877 | 2.18E-14 | 15 | passed |
/19/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:19 | STAT-REG-ROWS-ADV-PLS-001:19 | passed | ||
/19/predicted | tolerance | 42.998016904610168 | 42.99801690461019 | 2.12E-14 | 15 | passed |
/20/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:20 | STAT-REG-ROWS-ADV-PLS-001:20 | passed | ||
/20/predicted | tolerance | 44.997472494391573 | 44.99747249439161 | 3.57E-14 | 15 | passed |
/21/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:21 | STAT-REG-ROWS-ADV-PLS-001:21 | passed | ||
/21/predicted | tolerance | 46.996928084172993 | 46.996928084173035 | 4.22E-14 | 15 | passed |
/22/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:22 | STAT-REG-ROWS-ADV-PLS-001:22 | passed | ||
/22/predicted | tolerance | 48.996383673954412 | 48.996383673954455 | 4.27E-14 | 15 | passed |
/23/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:23 | STAT-REG-ROWS-ADV-PLS-001:23 | passed | ||
/23/predicted | tolerance | 50.995839263735832 | 50.995839263735874 | 4.22E-14 | 15 | passed |
/24/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:24 | STAT-REG-ROWS-ADV-PLS-001:24 | passed | ||
/24/predicted | tolerance | 52.995294853517251 | 52.995294853517294 | 4.26E-14 | 15 | passed |
/25/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:25 | STAT-REG-ROWS-ADV-PLS-001:25 | passed | ||
/25/predicted | tolerance | 54.994750443298656 | 54.99475044329871 | 5.71E-14 | 14 | passed |
/26/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:26 | STAT-REG-ROWS-ADV-PLS-001:26 | passed | ||
/26/predicted | tolerance | 56.994206033080076 | 56.99420603308013 | 5.66E-14 | 15 | passed |
/27/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:27 | STAT-REG-ROWS-ADV-PLS-001:27 | passed | ||
/27/predicted | tolerance | 58.993661622861495 | 58.99366162286155 | 5.70E-14 | 15 | passed |
/28/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:28 | STAT-REG-ROWS-ADV-PLS-001:28 | passed | ||
/28/predicted | tolerance | 60.993117212642915 | 60.99311721264297 | 5.65E-14 | 15 | passed |
/29/row_id | exact | STAT-REG-ROWS-ADV-PLS-001:29 | STAT-REG-ROWS-ADV-PLS-001:29 | passed | ||
/29/predicted | tolerance | 62.992572802424334 | 62.99257280242439 | 5.69E-14 | 15 | passed |
Convention
- R pls::plsr predicts every row from the exported table in source order.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
90 pls_id <- "STAT-REG-ROWS-ADV-PLS-001"
Regression II complete row alignment STAT-REG-ROWS-ADV-TREE-CLASS-001
Case STAT-REG-ROWS-ADV-TREE-CLASS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_rows.R · sha256 504917bf3c718b60
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "class_order": ["A", "B"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "class_probabilities": [[0.5, 0.5], [1, 0], [0, 1]], "n_node_samples": [40, 20, 20], "encoding": {"numeric_predictors": ["x"], "categorical_predictors": [], "categorical_levels": [], "feature_names": ["x"]}}row_ids= ["STAT-REG-ROWS-ADV-TREE-CLASS-001:0", "STAT-REG-ROWS-ADV-TREE-CLASS-001:1", "STAT-REG-ROWS-ADV-TREE-CLASS-001:2", "STAT-REG-ROWS-ADV-TREE-CLASS-001:3", "STAT-REG-ROWS-ADV-TREE-CLASS-001:4", "STAT-REG-ROWS-ADV-TREE-CLASS-001:5", "STAT-REG-ROWS-ADV-TREE-CLASS-001:6", "STAT-REG-ROWS-ADV-TREE-CLASS-001:7", "STAT-REG-ROWS-ADV-TREE-CLASS-001:8", "STAT-REG-ROWS-ADV-TREE-CLASS-001:9", "STAT-REG-ROWS-ADV-TREE-CLASS-001:10", "STAT-REG-ROWS-ADV-TREE-CLASS-001:11", "STAT-REG-ROWS-ADV-TREE-CLASS-001:12", "STAT-REG-ROWS-ADV-TREE-CLASS-001:13", "STAT-REG-ROWS-ADV-TREE-CLASS-001:14", "STAT-REG-ROWS-ADV-TREE-CLASS-001:15", "STAT-REG-ROWS-ADV-TREE-CLASS-001:16", "STAT-REG-ROWS-ADV-TREE-CLASS-001:17", "STAT-REG-ROWS-ADV-TREE-CLASS-001:18", "STAT-REG-ROWS-ADV-TREE-CLASS-001:19", "STAT-REG-ROWS-ADV-TREE-CLASS-001:20", "STAT-REG-ROWS-ADV-TREE-CLASS-001:21", "STAT-REG-ROWS-ADV-TREE-CLASS-001:22", "STAT-REG-ROWS-ADV-TREE-CLASS-001:23", "STAT-REG-ROWS-ADV-TREE-CLASS-001:24", "STAT-REG-ROWS-ADV-TREE-CLASS-001:25", "STAT-REG-ROWS-ADV-TREE-CLASS-001:26", "STAT-REG-ROWS-ADV-TREE-CLASS-001:27", "STAT-REG-ROWS-ADV-TREE-CLASS-001:28", "STAT-REG-ROWS-ADV-TREE-CLASS-001:29", "STAT-REG-ROWS-ADV-TREE-CLASS-001:30", "STAT-REG-ROWS-ADV-TREE-CLASS-001:31", "STAT-REG-ROWS-ADV-TREE-CLASS-001:32", "STAT-REG-ROWS-ADV-TREE-CLASS-001:33", "STAT-REG-ROWS-ADV-TREE-CLASS-001:34", "STAT-REG-ROWS-ADV-TREE-CLASS-001:35", "STAT-REG-ROWS-ADV-TREE-CLASS-001:36", "STAT-REG-ROWS-ADV-TREE-CLASS-001:37", "STAT-REG-ROWS-ADV-TREE-CLASS-001:38", "STAT-REG-ROWS-ADV-TREE-CLASS-001:39"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:0 | STAT-REG-ROWS-ADV-TREE-CLASS-001:0 | passed | ||
/0/tree_score | exact | A | A | passed | ||
/1/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:1 | STAT-REG-ROWS-ADV-TREE-CLASS-001:1 | passed | ||
/1/tree_score | absent | None | passed | |||
/2/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:2 | STAT-REG-ROWS-ADV-TREE-CLASS-001:2 | passed | ||
/2/tree_score | exact | A | A | passed | ||
/3/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:3 | STAT-REG-ROWS-ADV-TREE-CLASS-001:3 | passed | ||
/3/tree_score | exact | B | B | passed | ||
/4/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:4 | STAT-REG-ROWS-ADV-TREE-CLASS-001:4 | passed | ||
/4/tree_score | exact | A | A | passed | ||
/5/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:5 | STAT-REG-ROWS-ADV-TREE-CLASS-001:5 | passed | ||
/5/tree_score | exact | B | B | passed | ||
/6/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:6 | STAT-REG-ROWS-ADV-TREE-CLASS-001:6 | passed | ||
/6/tree_score | exact | A | A | passed | ||
/7/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:7 | STAT-REG-ROWS-ADV-TREE-CLASS-001:7 | passed | ||
/7/tree_score | exact | B | B | passed | ||
/8/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:8 | STAT-REG-ROWS-ADV-TREE-CLASS-001:8 | passed | ||
/8/tree_score | exact | A | A | passed | ||
/9/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:9 | STAT-REG-ROWS-ADV-TREE-CLASS-001:9 | passed | ||
/9/tree_score | exact | B | B | passed | ||
/10/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:10 | STAT-REG-ROWS-ADV-TREE-CLASS-001:10 | passed | ||
/10/tree_score | exact | A | A | passed | ||
/11/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:11 | STAT-REG-ROWS-ADV-TREE-CLASS-001:11 | passed | ||
/11/tree_score | exact | B | B | passed | ||
/12/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:12 | STAT-REG-ROWS-ADV-TREE-CLASS-001:12 | passed | ||
/12/tree_score | exact | A | A | passed | ||
/13/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:13 | STAT-REG-ROWS-ADV-TREE-CLASS-001:13 | passed | ||
/13/tree_score | exact | B | B | passed | ||
/14/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:14 | STAT-REG-ROWS-ADV-TREE-CLASS-001:14 | passed | ||
/14/tree_score | exact | A | A | passed | ||
/15/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:15 | STAT-REG-ROWS-ADV-TREE-CLASS-001:15 | passed | ||
/15/tree_score | exact | B | B | passed | ||
/16/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:16 | STAT-REG-ROWS-ADV-TREE-CLASS-001:16 | passed | ||
/16/tree_score | exact | A | A | passed | ||
/17/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:17 | STAT-REG-ROWS-ADV-TREE-CLASS-001:17 | passed | ||
/17/tree_score | exact | B | B | passed | ||
/18/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:18 | STAT-REG-ROWS-ADV-TREE-CLASS-001:18 | passed | ||
/18/tree_score | exact | A | A | passed | ||
/19/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:19 | STAT-REG-ROWS-ADV-TREE-CLASS-001:19 | passed | ||
/19/tree_score | exact | B | B | passed | ||
/20/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:20 | STAT-REG-ROWS-ADV-TREE-CLASS-001:20 | passed | ||
/20/tree_score | exact | A | A | passed | ||
/21/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:21 | STAT-REG-ROWS-ADV-TREE-CLASS-001:21 | passed | ||
/21/tree_score | exact | B | B | passed | ||
/22/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:22 | STAT-REG-ROWS-ADV-TREE-CLASS-001:22 | passed | ||
/22/tree_score | exact | A | A | passed | ||
/23/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:23 | STAT-REG-ROWS-ADV-TREE-CLASS-001:23 | passed | ||
/23/tree_score | exact | B | B | passed | ||
/24/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:24 | STAT-REG-ROWS-ADV-TREE-CLASS-001:24 | passed | ||
/24/tree_score | exact | A | A | passed | ||
/25/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:25 | STAT-REG-ROWS-ADV-TREE-CLASS-001:25 | passed | ||
/25/tree_score | exact | B | B | passed | ||
/26/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:26 | STAT-REG-ROWS-ADV-TREE-CLASS-001:26 | passed | ||
/26/tree_score | exact | A | A | passed | ||
/27/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:27 | STAT-REG-ROWS-ADV-TREE-CLASS-001:27 | passed | ||
/27/tree_score | exact | B | B | passed | ||
/28/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:28 | STAT-REG-ROWS-ADV-TREE-CLASS-001:28 | passed | ||
/28/tree_score | exact | A | A | passed | ||
/29/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:29 | STAT-REG-ROWS-ADV-TREE-CLASS-001:29 | passed | ||
/29/tree_score | exact | B | B | passed | ||
/30/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:30 | STAT-REG-ROWS-ADV-TREE-CLASS-001:30 | passed | ||
/30/tree_score | exact | A | A | passed | ||
/31/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:31 | STAT-REG-ROWS-ADV-TREE-CLASS-001:31 | passed | ||
/31/tree_score | exact | B | B | passed | ||
/32/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:32 | STAT-REG-ROWS-ADV-TREE-CLASS-001:32 | passed | ||
/32/tree_score | exact | A | A | passed | ||
/33/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:33 | STAT-REG-ROWS-ADV-TREE-CLASS-001:33 | passed | ||
/33/tree_score | exact | B | B | passed | ||
/34/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:34 | STAT-REG-ROWS-ADV-TREE-CLASS-001:34 | passed | ||
/34/tree_score | exact | A | A | passed | ||
/35/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:35 | STAT-REG-ROWS-ADV-TREE-CLASS-001:35 | passed | ||
/35/tree_score | exact | B | B | passed | ||
/36/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:36 | STAT-REG-ROWS-ADV-TREE-CLASS-001:36 | passed | ||
/36/tree_score | exact | A | A | passed | ||
/37/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:37 | STAT-REG-ROWS-ADV-TREE-CLASS-001:37 | passed | ||
/37/tree_score | exact | B | B | passed | ||
/38/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:38 | STAT-REG-ROWS-ADV-TREE-CLASS-001:38 | passed | ||
/38/tree_score | exact | A | A | passed | ||
/39/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-CLASS-001:39 | STAT-REG-ROWS-ADV-TREE-CLASS-001:39 | passed | ||
/39/tree_score | exact | B | B | passed |
Convention
- All 40 ordered row IDs and class scores; source row 2 excluded.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
36 class_id <- "STAT-REG-ROWS-ADV-TREE-CLASS-001"
Regression II complete row alignment STAT-REG-ROWS-ADV-TREE-REG-001
Case STAT-REG-ROWS-ADV-TREE-REG-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_rows.R · sha256 504917bf3c718b60
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "value": [0, -2, 2], "n_node_samples": [40, 20, 20]}row_ids= ["STAT-REG-ROWS-ADV-TREE-REG-001:0", "STAT-REG-ROWS-ADV-TREE-REG-001:1", "STAT-REG-ROWS-ADV-TREE-REG-001:2", "STAT-REG-ROWS-ADV-TREE-REG-001:3", "STAT-REG-ROWS-ADV-TREE-REG-001:4", "STAT-REG-ROWS-ADV-TREE-REG-001:5", "STAT-REG-ROWS-ADV-TREE-REG-001:6", "STAT-REG-ROWS-ADV-TREE-REG-001:7", "STAT-REG-ROWS-ADV-TREE-REG-001:8", "STAT-REG-ROWS-ADV-TREE-REG-001:9", "STAT-REG-ROWS-ADV-TREE-REG-001:10", "STAT-REG-ROWS-ADV-TREE-REG-001:11", "STAT-REG-ROWS-ADV-TREE-REG-001:12", "STAT-REG-ROWS-ADV-TREE-REG-001:13", "STAT-REG-ROWS-ADV-TREE-REG-001:14", "STAT-REG-ROWS-ADV-TREE-REG-001:15", "STAT-REG-ROWS-ADV-TREE-REG-001:16", "STAT-REG-ROWS-ADV-TREE-REG-001:17", "STAT-REG-ROWS-ADV-TREE-REG-001:18", "STAT-REG-ROWS-ADV-TREE-REG-001:19", "STAT-REG-ROWS-ADV-TREE-REG-001:20", "STAT-REG-ROWS-ADV-TREE-REG-001:21", "STAT-REG-ROWS-ADV-TREE-REG-001:22", "STAT-REG-ROWS-ADV-TREE-REG-001:23", "STAT-REG-ROWS-ADV-TREE-REG-001:24", "STAT-REG-ROWS-ADV-TREE-REG-001:25", "STAT-REG-ROWS-ADV-TREE-REG-001:26", "STAT-REG-ROWS-ADV-TREE-REG-001:27", "STAT-REG-ROWS-ADV-TREE-REG-001:28", "STAT-REG-ROWS-ADV-TREE-REG-001:29", "STAT-REG-ROWS-ADV-TREE-REG-001:30", "STAT-REG-ROWS-ADV-TREE-REG-001:31", "STAT-REG-ROWS-ADV-TREE-REG-001:32", "STAT-REG-ROWS-ADV-TREE-REG-001:33", "STAT-REG-ROWS-ADV-TREE-REG-001:34", "STAT-REG-ROWS-ADV-TREE-REG-001:35", "STAT-REG-ROWS-ADV-TREE-REG-001:36", "STAT-REG-ROWS-ADV-TREE-REG-001:37", "STAT-REG-ROWS-ADV-TREE-REG-001:38"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:0 | STAT-REG-ROWS-ADV-TREE-REG-001:0 | passed | ||
/0/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/1/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:1 | STAT-REG-ROWS-ADV-TREE-REG-001:1 | passed | ||
/1/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/2/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:2 | STAT-REG-ROWS-ADV-TREE-REG-001:2 | passed | ||
/2/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/3/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:3 | STAT-REG-ROWS-ADV-TREE-REG-001:3 | passed | ||
/3/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/4/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:4 | STAT-REG-ROWS-ADV-TREE-REG-001:4 | passed | ||
/4/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/5/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:5 | STAT-REG-ROWS-ADV-TREE-REG-001:5 | passed | ||
/5/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/6/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:6 | STAT-REG-ROWS-ADV-TREE-REG-001:6 | passed | ||
/6/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/7/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:7 | STAT-REG-ROWS-ADV-TREE-REG-001:7 | passed | ||
/7/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/8/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:8 | STAT-REG-ROWS-ADV-TREE-REG-001:8 | passed | ||
/8/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/9/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:9 | STAT-REG-ROWS-ADV-TREE-REG-001:9 | passed | ||
/9/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/10/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:10 | STAT-REG-ROWS-ADV-TREE-REG-001:10 | passed | ||
/10/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/11/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:11 | STAT-REG-ROWS-ADV-TREE-REG-001:11 | passed | ||
/11/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/12/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:12 | STAT-REG-ROWS-ADV-TREE-REG-001:12 | passed | ||
/12/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/13/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:13 | STAT-REG-ROWS-ADV-TREE-REG-001:13 | passed | ||
/13/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/14/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:14 | STAT-REG-ROWS-ADV-TREE-REG-001:14 | passed | ||
/14/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/15/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:15 | STAT-REG-ROWS-ADV-TREE-REG-001:15 | passed | ||
/15/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/16/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:16 | STAT-REG-ROWS-ADV-TREE-REG-001:16 | passed | ||
/16/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/17/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:17 | STAT-REG-ROWS-ADV-TREE-REG-001:17 | passed | ||
/17/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/18/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:18 | STAT-REG-ROWS-ADV-TREE-REG-001:18 | passed | ||
/18/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/19/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:19 | STAT-REG-ROWS-ADV-TREE-REG-001:19 | passed | ||
/19/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/20/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:20 | STAT-REG-ROWS-ADV-TREE-REG-001:20 | passed | ||
/20/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/21/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:21 | STAT-REG-ROWS-ADV-TREE-REG-001:21 | passed | ||
/21/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/22/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:22 | STAT-REG-ROWS-ADV-TREE-REG-001:22 | passed | ||
/22/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/23/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:23 | STAT-REG-ROWS-ADV-TREE-REG-001:23 | passed | ||
/23/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/24/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:24 | STAT-REG-ROWS-ADV-TREE-REG-001:24 | passed | ||
/24/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/25/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:25 | STAT-REG-ROWS-ADV-TREE-REG-001:25 | passed | ||
/25/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/26/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:26 | STAT-REG-ROWS-ADV-TREE-REG-001:26 | passed | ||
/26/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/27/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:27 | STAT-REG-ROWS-ADV-TREE-REG-001:27 | passed | ||
/27/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/28/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:28 | STAT-REG-ROWS-ADV-TREE-REG-001:28 | passed | ||
/28/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/29/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:29 | STAT-REG-ROWS-ADV-TREE-REG-001:29 | passed | ||
/29/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/30/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:30 | STAT-REG-ROWS-ADV-TREE-REG-001:30 | passed | ||
/30/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/31/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:31 | STAT-REG-ROWS-ADV-TREE-REG-001:31 | passed | ||
/31/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/32/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:32 | STAT-REG-ROWS-ADV-TREE-REG-001:32 | passed | ||
/32/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/33/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:33 | STAT-REG-ROWS-ADV-TREE-REG-001:33 | passed | ||
/33/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/34/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:34 | STAT-REG-ROWS-ADV-TREE-REG-001:34 | passed | ||
/34/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/35/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:35 | STAT-REG-ROWS-ADV-TREE-REG-001:35 | passed | ||
/35/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/36/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:36 | STAT-REG-ROWS-ADV-TREE-REG-001:36 | passed | ||
/36/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/37/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:37 | STAT-REG-ROWS-ADV-TREE-REG-001:37 | passed | ||
/37/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/38/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:38 | STAT-REG-ROWS-ADV-TREE-REG-001:38 | passed | ||
/38/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/39/__tabelz_row_id | exact | STAT-REG-ROWS-ADV-TREE-REG-001:39 | STAT-REG-ROWS-ADV-TREE-REG-001:39 | passed | ||
/39/tree_score | absent | None | passed |
Convention
- All 40 ordered row IDs and predictions; final row outside artifact population.
- R re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
53 reg_id <- "STAT-REG-ROWS-ADV-TREE-REG-001"
Regression setting STAT-REG-ROWS-OLS-001
Case STAT-REG-ROWS-OLS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fits
- Citation
- R stats::lm/glm/predict.lm, MASS::polr/glm.nb, nnet::multinom and car::Anova help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_options.R · sha256 b22011f9ca86fc99
- Dataset
- reference_data/datasets/REG_MISSING.json
Settings compared
x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/responses/0/actual_predicted/x | sequence | ['-0.79564612573140181', '-0.67321627912056847', '0.06657318 | [-0.7956461257314031, -0.6732162791205702, 0.066573186344934 | passed | ||
/responses/0/actual_predicted/y | sequence | ['-0.66396923222151238', '-0.27142121217491777', '0.06951530 | [-0.6639692322215123, -0.27142121217491777, 0.06951530968505 | passed |
Convention
- The Actual by Predicted payload has x=fitted and y=observed; all retained rows are below the plot cap.
- All fit inputs come from re-read exported CSVs.
Reference code
The lines of the reference script that produce this case's expected values.
36 remaining <- m[-c(3L, 8L), , drop = FALSE]
37 usable <- remaining[stats::complete.cases(remaining[c("y", "x", "z")]), , drop = FALSE]
38 fit <- stats::lm(y ~ x + z, data = usable)
39 emit("STAT-REG-ROWS-OLS-001", "tabelz.analysis.fit_y_by_x:compute_fits",
40 "fitYByXMenuItem", "row_alignment",
41 list(y_columns = list("y"), x_columns = list("x", "z")),
42 list("/responses/0/actual_predicted/x" = sequence(stats::predict(fit),
43 "all fitted means in retained row order"),
44 "/responses/0/actual_predicted/y" = sequence(usable$y,
45 "all observed responses in retained row order")),
46 list("The Actual by Predicted payload has x=fitted and y=observed; all retained rows are below the plot cap."),
47 dataset = "REG_MISSING", excluded = list(2L, 7L))
Regression II STAT-REG-SELECTION-001
Case STAT-REG-SELECTION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats
- Citation
- R nlme::Orthodont, nlme::lme, plm::plm, stats::nls/lm/step documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_core.R · sha256 b7543c65b2778e63
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
candidate_predictors= ["age"]response= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 0.66018518518518476 | 0.6601851851851848 | 4.12E-18 | 17 | passed |
/n | exact | 108 | 108 | 0.00E+2 | passed |
Convention
- With one strong numeric candidate, R step and best-subset search both select age; refit is R lm.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
106 selection_data <- d
107 selection_fit <- stats::lm(distance ~ age, data = selection_data)
108 emit("STAT-REG-SELECTION-001", "tabelz.analysis.model_selection:compute_model_selection",
109 "modelSelectionMenuItem", "REG_ORTHODONT",
110 list(response = "distance", candidate_predictors = list("age")),
111 list("/coefficients/1/coefficient" = tol(coef(selection_fit)[["age"]],
112 "single candidate selected slope", "1e-9"),
113 "/n" = exact(nrow(selection_data), "all complete rows")),
114 list("With one strong numeric candidate, R step and best-subset search both select age; refit is R lm."))
Regression edge STAT-REG-SELECTION-ALIAS-001
Case STAT-REG-SELECTION-ALIAS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/rpart
- Citation
- R nlme::lme, plm::plm, stats::nls/lm/step, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_a.R · sha256 b8ea61b61080b6f8
- Dataset
- reference_data/datasets/REG_EDGE_SELECTION_ALIAS.json
Settings compared
candidate_predictors= ["x", "z"]direction= "forward"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- x and z are exactly aliased; R step breaks the tie by candidate order.
- Only population size is asserted until Tabelz and R alias-selection conventions are aligned.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
92 sel <- read_dataset("REG_MIN_SELECTION")
93 sel$z <- sel$x
94 export_dataset(sel,"REG_EDGE_SELECTION_ALIAS","Two exactly aliased candidate predictors",
95 "R stats lm/step AIC alias boundary",
96 "Constructed validation data; no third-party license.",
97 c(x="Float64",y="Float64",z="Float64"))
98 s <- read_dataset("REG_EDGE_SELECTION_ALIAS")
99 fit <- stats::step(stats::lm(y~1,data=s),scope=list(lower=~1,upper=~x+z),
100 direction="forward",trace=0)
101 emit("STAT-REG-SELECTION-ALIAS-001",
102 "tabelz.analysis.model_selection:compute_model_selection",
103 "modelSelectionMenuItem","REG_EDGE_SELECTION_ALIAS",
104 list(response="y",candidate_predictors=list("x","z"),direction="forward"),
105 list("/n"=exact(as.integer(nrow(s)),"five source rows")),
106 c("x and z are exactly aliased; R step breaks the tie by candidate order.",
107 "Only population size is asserted until Tabelz and R alias-selection conventions are aligned."),
108 deferred=list(list(path="/selected",
109 reason="Exact-alias tie breaking is not specified in the manual.")))
Small-sample boundary STAT-REG-SELECTION-MIN-001
Case STAT-REG-SELECTION-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, plm, rpart
- Citation
- R stats::nls/lm, plm::plm, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_a.R · sha256 e69dea823e2a8f59
- Dataset
- reference_data/datasets/REG_MIN_SELECTION.json
Settings compared
candidate_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/coefficient | tolerance | 1.99 | 1.9900000000000002 | 2.13E-16 | 15 | passed |
/n | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- One strong candidate gives the unique one-term AIC choice.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
55 sel <- data.frame(x=c(1,2,3,4,5),y=c(2.1,4.0,6.2,8.1,10.0))
56 export_dataset(sel,"REG_MIN_SELECTION","Five-row one-predictor selection design",
57 "R lm and step AIC small-sample boundary",
58 "Constructed validation data; no third-party license.",
59 c(x="Float64",y="Float64"))
60 s <- read_dataset("REG_MIN_SELECTION")
61 fit <- stats::lm(y~x,data=s)
62 emit("STAT-REG-SELECTION-MIN-001","tabelz.analysis.model_selection:compute_model_selection",
63 "modelSelectionMenuItem","REG_MIN_SELECTION",
64 list(response="y",candidate_predictors=list("x")),
65 list("/coefficients/1/coefficient"=tol(coef(fit)[["x"]],"single selected OLS slope"),
66 "/n"=exact(nrow(s),"five selected rows")),
67 c("One strong candidate gives the unique one-term AIC choice."))
True minimum sample STAT-REG-SELECTION-TRUE-MIN-001
Case STAT-REG-SELECTION-TRUE-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats/rpart/pls and analytic sample conditions
- Citation
- R stats::lm, rpart::rpart, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_true_min.R · sha256 f10363ad1ec76730
- Dataset
- reference_data/datasets/REG_TRUE_MIN_SELECTION.json
Settings compared
candidate_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 3 | 3 | 0.00E+2 | passed | |
/coefficients/1/coefficient | tolerance | 2.0500000000000007 | 2.05 | 8.78E-16 | 15 | passed |
Convention
- Three complete rows are the smallest accepted for one candidate predictor.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
25 sel <- read_dataset("REG_MIN_SELECTION")[1:3,]
26 export_dataset(sel,"REG_TRUE_MIN_SELECTION","Three rows for one candidate predictor",
27 "R lm/step AIC minimal one-predictor model",
28 "Constructed validation data; no third-party license.",
29 c(x="Float64",y="Float64"))
30 s <- read_dataset("REG_TRUE_MIN_SELECTION")
31 fit <- stats::lm(y~x,data=s)
32 emit("STAT-REG-SELECTION-TRUE-MIN-001","STAT-REG-SELECTION-001",
33 "REG_TRUE_MIN_SELECTION",list(response="y",candidate_predictors=list("x")),
34 list("/n"=exact(as.integer(nrow(s)),"three rows exceed one predictor plus intercept"),
35 "/coefficients/1/coefficient"=tol(coef(fit)[["x"]],"three-point OLS slope")),
36 "Three complete rows are the smallest accepted for one candidate predictor.")
Large-offset random-slope mixed model
Case STAT-REG-STRUCT-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme::lme
- Citation
- R nlme::lme REML random-slope documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · nlme 3.1.169, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_structure_hard.R · sha256 b4579cd3289ab12d
- Dataset
- reference_data/datasets/REG_ADV_HARD_ORTH.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"model_mode= "random_slope"random_slope_column= "age"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.66018518518522029 | 0.6601851851851852 | 3.51E-14 | 13 | passed |
Convention
- Both age and response have large common offsets; fixed age slope should be translation-invariant.
- nlme::lme uses REML, random=~age|subject, control opt=optim.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
1 source("common.R",local=TRUE)
2 d <- read_dataset("REG_ADV_HARD_ORTH")
3 fit <- nlme::lme(distance~age,random=~age|subject,data=d,method="REML",
4 control=nlme::lmeControl(opt="optim"))
5 id <- "STAT-REG-STRUCT-HARD-001"Whole script generators/r/regression_advanced_structure_hard.R
Small-sample boundary STAT-REG-STRUCT-MIN-001
Case STAT-REG-STRUCT-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/MASS/pls/stats
- Citation
- R nlme::lme, MASS::lda, pls::plsr and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_b.R · sha256 e3e09e1965800ae1
- Dataset
- reference_data/datasets/REG_MIN_SLOPE.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"model_mode= "random_slope"random_slope_column= "age"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | 0.56250000000000022 | 0.5625 | 2.20E-16 | 15 | passed |
Convention
- Two groups each have three complete rows, the declared random-slope minimum.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
41 six <- orth[c(1:3,5:7),]
42 export_dataset(six,"REG_MIN_SLOPE","Two repeated subjects with three observations each",
43 "R nlme random-slope minimum-group-size boundary",
44 "Derived from R nlme::Orthodont; retain attribution.",types)
45 m <- read_dataset("REG_MIN_SLOPE")
46 fit <- nlme::lme(distance~age,random=~age|subject,data=m,method="REML",
47 control=nlme::lmeControl(opt="optim"))
48 emit("STAT-REG-STRUCT-MIN-001","tabelz.executor.mixed_model_structures",
49 "mixedModelStructuresMenuItem","REG_MIN_SLOPE",
50 list(response_column="distance",fixed_numeric_columns=list("age"),
51 model_mode="random_slope",group_column="subject",random_slope_column="age",
52 estimation="reml"),
53 list("/coefficients/1/estimate"=tol(nlme::fixef(fit)[["age"]],"random-slope fixed age effect")),
54 c("Two groups each have three complete rows, the declared random-slope minimum."))
Regression edge STAT-REG-STRUCT-ONEGROUP-001
Case STAT-REG-STRUCT-ONEGROUP-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic design condition
- Citation
- Tabelz manual regression model design conditions; R stats/plm references
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_b.R · sha256 4a5d01b584989ad6
- Dataset
- reference_data/datasets/REG_EDGE_STRUCT_ONE_GROUP.json
Settings compared
estimation= "reml"fixed_numeric_columns= ["age"]group_column= "subject"model_mode= "random_slope"random_slope_column= "age"response_column= "distance"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A random-slope variance cannot be identified from one repeated group.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
24 err <- function(cls,message) list(error_class=cls,message_contains=message)
25 exact <- function(x,note) list(comparison="exact",value=as.integer(x),rationale=note)
26 tol <- function(x,note) list(comparison="tolerance",value=dec(unname(x)),
27 absolute_tolerance="0",relative_tolerance="1e-9",rationale=note)
28 orth <- read_dataset("REG_ORTHODONT")[1:4,]
29 export_dataset(orth,"REG_EDGE_STRUCT_ONE_GROUP","One repeated group with four observations",
30 "Analytic random-slope group-count design condition",
31 "Derived from R nlme::Orthodont; retain attribution.",
32 c(distance="Float64",age="Float64",subject="String",sex="String",
33 time="Int64",age_sq="Float64"))
34 emit("STAT-REG-STRUCT-ONEGROUP-001","STAT-REG-MIXED-STRUCT-SLOPE-001",
35 "REG_EDGE_STRUCT_ONE_GROUP",
36 list(response_column="distance",fixed_numeric_columns=list("age"),
37 model_mode="random_slope",group_column="subject",random_slope_column="age",
38 estimation="reml"),error=err("RuntimeError","at least two groups"),
39 note="A random-slope variance cannot be identified from one repeated group.")
Survey Cox regression (Taylor)
Case STAT-REG-SURVEY-COX-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.95covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}event_value= "event"factors= ["grp"]status= "status"time= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | 0.42966740705599044 | 0.4296674070559912 | 7.73E-16 | 14 | passed |
/fit/coefficients/0/standard_error | tolerance | 0.5753135997115808 | 0.5753135997115806 | 2.19E-16 | 15 | passed |
/fit/coefficients/0/statistic | tolerance | 0.74684034459013926 | 0.7468403445901409 | 1.67E-15 | 14 | passed |
/fit/coefficients/0/p_value | tail_probability | 0.45515993918373154 | 0.45515993918373054 | 9.96E-16 | 14 | passed |
/fit/coefficients/0/lower | tolerance | -0.69792652819480083 | -0.6979265281947999 | 8.86E-16 | 14 | passed |
/fit/coefficients/0/upper | tolerance | 1.5572613423067818 | 1.5572613423067823 | 4.59E-16 | 15 | passed |
/fit/coefficients/0/ratio | tolerance | 1.5367463275576256 | 1.536746327557627 | 1.37E-15 | 15 | passed |
/fit/coefficients/0/ratio_lower | tolerance | 0.49761602763683216 | 0.4976160276368326 | 4.43E-16 | 15 | passed |
/fit/coefficients/0/ratio_upper | tolerance | 4.7458062926087532 | 4.745806292608756 | 2.66E-15 | 15 | passed |
/fit/coefficients/1/estimate | tolerance | 0.89112098975856369 | 0.8911209897585647 | 9.96E-16 | 14 | passed |
/fit/coefficients/1/standard_error | tolerance | 0.53271792720548616 | 0.5327179272054858 | 3.29E-16 | 15 | passed |
/fit/coefficients/1/statistic | tolerance | 1.6727820564124363 | 1.6727820564124392 | 2.86E-15 | 14 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.09437020851916253 | 0.0943702085191619 | 6.25E-16 | 14 | passed |
/fit/coefficients/1/lower | tolerance | -0.15298696148301927 | -0.15298696148301782 | 1.45E-15 | 14 | passed |
/fit/coefficients/1/upper | tolerance | 1.9352289410001466 | 1.935228941000147 | 4.85E-16 | 15 | passed |
/fit/coefficients/1/ratio | tolerance | 2.4378609372755387 | 2.4378609372755413 | 2.62E-15 | 14 | passed |
/fit/coefficients/1/ratio_lower | tolerance | 0.8581409106232859 | 0.8581409106232871 | 1.22E-15 | 14 | passed |
/fit/coefficients/1/ratio_upper | tolerance | 6.9256294344215812 | 6.925629434421585 | 3.54E-15 | 15 | passed |
/fit/coefficients/2/estimate | tolerance | -0.056981380091591177 | -0.056981380091591205 | 2.80E-17 | 15 | passed |
/fit/coefficients/2/standard_error | tolerance | 0.28564783662388482 | 0.2856478366238848 | 9.95E-19 | 17 | passed |
/fit/coefficients/2/statistic | tolerance | -0.19948122403118038 | -0.19948122403118046 | 7.96E-17 | 15 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.84188632925730278 | 0.8418863292573028 | 9.94E-19 | 17 | passed |
/fit/coefficients/2/lower | tolerance | -0.61684085213618667 | -0.6168408521361868 | 1.09E-16 | 15 | passed |
/fit/coefficients/2/upper | tolerance | 0.50287809195300437 | 0.5028780919530045 | 1.10E-16 | 15 | passed |
/fit/coefficients/2/ratio | tolerance | 0.9446116577853253 | 0.9446116577853253 | 1.76E-18 | 17 | passed |
/fit/coefficients/2/ratio_lower | tolerance | 0.53964657084522538 | 0.5396465708452254 | 1.77E-18 | 17 | passed |
/fit/coefficients/2/ratio_upper | tolerance | 1.6534732771976723 | 1.6534732771976723 | 4.20E-17 | 16 | passed |
/fit/term_tests/[term=grp]/df | exact | 2 | 2 | 0.00E+2 | passed | |
/fit/term_tests/[term=grp]/statistic | tolerance | 2.8616779197641353 | 2.8616779197641455 | 1.02E-14 | 14 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.23910823585425717 | 0.23910823585425595 | 1.22E-15 | 14 | passed |
/fit/term_tests/[term=x]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/fit/term_tests/[term=x]/statistic | tolerance | 0.039792758740977971 | 0.03979275874097801 | 4.16E-17 | 14 | passed |
/fit/term_tests/[term=x]/p_value | tail_probability | 0.84188632925730289 | 0.8418863292573027 | 2.22E-16 | 15 | passed |
/fit/term_tests/[term=All predictors]/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/term_tests/[term=All predictors]/statistic | tolerance | 3.0644580222406415 | 3.064458022240655 | 1.37E-14 | 14 | passed |
/fit/term_tests/[term=All predictors]/p_value | tail_probability | 0.38179339447841404 | 0.38179339447841065 | 3.39E-15 | 14 | passed |
/events | exact | 23 | 23 | 0.00E+2 | passed | |
/fit/statistics/[label=Weighted events]/value | tolerance | 51.301499999999997 | 51.30150000000001 | 1.44E-14 | 15 | passed |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Linearized design variance of the weighted score residuals.
- svycoxph(Surv(time, event) ~ grp + x): Efron ties (none here, times are distinct), design-based (Binder 1992) variance.
- Hazard ratios exp(coefficient) with normal intervals; term Wald chi-square from vcov(svycoxph).
- Iterative fit: 1e-6 relative tolerance.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
422 COX <- "tabelz.analysis.survey_models:compute_survey_cox" 423 COX_REQ <- "REQ-STAT-REG-SURVEY-COX-001"
Survey Cox regression from supplied replicate weights with 90% intervals
Case STAT-REG-SURVEY-COX-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.9covariates= ["x"]design= {"weight": "w", "variance": "replicate", "replicates": {"columns": ["rw1", "rw2", "rw3", "rw4"], "method": "other", "weight_type": "full", "scale": 0.75, "rscales": null, "fay_rho": null, "centering": "full_sample"}}event_value= "event"factors= ["grp"]status= "status"time= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | 0.42966740705599044 | 0.4296674070559912 | 7.73E-16 | 14 | passed |
/fit/coefficients/0/standard_error | tolerance | 0.15460116214155684 | 0.15460116216810646 | 2.65E-11 | 9 | passed |
/fit/coefficients/0/statistic | tolerance | 2.7791990765410666 | 2.7791990760638003 | 4.77E-10 | 9 | passed |
/fit/coefficients/0/p_value | tail_probability | 0.0054493117415761886 | 0.0054493117495831335 | 8.01E-12 | 8 | passed |
/fit/coefficients/0/lower | tolerance | 0.17537112477653816 | 0.1753711247328686 | 4.37E-11 | 9 | passed |
/fit/coefficients/0/upper | tolerance | 0.68396368933544271 | 0.6839636893791139 | 4.37E-11 | 10 | passed |
/fit/coefficients/0/ratio | tolerance | 1.5367463275576256 | 1.536746327557627 | 1.37E-15 | 15 | passed |
/fit/coefficients/0/ratio_lower | tolerance | 1.1916883996457648 | 1.1916883995937242 | 5.20E-11 | 10 | passed |
/fit/coefficients/0/ratio_upper | tolerance | 1.9817170964858291 | 1.9817170965723732 | 8.65E-11 | 10 | passed |
/fit/coefficients/1/estimate | tolerance | 0.89112098975856413 | 0.8911209897585647 | 5.56E-16 | 15 | passed |
/fit/coefficients/1/standard_error | tolerance | 0.14494438610395599 | 0.14494438610316565 | 7.90E-13 | 11 | passed |
/fit/coefficients/1/statistic | tolerance | 6.1480200352115784 | 6.148020035245105 | 3.35E-11 | 11 | passed |
/fit/coefficients/1/p_value | tail_probability | 7.8456125557156509e-10 | 7.845612554057671e-10 | 1.66E-19 | 9 | passed |
/fit/coefficients/1/lower | tolerance | 0.65270869056921765 | 0.6527086905705182 | 1.30E-12 | 11 | passed |
/fit/coefficients/1/upper | tolerance | 1.1295332889479106 | 1.1295332889466112 | 1.30E-12 | 11 | passed |
/fit/coefficients/1/ratio | tolerance | 2.43786093727554 | 2.4378609372755413 | 1.32E-15 | 15 | passed |
/fit/coefficients/1/ratio_lower | tolerance | 1.920736469907439 | 1.920736469909937 | 2.50E-12 | 11 | passed |
/fit/coefficients/1/ratio_upper | tolerance | 3.0942120601169076 | 3.094212060112887 | 4.02E-12 | 11 | passed |
/fit/coefficients/2/estimate | tolerance | -0.056981380091591198 | -0.056981380091591205 | 6.98E-18 | 15 | passed |
/fit/coefficients/2/standard_error | tolerance | 0.11790641094292995 | 0.11790641092480736 | 1.81E-11 | 9 | passed |
/fit/coefficients/2/statistic | tolerance | -0.48327635143751263 | -0.48327635151179377 | 7.43E-11 | 9 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.62889952911296021 | 0.6288995290602247 | 5.27E-11 | 10 | passed |
/fit/coefficients/2/lower | tolerance | -0.25092016777190018 | -0.25092016774209125 | 2.98E-11 | 9 | passed |
/fit/coefficients/2/upper | tolerance | 0.1369574075887178 | 0.13695740755890887 | 2.98E-11 | 9 | passed |
/fit/coefficients/2/ratio | tolerance | 0.9446116577853253 | 0.9446116577853253 | 1.76E-18 | 17 | passed |
/fit/coefficients/2/ratio_lower | tolerance | 0.77808448529769647 | 0.7780844853208904 | 2.32E-11 | 10 | passed |
/fit/coefficients/2/ratio_upper | tolerance | 1.1467793033844498 | 1.1467793033502656 | 3.42E-11 | 10 | passed |
/fit/term_tests/[term=grp]/df | exact | 2 | 2 | 0.00E+2 | passed | |
/fit/term_tests/[term=grp]/statistic | tolerance | 39.143554992118595 | 39.143554991593724 | 5.25E-10 | 10 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 3.1628968770117634e-09 | 3.1628968778418213e-09 | 8.30E-19 | 9 | passed |
/fit/term_tests/[term=x]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/fit/term_tests/[term=x]/statistic | tolerance | 0.2335560318587542 | 0.23355603193055088 | 7.18E-11 | 9 | passed |
/fit/term_tests/[term=x]/p_value | tail_probability | 0.62889952911295999 | 0.6288995290602247 | 5.27E-11 | 10 | passed |
/fit/term_tests/[term=All predictors]/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/term_tests/[term=All predictors]/statistic | tolerance | 41.730271254328194 | 41.73027124933836 | 4.99E-9 | 9 | passed |
/fit/term_tests/[term=All predictors]/p_value | tail_probability | 4.5772952643513363e-09 | 4.577295275509918e-09 | 1.12E-17 | 8 | passed |
/events | exact | 23 | 23 | 0.00E+2 | passed | |
/fit/statistics/[label=Weighted events]/value | tolerance | 51.301499999999997 | 51.30150000000001 | 1.44E-14 | 15 | passed |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/design_df | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- svycoxph on svrepdesign(type = 'other', scale = 0.75, mse = TRUE): the model is refitted under each replicate weight column.
- degf = qr(replicate weights)$rank - 1 = 3 (reference only; normal inference).
- svycoxph(Surv(time, event) ~ grp + x): Efron ties (none here, times are distinct), design-based (Binder 1992) variance.
- Hazard ratios exp(coefficient) with normal intervals; term Wald chi-square from vcov(svycoxph).
- Iterative fit: 1e-6 relative tolerance.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
448 cox_case("STAT-REG-SURVEY-COX-002", "Survey Cox regression from supplied replicate weights with 90% intervals",
449 replicate, design_rep, D_R, 0.90,
450 c("svycoxph on svrepdesign(type = 'other', scale = 0.75, mse = TRUE): the model is refitted under each replicate weight column.",
451 "degf = qr(replicate weights)$rank - 1 = 3 (reference only; normal inference)."), "axis_coverage")
Survey linear regression with design-df t and F inference
Case STAT-REG-SURVEY-LINEAR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.95covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}factors= ["grp"]inference= "design_df"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | 4.7521074910375658 | 4.752107491037567 | 8.89E-16 | 15 | passed |
/fit/coefficients/0/standard_error | tolerance | 0.37182542928877277 | 0.3718254292887724 | 3.90E-16 | 14 | passed |
/fit/coefficients/0/statistic | tolerance | 12.780480076705327 | 12.780480076705343 | 1.63E-14 | 14 | passed |
/fit/coefficients/0/p_value | tail_probability | 5.2178844394329544e-05 | 5.217884439432926e-05 | 2.85E-19 | 14 | passed |
/fit/coefficients/0/lower | tolerance | 3.7962997964801719 | 3.7962997964801737 | 1.78E-15 | 15 | passed |
/fit/coefficients/0/upper | tolerance | 5.7079151855949597 | 5.70791518559496 | 5.02E-18 | 18 | passed |
/fit/coefficients/0/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/1/estimate | tolerance | 0.97718223431134976 | 0.9771822343113507 | 8.90E-16 | 15 | passed |
/fit/coefficients/1/standard_error | tolerance | 0.48364884815350978 | 0.48364884815350934 | 4.44E-16 | 15 | passed |
/fit/coefficients/1/statistic | tolerance | 2.0204374269515326 | 2.020437426951536 | 3.56E-15 | 14 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.099314857933451919 | 0.09931485793345153 | 3.88E-16 | 14 | passed |
/fit/coefficients/1/lower | tolerance | -0.26607670957848806 | -0.2660767095784865 | 1.56E-15 | 14 | passed |
/fit/coefficients/1/upper | tolerance | 2.2204411782011877 | 2.2204411782011877 | 6.98E-18 | 17 | passed |
/fit/coefficients/1/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/2/estimate | tolerance | -0.25080171609245849 | -0.25080171609245855 | 5.87E-17 | 15 | passed |
/fit/coefficients/2/standard_error | tolerance | 0.43987378725421716 | 0.43987378725421666 | 4.96E-16 | 14 | passed |
/fit/coefficients/2/statistic | tolerance | -0.57016745111822753 | -0.5701674511182283 | 7.78E-16 | 14 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.59322828163943042 | 0.5932282816394296 | 7.76E-16 | 14 | passed |
/fit/coefficients/2/lower | tolerance | -1.3815332835807015 | -1.3815332835807004 | 1.12E-15 | 15 | passed |
/fit/coefficients/2/upper | tolerance | 0.8799298513957845 | 0.8799298513957834 | 1.11E-15 | 14 | passed |
/fit/coefficients/2/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/3/estimate | tolerance | 1.1707387409527739 | 1.1707387409527714 | 2.48E-15 | 14 | passed |
/fit/coefficients/3/standard_error | tolerance | 0.15488611380829398 | 0.15488611380829434 | 3.60E-16 | 14 | passed |
/fit/coefficients/3/statistic | tolerance | 7.5587069245072769 | 7.558706924507243 | 3.38E-14 | 14 | passed |
/fit/coefficients/3/p_value | tail_probability | 0.00064252133104061751 | 0.000642521331040631 | 1.34E-17 | 13 | passed |
/fit/coefficients/3/lower | tolerance | 0.77259131020487448 | 0.772591310204871 | 3.44E-15 | 14 | passed |
/fit/coefficients/3/upper | tolerance | 1.5688861717006732 | 1.568886171700672 | 1.29E-15 | 15 | passed |
/fit/coefficients/3/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/term_tests/[term=grp]/statistic | tolerance | 2.9429097140465221 | 2.942909714046525 | 2.69E-15 | 15 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.14297898039614299 | 0.14297898039614276 | 2.27E-16 | 14 | passed |
/fit/term_tests/[term=grp]/denominator_df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/term_tests/[term=x]/statistic | tolerance | 57.13405037059426 | 57.13405037059376 | 4.98E-13 | 14 | passed |
/fit/term_tests/[term=x]/p_value | tail_probability | 0.00064252133104061751 | 0.0006425213310406305 | 1.30E-17 | 13 | passed |
/fit/term_tests/[term=All predictors]/statistic | tolerance | 50.198362800614575 | 50.19836280061403 | 5.47E-13 | 13 | passed |
/fit/term_tests/[term=All predictors]/p_value | tail_probability | 0.00037275235532617811 | 0.0003727523553261876 | 9.48E-18 | 13 | passed |
/fit/statistics/[label=Weighted R-squared]/value | tolerance | 0.56736275519537971 | 0.5673627551953797 | 1.21E-18 | 17 | passed |
/fit/statistics/[label=Sum of weights (analysed rows)]/value | tolerance | 65.841200000000001 | 65.8412 | 3.86E-16 | 17 | passed |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed | |
/fit/test_df | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- svyglm(y ~ grp + x): coefficients (Intercept), grp = b (vs a), grp = c (vs a), x in that order (factors before covariates).
- D = 10 PSUs - 2 strata = 8; coefficient t and term-test F use D - rank(X) + 1 = 5 (svyglm df.residual).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
167 LINEAR <- "tabelz.analysis.survey_models:compute_survey_linear" 168 LIN_REQ <- "REQ-STAT-REG-SURVEY-LINEAR-001"
Survey linear regression with normal inference
Case STAT-REG-SURVEY-LINEAR-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.95covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}factors= ["grp"]inference= "normal"response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | 4.7521074910375658 | 4.752107491037567 | 8.89E-16 | 15 | passed |
/fit/coefficients/0/standard_error | tolerance | 0.37182542928877277 | 0.3718254292887724 | 3.90E-16 | 14 | passed |
/fit/coefficients/0/statistic | tolerance | 12.780480076705327 | 12.780480076705343 | 1.63E-14 | 14 | passed |
/fit/coefficients/0/p_value | tail_probability | 2.1076453902737243e-37 | 2.107645390273297e-37 | 4.27E-50 | 12 | passed |
/fit/coefficients/0/lower | tolerance | 4.0233430410954263 | 4.023343041095428 | 1.76E-15 | 15 | passed |
/fit/coefficients/0/upper | tolerance | 5.4808719409797053 | 5.480871940979705 | 1.46E-17 | 17 | passed |
/fit/coefficients/1/estimate | tolerance | 0.97718223431134976 | 0.9771822343113507 | 8.90E-16 | 15 | passed |
/fit/coefficients/1/standard_error | tolerance | 0.48364884815350978 | 0.48364884815350934 | 4.44E-16 | 15 | passed |
/fit/coefficients/1/statistic | tolerance | 2.0204374269515326 | 2.020437426951536 | 3.56E-15 | 14 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.043338034524218798 | 0.04333803452421844 | 3.61E-16 | 14 | passed |
/fit/coefficients/1/lower | tolerance | 0.029247910766189378 | 0.029247910766190932 | 1.55E-15 | 13 | passed |
/fit/coefficients/1/upper | tolerance | 1.9251165578565101 | 1.9251165578565104 | 2.69E-16 | 15 | passed |
/fit/coefficients/2/estimate | tolerance | -0.25080171609245849 | -0.25080171609245855 | 5.87E-17 | 15 | passed |
/fit/coefficients/2/standard_error | tolerance | 0.43987378725421716 | 0.43987378725421666 | 4.96E-16 | 14 | passed |
/fit/coefficients/2/statistic | tolerance | -0.57016745111822753 | -0.5701674511182283 | 7.78E-16 | 14 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.56856413002221051 | 0.56856413002221 | 5.53E-16 | 15 | passed |
/fit/coefficients/2/lower | tolerance | -1.1129384968539577 | -1.112938496853957 | 6.29E-16 | 15 | passed |
/fit/coefficients/2/upper | tolerance | 0.61133506466904086 | 0.6113350646690401 | 7.75E-16 | 14 | passed |
/fit/coefficients/3/estimate | tolerance | 1.1707387409527739 | 1.1707387409527714 | 2.48E-15 | 14 | passed |
/fit/coefficients/3/standard_error | tolerance | 0.15488611380829398 | 0.15488611380829434 | 3.60E-16 | 14 | passed |
/fit/coefficients/3/statistic | tolerance | 7.5587069245072769 | 7.558706924507243 | 3.38E-14 | 14 | passed |
/fit/coefficients/3/p_value | tail_probability | 4.0709599079711517e-14 | 4.07095990797219e-14 | 1.04E-26 | 12 | passed |
/fit/coefficients/3/lower | tolerance | 0.86716753618314579 | 0.8671675361831426 | 3.22E-15 | 14 | passed |
/fit/coefficients/3/upper | tolerance | 1.474309945722402 | 1.4743099457224003 | 1.74E-15 | 14 | passed |
/fit/term_tests/[term=grp]/df | exact | 2 | 2 | 0.00E+2 | passed | |
/fit/term_tests/[term=grp]/statistic | tolerance | 5.8858194280930443 | 5.88581942809305 | 5.29E-15 | 15 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.052712128160111553 | 0.05271212816011143 | 1.25E-16 | 14 | passed |
/fit/term_tests/[term=x]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/fit/term_tests/[term=x]/statistic | tolerance | 57.13405037059426 | 57.13405037059376 | 4.98E-13 | 14 | passed |
/fit/term_tests/[term=x]/p_value | tail_probability | 4.0709599079711429e-14 | 4.070959907972173e-14 | 1.03E-26 | 12 | passed |
/fit/term_tests/[term=All predictors]/statistic | tolerance | 150.59508840184373 | 150.59508840184208 | 1.65E-12 | 13 | passed |
/fit/term_tests/[term=All predictors]/p_value | tail_probability | 1.9606188963164449e-32 | 1.960618896318026e-32 | 1.58E-44 | 12 | passed |
/fit/statistics/[label=Weighted R-squared]/value | tolerance | 0.56736275519537971 | 0.5673627551953797 | 1.21E-18 | 17 | passed |
/fit/statistics/[label=Sum of weights (analysed rows)]/value | tolerance | 65.841200000000001 | 65.8412 | 3.86E-16 | 17 | passed |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Normal inference: z = estimate / SE, 2 * pnorm(-|z|), qnorm intervals; term tests are Wald chi-square(q) (regTermTest df = Inf).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
229 linear_case("STAT-REG-SURVEY-LINEAR-002", "Survey linear regression with normal inference",
230 taylor, design_taylor, D_T, "normal", 0.95, list(), y ~ grp + x,
231 c("Normal inference: z = estimate / SE, 2 * pnorm(-|z|), qnorm intervals; term tests are Wald chi-square(q) (regTermTest df = Inf)."),
232 "axis_coverage")
Survey linear regression with an interaction and 90% intervals
Case STAT-REG-SURVEY-LINEAR-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.9covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}factors= ["grp"]inference= "design_df"interactions= ["grp:x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | 4.7042193167823072 | 4.704219316782311 | 3.56E-15 | 15 | passed |
/fit/coefficients/0/standard_error | tolerance | 0.31595023626971552 | 0.31595023626971575 | 2.25E-16 | 15 | passed |
/fit/coefficients/0/statistic | tolerance | 14.889114729974381 | 14.88911472997438 | 3.20E-16 | 16 | passed |
/fit/coefficients/0/p_value | tail_probability | 0.00065743999805110032 | 0.0006574399980511003 | 4.27E-22 | 18 | passed |
/fit/coefficients/0/lower | tolerance | 3.9606735835281617 | 3.960673583528165 | 3.09E-15 | 15 | passed |
/fit/coefficients/0/upper | tolerance | 5.4477650500364527 | 5.447765050036456 | 3.58E-15 | 15 | passed |
/fit/coefficients/0/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/coefficients/1/estimate | tolerance | 1.3338263135153285 | 1.333826313515327 | 1.51E-15 | 14 | passed |
/fit/coefficients/1/standard_error | tolerance | 0.47711397925359328 | 0.4771139792535933 | 1.13E-18 | 17 | passed |
/fit/coefficients/1/statistic | tolerance | 2.7956135672276745 | 2.795613567227671 | 3.54E-15 | 14 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.068100431514712484 | 0.06810043151471266 | 1.80E-16 | 14 | passed |
/fit/coefficients/1/lower | tolerance | 0.21100372050712579 | 0.2110037205071249 | 8.87E-16 | 14 | passed |
/fit/coefficients/1/upper | tolerance | 2.4566489065235313 | 2.456648906523529 | 2.23E-15 | 15 | passed |
/fit/coefficients/1/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/coefficients/2/estimate | tolerance | -0.15506232265492842 | -0.15506232265492903 | 6.10E-16 | 14 | passed |
/fit/coefficients/2/standard_error | tolerance | 0.41060914760849243 | 0.4106091476084923 | 1.10E-16 | 15 | passed |
/fit/coefficients/2/statistic | tolerance | -0.3776397178632202 | -0.3776397178632218 | 1.61E-15 | 14 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.7308326896812144 | 0.7308326896812133 | 1.11E-15 | 14 | passed |
/fit/coefficients/2/lower | tolerance | -1.1213748766318996 | -1.1213748766318994 | 2.13E-16 | 15 | passed |
/fit/coefficients/2/upper | tolerance | 0.81125023132204266 | 0.8112502313220413 | 1.33E-15 | 14 | passed |
/fit/coefficients/2/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/coefficients/3/estimate | tolerance | 0.8272461587841593 | 0.82724615878416 | 6.68E-16 | 15 | passed |
/fit/coefficients/3/standard_error | tolerance | 0.17945668741907586 | 0.17945668741907572 | 1.38E-16 | 15 | passed |
/fit/coefficients/3/statistic | tolerance | 4.6097260050963405 | 4.609726005096348 | 7.06E-15 | 14 | passed |
/fit/coefficients/3/p_value | tail_probability | 0.019202613890340621 | 0.019202613890340538 | 8.33E-17 | 14 | passed |
/fit/coefficients/3/lower | tolerance | 0.40491935248144556 | 0.4049193524814468 | 1.22E-15 | 14 | passed |
/fit/coefficients/3/upper | tolerance | 1.249572965086873 | 1.2495729650868732 | 2.11E-16 | 15 | passed |
/fit/coefficients/3/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/coefficients/4/estimate | tolerance | 1.1576797371029111 | 1.1576797371029082 | 2.93E-15 | 14 | passed |
/fit/coefficients/4/standard_error | tolerance | 0.64345889915374554 | 0.6434588991537455 | 4.91E-18 | 17 | passed |
/fit/coefficients/4/statistic | tolerance | 1.7991510236713653 | 1.7991510236713608 | 4.48E-15 | 14 | passed |
/fit/coefficients/4/p_value | tail_probability | 0.16982425043518934 | 0.16982425043519012 | 7.76E-16 | 14 | passed |
/fit/coefficients/4/lower | tolerance | -0.35661290796334844 | -0.35661290796335043 | 1.99E-15 | 14 | passed |
/fit/coefficients/4/upper | tolerance | 2.6719723821691703 | 2.6719723821691668 | 3.53E-15 | 14 | passed |
/fit/coefficients/4/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/coefficients/5/estimate | tolerance | 0.59410728183800698 | 0.5941072818380048 | 2.22E-15 | 14 | passed |
/fit/coefficients/5/standard_error | tolerance | 0.31628296229024849 | 0.31628296229024766 | 8.30E-16 | 14 | passed |
/fit/coefficients/5/statistic | tolerance | 1.8784043172480565 | 1.8784043172480542 | 2.27E-15 | 14 | passed |
/fit/coefficients/5/p_value | tail_probability | 0.15694255577867436 | 0.1569425557786747 | 3.32E-16 | 14 | passed |
/fit/coefficients/5/lower | tolerance | -0.15022147666666819 | -0.15022147666666807 | 1.15E-16 | 15 | passed |
/fit/coefficients/5/upper | tolerance | 1.3384360403426823 | 1.3384360403426776 | 4.70E-15 | 14 | passed |
/fit/coefficients/5/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/term_tests/[term=grp]/statistic | tolerance | 5.1414942571822175 | 5.141494257182211 | 6.19E-15 | 14 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.10733421550031992 | 0.10733421550032007 | 1.54E-16 | 14 | passed |
/fit/term_tests/[term=grp]/denominator_df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/term_tests/[term=x]/statistic | tolerance | 21.249573842061469 | 21.249573842061537 | 6.78E-14 | 14 | passed |
/fit/term_tests/[term=x]/p_value | tail_probability | 0.019202613890340614 | 0.01920261389034053 | 8.32E-17 | 14 | passed |
/fit/term_tests/[term=grp:x]/statistic | tolerance | 2.5065854852038827 | 2.5065854852038756 | 7.11E-15 | 14 | passed |
/fit/term_tests/[term=grp:x]/p_value | tail_probability | 0.22907372000970538 | 0.229073720009706 | 6.14E-16 | 14 | passed |
/fit/statistics/[label=Weighted R-squared]/value | tolerance | 0.62894222702147529 | 0.6289422270214753 | 3.64E-18 | 17 | passed |
/fit/statistics/[label=Sum of weights (analysed rows)]/value | tolerance | 65.841200000000001 | 65.8412 | 3.86E-16 | 17 | passed |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 6 | 6 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed | |
/fit/test_df | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- svyglm(y ~ grp + x + grp:x): interaction columns grp = b (vs a):x and grp = c (vs a):x follow the main effects (indices 4 and 5).
- Test df = D - rank(X) + 1 = 8 - 6 + 1 = 3; 90% intervals use qt(0.95, 3).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
233 domain_a <- subset(taylor, dom == "A")
234 linear_case("STAT-REG-SURVEY-LINEAR-003", "Survey linear regression with an interaction and 90% intervals",
235 taylor, design_taylor, D_T, "design_df", 0.90,
236 list(interactions = list("grp:x")), y ~ grp + x + grp:x,
237 c("svyglm(y ~ grp + x + grp:x): interaction columns grp = b (vs a):x and grp = c (vs a):x follow the main effects (indices 4 and 5).",
238 "Test df = D - rank(X) + 1 = 8 - 6 + 1 = 3; 90% intervals use qt(0.95, 3)."),
239 "axis_coverage")
Survey logistic regression with design-df inference
Case STAT-REG-SURVEY-LOGIT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.95covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}event_value= "yes"factors= ["grp"]inference= "design_df"response= "b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | -1.0714957947790638 | -1.0714957947790626 | 1.15E-15 | 14 | passed |
/fit/coefficients/0/standard_error | tolerance | 0.77073909878765123 | 0.7707390987877176 | 6.64E-14 | 13 | passed |
/fit/coefficients/0/statistic | tolerance | -1.3902185531582523 | -1.390218553158131 | 1.21E-13 | 13 | passed |
/fit/coefficients/0/p_value | tail_probability | 0.22317345159316815 | 0.2231734515932028 | 3.46E-14 | 12 | passed |
/fit/coefficients/0/lower | tolerance | -3.0527437221373024 | -3.052743722137473 | 1.71E-13 | 13 | passed |
/fit/coefficients/0/upper | tolerance | 0.90975213257917487 | 0.9097521325793474 | 1.73E-13 | 12 | passed |
/fit/coefficients/0/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/1/estimate | tolerance | 3.0813829398912134 | 3.0813829398912125 | 9.20E-16 | 15 | passed |
/fit/coefficients/1/standard_error | tolerance | 1.2842318477072949 | 1.2842318477074062 | 1.11E-13 | 13 | passed |
/fit/coefficients/1/statistic | tolerance | 2.399397698626089 | 2.3993976986258803 | 2.09E-13 | 13 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.061666692598068812 | 0.06166669259808473 | 1.59E-14 | 12 | passed |
/fit/coefficients/1/lower | tolerance | -0.21984012057081959 | -0.2198401205711078 | 2.88E-13 | 11 | passed |
/fit/coefficients/1/upper | tolerance | 6.3826060003532463 | 6.382606000353533 | 2.87E-13 | 13 | passed |
/fit/coefficients/1/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/1/ratio | tolerance | 21.788513775154364 | 21.788513775154343 | 2.15E-14 | 15 | passed |
/fit/coefficients/1/ratio_lower | tolerance | 0.80264711446711468 | 0.8026471144668834 | 2.31E-13 | 12 | passed |
/fit/coefficients/1/ratio_upper | tolerance | 591.46706438392357 | 591.4670643840933 | 1.70E-10 | 12 | passed |
/fit/coefficients/2/estimate | tolerance | -0.14917538856652648 | -0.14917538856652687 | 3.93E-16 | 14 | passed |
/fit/coefficients/2/standard_error | tolerance | 1.1494259783713241 | 1.1494259783713954 | 7.13E-14 | 13 | passed |
/fit/coefficients/2/statistic | tolerance | -0.12978251002983257 | -0.12978251002982485 | 7.72E-15 | 13 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.90179797233583936 | 0.9017979723358452 | 5.88E-15 | 14 | passed |
/fit/coefficients/2/lower | tolerance | -3.1038689299763509 | -3.103868929976535 | 1.84E-13 | 13 | passed |
/fit/coefficients/2/upper | tolerance | 2.8055181528432978 | 2.805518152843481 | 1.83E-13 | 13 | passed |
/fit/coefficients/2/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/2/ratio | tolerance | 0.86141801877758606 | 0.8614180187775857 | 3.34E-16 | 15 | passed |
/fit/coefficients/2/ratio_lower | tolerance | 0.044875246911785058 | 0.04487524691177679 | 8.27E-15 | 12 | passed |
/fit/coefficients/2/ratio_upper | tolerance | 16.53564167643227 | 16.535641676435304 | 3.03E-12 | 12 | passed |
/fit/coefficients/3/estimate | tolerance | 2.4117912810556699 | 2.4117912810556708 | 8.55E-16 | 15 | passed |
/fit/coefficients/3/standard_error | tolerance | 0.4888754595932252 | 0.4888754595932613 | 3.61E-14 | 13 | passed |
/fit/coefficients/3/statistic | tolerance | 4.9333449526438296 | 4.933344952643467 | 3.62E-13 | 13 | passed |
/fit/coefficients/3/p_value | tail_probability | 0.0043470091734908135 | 0.004347009173492175 | 1.36E-15 | 12 | passed |
/fit/coefficients/3/lower | tolerance | 1.1550969047369706 | 1.1550969047368782 | 9.24E-14 | 13 | passed |
/fit/coefficients/3/upper | tolerance | 3.6684856573743692 | 3.6684856573744633 | 9.41E-14 | 13 | passed |
/fit/coefficients/3/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/3/ratio | tolerance | 11.153923072112269 | 11.15392307211228 | 1.05E-14 | 15 | passed |
/fit/coefficients/3/ratio_lower | tolerance | 3.1743310103353735 | 3.1743310103350804 | 2.93E-13 | 13 | passed |
/fit/coefficients/3/ratio_upper | tolerance | 39.192510010307423 | 39.19251001031111 | 3.69E-12 | 13 | passed |
/fit/term_tests/[term=grp]/statistic | tolerance | 3.862710695787456 | 3.862710695787102 | 3.54E-13 | 13 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.096770855288504334 | 0.09677085528851775 | 1.34E-14 | 12 | passed |
/fit/term_tests/[term=grp]/denominator_df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/statistics/[label=Event rows]/value | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed | |
/fit/test_df | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- Coefficient t with D - rank(X) + 1 = 8 - 4 + 1 = 5 df; term F(2, 5).
- svyglm(family = quasibinomial()) pseudo-maximum likelihood; odds ratios are exp(coefficient) with the interval exponentiated.
- Iterative fit: the reference IRLS is converged to 1e-14 in deviance; outputs allow 1e-6 absolute or relative (p-values 1e-5 relative) for the engine's own stopping tolerance.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
275 logistic_case("STAT-REG-SURVEY-LOGIT-001", "Survey logistic regression with design-df inference",
276 taylor, design_taylor, D_T, "design_df", 0.95,
277 c("Coefficient t with D - rank(X) + 1 = 8 - 4 + 1 = 5 df; term F(2, 5)."), "nominal")
Survey logistic regression with normal inference
Case STAT-REG-SURVEY-LOGIT-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.95covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}event_value= "yes"factors= ["grp"]inference= "normal"response= "b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | -1.0714957947790638 | -1.0714957947790626 | 1.15E-15 | 14 | passed |
/fit/coefficients/0/standard_error | tolerance | 0.77073909878765123 | 0.7707390987877176 | 6.64E-14 | 13 | passed |
/fit/coefficients/0/statistic | tolerance | -1.3902185531582523 | -1.390218553158131 | 1.21E-13 | 13 | passed |
/fit/coefficients/0/p_value | tail_probability | 0.16446252123359389 | 0.1644625212336307 | 3.68E-14 | 12 | passed |
/fit/coefficients/0/lower | tolerance | -2.5821166698797189 | -2.582116669879848 | 1.29E-13 | 13 | passed |
/fit/coefficients/0/upper | tolerance | 0.43912508032159114 | 0.4391250803217228 | 1.32E-13 | 12 | passed |
/fit/coefficients/1/estimate | tolerance | 3.0813829398912134 | 3.0813829398912125 | 9.20E-16 | 15 | passed |
/fit/coefficients/1/standard_error | tolerance | 1.2842318477072949 | 1.2842318477074062 | 1.11E-13 | 13 | passed |
/fit/coefficients/1/statistic | tolerance | 2.399397698626089 | 2.3993976986258803 | 2.09E-13 | 13 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.016422067867275757 | 0.016422067867285114 | 9.36E-15 | 12 | passed |
/fit/coefficients/1/lower | tolerance | 0.56433477058558834 | 0.564334770585369 | 2.19E-13 | 12 | passed |
/fit/coefficients/1/upper | tolerance | 5.598431109196838 | 5.598431109197056 | 2.18E-13 | 13 | passed |
/fit/coefficients/1/ratio | tolerance | 21.788513775154364 | 21.788513775154343 | 2.15E-14 | 15 | passed |
/fit/coefficients/1/ratio_lower | tolerance | 1.7582777355216825 | 1.7582777355212968 | 3.86E-13 | 12 | passed |
/fit/coefficients/1/ratio_upper | tolerance | 270.00247056488814 | 270.0024705649471 | 5.89E-11 | 12 | passed |
/fit/coefficients/2/estimate | tolerance | -0.14917538856652648 | -0.14917538856652687 | 3.93E-16 | 14 | passed |
/fit/coefficients/2/standard_error | tolerance | 1.1494259783713241 | 1.1494259783713954 | 7.13E-14 | 13 | passed |
/fit/coefficients/2/statistic | tolerance | -0.12978251002983257 | -0.12978251002982485 | 7.72E-15 | 13 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.89673850084484918 | 0.8967385008448553 | 6.11E-15 | 14 | passed |
/fit/coefficients/2/lower | tolerance | -2.4020089090690364 | -2.402008909069177 | 1.41E-13 | 13 | passed |
/fit/coefficients/2/upper | tolerance | 2.1036581319359833 | 2.103658131936123 | 1.40E-13 | 13 | passed |
/fit/coefficients/2/ratio | tolerance | 0.86141801877758606 | 0.8614180187775857 | 3.34E-16 | 15 | passed |
/fit/coefficients/2/ratio_lower | tolerance | 0.090535892103737414 | 0.09053589210372467 | 1.27E-14 | 12 | passed |
/fit/coefficients/2/ratio_upper | tolerance | 8.1960975457607397 | 8.196097545761887 | 1.15E-12 | 12 | passed |
/fit/coefficients/3/estimate | tolerance | 2.4117912810556699 | 2.4117912810556708 | 8.55E-16 | 15 | passed |
/fit/coefficients/3/standard_error | tolerance | 0.4888754595932252 | 0.4888754595932613 | 3.61E-14 | 13 | passed |
/fit/coefficients/3/statistic | tolerance | 4.9333449526438296 | 4.933344952643467 | 3.62E-13 | 13 | passed |
/fit/coefficients/3/p_value | tail_probability | 8.0833212135920942e-07 | 8.083321213607072e-07 | 1.50E-18 | 11 | passed |
/fit/coefficients/3/lower | tolerance | 1.4536129873274821 | 1.4536129873274122 | 6.99E-14 | 13 | passed |
/fit/coefficients/3/upper | tolerance | 3.3699695747838576 | 3.369969574783929 | 7.15E-14 | 13 | passed |
/fit/coefficients/3/ratio | tolerance | 11.153923072112269 | 11.15392307211228 | 1.05E-14 | 15 | passed |
/fit/coefficients/3/ratio_lower | tolerance | 4.2785449520889269 | 4.278544952088628 | 2.99E-13 | 13 | passed |
/fit/coefficients/3/ratio_upper | tolerance | 29.077642350785009 | 29.077642350787087 | 2.08E-12 | 13 | passed |
/fit/term_tests/[term=grp]/statistic | tolerance | 7.7254213915749119 | 7.725421391574204 | 7.08E-13 | 13 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.021010967918071607 | 0.021010967918079045 | 7.44E-15 | 12 | passed |
/fit/statistics/[label=Event rows]/value | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Normal inference: z tests, qnorm intervals, chi-square term tests.
- svyglm(family = quasibinomial()) pseudo-maximum likelihood; odds ratios are exp(coefficient) with the interval exponentiated.
- Iterative fit: the reference IRLS is converged to 1e-14 in deviance; outputs allow 1e-6 absolute or relative (p-values 1e-5 relative) for the engine's own stopping tolerance.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
278 logistic_case("STAT-REG-SURVEY-LOGIT-002", "Survey logistic regression with normal inference",
279 taylor, design_taylor, D_T, "normal", 0.95,
280 c("Normal inference: z tests, qnorm intervals, chi-square term tests."), "axis_coverage")
Survey logistic regression with a first-stage FPC and 90% intervals
Case STAT-REG-SURVEY-LOGIT-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.9covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu", "fpc": "N", "fpc_kind": "count"}}event_value= "yes"factors= ["grp"]inference= "design_df"response= "b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | -1.0714957947790638 | -1.0714957947790626 | 1.15E-15 | 14 | passed |
/fit/coefficients/0/standard_error | tolerance | 0.71913464242514313 | 0.7191346424252044 | 6.13E-14 | 13 | passed |
/fit/coefficients/0/statistic | tolerance | -1.4899793885129082 | -1.48997938851278 | 1.28E-13 | 13 | passed |
/fit/coefficients/0/p_value | tail_probability | 0.19641473248340058 | 0.19641473248343316 | 3.26E-14 | 12 | passed |
/fit/coefficients/0/lower | tolerance | -2.5205868862052734 | -2.520586886205396 | 1.23E-13 | 13 | passed |
/fit/coefficients/0/upper | tolerance | 0.37759529664714564 | 0.3775952966472709 | 1.25E-13 | 12 | passed |
/fit/coefficients/0/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/1/estimate | tolerance | 3.0813829398912134 | 3.0813829398912125 | 9.20E-16 | 15 | passed |
/fit/coefficients/1/standard_error | tolerance | 1.1674765974000396 | 1.1674765974001398 | 1.00E-13 | 13 | passed |
/fit/coefficients/1/statistic | tolerance | 2.6393530686211841 | 2.639353068620957 | 2.27E-13 | 13 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.046012006438551162 | 0.04601200643856372 | 1.26E-14 | 12 | passed |
/fit/coefficients/1/lower | tolerance | 0.72886112139589176 | 0.7288611213956879 | 2.04E-13 | 12 | passed |
/fit/coefficients/1/upper | tolerance | 5.433904758386535 | 5.433904758386737 | 2.02E-13 | 13 | passed |
/fit/coefficients/1/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/1/ratio | tolerance | 21.788513775154364 | 21.788513775154343 | 2.15E-14 | 15 | passed |
/fit/coefficients/1/ratio_lower | tolerance | 2.0727186879934298 | 2.0727186879930075 | 4.22E-13 | 12 | passed |
/fit/coefficients/1/ratio_upper | tolerance | 229.04185468105175 | 229.04185468109793 | 4.62E-11 | 12 | passed |
/fit/coefficients/2/estimate | tolerance | -0.14917538856652648 | -0.14917538856652687 | 3.93E-16 | 14 | passed |
/fit/coefficients/2/standard_error | tolerance | 1.061216196749019 | 1.061216196749085 | 6.60E-14 | 13 | passed |
/fit/coefficients/2/statistic | tolerance | -0.14057021464949138 | -0.14057021464948302 | 8.36E-15 | 13 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.89369698957626942 | 0.8936969895762756 | 6.22E-15 | 14 | passed |
/fit/coefficients/2/lower | tolerance | -2.2875773595802942 | -2.2875773595804283 | 1.34E-13 | 13 | passed |
/fit/coefficients/2/upper | tolerance | 1.989226582447241 | 1.9892265824473745 | 1.33E-13 | 13 | passed |
/fit/coefficients/2/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/2/ratio | tolerance | 0.86141801877758606 | 0.8614180187775857 | 3.34E-16 | 15 | passed |
/fit/coefficients/2/ratio_lower | tolerance | 0.10151209149354071 | 0.10151209149352709 | 1.36E-14 | 12 | passed |
/fit/coefficients/2/ratio_upper | tolerance | 7.309877987509676 | 7.309877987510652 | 9.76E-13 | 12 | passed |
/fit/coefficients/3/estimate | tolerance | 2.4117912810556699 | 2.4117912810556708 | 8.55E-16 | 15 | passed |
/fit/coefficients/3/standard_error | tolerance | 0.44694893307117683 | 0.4469489330712081 | 3.13E-14 | 13 | passed |
/fit/coefficients/3/statistic | tolerance | 5.3961226945620453 | 5.39612269456167 | 3.76E-13 | 13 | passed |
/fit/coefficients/3/p_value | tail_probability | 0.0029515152345743925 | 0.0029515152345752937 | 9.01E-16 | 12 | passed |
/fit/coefficients/3/lower | tolerance | 1.5111675605076651 | 1.5111675605076025 | 6.26E-14 | 13 | passed |
/fit/coefficients/3/upper | tolerance | 3.3124150016036746 | 3.312415001603739 | 6.44E-14 | 13 | passed |
/fit/coefficients/3/df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/coefficients/3/ratio | tolerance | 11.153923072112269 | 11.15392307211228 | 1.05E-14 | 15 | passed |
/fit/coefficients/3/ratio_lower | tolerance | 4.5320191130338179 | 4.532019113033534 | 2.84E-13 | 13 | passed |
/fit/coefficients/3/ratio_upper | tolerance | 27.451340516372191 | 27.45134051637396 | 1.77E-12 | 13 | passed |
/fit/term_tests/[term=grp]/statistic | tolerance | 4.6630283184900962 | 4.6630283184896735 | 4.23E-13 | 13 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.07196284945107706 | 0.07196284945108768 | 1.06E-14 | 12 | passed |
/fit/term_tests/[term=grp]/denominator_df | exact | 5 | 5 | 0.00E+2 | passed | |
/fit/statistics/[label=Event rows]/value | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 4 | 4 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed | |
/fit/test_df | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- svydesign(fpc = ~N) with stratum PSU population counts 25 and 40; 90% intervals use qt(0.95, 5).
- svyglm(family = quasibinomial()) pseudo-maximum likelihood; odds ratios are exp(coefficient) with the interval exponentiated.
- Iterative fit: the reference IRLS is converged to 1e-14 in deviance; outputs allow 1e-6 absolute or relative (p-values 1e-5 relative) for the engine's own stopping tolerance.
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
281 logistic_case("STAT-REG-SURVEY-LOGIT-003", "Survey logistic regression with a first-stage FPC and 90% intervals",
282 with_fpc, design_fpc, D_F, "design_df", 0.90,
283 c("svydesign(fpc = ~N) with stratum PSU population counts 25 and 40; 90% intervals use qt(0.95, 5)."),
284 "axis_coverage")
Survey proportional-odds regression (Taylor)
Case STAT-REG-SURVEY-ORD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.95covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}factors= ["grp"]level_order= ["low", "mid", "high"]response= "ord"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | 1.3524637864024327 | 1.352463786402432 | 6.67E-16 | 15 | passed |
/fit/coefficients/0/standard_error | tolerance | 1.3461426938999705 | 1.3461426938999717 | 1.15E-15 | 15 | passed |
/fit/coefficients/0/statistic | tolerance | 1.0046957076178522 | 1.0046957076178509 | 1.33E-15 | 14 | passed |
/fit/coefficients/0/p_value | tail_probability | 0.31504339566911499 | 0.31504339566911566 | 6.66E-16 | 14 | passed |
/fit/coefficients/0/lower | tolerance | -1.2859274116932351 | -1.2859274116932389 | 3.78E-15 | 14 | passed |
/fit/coefficients/0/upper | tolerance | 3.9908549844981005 | 3.990854984498103 | 2.66E-15 | 15 | passed |
/fit/coefficients/0/ratio | tolerance | 3.8669411206449698 | 3.866941120644967 | 2.71E-15 | 15 | passed |
/fit/coefficients/0/ratio_lower | tolerance | 0.27639413358154141 | 0.27639413358154036 | 1.05E-15 | 14 | passed |
/fit/coefficients/0/ratio_upper | tolerance | 54.101125218431925 | 54.101125218432074 | 1.49E-13 | 14 | passed |
/fit/coefficients/1/estimate | tolerance | 0.088668695276449633 | 0.08866869527644983 | 1.94E-16 | 14 | passed |
/fit/coefficients/1/standard_error | tolerance | 0.77920574944378918 | 0.779205749443789 | 2.27E-16 | 15 | passed |
/fit/coefficients/1/statistic | tolerance | 0.11379368714841094 | 0.11379368714841123 | 2.92E-16 | 14 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.90940134301278841 | 0.9094013430127881 | 3.33E-16 | 15 | passed |
/fit/coefficients/1/lower | tolerance | -1.438546510179918 | -1.438546510179918 | 3.01E-17 | 16 | passed |
/fit/coefficients/1/upper | tolerance | 1.6158839007328174 | 1.6158839007328174 | 2.00E-18 | 17 | passed |
/fit/coefficients/1/ratio | tolerance | 1.0927185735248508 | 1.092718573524851 | 2.22E-16 | 15 | passed |
/fit/coefficients/1/ratio_lower | tolerance | 0.23727238115942062 | 0.23727238115942062 | 2.26E-20 | 19 | passed |
/fit/coefficients/1/ratio_upper | tolerance | 5.0323340419630531 | 5.032334041963053 | 1.73E-17 | 17 | passed |
/fit/coefficients/2/estimate | tolerance | 0.97978234486136628 | 0.9797823448613658 | 4.41E-16 | 15 | passed |
/fit/coefficients/2/standard_error | tolerance | 0.62789565109022172 | 0.627895651090222 | 3.31E-16 | 15 | passed |
/fit/coefficients/2/statistic | tolerance | 1.5604222503534784 | 1.5604222503534768 | 1.59E-15 | 14 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.11866013013048522 | 0.1186601301304856 | 3.77E-16 | 14 | passed |
/fit/coefficients/2/lower | tolerance | -0.25087051732479604 | -0.25087051732479737 | 1.33E-15 | 14 | passed |
/fit/coefficients/2/upper | tolerance | 2.2104352070475288 | 2.210435207047529 | 2.72E-17 | 16 | passed |
/fit/coefficients/2/ratio | tolerance | 2.6638763724447725 | 2.663876372444771 | 1.34E-15 | 15 | passed |
/fit/coefficients/2/ratio_lower | tolerance | 0.77812311849934623 | 0.7781231184993452 | 9.96E-16 | 14 | passed |
/fit/coefficients/2/ratio_upper | tolerance | 9.1196844804650059 | 9.119684480465006 | 4.65E-18 | 18 | passed |
/fit/thresholds/0/estimate | tolerance | 0.030478131124535568 | 0.030478131124535523 | 4.52E-17 | 14 | passed |
/fit/thresholds/0/standard_error | tolerance | 0.57152136702059819 | 0.5715213670205983 | 1.13E-16 | 15 | passed |
/fit/thresholds/0/statistic | tolerance | 0.053328069400836779 | 0.05332806940083669 | 9.00E-17 | 14 | passed |
/fit/thresholds/0/p_value | tail_probability | 0.95747051586844811 | 0.9574705158684482 | 1.14E-16 | 15 | passed |
/fit/thresholds/0/lower | tolerance | -1.0896831646309346 | -1.089683164630935 | 4.64E-16 | 15 | passed |
/fit/thresholds/0/upper | tolerance | 1.1506394268800055 | 1.150639426880006 | 4.78E-16 | 15 | passed |
/fit/thresholds/1/estimate | tolerance | 1.4641814184907009 | 1.4641814184907007 | 1.85E-16 | 15 | passed |
/fit/thresholds/1/standard_error | tolerance | 0.72267243689182326 | 0.7226724368918233 | 4.50E-18 | 17 | passed |
/fit/thresholds/1/statistic | tolerance | 2.0260651212713596 | 2.0260651212713596 | 2.59E-17 | 16 | passed |
/fit/thresholds/1/p_value | tail_probability | 0.042758111734708226 | 0.04275811173470819 | 3.45E-17 | 15 | passed |
/fit/thresholds/1/lower | tolerance | 0.047769469562932487 | 0.04776946956293204 | 4.44E-16 | 14 | passed |
/fit/thresholds/1/upper | tolerance | 2.8805933674184692 | 2.880593367418469 | 3.60E-17 | 16 | passed |
/fit/term_tests/[term=grp]/df | exact | 2 | 2 | 0.00E+2 | passed | |
/fit/term_tests/[term=grp]/statistic | tolerance | 1.1998909649005423 | 1.1998909649005396 | 2.71E-15 | 14 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.54884155677528268 | 0.5488415567752835 | 7.77E-16 | 14 | passed |
/fit/term_tests/[term=x]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/fit/term_tests/[term=x]/statistic | tolerance | 2.4349175993982137 | 2.4349175993982093 | 4.41E-15 | 14 | passed |
/fit/term_tests/[term=x]/p_value | tail_probability | 0.1186601301304851 | 0.11866013013048579 | 6.91E-16 | 14 | passed |
/fit/term_tests/[term=All predictors]/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/term_tests/[term=All predictors]/statistic | tolerance | 7.3319800737141394 | 7.3319800737141385 | 8.87E-16 | 15 | passed |
/fit/term_tests/[term=All predictors]/p_value | tail_probability | 0.062036457148691958 | 0.06203645714869201 | 5.53E-17 | 15 | passed |
/fit/rows_used | exact | 30 | 30 | 0.00E+2 | passed | |
/fit/rank | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Normal reference for every coefficient; D = 8 shown for reference only.
- svyolr(factor(ord, levels = c('low', 'mid', 'high')) ~ grp + x): logit P(Y <= j) = zeta_j - eta, the engine's threshold_j - x'b.
- Thresholds low|mid and mid|high are listed before the coefficients; term Wald chi-square b' V^-1 b from the design covariance.
- Reference: svyolr (BFGS, reltol 1e-15) cross-checked against an R Newton refinement of the same weighted log-likelihood (parameter step below 1e-12, likelihood not below svyolr's, parameters within 1e-3, svyrecvar design covariance within 1e-3 of svyolr's own); the refined values are compared because svyolr's function-value stopping leaves the near-null grpb direction resolved only to about 1e-4, while the engine's Newton stops on the parameter step (1e-10). Agreement expected between the two parameter-converged fits: outputs allow 1e-7 absolute or 1e-6 relative (p-values 1e-5 relative).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
413 ordinal_case("STAT-REG-SURVEY-ORD-001", "Survey proportional-odds regression (Taylor)",
414 taylor, design_taylor, D_T, 0.95, list(),
415 c("Normal reference for every coefficient; D = 8 shown for reference only."), "nominal")
Survey proportional-odds regression in a domain with 90% intervals
Case STAT-REG-SURVEY-ORD-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survey package: svydesign, svrepdesign, svyglm, svyolr, svycoxph, regTermTest
- Citation
- Lumley, T. (2024). survey: analysis of complex survey samples. R package version 4.5; Binder (1983, 1992); Lumley (2010) Complex Surveys, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survey 4.5, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/regression_survey_models.R · sha256 6c4d50bfb5529493
- Dataset
- reference_data/datasets/REG_SURVEY_B7.json
Settings compared
confidence_level= 0.9covariates= ["x"]design= {"weight": "w", "variance": "linearization", "stage1": {"strata": "h", "units": "psu"}}domain_column= "dom"domain_values= ["A"]factors= ["grp"]level_order= ["low", "mid", "high"]response= "ord"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fit/coefficients/0/estimate | tolerance | 1.2575085493494313 | 1.2575085493494322 | 9.36E-16 | 15 | passed |
/fit/coefficients/0/standard_error | tolerance | 1.9339973860837509 | 1.9339973860837427 | 8.18E-15 | 14 | passed |
/fit/coefficients/0/statistic | tolerance | 0.65021212458607502 | 0.6502121245860782 | 3.22E-15 | 14 | passed |
/fit/coefficients/0/p_value | tail_probability | 0.51555521030238438 | 0.5155552103023824 | 2.00E-15 | 14 | passed |
/fit/coefficients/0/lower | tolerance | -1.9236340656650919 | -1.9236340656650786 | 1.33E-14 | 14 | passed |
/fit/coefficients/0/upper | tolerance | 4.4386511643639546 | 4.438651164363943 | 1.16E-14 | 14 | passed |
/fit/coefficients/0/ratio | tolerance | 3.5166490063467313 | 3.5166490063467344 | 3.09E-15 | 15 | passed |
/fit/coefficients/0/ratio_lower | tolerance | 0.14607514970891794 | 0.14607514970891988 | 1.94E-15 | 13 | passed |
/fit/coefficients/0/ratio_upper | tolerance | 84.660671294759268 | 84.6606712947583 | 9.66E-13 | 13 | passed |
/fit/coefficients/1/estimate | tolerance | -0.00019148310635745192 | -0.00019148310635658174 | 8.70E-16 | 11 | passed |
/fit/coefficients/1/standard_error | tolerance | 1.0105061477003414 | 1.0105061477003368 | 4.65E-15 | 14 | passed |
/fit/coefficients/1/statistic | tolerance | -0.000189492272553927 | -0.00018949227255306677 | 8.60E-16 | 11 | passed |
/fit/coefficients/1/p_value | tail_probability | 0.99984880704224255 | 0.9998488070422433 | 7.76E-16 | 15 | passed |
/fit/coefficients/1/lower | tolerance | -1.6623261852080233 | -1.6623261852080156 | 7.74E-15 | 14 | passed |
/fit/coefficients/1/upper | tolerance | 1.6619432189953085 | 1.6619432189953025 | 5.99E-15 | 14 | passed |
/fit/coefficients/1/ratio | tolerance | 0.9998085352253625 | 0.9998085352253634 | 8.93E-16 | 15 | passed |
/fit/coefficients/1/ratio_lower | tolerance | 0.18969719565397625 | 0.18969719565397772 | 1.47E-15 | 14 | passed |
/fit/coefficients/1/ratio_upper | tolerance | 5.2695407734591457 | 5.269540773459115 | 3.11E-14 | 14 | passed |
/fit/coefficients/2/estimate | tolerance | 0.37937995879613845 | 0.37937995879613867 | 2.22E-16 | 15 | passed |
/fit/coefficients/2/standard_error | tolerance | 1.3757306649759442 | 1.3757306649759413 | 2.88E-15 | 14 | passed |
/fit/coefficients/2/statistic | tolerance | 0.27576615718075326 | 0.27576615718075403 | 7.75E-16 | 14 | passed |
/fit/coefficients/2/p_value | tail_probability | 0.78272767879298555 | 0.782727678792985 | 5.57E-16 | 15 | passed |
/fit/coefficients/2/lower | tolerance | -1.883495615197903 | -1.8834956151978992 | 3.79E-15 | 14 | passed |
/fit/coefficients/2/upper | tolerance | 2.64225553279018 | 2.6422555327901764 | 3.56E-15 | 14 | passed |
/fit/coefficients/2/ratio | tolerance | 1.4613781937673724 | 1.4613781937673729 | 4.79E-16 | 15 | passed |
/fit/coefficients/2/ratio_lower | tolerance | 0.15205764065290234 | 0.1520576406529029 | 5.52E-16 | 14 | passed |
/fit/coefficients/2/ratio_upper | tolerance | 14.044846520364747 | 14.044846520364697 | 5.02E-14 | 14 | passed |
/fit/thresholds/0/estimate | tolerance | -0.52360386930507496 | -0.523603869305074 | 9.94E-16 | 14 | passed |
/fit/thresholds/0/standard_error | tolerance | 1.3550015871448218 | 1.3550015871448156 | 6.24E-15 | 14 | passed |
/fit/thresholds/0/statistic | tolerance | -0.38642306715550179 | -0.38642306715550284 | 1.05E-15 | 14 | passed |
/fit/thresholds/0/p_value | tail_probability | 0.69918336921388591 | 0.6991833692138851 | 7.79E-16 | 14 | passed |
/fit/thresholds/0/lower | tolerance | -2.7523831444452358 | -2.7523831444452256 | 1.02E-14 | 14 | passed |
/fit/thresholds/0/upper | tolerance | 1.7051754058350856 | 1.7051754058350774 | 8.17E-15 | 14 | passed |
/fit/thresholds/1/estimate | tolerance | 1.2438510252035826 | 1.2438510252035835 | 8.82E-16 | 15 | passed |
/fit/thresholds/1/standard_error | tolerance | 1.3150244993186406 | 1.315024499318634 | 6.63E-15 | 14 | passed |
/fit/thresholds/1/statistic | tolerance | 0.94587669343655922 | 0.9458766934365647 | 5.44E-15 | 14 | passed |
/fit/thresholds/1/p_value | tail_probability | 0.34421148222970077 | 0.344211482229698 | 2.77E-15 | 14 | passed |
/fit/thresholds/1/lower | tolerance | -0.9191717920307263 | -0.9191717920307152 | 1.11E-14 | 13 | passed |
/fit/thresholds/1/upper | tolerance | 3.4068738424378915 | 3.406873842437882 | 9.34E-15 | 14 | passed |
/fit/term_tests/[term=grp]/df | exact | 2 | 2 | 0.00E+2 | passed | |
/fit/term_tests/[term=grp]/statistic | tolerance | 0.50705224880612132 | 0.5070522488061223 | 9.99E-16 | 14 | passed |
/fit/term_tests/[term=grp]/p_value | tail_probability | 0.77605947056990199 | 0.7760594705699015 | 4.46E-16 | 15 | passed |
/fit/term_tests/[term=x]/df | exact | 1 | 1 | 0.00E+2 | passed | |
/fit/term_tests/[term=x]/statistic | tolerance | 0.076046973446239896 | 0.07604697344624034 | 4.44E-16 | 14 | passed |
/fit/term_tests/[term=x]/p_value | tail_probability | 0.78272767879298566 | 0.782727678792985 | 6.67E-16 | 15 | passed |
/fit/term_tests/[term=All predictors]/df | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/term_tests/[term=All predictors]/statistic | tolerance | 1.1129108472502891 | 1.1129108472503035 | 1.44E-14 | 13 | passed |
/fit/term_tests/[term=All predictors]/p_value | tail_probability | 0.77395830349196315 | 0.7739583034919597 | 3.44E-15 | 14 | passed |
/fit/rows_used | exact | 17 | 17 | 0.00E+2 | passed | |
/fit/rank | exact | 3 | 3 | 0.00E+2 | passed | |
/fit/design_df | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- svyolr on subset(design, dom == 'A'); qnorm(0.95) intervals.
- svyolr(factor(ord, levels = c('low', 'mid', 'high')) ~ grp + x): logit P(Y <= j) = zeta_j - eta, the engine's threshold_j - x'b.
- Thresholds low|mid and mid|high are listed before the coefficients; term Wald chi-square b' V^-1 b from the design covariance.
- Reference: svyolr (BFGS, reltol 1e-15) cross-checked against an R Newton refinement of the same weighted log-likelihood (parameter step below 1e-12, likelihood not below svyolr's, parameters within 1e-3, svyrecvar design covariance within 1e-3 of svyolr's own); the refined values are compared because svyolr's function-value stopping leaves the near-null grpb direction resolved only to about 1e-4, while the engine's Newton stops on the parameter step (1e-10). Agreement expected between the two parameter-converged fits: outputs allow 1e-7 absolute or 1e-6 relative (p-values 1e-5 relative).
- R re-reads the exported CSV before calculating the reference.
- docs/manual/chapters/87-complex-surveys.tex:77-86: linear/logistic coefficient tests use t with D - rank(X) + 1 df and term tests F with the same denominator; normal/chi-square inference is an explicit alternative.
- docs/manual/chapters/87-complex-surveys.tex:86-89: ordinal proportional-odds and survey Cox models use asymptotic normal/chi-square inference; a positive ordinal coefficient shifts probability toward higher levels; a Cox coefficient exponentiates to a hazard ratio.
Reference code
The lines of the reference script that produce this case's expected values.
416 ordinal_case("STAT-REG-SURVEY-ORD-002", "Survey proportional-odds regression in a domain with 90% intervals",
417 domain_a, design_taylor, D_T, 0.90,
418 list(domain_column = "dom", domain_values = list("A")),
419 c("svyolr on subset(design, dom == 'A'); qnorm(0.95) intervals."), "axis_coverage")
Regression completion STAT-REG-THRESHOLD-BINARY-ABOVE-001
Case STAT-REG-THRESHOLD-BINARY-ABOVE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fit
- Citation
- R stats::glm/lm and car::Anova help pages; Tabelz manual chapters 07 and 08
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_lastmile.R · sha256 512832af1db86a5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]threshold= 0.0840219264120618
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/accuracy | tolerance | 0.93055555555555558 | 0.9305555555555556 | 2.27E-19 | 18 | passed |
Convention
- Threshold is one-third of the nearest probability gap below/above the same R-fitted row.
- Exactly one row's class changes between the paired thresholds.
- The fit uses only the exported CSV.
Reference code
Regression completion STAT-REG-THRESHOLD-BINARY-BELOW-001
Case STAT-REG-THRESHOLD-BINARY-BELOW-001 · status: passed
Reference
- Evidence type
- R
- Source
- R regression fit
- Citation
- R stats::glm/lm and car::Anova help pages; Tabelz manual chapters 07 and 08
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, car 3.1.5, jsonlite 2.0.0
- Reference script
- generators/r/regression_lastmile.R · sha256 512832af1db86a5f
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
event_value= "event"outcome_column= "binary"predictors= ["x"]threshold= 0.0835258752367257
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/accuracy | tolerance | 0.91666666666666663 | 0.9166666666666666 | 3.41E-19 | 18 | passed |
Convention
- Threshold is one-third of the nearest probability gap below/above the same R-fitted row.
- Exactly one row's class changes between the paired thresholds.
- The fit uses only the exported CSV.
Reference code
Regression II STAT-REG-TREE-CLASS-001
Case STAT-REG-TREE-CLASS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
cv_folds= 2max_depth= 1min_samples_leaf= 1numeric_predictors= ["x"]positive_class= "B"response= "class"split_assignment= {"train_row_ids": ["STAT-REG-TREE-CLASS-001:0", "STAT-REG-TREE-CLASS-001:1", "STAT-REG-TREE-CLASS-001:12", "STAT-REG-TREE-CLASS-001:13", "STAT-REG-TREE-CLASS-001:14", "STAT-REG-TREE-CLASS-001:15", "STAT-REG-TREE-CLASS-001:16", "STAT-REG-TREE-CLASS-001:17", "STAT-REG-TREE-CLASS-001:20", "STAT-REG-TREE-CLASS-001:21", "STAT-REG-TREE-CLASS-001:22", "STAT-REG-TREE-CLASS-001:23", "STAT-REG-TREE-CLASS-001:24", "STAT-REG-TREE-CLASS-001:25", "STAT-REG-TREE-CLASS-001:28", "STAT-REG-TREE-CLASS-001:29", "STAT-REG-TREE-CLASS-001:30", "STAT-REG-TREE-CLASS-001:31", "STAT-REG-TREE-CLASS-001:32", "STAT-REG-TREE-CLASS-001:33", "STAT-REG-TREE-CLASS-001:36", "STAT-REG-TREE-CLASS-001:37", "STAT-REG-TREE-CLASS-001:38", "STAT-REG-TREE-CLASS-001:39", "STAT-REG-TREE-CLASS-001:4", "STAT-REG-TREE-CLASS-001:5", "STAT-REG-TREE-CLASS-001:6", "STAT-REG-TREE-CLASS-001:7", "STAT-REG-TREE-CLASS-001:8", "STAT-REG-TREE-CLASS-001:9"], "test_row_ids": ["STAT-REG-TREE-CLASS-001:10", "STAT-REG-TREE-CLASS-001:11", "STAT-REG-TREE-CLASS-001:18", "STAT-REG-TREE-CLASS-001:19", "STAT-REG-TREE-CLASS-001:2", "STAT-REG-TREE-CLASS-001:26", "STAT-REG-TREE-CLASS-001:27", "STAT-REG-TREE-CLASS-001:3", "STAT-REG-TREE-CLASS-001:34", "STAT-REG-TREE-CLASS-001:35"], "test_fraction": 0.25, "seed": 0}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/threshold/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/training_metrics/accuracy | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/test_metrics/accuracy | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/source_count | exact | 40 | 40 | 0.00E+2 | passed |
Convention
- A unique numeric split at zero separates both classes; explicit row split is replayable.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
51 tree_class <- rpart::rpart(class ~ x, data = tree, method = "class",
52 control = rpart::rpart.control(cp = 0, xval = 0,
53 minsplit = 2, minbucket = 1,
54 maxdepth = 1))
55 tree_reg <- rpart::rpart(y ~ x, data = tree, method = "anova",
56 control = rpart::rpart.control(cp = 0, xval = 0,
57 minsplit = 2, minbucket = 1,
58 maxdepth = 1))
59 stopifnot(nrow(tree_class$frame) == 3L, nrow(tree_reg$frame) == 3L,
60 abs(tree_class$splits[1L, "index"]) < 1e-12,
61 abs(tree_reg$splits[1L, "index"]) < 1e-12)
62 tree_id <- function(id, i) paste0(id, ":", i - 1L)
63 test_positions <- which((seq_len(nrow(tree)) - 1L) %% 8L %in% c(2L, 3L))
64 train <- sort(vapply(setdiff(seq_len(nrow(tree)), test_positions),
65 function(i) tree_id("STAT-REG-TREE-CLASS-001", i), ""))
Small-sample boundary STAT-REG-TREE-CLASS-MIN-001
Case STAT-REG-TREE-CLASS-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, plm, rpart
- Citation
- R stats::nls/lm, plm::plm, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_a.R · sha256 e69dea823e2a8f59
- Dataset
- reference_data/datasets/REG_MIN_TREE.json
Settings compared
cv_folds= 2max_depth= 1min_samples_leaf= 1numeric_predictors= ["x"]positive_class= "B"response= "class"split_assignment= {"train_row_ids": ["STAT-REG-TREE-CLASS-MIN-001:0", "STAT-REG-TREE-CLASS-MIN-001:1", "STAT-REG-TREE-CLASS-MIN-001:2", "STAT-REG-TREE-CLASS-MIN-001:4", "STAT-REG-TREE-CLASS-MIN-001:5", "STAT-REG-TREE-CLASS-MIN-001:6"], "test_row_ids": ["STAT-REG-TREE-CLASS-MIN-001:3", "STAT-REG-TREE-CLASS-MIN-001:7"], "test_fraction": 0.25, "seed": 0}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/threshold/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/source_count | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- Six explicit training rows contain three per class; two held-out rows contain one per class.
- rpart uses cp=0, xval=0, minsplit=2, minbucket=1, maxdepth=1.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
68 tree <- data.frame(x=rep(c(-1,1),each=4L),class=rep(c("A","B"),each=4L),
69 y=rep(c(-2,2),each=4L))
70 export_dataset(tree,"REG_MIN_TREE","Eight rows in two pure CART classes",
71 "R rpart unique-split classification and regression tree",
72 "Constructed validation data; no third-party license.",
73 c(x="Float64",class="String",y="Float64"))
74 t <- read_dataset("REG_MIN_TREE")
75 train <- c(1L,2L,3L,5L,6L,7L)
76 fit <- rpart::rpart(class~x,data=t[train,],method="class",
77 control=rpart::rpart.control(cp=0,xval=0,minsplit=2,
78 minbucket=1,maxdepth=1))
79 id <- "STAT-REG-TREE-CLASS-MIN-001"
Regression edge STAT-REG-TREE-CLASS-ONECLASS-001
Case STAT-REG-TREE-CLASS-ONECLASS-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic design condition
- Citation
- Tabelz manual regression model design conditions; R stats/plm references
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_b.R · sha256 4a5d01b584989ad6
- Dataset
- reference_data/datasets/REG_EDGE_TREE_ONECLASS.json
Settings compared
cv_folds= 2max_depth= 1min_samples_leaf= 1numeric_predictors= ["x"]positive_class= "B"response= "class"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A classification tree requires two observed response classes before splitting.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
51 tree <- read_dataset("REG_MIN_TREE")
52 tree$class <- rep("A",nrow(tree))
53 export_dataset(tree,"REG_EDGE_TREE_ONECLASS","Constant class response for a classification tree",
54 "Analytic two-class requirement",
55 "Constructed validation data; no third-party license.",
56 c(x="Float64",class="String",y="Float64"))
57 emit("STAT-REG-TREE-CLASS-ONECLASS-001","STAT-REG-TREE-CLASS-001",
58 "REG_EDGE_TREE_ONECLASS",
59 list(response="class",numeric_predictors=list("x"),positive_class="B",
60 cv_folds=2L,max_depth=1L,min_samples_leaf=1L),
61 error=err("RuntimeError","at least two classes"),
62 note="A classification tree requires two observed response classes before splitting.")
True minimum sample STAT-REG-TREE-CLASS-TRUE-MIN-001
Case STAT-REG-TREE-CLASS-TRUE-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats/rpart/pls and analytic sample conditions
- Citation
- R stats::lm, rpart::rpart, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_true_min.R · sha256 f10363ad1ec76730
- Dataset
- reference_data/datasets/REG_TRUE_MIN_CLASS_TREE.json
Settings compared
cv_folds= 2max_depth= 1min_samples_leaf= 1numeric_predictors= ["x"]positive_class= "B"response= "class"split_assignment= {"train_row_ids": ["STAT-REG-TREE-CLASS-TRUE-MIN-001:0", "STAT-REG-TREE-CLASS-TRUE-MIN-001:1", "STAT-REG-TREE-CLASS-TRUE-MIN-001:3", "STAT-REG-TREE-CLASS-TRUE-MIN-001:4"], "test_row_ids": ["STAT-REG-TREE-CLASS-TRUE-MIN-001:2", "STAT-REG-TREE-CLASS-TRUE-MIN-001:5"], "test_fraction": 0.333333333333333, "seed": 0}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/threshold/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/source_count | exact | 6 | 6 | 0.00E+2 | passed |
Convention
- Each class supplies two training rows for two-fold CV and one test row; n=6 is minimal.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
52 tree <- data.frame(x=c(-1,-1,-1,1,1,1),class=c("A","A","A","B","B","B"),
53 y=c(-2,-2,-2,2,2,2))
54 export_dataset(tree,"REG_TRUE_MIN_CLASS_TREE","Three rows in each pure class",
55 "R rpart unique two-leaf split at the smallest CV-valid stratified sample",
56 "Constructed validation data; no third-party license.",
57 c(x="Float64",class="String",y="Float64"))
58 t <- read_dataset("REG_TRUE_MIN_CLASS_TREE")
59 train <- c(1L,2L,4L,5L); test <- c(3L,6L)
60 fit <- rpart::rpart(class~x,data=t[train,],method="class",
61 control=rpart::rpart.control(cp=0,xval=0,minsplit=2,
62 minbucket=1,maxdepth=1))
63 id <- "STAT-REG-TREE-CLASS-TRUE-MIN-001"
Regression II STAT-REG-TREE-REG-001
Case STAT-REG-TREE-REG-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
cv_folds= 2depth_grid= [1]max_depth= 1min_leaf_grid= [1]numeric_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/artifact/threshold/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/artifact/value/1 | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/artifact/value/2 | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/source_count | exact | 40 | 40 | 0.00E+2 | passed |
Convention
- Response is exactly constant on each side; random holdout cannot change leaf means.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
80 emit("STAT-REG-TREE-REG-001", "tabelz.executor.regression_tree",
81 "regressionTreeMenuItem", "REG_TREE",
82 list(response = "y", numeric_predictors = list("x"), cv_folds = 2L,
83 max_depth = 1L, depth_grid = list(1L), min_leaf_grid = list(1L)),
84 list("/artifact/threshold/0" = tol(tree_reg$splits[1L, "index"], "unique CART split", "1e-12"),
85 "/artifact/value/1" = tol(-2, "left-leaf mean", "1e-12"),
86 "/artifact/value/2" = tol(2, "right-leaf mean", "1e-12"),
87 "/source_count" = exact(as.integer(nrow(tree)), "complete source rows")),
88 list("Response is exactly constant on each side; random holdout cannot change leaf means."),
89 kind = "hard_numeric", deferred = list(list(path = "/split",
90 reason = "No explicit split assignment exists for regression trees; NumPy chooses held-out identities.")))
Regression edge STAT-REG-TREE-REG-CONSTANT-001
Case STAT-REG-TREE-REG-CONSTANT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats/rpart
- Citation
- R nlme::lme, plm::plm, stats::nls/lm/step, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_a.R · sha256 b8ea61b61080b6f8
- Dataset
- reference_data/datasets/REG_EDGE_TREE_CONSTANT.json
Settings compared
cv_folds= 2depth_grid= [1]max_depth= 1min_leaf_grid= [1]numeric_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 8 | 8 | 0.00E+2 | passed | |
/artifact/value/0 | tolerance | 7 | 7.0 | 0.00E+2 | passed |
Convention
- With zero response variance, R rpart produces one leaf of value seven.
- The random holdout cannot change the constant training response.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
76 tree <- data.frame(x=c(-2,-1,0,1,2,3,4,5),y=rep(7,8L))
77 export_dataset(tree,"REG_EDGE_TREE_CONSTANT","Constant-response regression tree",
78 "R rpart no-split leaf mean boundary",
79 "Constructed validation data; no third-party license.",
80 c(x="Float64",y="Float64"))
81 t <- read_dataset("REG_EDGE_TREE_CONSTANT")
82 fit <- rpart::rpart(y~x,data=t,method="anova",
83 control=rpart::rpart.control(cp=0,xval=0,minsplit=2,minbucket=1))
84 emit("STAT-REG-TREE-REG-CONSTANT-001","tabelz.executor.regression_tree",
85 "regressionTreeMenuItem","REG_EDGE_TREE_CONSTANT",
86 list(response="y",numeric_predictors=list("x"),cv_folds=2L,max_depth=1L,
87 depth_grid=list(1L),min_leaf_grid=list(1L)),
88 list("/source_count"=exact(as.integer(nrow(t)),"all eight constant-response rows"),
89 "/artifact/value/0"=tol(fit$frame$yval[1L],"constant-response root leaf mean","1e-9")),
90 c("With zero response variance, R rpart produces one leaf of value seven.",
91 "The random holdout cannot change the constant training response."))
Small-sample boundary STAT-REG-TREE-REG-MIN-001
Case STAT-REG-TREE-REG-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, plm, rpart
- Citation
- R stats::nls/lm, plm::plm, rpart::rpart documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_a.R · sha256 e69dea823e2a8f59
- Dataset
- reference_data/datasets/REG_MIN_TREE.json
Settings compared
cv_folds= 2depth_grid= [1]max_depth= 1min_leaf_grid= [1]numeric_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 8 | 8 | 0.00E+2 | passed |
Convention
- R full-sample split is uniquely at zero, but the engine's split and CV folds use NumPy RNG.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
80 make_ids <- function(idx) as.list(sort(paste0(id,":",idx-1L)))
81 emit(id,"tabelz.executor.classification_tree","classificationTreeMenuItem",
82 "REG_MIN_TREE",
83 list(response="class",numeric_predictors=list("x"),positive_class="B",cv_folds=2L,
84 max_depth=1L,min_samples_leaf=1L,
85 split_assignment=list(train_row_ids=make_ids(train),
86 test_row_ids=make_ids(c(4L,8L)),test_fraction=0.25,seed=0L)),
87 list("/artifact/threshold/0"=tol(fit$splits[1L,"index"],"unique split at zero"),
88 "/source_count"=exact(nrow(t),"eight complete rows")),
89 c("Six explicit training rows contain three per class; two held-out rows contain one per class.",
90 "rpart uses cp=0, xval=0, minsplit=2, minbucket=1, maxdepth=1."))
91 fit <- rpart::rpart(y~x,data=t,method="anova",
92 control=rpart::rpart.control(cp=0,xval=0,minsplit=2,
93 minbucket=1,maxdepth=1))
94 emit("STAT-REG-TREE-REG-MIN-001","tabelz.executor.regression_tree",
95 "regressionTreeMenuItem","REG_MIN_TREE",
96 list(response="y",numeric_predictors=list("x"),cv_folds=2L,max_depth=1L,
97 depth_grid=list(1L),min_leaf_grid=list(1L)),
98 list("/source_count"=exact(nrow(t),"eight complete rows")),
99 c("R full-sample split is uniquely at zero, but the engine's split and CV folds use NumPy RNG."),
100 deferred=list(list(path="/artifact/threshold/0",
101 reason="The regression-tree API does not expose an explicit split assignment.")))
True minimum sample STAT-REG-TREE-REG-TRUE-MIN-001
Case STAT-REG-TREE-REG-TRUE-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats/rpart/pls and analytic sample conditions
- Citation
- R stats::lm, rpart::rpart, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_true_min.R · sha256 f10363ad1ec76730
- Dataset
- reference_data/datasets/REG_TRUE_MIN_REG_TREE.json
Settings compared
cv_folds= 2depth_grid= [1]max_depth= 1min_leaf_grid= [1]numeric_predictors= ["x"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- One held-out row leaves two training rows for two-fold CV; fitted split depends on NumPy holdout.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
73 reg <- data.frame(x=c(-1,1,2),y=c(-2,2,3))
74 export_dataset(reg,"REG_TRUE_MIN_REG_TREE","Three finite regression-tree rows",
75 "R rpart small-sample regression-tree estimability",
76 "Constructed validation data; no third-party license.",
77 c(x="Float64",y="Float64"))
78 r <- read_dataset("REG_TRUE_MIN_REG_TREE")
79 emit("STAT-REG-TREE-REG-TRUE-MIN-001","STAT-REG-TREE-REG-001",
80 "REG_TRUE_MIN_REG_TREE",
81 list(response="y",numeric_predictors=list("x"),cv_folds=2L,max_depth=1L,
82 depth_grid=list(1L),min_leaf_grid=list(1L)),
83 list("/source_count"=exact(as.integer(nrow(r)),"three finite tree rows")),
84 "One held-out row leaves two training rows for two-fold CV; fitted split depends on NumPy holdout.",
85 deferred=list(list(path="/artifact/threshold/0",
86 reason="The API does not expose the regression-tree training split.")))
Regression II STAT-REG-TREE-SCORE-CLASS-001
Case STAT-REG-TREE-SCORE-CLASS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "class_order": ["A", "B"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "class_probabilities": [[0.5, 0.5], [1, 0], [0, 1]], "n_node_samples": [40, 20, 20], "encoding": {"numeric_predictors": ["x"], "categorical_predictors": [], "categorical_levels": [], "feature_names": ["x"]}}row_ids= ["STAT-REG-TREE-SCORE-CLASS-001:0", "STAT-REG-TREE-SCORE-CLASS-001:1", "STAT-REG-TREE-SCORE-CLASS-001:2", "STAT-REG-TREE-SCORE-CLASS-001:3", "STAT-REG-TREE-SCORE-CLASS-001:4", "STAT-REG-TREE-SCORE-CLASS-001:5", "STAT-REG-TREE-SCORE-CLASS-001:6", "STAT-REG-TREE-SCORE-CLASS-001:7", "STAT-REG-TREE-SCORE-CLASS-001:8", "STAT-REG-TREE-SCORE-CLASS-001:9", "STAT-REG-TREE-SCORE-CLASS-001:10", "STAT-REG-TREE-SCORE-CLASS-001:11", "STAT-REG-TREE-SCORE-CLASS-001:12", "STAT-REG-TREE-SCORE-CLASS-001:13", "STAT-REG-TREE-SCORE-CLASS-001:14", "STAT-REG-TREE-SCORE-CLASS-001:15", "STAT-REG-TREE-SCORE-CLASS-001:16", "STAT-REG-TREE-SCORE-CLASS-001:17", "STAT-REG-TREE-SCORE-CLASS-001:18", "STAT-REG-TREE-SCORE-CLASS-001:19", "STAT-REG-TREE-SCORE-CLASS-001:20", "STAT-REG-TREE-SCORE-CLASS-001:21", "STAT-REG-TREE-SCORE-CLASS-001:22", "STAT-REG-TREE-SCORE-CLASS-001:23", "STAT-REG-TREE-SCORE-CLASS-001:24", "STAT-REG-TREE-SCORE-CLASS-001:25", "STAT-REG-TREE-SCORE-CLASS-001:26", "STAT-REG-TREE-SCORE-CLASS-001:27", "STAT-REG-TREE-SCORE-CLASS-001:28", "STAT-REG-TREE-SCORE-CLASS-001:29", "STAT-REG-TREE-SCORE-CLASS-001:30", "STAT-REG-TREE-SCORE-CLASS-001:31", "STAT-REG-TREE-SCORE-CLASS-001:32", "STAT-REG-TREE-SCORE-CLASS-001:33", "STAT-REG-TREE-SCORE-CLASS-001:34", "STAT-REG-TREE-SCORE-CLASS-001:35", "STAT-REG-TREE-SCORE-CLASS-001:36", "STAT-REG-TREE-SCORE-CLASS-001:37", "STAT-REG-TREE-SCORE-CLASS-001:38", "STAT-REG-TREE-SCORE-CLASS-001:39"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/tree_score | exact | A | A | passed | ||
/1/tree_score | absent | None | passed | |||
/2/tree_score | exact | A | A | passed | ||
/2/__tabelz_row_id | exact | STAT-REG-TREE-SCORE-CLASS-001:2 | STAT-REG-TREE-SCORE-CLASS-001:2 | passed |
Convention
- R rpart pure split; active exclusion affects only the selected target row.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
93 reg_rows <- as.list(vapply(seq_len(nrow(tree) - 1L), function(i) tree_id(reg_op_id, i), ""))
94 reg_art <- list(feature_order = list("x"), children_left = list(1L, -1L, -1L),
95 children_right = list(2L, -1L, -1L), feature = list(0L, -2L, -2L),
96 threshold = list(0, 0, 0), value = list(0, -2, 2),
97 n_node_samples = list(40L, 20L, 20L))
98 emit(reg_op_id, "operation:tabelz.regression_tree_scores", "regressionTreeMenuItem",
99 "REG_TREE", list(artifact = reg_art, row_ids = reg_rows),
100 list("/0/tree_score" = tol(-2, "first row follows left leaf", "1e-12"),
101 "/1/tree_score" = tol(2, "second row follows right leaf", "1e-12"),
102 "/0/__tabelz_row_id" = exact(tree_id(reg_op_id, 1L), "retained row identity"),
103 "/39/tree_score" = absent("unfitted final row must receive null")),
104 list("R rpart two-leaf model stored as the documented immutable numeric artifact."),
105 kind = "row_alignment")
106 class_op_id <- "STAT-REG-TREE-SCORE-CLASS-001"
Retained scoring boundary STAT-REG-TREE-SCORE-CLASS-MISSING-001
Case STAT-REG-TREE-SCORE-CLASS-MISSING-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls and analytic retained tree
- Citation
- R MASS::lda, pls::plsr and rpart::rpart documentation; Tabelz retained-artifact contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_boundaries.R · sha256 9a546ee72b8c92a9
- Dataset
- reference_data/datasets/REG_SCORE_BOUND_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "class_order": ["A", "B"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "class_probabilities": [[0.5, 0.5], [1, 0], [0, 1]], "n_node_samples": [40, 20, 20], "encoding": {"numeric_predictors": ["x"], "categorical_predictors": [], "categorical_levels": [], "feature_names": ["x"]}}row_ids= ["STAT-REG-TREE-SCORE-CLASS-MISSING-001:0", "STAT-REG-TREE-SCORE-CLASS-MISSING-001:1", "STAT-REG-TREE-SCORE-CLASS-MISSING-001:2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/1/tree_score | absent | None | passed |
Convention
- Stored two-leaf CART artifact has threshold zero and pure A/B leaves.
- No tree is refitted for scoring.
- R re-reads the exported CSV.
Reference code
Whole script generators/r/regression_advanced_score_boundaries.R
Retained scoring boundary STAT-REG-TREE-SCORE-CLASS-THRESHOLD-001
Case STAT-REG-TREE-SCORE-CLASS-THRESHOLD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls and analytic retained tree
- Citation
- R MASS::lda, pls::plsr and rpart::rpart documentation; Tabelz retained-artifact contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_boundaries.R · sha256 9a546ee72b8c92a9
- Dataset
- reference_data/datasets/REG_SCORE_BOUND_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "class_order": ["A", "B"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "class_probabilities": [[0.5, 0.5], [1, 0], [0, 1]], "n_node_samples": [40, 20, 20], "encoding": {"numeric_predictors": ["x"], "categorical_predictors": [], "categorical_levels": [], "feature_names": ["x"]}}row_ids= ["STAT-REG-TREE-SCORE-CLASS-THRESHOLD-001:0", "STAT-REG-TREE-SCORE-CLASS-THRESHOLD-001:1", "STAT-REG-TREE-SCORE-CLASS-THRESHOLD-001:2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/tree_score | exact | A | A | passed |
Convention
- Stored two-leaf CART artifact has threshold zero and pure A/B leaves.
- No tree is refitted for scoring.
- R re-reads the exported CSV.
Reference code
Whole script generators/r/regression_advanced_score_boundaries.R
True minimum sample STAT-REG-TREE-SCORE-CLASS-TRUE-MIN-001
Case STAT-REG-TREE-SCORE-CLASS-TRUE-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats/rpart/pls and analytic sample conditions
- Citation
- R stats::lm, rpart::rpart, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_true_min.R · sha256 f10363ad1ec76730
- Dataset
- reference_data/datasets/REG_SCORE_MID_DA.json
Settings compared
artifact= {"feature_order": ["x"], "class_order": ["A", "B"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "class_probabilities": [[0.5, 0.5], [1, 0], [0, 1]], "n_node_samples": [40, 20, 20], "encoding": {"numeric_predictors": ["x"], "categorical_predictors": [], "categorical_levels": [], "feature_names": ["x"]}}row_ids= ["STAT-REG-TREE-SCORE-CLASS-TRUE-MIN-001:0"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/tree_score | exact | A | A | passed |
Convention
- The retained classification-tree operation accepts one row ID; x equal to threshold zero follows <= left.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
87 id <- "STAT-REG-TREE-SCORE-CLASS-TRUE-MIN-001"
Regression II STAT-REG-TREE-SCORE-REG-001
Case STAT-REG-TREE-SCORE-REG-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart/MASS/pls
- Citation
- R rpart::rpart, MASS::lda/qda, pls::plsr documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_scoring.R · sha256 b719391a082cd335
- Dataset
- reference_data/datasets/REG_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "value": [0, -2, 2], "n_node_samples": [40, 20, 20]}row_ids= ["STAT-REG-TREE-SCORE-REG-001:0", "STAT-REG-TREE-SCORE-REG-001:1", "STAT-REG-TREE-SCORE-REG-001:2", "STAT-REG-TREE-SCORE-REG-001:3", "STAT-REG-TREE-SCORE-REG-001:4", "STAT-REG-TREE-SCORE-REG-001:5", "STAT-REG-TREE-SCORE-REG-001:6", "STAT-REG-TREE-SCORE-REG-001:7", "STAT-REG-TREE-SCORE-REG-001:8", "STAT-REG-TREE-SCORE-REG-001:9", "STAT-REG-TREE-SCORE-REG-001:10", "STAT-REG-TREE-SCORE-REG-001:11", "STAT-REG-TREE-SCORE-REG-001:12", "STAT-REG-TREE-SCORE-REG-001:13", "STAT-REG-TREE-SCORE-REG-001:14", "STAT-REG-TREE-SCORE-REG-001:15", "STAT-REG-TREE-SCORE-REG-001:16", "STAT-REG-TREE-SCORE-REG-001:17", "STAT-REG-TREE-SCORE-REG-001:18", "STAT-REG-TREE-SCORE-REG-001:19", "STAT-REG-TREE-SCORE-REG-001:20", "STAT-REG-TREE-SCORE-REG-001:21", "STAT-REG-TREE-SCORE-REG-001:22", "STAT-REG-TREE-SCORE-REG-001:23", "STAT-REG-TREE-SCORE-REG-001:24", "STAT-REG-TREE-SCORE-REG-001:25", "STAT-REG-TREE-SCORE-REG-001:26", "STAT-REG-TREE-SCORE-REG-001:27", "STAT-REG-TREE-SCORE-REG-001:28", "STAT-REG-TREE-SCORE-REG-001:29", "STAT-REG-TREE-SCORE-REG-001:30", "STAT-REG-TREE-SCORE-REG-001:31", "STAT-REG-TREE-SCORE-REG-001:32", "STAT-REG-TREE-SCORE-REG-001:33", "STAT-REG-TREE-SCORE-REG-001:34", "STAT-REG-TREE-SCORE-REG-001:35", "STAT-REG-TREE-SCORE-REG-001:36", "STAT-REG-TREE-SCORE-REG-001:37", "STAT-REG-TREE-SCORE-REG-001:38"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed | |
/1/tree_score | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/0/__tabelz_row_id | exact | STAT-REG-TREE-SCORE-REG-001:0 | STAT-REG-TREE-SCORE-REG-001:0 | passed | ||
/39/tree_score | absent | None | passed |
Convention
- R rpart two-leaf model stored as the documented immutable numeric artifact.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
92 reg_op_id <- "STAT-REG-TREE-SCORE-REG-001"
Large-offset retained tree scoring
Case STAT-REG-TREE-SCORE-REG-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R rpart and analytic tree traversal
- Citation
- R rpart::rpart documentation and Tabelz retained tree scoring contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, rpart 4.1.27, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_hard_closure.R · sha256 305566a494a873a8
- Dataset
- reference_data/datasets/REG_TREE_SCORE_HARD.json
Settings compared
artifact= {"feature_order": ["x"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [100000000, 0, 0], "value": [1000000, 999999.875, 1000000.125], "n_node_samples": [8, 4, 4]}row_ids= ["STAT-REG-TREE-SCORE-REG-HARD-001:0", "STAT-REG-TREE-SCORE-REG-HARD-001:1", "STAT-REG-TREE-SCORE-REG-HARD-001:2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/tree_score | tolerance | 999999.875 | 999999.875 | 0.00E-1 | passed | |
/1/tree_score | tolerance | 999999.875 | 999999.875 | 0.00E-1 | passed | |
/2/tree_score | tolerance | 999999.875 | 999999.875 | 0.00E-1 | passed |
Convention
- R rpart on eight pure training rows yields a unique split at 1e8.
- Leaf responses are 1e6 plus/minus 0.125; stored artifact uses the R leaf means.
- Manual chapter 15: score rows are rounded to IEEE float32 before routing, as the fit was.
- R re-reads the exported scoring CSV.
Reference code
The lines of the reference script that produce this case's expected values.
1 source("common.R",local=TRUE)
2 run <- generator_run(c("stats","rpart","jsonlite"))
3 tol <- function(x,note) list(comparison="tolerance",value=dec(unname(x)),
4 absolute_tolerance="0",relative_tolerance="1e-9",rationale=note)
5 score <- data.frame(x=c(1e8-1,1e8,1e8+1),y=c(1e6-0.125,1e6-0.125,1e6+0.125))
6 export_dataset(score,"REG_TREE_SCORE_HARD","Large-offset predictor and leaf values",
7 "R rpart unique threshold and analytic retained tree scoring",
8 "Constructed validation data; no third-party license.",
9 c(x="Float64",y="Float64"))
10 score <- read_dataset("REG_TREE_SCORE_HARD")
11 training <- data.frame(x=rep(c(1e8-1,1e8+1),each=4L),
12 y=rep(c(1e6-0.125,1e6+0.125),each=4L))
13 tree <- rpart::rpart(y~x,data=training,method="anova",
14 control=rpart::rpart.control(cp=0,xval=0,minsplit=2,
15 minbucket=1,maxdepth=1))
16 stopifnot(nrow(tree$frame)==3L,abs(tree$splits[1L,"index"]-1e8)<1e-12)
17 id <- "STAT-REG-TREE-SCORE-REG-HARD-001"Whole script generators/r/regression_advanced_hard_closure.R
Retained scoring boundary STAT-REG-TREE-SCORE-REG-MISSING-001
Case STAT-REG-TREE-SCORE-REG-MISSING-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls and analytic retained tree
- Citation
- R MASS::lda, pls::plsr and rpart::rpart documentation; Tabelz retained-artifact contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_boundaries.R · sha256 9a546ee72b8c92a9
- Dataset
- reference_data/datasets/REG_SCORE_BOUND_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "value": [0, -2, 2], "n_node_samples": [40, 20, 20]}row_ids= ["STAT-REG-TREE-SCORE-REG-MISSING-001:0", "STAT-REG-TREE-SCORE-REG-MISSING-001:1", "STAT-REG-TREE-SCORE-REG-MISSING-001:2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/1/tree_score | absent | None | passed |
Convention
- Stored two-leaf regression tree has threshold zero and leaf means -2 and 2.
- No tree is refitted for scoring.
- R re-reads the exported CSV.
Reference code
Whole script generators/r/regression_advanced_score_boundaries.R
Retained scoring boundary STAT-REG-TREE-SCORE-REG-THRESHOLD-001
Case STAT-REG-TREE-SCORE-REG-THRESHOLD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R MASS/pls and analytic retained tree
- Citation
- R MASS::lda, pls::plsr and rpart::rpart documentation; Tabelz retained-artifact contract
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_score_boundaries.R · sha256 9a546ee72b8c92a9
- Dataset
- reference_data/datasets/REG_SCORE_BOUND_TREE.json
Settings compared
artifact= {"feature_order": ["x"], "children_left": [1, -1, -1], "children_right": [2, -1, -1], "feature": [0, -2, -2], "threshold": [0, 0, 0], "value": [0, -2, 2], "n_node_samples": [40, 20, 20]}row_ids= ["STAT-REG-TREE-SCORE-REG-THRESHOLD-001:0", "STAT-REG-TREE-SCORE-REG-THRESHOLD-001:1", "STAT-REG-TREE-SCORE-REG-THRESHOLD-001:2"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/tree_score | tolerance | -2 | -2.0 | 0.00E+2 | passed |
Convention
- Stored two-leaf regression tree has threshold zero and leaf means -2 and 2.
- No tree is refitted for scoring.
- R re-reads the exported CSV.
Reference code
Whole script generators/r/regression_advanced_score_boundaries.R
STAT REG TWO STAGE 001
Case STAT-REG-TWO-STAGE-001 · status: passed
Reference
- Evidence type
- R
- Source
- Base R: solve/crossprod for the IV estimator, stats::lm for first stages and the Sargan auxiliary regression, stats::pt/pf/pchisq
- Citation
- R Core Team, stats package help: lm, summary.lm, pt, pf, pchisq. Wooldridge, Introductory Econometrics, ch. 15 (2SLS, first-stage F, Sargan n R^2).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_two_stage.R · sha256 7494053441fd504b
- Dataset
- reference_data/datasets/REG_IV_01.json
Settings compared
confidence_level= 0.95covariance= "classical"endogenous= ["x"]exogenous= ["w"]instruments= ["z1", "z2"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 29 | 29 | 0.00E+2 | passed | |
/residual_standard_error | tolerance | 0.64012940363212412 | 0.6401294036321247 | 5.52E-16 | 15 | passed |
/r_squared | tolerance | 0.92192794596083327 | 0.921927945960833 | 2.19E-16 | 15 | passed |
/wald_f | tolerance | 102.0859343727042 | 102.08593437270397 | 2.26E-13 | 14 | passed |
/wald_df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/wald_df2 | exact | 26 | 26 | 0.00E+2 | passed | |
/wald_p | tail_probability | 4.8749970266896481e-13 | 4.874997026689796e-13 | 1.47E-26 | 13 | passed |
/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/coefficients/0/role | exact | constant | constant | passed | ||
/coefficients/0/estimate | tolerance | 1.448838547180507 | 1.4488385471805092 | 2.20E-15 | 14 | passed |
/coefficients/0/standard_error | tolerance | 0.23623357134432132 | 0.23623357134432166 | 3.38E-16 | 14 | passed |
/coefficients/0/t_value | tolerance | 6.1330764248945719 | 6.133076424894573 | 9.31E-16 | 15 | passed |
/coefficients/0/p_value | tail_probability | 1.7483277866324688e-06 | 1.748327786632463e-06 | 5.76E-21 | 14 | passed |
/coefficients/0/lower | tolerance | 0.96325348688651313 | 0.9632534868865145 | 1.34E-15 | 14 | passed |
/coefficients/0/upper | tolerance | 1.9344236074745007 | 1.9344236074745038 | 3.11E-15 | 14 | passed |
/coefficients/1/term | exact | w | w | passed | ||
/coefficients/1/role | exact | exogenous | exogenous | passed | ||
/coefficients/1/estimate | tolerance | -0.90159386918586648 | -0.9015938691858666 | 1.12E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.16715121506009187 | 0.16715121506009198 | 1.09E-16 | 15 | passed |
/coefficients/1/t_value | tolerance | -5.3938816350317174 | -5.393881635031714 | 3.59E-15 | 15 | passed |
/coefficients/1/p_value | tail_probability | 1.1919832986486634e-05 | 1.1919832986486771e-05 | 1.37E-19 | 13 | passed |
/coefficients/1/lower | tolerance | -1.2451781124468111 | -1.2451781124468118 | 6.58E-16 | 15 | passed |
/coefficients/1/upper | tolerance | -0.55800962592492176 | -0.5580096259249214 | 3.34E-16 | 15 | passed |
/coefficients/2/term | exact | x | x | passed | ||
/coefficients/2/role | exact | endogenous | endogenous | passed | ||
/coefficients/2/estimate | tolerance | 1.2149163891843449 | 1.2149163891843437 | 1.15E-15 | 15 | passed |
/coefficients/2/standard_error | tolerance | 0.10407263160959149 | 0.1040726316095915 | 1.11E-17 | 15 | passed |
/coefficients/2/t_value | tolerance | 11.673735643986314 | 11.673735643986301 | 1.26E-14 | 14 | passed |
/coefficients/2/p_value | tail_probability | 7.7023964838325291e-12 | 7.702396483832708e-12 | 1.79E-25 | 13 | passed |
/coefficients/2/lower | tolerance | 1.0009920311537948 | 1.0009920311537936 | 1.15E-15 | 14 | passed |
/coefficients/2/upper | tolerance | 1.428840747214895 | 1.4288407472148938 | 1.15E-15 | 15 | passed |
/first_stages/0/r_squared | tolerance | 0.69985915836729351 | 0.6998591583672934 | 1.11E-16 | 15 | passed |
/first_stages/0/partial_r_squared | tolerance | 0.68877348592108967 | 0.6887734859210894 | 2.24E-16 | 15 | passed |
/first_stages/0/f_value | tolerance | 27.663673191515652 | 27.663673191515635 | 1.74E-14 | 15 | passed |
/first_stages/0/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/first_stages/0/df2 | exact | 25 | 25 | 0.00E+2 | passed | |
/first_stages/0/p_value | tail_probability | 4.6074152462148602e-07 | 4.607415246214892e-07 | 3.18E-21 | 14 | passed |
/sargan/statistic | tolerance | 0.67918373487740957 | 0.6791837348774159 | 6.33E-15 | 14 | passed |
/sargan/df | exact | 1 | 1 | 0.00E+2 | passed | |
/sargan/p_value | tail_probability | 0.4098679438281625 | 0.4098679438281604 | 2.11E-15 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Classical covariance s^2 (X_hat'X_hat)^-1; two excluded instruments for one endogenous regressor give a 1-df Sargan test.
- Instruments Z = [1, exogenous, excluded instruments]; X = [1, exogenous, endogenous]; beta = (X'P_Z X)^-1 X'P_Z y; residual variance from u = y - X beta on n - k df; t intervals (docs/manual/chapters/86-regression-and-count-models.tex:90-105).
- HC1 covariance: (X_hat'X_hat)^-1 [sum u_i^2 x_hat_i x_hat_i'] (X_hat'X_hat)^-1 n/(n-k); the Sargan statistic n R^2 of u on Z is unchanged by it; robust first-stage F is the HC1 joint Wald statistic of the excluded instruments divided by their number.
- First-stage F compares the first-stage regression on Z with the regression on the included exogenous regressors; partial R^2 = (RSS_restricted - RSS_full)/RSS_restricted.
- Rows with a missing value in any role are dropped; excluded rows are removed first.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
34 emit <- function(id, kind, config, outputs, notes, excluded = list()) {
35 write_expected("regression", id, list(
36 schema_version = "2.0.0", case_id = id, outputs = outputs,
37 expected_error = NULL, deferred_outputs = list(), generator_run = run))
38 write_case("regression", id, list(
39 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
40 entry_point = "tabelz.analysis.two_stage_least_squares:compute_two_stage",
41 menu_items = list("twoStageLeastSquaresMenuItem"), title = gsub("-", " ", id),
42 case_kind = kind,
43 dataset = list(path = "reference_data/datasets/REG_IV_01.json", sha256 = ""),
44 excluded_rows = excluded, configuration = config, "repeat" = 1L,
45 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
46 oracle = list(
47 oracle_class = "independent_implementation",
48 source = "Base R: solve/crossprod for the IV estimator, stats::lm for first stages and the Sargan auxiliary regression, stats::pt/pf/pchisq",
49 citation = "R Core Team, stats package help: lm, summary.lm, pt, pf, pchisq. Wooldridge, Introductory Econometrics, ch. 15 (2SLS, first-stage F, Sargan n R^2).",
50 generator = list(path = "generators/r/regression_two_stage.R", sha256 = ""),
51 independent = TRUE,
52 convention_notes = c(
53 notes,
54 "Instruments Z = [1, exogenous, excluded instruments]; X = [1, exogenous, endogenous]; beta = (X'P_Z X)^-1 X'P_Z y; residual variance from u = y - X beta on n - k df; t intervals (docs/manual/chapters/86-regression-and-count-models.tex:90-105).",
55 "HC1 covariance: (X_hat'X_hat)^-1 [sum u_i^2 x_hat_i x_hat_i'] (X_hat'X_hat)^-1 n/(n-k); the Sargan statistic n R^2 of u on Z is unchanged by it; robust first-stage F is the HC1 joint Wald statistic of the excluded instruments divided by their number.",
56 "First-stage F compares the first-stage regression on Z with the regression on the included exogenous regressors; partial R^2 = (RSS_restricted - RSS_full)/RSS_restricted.",
57 "Rows with a missing value in any role are dropped; excluded rows are removed first.",
58 "Expected computed from the exported CSV."
59 )),
60 supported = TRUE, unsupported_reason = NULL,
61 requirement_ids = list("REQ-STAT-REG-TWO-STAGE-001"),
62 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
STAT REG TWO STAGE 002
Case STAT-REG-TWO-STAGE-002 · status: passed
Reference
- Evidence type
- R
- Source
- Base R: solve/crossprod for the IV estimator, stats::lm for first stages and the Sargan auxiliary regression, stats::pt/pf/pchisq
- Citation
- R Core Team, stats package help: lm, summary.lm, pt, pf, pchisq. Wooldridge, Introductory Econometrics, ch. 15 (2SLS, first-stage F, Sargan n R^2).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_two_stage.R · sha256 7494053441fd504b
- Dataset
- reference_data/datasets/REG_IV_01.json
Settings compared
confidence_level= 0.95covariance= "hc1"endogenous= ["x"]exogenous= ["w"]instruments= ["z1", "z2"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 29 | 29 | 0.00E+2 | passed | |
/residual_standard_error | tolerance | 0.64012940363212412 | 0.6401294036321247 | 5.52E-16 | 15 | passed |
/r_squared | tolerance | 0.92192794596083327 | 0.921927945960833 | 2.19E-16 | 15 | passed |
/wald_f | tolerance | 128.71116087984973 | 128.71116087984961 | 1.15E-13 | 15 | passed |
/wald_df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/wald_df2 | exact | 26 | 26 | 0.00E+2 | passed | |
/wald_p | tail_probability | 3.2584484556997336e-14 | 3.258448455699767e-14 | 3.34E-28 | 13 | passed |
/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/coefficients/0/role | exact | constant | constant | passed | ||
/coefficients/0/estimate | tolerance | 1.448838547180507 | 1.4488385471805092 | 2.20E-15 | 14 | passed |
/coefficients/0/standard_error | tolerance | 0.29986333446104485 | 0.2998633344610453 | 4.44E-16 | 14 | passed |
/coefficients/0/t_value | tolerance | 4.8316628966477566 | 4.831662896647757 | 1.09E-17 | 17 | passed |
/coefficients/0/p_value | tail_probability | 5.2406693160626065e-05 | 5.240669316062602e-05 | 4.77E-20 | 15 | passed |
/coefficients/0/lower | tolerance | 0.83246063562621553 | 0.8324606356262165 | 9.97E-16 | 14 | passed |
/coefficients/0/upper | tolerance | 2.0652164587347985 | 2.0652164587348016 | 3.14E-15 | 14 | passed |
/coefficients/1/term | exact | w | w | passed | ||
/coefficients/1/role | exact | exogenous | exogenous | passed | ||
/coefficients/1/estimate | tolerance | -0.90159386918586648 | -0.9015938691858666 | 1.12E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.19210593797143458 | 0.1921059379714346 | 2.38E-17 | 15 | passed |
/coefficients/1/t_value | tolerance | -4.6932118741687727 | -4.693211874168773 | 2.37E-17 | 17 | passed |
/coefficients/1/p_value | tail_probability | 7.55420101092384e-05 | 7.554201010923822e-05 | 1.76E-19 | 14 | passed |
/coefficients/1/lower | tolerance | -1.296473280024252 | -1.2964732800242522 | 2.17E-16 | 15 | passed |
/coefficients/1/upper | tolerance | -0.50671445834748108 | -0.506714458347481 | 1.13E-16 | 15 | passed |
/coefficients/2/term | exact | x | x | passed | ||
/coefficients/2/role | exact | endogenous | endogenous | passed | ||
/coefficients/2/estimate | tolerance | 1.2149163891843449 | 1.2149163891843437 | 1.15E-15 | 15 | passed |
/coefficients/2/standard_error | tolerance | 0.10783985091483775 | 0.10783985091483778 | 2.60E-17 | 15 | passed |
/coefficients/2/t_value | tolerance | 11.265931646583757 | 11.265931646583743 | 1.39E-14 | 14 | passed |
/coefficients/2/p_value | tail_probability | 1.6756860531821621e-11 | 1.675686053182208e-11 | 4.59E-25 | 13 | passed |
/coefficients/2/lower | tolerance | 0.9932484009700373 | 0.9932484009700361 | 1.22E-15 | 14 | passed |
/coefficients/2/upper | tolerance | 1.4365843773986524 | 1.4365843773986513 | 1.10E-15 | 15 | passed |
/first_stages/0/r_squared | tolerance | 0.69985915836729351 | 0.6998591583672934 | 1.11E-16 | 15 | passed |
/first_stages/0/partial_r_squared | tolerance | 0.68877348592108967 | 0.6887734859210894 | 2.24E-16 | 15 | passed |
/first_stages/0/f_value | tolerance | 27.663673191515652 | 27.663673191515635 | 1.74E-14 | 15 | passed |
/first_stages/0/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/first_stages/0/df2 | exact | 25 | 25 | 0.00E+2 | passed | |
/first_stages/0/p_value | tail_probability | 4.6074152462148602e-07 | 4.607415246214892e-07 | 3.18E-21 | 14 | passed |
/first_stages/0/robust_f | tolerance | 32.641079551023367 | 32.64107955102336 | 7.22E-15 | 15 | passed |
/first_stages/0/robust_p | tail_probability | 1.0696110960674005e-07 | 1.069611096067404e-07 | 3.56E-22 | 14 | passed |
/sargan/statistic | tolerance | 0.67918373487740957 | 0.6791837348774159 | 6.33E-15 | 14 | passed |
/sargan/df | exact | 1 | 1 | 0.00E+2 | passed | |
/sargan/p_value | tail_probability | 0.4098679438281625 | 0.4098679438281604 | 2.11E-15 | 14 | passed |
Convention
- HC1 coefficient covariance and the robust first-stage F; the Sargan statistic is the homoskedastic n R^2.
- Instruments Z = [1, exogenous, excluded instruments]; X = [1, exogenous, endogenous]; beta = (X'P_Z X)^-1 X'P_Z y; residual variance from u = y - X beta on n - k df; t intervals (docs/manual/chapters/86-regression-and-count-models.tex:90-105).
- HC1 covariance: (X_hat'X_hat)^-1 [sum u_i^2 x_hat_i x_hat_i'] (X_hat'X_hat)^-1 n/(n-k); the Sargan statistic n R^2 of u on Z is unchanged by it; robust first-stage F is the HC1 joint Wald statistic of the excluded instruments divided by their number.
- First-stage F compares the first-stage regression on Z with the regression on the included exogenous regressors; partial R^2 = (RSS_restricted - RSS_full)/RSS_restricted.
- Rows with a missing value in any role are dropped; excluded rows are removed first.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
195 r <- two_stage(d, "x", "w", c("z1", "z2"), "hc1", 0.95)
196 emit("STAT-REG-TWO-STAGE-002", "axis_coverage",
197 list(response = "y", endogenous = list("x"), exogenous = list("w"),
198 instruments = list("z1", "z2"), covariance = "hc1", confidence_level = 0.95),
199 outputs_for(r, c("(Intercept)", "w", "x"), c("constant", "exogenous", "endogenous")),
200 list("HC1 coefficient covariance and the robust first-stage F; the Sargan statistic is the homoskedastic n R^2."))
STAT REG TWO STAGE 003
Case STAT-REG-TWO-STAGE-003 · status: passed
Reference
- Evidence type
- R
- Source
- Base R: solve/crossprod for the IV estimator, stats::lm for first stages and the Sargan auxiliary regression, stats::pt/pf/pchisq
- Citation
- R Core Team, stats package help: lm, summary.lm, pt, pf, pchisq. Wooldridge, Introductory Econometrics, ch. 15 (2SLS, first-stage F, Sargan n R^2).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_two_stage.R · sha256 7494053441fd504b
- Dataset
- reference_data/datasets/REG_IV_01.json
Settings compared
confidence_level= 0.9covariance= "classical"endogenous= ["x"]exogenous= []instruments= ["z1"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 30 | 30 | 0.00E+2 | passed | |
/residual_standard_error | tolerance | 0.8635389823337436 | 0.8635389823337434 | 2.23E-16 | 15 | passed |
/r_squared | tolerance | 0.84753372030924723 | 0.8475337203092472 | 6.48E-19 | 18 | passed |
/wald_f | tolerance | 90.593961207421188 | 90.59396120742136 | 1.70E-13 | 14 | passed |
/wald_df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/wald_df2 | exact | 28 | 28 | 0.00E+2 | passed | |
/wald_p | tail_probability | 2.8309367585977058e-10 | 2.830936758597643e-10 | 6.31E-24 | 13 | passed |
/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/coefficients/0/role | exact | constant | constant | passed | ||
/coefficients/0/estimate | tolerance | 0.47028538121177776 | 0.47028538121177665 | 1.11E-15 | 14 | passed |
/coefficients/0/standard_error | tolerance | 0.21777631344810289 | 0.2177763134481027 | 1.97E-16 | 15 | passed |
/coefficients/0/t_value | tolerance | 2.1594882095561276 | 2.1594882095561245 | 3.07E-15 | 14 | passed |
/coefficients/0/p_value | tail_probability | 0.039527029877812196 | 0.03952702987781244 | 2.43E-16 | 14 | passed |
/coefficients/0/lower | tolerance | 0.09981935765481631 | 0.09981935765481542 | 8.88E-16 | 14 | passed |
/coefficients/0/upper | tolerance | 0.84075140476873922 | 0.8407514047687379 | 1.33E-15 | 14 | passed |
/coefficients/1/term | exact | x | x | passed | ||
/coefficients/1/role | exact | endogenous | endogenous | passed | ||
/coefficients/1/estimate | tolerance | 1.3684306774757937 | 1.3684306774757942 | 4.66E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.14377162348503031 | 0.14377162348503023 | 8.45E-17 | 15 | passed |
/coefficients/1/t_value | tolerance | 9.5180860054646086 | 9.518086005464616 | 7.10E-15 | 15 | passed |
/coefficients/1/p_value | tail_probability | 2.8309367585976857e-10 | 2.830936758597643e-10 | 4.30E-24 | 13 | passed |
/coefficients/1/lower | tolerance | 1.1238563212957744 | 1.123856321295775 | 6.63E-16 | 15 | passed |
/coefficients/1/upper | tolerance | 1.613005033655813 | 1.6130050336558133 | 2.70E-16 | 15 | passed |
/first_stages/0/r_squared | tolerance | 0.62969394492442587 | 0.6296939449244261 | 2.27E-16 | 15 | passed |
/first_stages/0/partial_r_squared | tolerance | 0.62969394492442587 | 0.6296939449244261 | 2.27E-16 | 15 | passed |
/first_stages/0/f_value | tolerance | 47.61313031807056 | 47.613130318070596 | 3.56E-14 | 15 | passed |
/first_stages/0/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/first_stages/0/df2 | exact | 28 | 28 | 0.00E+2 | passed | |
/first_stages/0/p_value | tail_probability | 1.6850561116548277e-07 | 1.6850561116548115e-07 | 1.62E-21 | 14 | passed |
Convention
- Exactly identified (one instrument, one endogenous regressor): the result carries no Sargan test, which the expected outputs therefore omit; 90% t intervals.
- Instruments Z = [1, exogenous, excluded instruments]; X = [1, exogenous, endogenous]; beta = (X'P_Z X)^-1 X'P_Z y; residual variance from u = y - X beta on n - k df; t intervals (docs/manual/chapters/86-regression-and-count-models.tex:90-105).
- HC1 covariance: (X_hat'X_hat)^-1 [sum u_i^2 x_hat_i x_hat_i'] (X_hat'X_hat)^-1 n/(n-k); the Sargan statistic n R^2 of u on Z is unchanged by it; robust first-stage F is the HC1 joint Wald statistic of the excluded instruments divided by their number.
- First-stage F compares the first-stage regression on Z with the regression on the included exogenous regressors; partial R^2 = (RSS_restricted - RSS_full)/RSS_restricted.
- Rows with a missing value in any role are dropped; excluded rows are removed first.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
203 r <- two_stage(d, "x", character(0), "z1", "classical", 0.90)
204 stopifnot(is.null(r$sargan))
205 emit("STAT-REG-TWO-STAGE-003", "axis_coverage",
206 list(response = "y", endogenous = list("x"), exogenous = list(),
207 instruments = list("z1"), covariance = "classical", confidence_level = 0.90),
208 outputs_for(r, c("(Intercept)", "x"), c("constant", "endogenous")),
209 list("Exactly identified (one instrument, one endogenous regressor): the result carries no Sargan test, which the expected outputs therefore omit; 90% t intervals."))
STAT REG TWO STAGE 004
Case STAT-REG-TWO-STAGE-004 · status: passed
Reference
- Evidence type
- R
- Source
- Base R: solve/crossprod for the IV estimator, stats::lm for first stages and the Sargan auxiliary regression, stats::pt/pf/pchisq
- Citation
- R Core Team, stats package help: lm, summary.lm, pt, pf, pchisq. Wooldridge, Introductory Econometrics, ch. 15 (2SLS, first-stage F, Sargan n R^2).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_two_stage.R · sha256 7494053441fd504b
- Dataset
- reference_data/datasets/REG_IV_01.json
Settings compared
confidence_level= 0.99covariance= "hc1"endogenous= ["x"]exogenous= ["w"]instruments= ["z1", "z2"]response= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 27 | 27 | 0.00E+2 | passed | |
/residual_standard_error | tolerance | 0.6634796397059165 | 0.663479639705917 | 4.46E-16 | 15 | passed |
/r_squared | tolerance | 0.91630151220145117 | 0.9163015122014511 | 1.07E-16 | 15 | passed |
/wald_f | tolerance | 98.152110408441132 | 98.15211040844105 | 8.53E-14 | 15 | passed |
/wald_df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/wald_df2 | exact | 24 | 24 | 0.00E+2 | passed | |
/wald_p | tail_probability | 2.7942231458926052e-12 | 2.7942231458926165e-12 | 1.13E-26 | 14 | passed |
/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/coefficients/0/role | exact | constant | constant | passed | ||
/coefficients/0/estimate | tolerance | 1.4482491849433865 | 1.448249184943387 | 4.47E-16 | 15 | passed |
/coefficients/0/standard_error | tolerance | 0.3143152451792533 | 0.31431524517925374 | 4.44E-16 | 14 | passed |
/coefficients/0/t_value | tolerance | 4.6076326463816706 | 4.607632646381665 | 5.35E-15 | 14 | passed |
/coefficients/0/p_value | tail_probability | 0.0001126286930062002 | 0.000112628693006202 | 1.80E-18 | 13 | passed |
/coefficients/0/lower | tolerance | 0.56912845874866413 | 0.5691284587486632 | 8.84E-16 | 14 | passed |
/coefficients/0/upper | tolerance | 2.327369911138109 | 2.3273699111381108 | 1.76E-15 | 15 | passed |
/coefficients/1/term | exact | w | w | passed | ||
/coefficients/1/role | exact | exogenous | exogenous | passed | ||
/coefficients/1/estimate | tolerance | -0.89752491265364487 | -0.8975249126536449 | 1.50E-18 | 17 | passed |
/coefficients/1/standard_error | tolerance | 0.1927282285872054 | 0.1927282285872057 | 3.02E-16 | 14 | passed |
/coefficients/1/t_value | tolerance | -4.6569457895864694 | -4.656945789586462 | 7.07E-15 | 14 | passed |
/coefficients/1/p_value | tail_probability | 9.9349751095310378e-05 | 9.934975109531268e-05 | 2.30E-18 | 13 | passed |
/coefficients/1/lower | tolerance | -1.4365741088744013 | -1.4365741088744022 | 8.78E-16 | 15 | passed |
/coefficients/1/upper | tolerance | -0.35847571643288856 | -0.35847571643288756 | 1.00E-15 | 14 | passed |
/coefficients/2/term | exact | x | x | passed | ||
/coefficients/2/role | exact | endogenous | endogenous | passed | ||
/coefficients/2/estimate | tolerance | 1.2178554429677289 | 1.217855442967728 | 9.36E-16 | 15 | passed |
/coefficients/2/standard_error | tolerance | 0.11892085648814316 | 0.11892085648814321 | 5.17E-17 | 15 | passed |
/coefficients/2/t_value | tolerance | 10.240890277216877 | 10.240890277216865 | 1.22E-14 | 14 | passed |
/coefficients/2/p_value | tail_probability | 3.0816876640204913e-10 | 3.081687664020575e-10 | 8.37E-24 | 13 | passed |
/coefficients/2/lower | tolerance | 0.88524100151442764 | 0.8852410015144265 | 1.11E-15 | 14 | passed |
/coefficients/2/upper | tolerance | 1.5504698844210301 | 1.5504698844210294 | 7.02E-16 | 15 | passed |
/first_stages/0/r_squared | tolerance | 0.68627339819132271 | 0.6862733981913227 | 4.37E-18 | 17 | passed |
/first_stages/0/partial_r_squared | tolerance | 0.6788374742144766 | 0.6788374742144765 | 1.12E-16 | 15 | passed |
/first_stages/0/f_value | tolerance | 24.307415488069282 | 24.30741548806927 | 1.10E-14 | 15 | passed |
/first_stages/0/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/first_stages/0/df2 | exact | 23 | 23 | 0.00E+2 | passed | |
/first_stages/0/p_value | tail_probability | 2.1248875153376344e-06 | 2.124887515337641e-06 | 6.81E-21 | 14 | passed |
/first_stages/0/robust_f | tolerance | 26.623484262367732 | 26.6234842623677 | 3.16E-14 | 14 | passed |
/first_stages/0/robust_p | tail_probability | 1.0334998740138908e-06 | 1.0334998740139014e-06 | 1.06E-20 | 13 | passed |
/sargan/statistic | tolerance | 0.67772871688539005 | 0.6777287168853878 | 2.22E-15 | 14 | passed |
/sargan/df | exact | 1 | 1 | 0.00E+2 | passed | |
/sargan/p_value | tail_probability | 0.41036993111217929 | 0.41036993111218034 | 1.05E-15 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Rows 0 and 5 (0-based) are excluded before the fit; HC1 covariance with 99% intervals.
- Instruments Z = [1, exogenous, excluded instruments]; X = [1, exogenous, endogenous]; beta = (X'P_Z X)^-1 X'P_Z y; residual variance from u = y - X beta on n - k df; t intervals (docs/manual/chapters/86-regression-and-count-models.tex:90-105).
- HC1 covariance: (X_hat'X_hat)^-1 [sum u_i^2 x_hat_i x_hat_i'] (X_hat'X_hat)^-1 n/(n-k); the Sargan statistic n R^2 of u on Z is unchanged by it; robust first-stage F is the HC1 joint Wald statistic of the excluded instruments divided by their number.
- First-stage F compares the first-stage regression on Z with the regression on the included exogenous regressors; partial R^2 = (RSS_restricted - RSS_full)/RSS_restricted.
- Rows with a missing value in any role are dropped; excluded rows are removed first.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
212 r <- two_stage(d[-c(1, 6), ], "x", "w", c("z1", "z2"), "hc1", 0.99)
213 emit("STAT-REG-TWO-STAGE-004", "axis_coverage",
214 list(response = "y", endogenous = list("x"), exogenous = list("w"),
215 instruments = list("z1", "z2"), covariance = "hc1", confidence_level = 0.99),
216 c(outputs_for(r, c("(Intercept)", "w", "x"), c("constant", "exogenous", "endogenous")),
217 list("/missing_count" = exact(1L, "one row has a missing w"),
218 "/excluded_count" = exact(2L, "two rows excluded by identity"))),
219 list("Rows 0 and 5 (0-based) are excluded before the fit; HC1 covariance with 99% intervals."),
220 excluded = list(0L, 5L))
Regression II STAT-REG-VALIDATED-COUNT-001
Case STAT-REG-VALIDATED-COUNT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/plm/stats
- Citation
- R nlme::Orthodont, nlme::lme, plm::plm, stats::nls/lm/step documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_core.R · sha256 b7543c65b2778e63
- Dataset
- reference_data/datasets/REG_ORTHODONT.json
Settings compared
algorithm= "ols"imputation= "drop"numeric_predictors= ["age"]response= "distance"seed= 0test_fraction= 0.25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 108 | 108 | 0.00E+2 | passed | |
/training_metrics/row_count | exact | 81 | 81 | 0.00E+2 | passed | |
/test_metrics/row_count | exact | 27 | 27 | 0.00E+2 | passed |
Convention
- R checks population and deterministic split sizes only; Python NumPy RNG assigns row identities.
- R reference re-reads exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
118 emit("STAT-REG-VALIDATED-COUNT-001",
119 "tabelz.analysis.predictive_validation:compute_validated_regression",
120 "validatedRegressionMenuItem", "REG_ORTHODONT",
121 list(response = "distance", numeric_predictors = list("age"),
122 algorithm = "ols", imputation = "drop", test_fraction = 0.25, seed = 0),
123 list("/source_count" = exact(nrow(d), "complete source population"),
124 "/training_metrics/row_count" = exact(nrow(d) - floor(nrow(d) * 0.25),
125 "training share after 25 percent holdout"),
126 "/test_metrics/row_count" = exact(floor(nrow(d) * 0.25),
127 "test share after 25 percent holdout")),
128 list("R checks population and deterministic split sizes only; Python NumPy RNG assigns row identities."),
129 kind = "determinism",
130 deferred = list(list(path = "/recipe/coefficients",
131 reason = "No explicit split assignment exists; R cannot reproduce NumPy's row permutation.")),
132 repeat_count = 2L)
Small-sample boundary STAT-REG-VALIDATED-MIN-001
Case STAT-REG-VALIDATED-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R nlme/MASS/pls/stats
- Citation
- R nlme::lme, MASS::lda, pls::plsr and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, nlme 3.1.169, MASS 7.3.65, pls 2.9.0, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_minimum_b.R · sha256 e3e09e1965800ae1
- Dataset
- reference_data/datasets/REG_MIN_SELECTION.json
Settings compared
algorithm= "ols"imputation= "drop"numeric_predictors= ["x"]response= "y"seed= 0test_fraction= 0.2
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 5 | 5 | 0.00E+2 | passed | |
/training_metrics/row_count | exact | 4 | 4 | 0.00E+2 | passed | |
/test_metrics/row_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- R checks population and split sizes; NumPy determines the held-out identity.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
55 v <- read_dataset("REG_MIN_SELECTION")
56 emit("STAT-REG-VALIDATED-MIN-001",
57 "tabelz.analysis.predictive_validation:compute_validated_regression",
58 "validatedRegressionMenuItem","REG_MIN_SELECTION",
59 list(response="y",numeric_predictors=list("x"),algorithm="ols",
60 imputation="drop",test_fraction=0.2,seed=0L),
61 list("/source_count"=exact(nrow(v),"five complete rows"),
62 "/training_metrics/row_count"=exact(4L,"four training rows"),
63 "/test_metrics/row_count"=exact(1L,"one held-out row")),
64 c("R checks population and split sizes; NumPy determines the held-out identity."),
65 deferred=list(list(path="/recipe/coefficients",
66 reason="No explicit row split exists to replay the NumPy permutation in R.")))
Regression edge STAT-REG-VALIDATED-SMALLTRAIN-001
Case STAT-REG-VALIDATED-SMALLTRAIN-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic design condition
- Citation
- Tabelz manual regression model design conditions; R stats/plm references
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, plm 2.6.7, jsonlite 2.0.0
- Reference script
- generators/r/regression_advanced_special_b.R · sha256 4a5d01b584989ad6
- Dataset
- reference_data/datasets/REG_EDGE_VALIDATED_SMALLTRAIN.json
Settings compared
algorithm= "ols"imputation= "drop"numeric_predictors= ["x"]response= "y"seed= 0test_fraction= 0.5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Two training rows cannot estimate the one-predictor model plus the required residual degrees of freedom.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
40 v <- read_dataset("REG_MIN_SELECTION")[1:4,]
41 export_dataset(v,"REG_EDGE_VALIDATED_SMALLTRAIN","Four-row OLS population with two-row holdout",
42 "Analytic train-rank boundary for one-predictor validated regression",
43 "Constructed validation data; no third-party license.",
44 c(x="Float64",y="Float64"))
45 emit("STAT-REG-VALIDATED-SMALLTRAIN-001","STAT-REG-VALIDATED-COUNT-001",
46 "REG_EDGE_VALIDATED_SMALLTRAIN",
47 list(response="y",numeric_predictors=list("x"),algorithm="ols",
48 imputation="drop",test_fraction=0.5,seed=0L),
49 error=err("ValueError","cannot estimate"),
50 note="Two training rows cannot estimate the one-predictor model plus the required residual degrees of freedom.")
STAT REG VIF 001
Case STAT-REG-VIF-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats, MASS and nnet
- Citation
- R stats::lm/glm, MASS::polr/glm.nb, nnet::multinom help pages
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, MASS 7.3.65, nnet 7.3.20, jsonlite 2.0.0
- Reference script
- generators/r/regression_core.R · sha256 4b30ab4a6f513e54
- Dataset
- reference_data/datasets/REG_CORE.json
Settings compared
degree= 2interactions= falsemissing= "drop"model_type= "linear"split_percent= 100x_columns= ["x", "z"]y_columns= ["y"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | tolerance | 1.0001090211033234 | 1.0001090211033237 | 2.70E-16 | 15 | passed |
/1 | tolerance | 1.0001090211033234 | 1.0001090211033232 | 1.74E-16 | 15 | passed |
Convention
- Each VIF = 1/(1-R-squared) from the auxiliary R lm regression.
- All reference fits use the re-read exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
76 vif_entry <- "tabelz.analysis.fit_y_by_x:compute_fit_vif"
77 r2_x <- summary(stats::lm(x ~ z, data = d))$r.squared
78 r2_z <- summary(stats::lm(z ~ x, data = d))$r.squared
79 emit("STAT-REG-VIF-001", vif_entry, fit_menu, "nominal",
80 list(y_columns = list("y"), x_columns = list("x", "z"),
81 missing = "drop", model_type = "linear", degree = 2L,
82 interactions = FALSE, split_percent = 100L),
83 list("/0" = tol(1 / (1 - r2_x), "x VIF", "1e-9"),
84 "/1" = tol(1 / (1 - r2_z), "z VIF", "1e-9")),
85 list("Each VIF = 1/(1-R-squared) from the auxiliary R lm regression."))
STAT REG WEIGHT ESTIMATION 001
Case STAT-REG-WEIGHT-ESTIMATION-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm with weights = z^-p, stats::qt/pt/pf
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_weight_estimation.R · sha256 8d75fc39f6126fa0
- Dataset
- reference_data/datasets/REG_WEIGHT_01.json
Settings compared
confidence_level= 0.95power_from= -2power_step= 0.5power_to= 2predictors= ["x1", "x2"]response= "y"weight_variable= "z"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 23 | 23 | 0.00E+2 | passed | |
/selected_power | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/at_boundary | exact | False | False | passed | ||
/r_squared | tolerance | 0.89338764148324978 | 0.8933876414832498 | 3.65E-18 | 17 | passed |
/adjusted_r_squared | tolerance | 0.88272640563157478 | 0.8827264056315748 | 4.22E-18 | 17 | passed |
/standard_error | tolerance | 0.47615214184936205 | 0.476152141849362 | 5.16E-17 | 15 | passed |
/f_value | tolerance | 83.797756086869313 | 83.79775608686934 | 2.86E-14 | 15 | passed |
/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/df2 | exact | 20 | 20 | 0.00E+2 | passed | |
/p_value | tail_probability | 1.8970357299823228e-10 | 1.8970357299823135e-10 | 9.32E-25 | 14 | passed |
/grid/0/log_likelihood | tolerance | -40.058970301800926 | -40.058970301800926 | 5.06E-18 | 18 | passed |
/grid/0/weighted_sse | tolerance | 595.09247849633539 | 595.0924784963354 | 1.37E-15 | 17 | passed |
/grid/1/log_likelihood | tolerance | -36.920447624680385 | -36.92044762468038 | 7.12E-15 | 15 | passed |
/grid/1/weighted_sse | tolerance | 236.00997405712687 | 236.00997405712687 | 1.73E-15 | 17 | passed |
/grid/2/log_likelihood | tolerance | -34.24487367233089 | -34.244873672330904 | 1.40E-14 | 15 | passed |
/grid/2/weighted_sse | tolerance | 97.444961922021378 | 97.4449619220214 | 2.81E-14 | 15 | passed |
/grid/3/log_likelihood | tolerance | -32.090104159755647 | -32.09010415975565 | 1.17E-16 | 17 | passed |
/grid/3/weighted_sse | tolerance | 42.09751557693977 | 42.097515576939756 | 1.40E-14 | 15 | passed |
/grid/4/log_likelihood | tolerance | -30.487057642566857 | -30.48705764256686 | 3.24E-15 | 15 | passed |
/grid/4/weighted_sse | tolerance | 19.080476512878214 | 19.080476512878224 | 1.03E-14 | 15 | passed |
/grid/5/log_likelihood | tolerance | -29.444361939337856 | -29.444361939337863 | 7.28E-15 | 15 | passed |
/grid/5/weighted_sse | tolerance | 9.079950232249745 | 9.079950232249749 | 3.51E-15 | 15 | passed |
/grid/6/log_likelihood | tolerance | -28.956251325968481 | -28.956251325968477 | 3.94E-15 | 15 | passed |
/grid/6/weighted_sse | tolerance | 4.5344172437547003 | 4.5344172437546995 | 8.44E-16 | 15 | passed |
/grid/7/log_likelihood | tolerance | -29.003524596610543 | -29.00352459661056 | 1.76E-14 | 15 | passed |
/grid/7/weighted_sse | tolerance | 2.3723465138039432 | 2.3723465138039463 | 3.14E-15 | 14 | passed |
/grid/8/log_likelihood | tolerance | -29.548849229465603 | -29.54884922946561 | 6.77E-15 | 15 | passed |
/grid/8/weighted_sse | tolerance | 1.2961150301344611 | 1.2961150301344617 | 6.21E-16 | 15 | passed |
/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/coefficients/0/estimate | tolerance | 1.9632738506836476 | 1.963273850683647 | 6.96E-16 | 15 | passed |
/coefficients/0/standard_error | tolerance | 0.41736634659734351 | 0.4173663465973435 | 2.84E-18 | 17 | passed |
/coefficients/0/t_value | tolerance | 4.7039582052784121 | 4.70395820527841 | 1.75E-15 | 15 | passed |
/coefficients/0/p_value | tail_probability | 0.00013616548558573243 | 0.00013616548558573316 | 7.28E-19 | 14 | passed |
/coefficients/0/lower | tolerance | 1.0926629075626932 | 1.0926629075626928 | 4.02E-16 | 15 | passed |
/coefficients/0/upper | tolerance | 2.8338847938046019 | 2.833884793804601 | 8.90E-16 | 15 | passed |
/coefficients/1/term | exact | x1 | x1 | passed | ||
/coefficients/1/estimate | tolerance | 0.77360298132106831 | 0.7736029813210685 | 2.18E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.091779669262537472 | 0.09177966926253746 | 1.37E-17 | 15 | passed |
/coefficients/1/t_value | tolerance | 8.4289144593467906 | 8.428914459346794 | 3.57E-15 | 15 | passed |
/coefficients/1/p_value | tail_probability | 5.1536697811237143e-08 | 5.153669781123687e-08 | 2.72E-22 | 14 | passed |
/coefficients/1/lower | tolerance | 0.58215394603726467 | 0.582153946037265 | 3.32E-16 | 15 | passed |
/coefficients/1/upper | tolerance | 0.96505201660487194 | 0.965052016604872 | 1.14E-16 | 15 | passed |
/coefficients/2/term | exact | x2 | x2 | passed | ||
/coefficients/2/estimate | tolerance | -1.1218811778017941 | -1.1218811778017939 | 2.39E-16 | 15 | passed |
/coefficients/2/standard_error | tolerance | 0.12383651842060889 | 0.12383651842060889 | 2.41E-18 | 16 | passed |
/coefficients/2/t_value | tolerance | -9.059372728740172 | -9.05937272874017 | 1.81E-15 | 15 | passed |
/coefficients/2/p_value | tail_probability | 1.6213705158206247e-08 | 1.6213705158206293e-08 | 4.64E-23 | 14 | passed |
/coefficients/2/lower | tolerance | -1.38019962866385 | -1.3801996286638498 | 1.80E-16 | 15 | passed |
/coefficients/2/upper | tolerance | -0.86356272693973801 | -0.8635627269397379 | 1.09E-16 | 15 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Default grid -2 to 2 by 0.5; the interior maximum is checked by R at every grid point.
- Weights are z^(-p); for each grid power p the profile log-likelihood is -n/2 [ln(2 pi) + ln(WSSE/n) + 1] + 1/2 sum ln w_i and the largest value selects p (docs/manual/chapters/86-regression-and-count-models.tex:71-84).
- The final fit is stats::lm(y ~ predictors, weights = z^-p_selected); s^2 = WSSE/(n-k); t intervals on n-k df; R-squared and F from weighted sums of squares about the weighted mean, as summary.lm reports for a weighted fit.
- Rows with a missing value in any role are dropped (R na.omit); excluded rows are removed before anything is computed.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
33 emit <- function(id, kind, config, outputs, notes, excluded = list()) {
34 write_expected("regression", id, list(
35 schema_version = "2.0.0", case_id = id, outputs = outputs,
36 expected_error = NULL, deferred_outputs = list(), generator_run = run))
37 write_case("regression", id, list(
38 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = "regression",
39 entry_point = "tabelz.analysis.weight_estimation:compute_weight_estimation",
40 menu_items = list("weightEstimationMenuItem"), title = gsub("-", " ", id),
41 case_kind = kind,
42 dataset = list(path = "reference_data/datasets/REG_WEIGHT_01.json", sha256 = ""),
43 excluded_rows = excluded, configuration = config, "repeat" = 1L,
44 expected = list(path = paste0("reference_data/expected/regression/", id, ".json"), sha256 = ""),
45 oracle = list(
46 oracle_class = "independent_implementation",
47 source = "R stats::lm with weights = z^-p, stats::qt/pt/pf",
48 citation = "R Core Team, stats package help: lm, summary.lm, confint.",
49 generator = list(path = "generators/r/regression_weight_estimation.R", sha256 = ""),
50 independent = TRUE,
51 convention_notes = c(
52 notes,
53 "Weights are z^(-p); for each grid power p the profile log-likelihood is -n/2 [ln(2 pi) + ln(WSSE/n) + 1] + 1/2 sum ln w_i and the largest value selects p (docs/manual/chapters/86-regression-and-count-models.tex:71-84).",
54 "The final fit is stats::lm(y ~ predictors, weights = z^-p_selected); s^2 = WSSE/(n-k); t intervals on n-k df; R-squared and F from weighted sums of squares about the weighted mean, as summary.lm reports for a weighted fit.",
55 "Rows with a missing value in any role are dropped (R na.omit); excluded rows are removed before anything is computed.",
56 "Expected computed from the exported CSV."
57 )),
58 supported = TRUE, unsupported_reason = NULL,
59 requirement_ids = list("REQ-STAT-REG-WEIGHT-ESTIMATION-001"),
60 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
STAT REG WEIGHT ESTIMATION 002
Case STAT-REG-WEIGHT-ESTIMATION-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm with weights = z^-p, stats::qt/pt/pf
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_weight_estimation.R · sha256 8d75fc39f6126fa0
- Dataset
- reference_data/datasets/REG_WEIGHT_01.json
Settings compared
confidence_level= 0.9power_from= -1power_step= 0.25power_to= 2predictors= ["x1"]response= "y"weight_variable= "z"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 24 | 24 | 0.00E+2 | passed | |
/selected_power | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/at_boundary | exact | False | False | passed | ||
/r_squared | tolerance | 0.47550644285745602 | 0.4755064428574559 | 1.07E-16 | 15 | passed |
/adjusted_r_squared | tolerance | 0.45166582662370403 | 0.4516658266237039 | 1.16E-16 | 15 | passed |
/standard_error | tolerance | 1.8375948254638235 | 1.8375948254638235 | 3.31E-17 | 16 | passed |
/f_value | tolerance | 19.945224493998808 | 19.9452244939988 | 7.40E-15 | 15 | passed |
/df1 | exact | 1 | 1 | 0.00E+2 | passed | |
/df2 | exact | 22 | 22 | 0.00E+2 | passed | |
/p_value | tail_probability | 0.0001932689406870422 | 0.00019326894068704214 | 5.64E-20 | 15 | passed |
/grid/0/log_likelihood | tolerance | -49.050588581031512 | -49.05058858103151 | 9.21E-17 | 17 | passed |
/grid/0/weighted_sse | tolerance | 299.61203346720413 | 299.61203346720407 | 5.87E-14 | 15 | passed |
/grid/1/log_likelihood | tolerance | -48.437045697714709 | -48.43704569771471 | 4.19E-16 | 17 | passed |
/grid/1/weighted_sse | tolerance | 206.98973267683368 | 206.9897326768336 | 8.28E-14 | 15 | passed |
/grid/2/log_likelihood | tolerance | -47.991264554924911 | -47.99126455492491 | 3.88E-16 | 17 | passed |
/grid/2/weighted_sse | tolerance | 145.01397425902388 | 145.0139742590239 | 3.09E-14 | 15 | passed |
/grid/3/log_likelihood | tolerance | -47.716161729161954 | -47.71616172916195 | 4.69E-16 | 17 | passed |
/grid/3/weighted_sse | tolerance | 103.04999157700033 | 103.04999157700034 | 1.12E-14 | 15 | passed |
/grid/4/log_likelihood | tolerance | -47.613369628266774 | -47.613369628266774 | 2.14E-16 | 17 | passed |
/grid/4/weighted_sse | tolerance | 74.288604336571225 | 74.28860433657124 | 1.46E-14 | 15 | passed |
/grid/5/log_likelihood | tolerance | -47.6836073553646 | -47.6836073553646 | 2.67E-16 | 17 | passed |
/grid/5/weighted_sse | tolerance | 54.332363338933824 | 54.332363338933824 | 8.18E-17 | 17 | passed |
/grid/6/log_likelihood | tolerance | -47.92676653104126 | -47.92676653104127 | 6.72E-15 | 15 | passed |
/grid/6/weighted_sse | tolerance | 40.313752871822828 | 40.313752871822835 | 7.29E-15 | 15 | passed |
/grid/7/log_likelihood | tolerance | -48.341655991568501 | -48.3416559915685 | 3.49E-16 | 17 | passed |
/grid/7/weighted_sse | tolerance | 30.343312397295279 | 30.34331239729528 | 4.85E-16 | 16 | passed |
/grid/8/log_likelihood | tolerance | -48.925519974388422 | -48.92551997438842 | 7.12E-17 | 17 | passed |
/grid/8/weighted_sse | tolerance | 23.162644378568366 | 23.162644378568373 | 7.33E-15 | 15 | passed |
/grid/9/log_likelihood | tolerance | -49.673564124456675 | -49.67356412445669 | 1.42E-14 | 15 | passed |
/grid/9/weighted_sse | tolerance | 17.924835090834204 | 17.92483509083421 | 7.12E-15 | 15 | passed |
/grid/10/log_likelihood | tolerance | -50.578724901158331 | -50.57872490115834 | 7.41E-15 | 15 | passed |
/grid/10/weighted_sse | tolerance | 14.054274723920223 | 14.05427472392023 | 6.92E-15 | 15 | passed |
/grid/11/log_likelihood | tolerance | -51.6318064802919 | -51.6318064802919 | 3.25E-16 | 17 | passed |
/grid/11/weighted_sse | tolerance | 11.156170441735425 | 11.156170441735414 | 1.11E-14 | 15 | passed |
/grid/12/log_likelihood | tolerance | -52.821956944820592 | -52.821956944820585 | 7.43E-15 | 15 | passed |
/grid/12/weighted_sse | tolerance | 8.957411607508476 | 8.957411607508474 | 1.79E-15 | 15 | passed |
/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/coefficients/0/estimate | tolerance | 1.2927129072344314 | 1.29271290723443 | 1.29E-15 | 15 | passed |
/coefficients/0/standard_error | tolerance | 0.89560559223290082 | 0.8956055922329011 | 3.29E-16 | 15 | passed |
/coefficients/0/t_value | tolerance | 1.4433953053056232 | 1.4433953053056212 | 1.99E-15 | 14 | passed |
/coefficients/0/p_value | tail_probability | 0.16299857286385949 | 0.16299857286386005 | 5.57E-16 | 14 | passed |
/coefficients/0/lower | tolerance | -0.24517119713177982 | -0.24517119713178137 | 1.55E-15 | 14 | passed |
/coefficients/0/upper | tolerance | 2.8305970116006423 | 2.8305970116006414 | 9.34E-16 | 15 | passed |
/coefficients/1/term | exact | x1 | x1 | passed | ||
/coefficients/1/estimate | tolerance | 0.80694555611341567 | 0.8069455561134158 | 1.15E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.1806861107353937 | 0.18068611073539373 | 2.90E-17 | 15 | passed |
/coefficients/1/t_value | tolerance | 4.4660076683766219 | 4.466007668376622 | 1.36E-17 | 17 | passed |
/coefficients/1/p_value | tail_probability | 0.00019326894068704293 | 0.00019326894068704307 | 1.35E-19 | 15 | passed |
/coefficients/1/lower | tolerance | 0.49668141753548883 | 0.49668141753548894 | 1.15E-16 | 15 | passed |
/coefficients/1/upper | tolerance | 1.1172096946913426 | 1.1172096946913426 | 3.03E-17 | 16 | passed |
Convention
- Grid -1 to 2 by 0.25 with 90% t intervals; one predictor.
- Weights are z^(-p); for each grid power p the profile log-likelihood is -n/2 [ln(2 pi) + ln(WSSE/n) + 1] + 1/2 sum ln w_i and the largest value selects p (docs/manual/chapters/86-regression-and-count-models.tex:71-84).
- The final fit is stats::lm(y ~ predictors, weights = z^-p_selected); s^2 = WSSE/(n-k); t intervals on n-k df; R-squared and F from weighted sums of squares about the weighted mean, as summary.lm reports for a weighted fit.
- Rows with a missing value in any role are dropped (R na.omit); excluded rows are removed before anything is computed.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
148 r <- profile(d, "x1", grid_of(-1, 2, 0.25), 0.90)
149 emit("STAT-REG-WEIGHT-ESTIMATION-002", "axis_coverage",
150 list(response = "y", predictors = list("x1"), weight_variable = "z",
151 power_from = -1, power_to = 2, power_step = 0.25, confidence_level = 0.90),
152 outputs_for(r, c("(Intercept)", "x1")),
153 list("Grid -1 to 2 by 0.25 with 90% t intervals; one predictor."))
STAT REG WEIGHT ESTIMATION 003
Case STAT-REG-WEIGHT-ESTIMATION-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm with weights = z^-p, stats::qt/pt/pf
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_weight_estimation.R · sha256 8d75fc39f6126fa0
- Dataset
- reference_data/datasets/REG_WEIGHT_01.json
Settings compared
confidence_level= 0.95power_from= -2power_step= 1power_to= 0predictors= ["x1", "x2"]response= "y"weight_variable= "z"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 23 | 23 | 0.00E+2 | passed | |
/selected_power | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/at_boundary | exact | True | True | passed | ||
/r_squared | tolerance | 0.86028028252013689 | 0.8602802825201368 | 1.16E-16 | 15 | passed |
/adjusted_r_squared | tolerance | 0.84630831077215052 | 0.8463083107721505 | 1.72E-18 | 17 | passed |
/standard_error | tolerance | 0.97674143233709021 | 0.9767414323370905 | 3.33E-16 | 15 | passed |
/f_value | tolerance | 61.571859579813662 | 61.571859579813626 | 3.57E-14 | 15 | passed |
/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/df2 | exact | 20 | 20 | 0.00E+2 | passed | |
/p_value | tail_probability | 2.8351561812214512e-09 | 2.8351561812214553e-09 | 4.12E-24 | 14 | passed |
/grid/0/log_likelihood | tolerance | -40.058970301800926 | -40.058970301800926 | 5.06E-18 | 18 | passed |
/grid/0/weighted_sse | tolerance | 595.09247849633539 | 595.0924784963354 | 1.37E-15 | 17 | passed |
/grid/1/log_likelihood | tolerance | -34.24487367233089 | -34.244873672330904 | 1.40E-14 | 15 | passed |
/grid/1/weighted_sse | tolerance | 97.444961922021378 | 97.4449619220214 | 2.81E-14 | 15 | passed |
/grid/2/log_likelihood | tolerance | -30.487057642566857 | -30.48705764256686 | 3.24E-15 | 15 | passed |
/grid/2/weighted_sse | tolerance | 19.080476512878214 | 19.080476512878224 | 1.03E-14 | 15 | passed |
/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/coefficients/0/estimate | tolerance | 2.0367576287010185 | 2.036757628701015 | 3.55E-15 | 14 | passed |
/coefficients/0/standard_error | tolerance | 0.4912294067412028 | 0.49122940674120313 | 3.34E-16 | 15 | passed |
/coefficients/0/t_value | tolerance | 4.1462453199062148 | 4.146245319906205 | 9.76E-15 | 14 | passed |
/coefficients/0/p_value | tail_probability | 0.00049974575375465321 | 0.0004997457537546639 | 1.07E-17 | 13 | passed |
/coefficients/0/lower | tolerance | 1.0120710420167736 | 1.0120710420167696 | 4.04E-15 | 14 | passed |
/coefficients/0/upper | tolerance | 3.0614442153852632 | 3.0614442153852606 | 2.63E-15 | 15 | passed |
/coefficients/1/term | exact | x1 | x1 | passed | ||
/coefficients/1/estimate | tolerance | 0.71855383771981574 | 0.718553837719816 | 2.18E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.10008055635023926 | 0.10008055635023931 | 5.08E-17 | 15 | passed |
/coefficients/1/t_value | tolerance | 7.1797546289129714 | 7.17975462891297 | 1.73E-15 | 15 | passed |
/coefficients/1/p_value | tail_probability | 5.9441133146721278e-07 | 5.94411331467215e-07 | 2.23E-21 | 14 | passed |
/coefficients/1/lower | tolerance | 0.50978945539118503 | 0.5097894553911853 | 2.23E-16 | 15 | passed |
/coefficients/1/upper | tolerance | 0.92731822004844644 | 0.9273182200484467 | 2.22E-16 | 15 | passed |
/coefficients/2/term | exact | x2 | x2 | passed | ||
/coefficients/2/estimate | tolerance | -1.0607241722640557 | -1.0607241722640555 | 2.35E-16 | 15 | passed |
/coefficients/2/standard_error | tolerance | 0.13945781039815985 | 0.13945781039815983 | 2.40E-17 | 15 | passed |
/coefficients/2/t_value | tolerance | -7.6060578409744766 | -7.606057840974477 | 3.07E-17 | 17 | passed |
/coefficients/2/p_value | tail_probability | 2.5204172062267379e-07 | 2.5204172062267374e-07 | 5.32E-23 | 15 | passed |
/coefficients/2/lower | tolerance | -1.3516280671903504 | -1.3516280671903502 | 1.76E-16 | 15 | passed |
/coefficients/2/upper | tolerance | -0.76982027733776093 | -0.7698202773377607 | 2.24E-16 | 15 | passed |
Convention
- Grid -2 to 0 by 1: the likelihood keeps rising to the upper edge, so at_boundary is true and the edge power is used for the final fit.
- Weights are z^(-p); for each grid power p the profile log-likelihood is -n/2 [ln(2 pi) + ln(WSSE/n) + 1] + 1/2 sum ln w_i and the largest value selects p (docs/manual/chapters/86-regression-and-count-models.tex:71-84).
- The final fit is stats::lm(y ~ predictors, weights = z^-p_selected); s^2 = WSSE/(n-k); t intervals on n-k df; R-squared and F from weighted sums of squares about the weighted mean, as summary.lm reports for a weighted fit.
- Rows with a missing value in any role are dropped (R na.omit); excluded rows are removed before anything is computed.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
156 r <- profile(d, c("x1", "x2"), grid_of(-2, 0, 1), 0.95)
157 stopifnot(isTRUE(r$at_boundary))
158 emit("STAT-REG-WEIGHT-ESTIMATION-003", "axis_coverage",
159 list(response = "y", predictors = list("x1", "x2"), weight_variable = "z",
160 power_from = -2, power_to = 0, power_step = 1, confidence_level = 0.95),
161 outputs_for(r, c("(Intercept)", "x1", "x2")),
162 list("Grid -2 to 0 by 1: the likelihood keeps rising to the upper edge, so at_boundary is true and the edge power is used for the final fit."))
STAT REG WEIGHT ESTIMATION 004
Case STAT-REG-WEIGHT-ESTIMATION-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm with weights = z^-p, stats::qt/pt/pf
- Citation
- R Core Team, stats package help: lm, summary.lm, confint.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/regression_weight_estimation.R · sha256 8d75fc39f6126fa0
- Dataset
- reference_data/datasets/REG_WEIGHT_01.json
Settings compared
confidence_level= 0.99power_from= -1power_step= 0.5power_to= 2predictors= ["x1", "x2"]response= "y"weight_variable= "z"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 21 | 21 | 0.00E+2 | passed | |
/selected_power | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/at_boundary | exact | False | False | passed | ||
/r_squared | tolerance | 0.90846168687038942 | 0.9084616868703896 | 2.20E-16 | 15 | passed |
/adjusted_r_squared | tolerance | 0.89829076318932155 | 0.8982907631893218 | 2.23E-16 | 15 | passed |
/standard_error | tolerance | 0.35814857602481642 | 0.35814857602481615 | 2.75E-16 | 15 | passed |
/f_value | tolerance | 89.319487133838237 | 89.3194871338384 | 1.56E-13 | 14 | passed |
/df1 | exact | 2 | 2 | 0.00E+2 | passed | |
/df2 | exact | 18 | 18 | 0.00E+2 | passed | |
/p_value | tail_probability | 4.5125927859333113e-10 | 4.5125927859332255e-10 | 8.58E-24 | 13 | passed |
/grid/0/log_likelihood | tolerance | -31.902550451695301 | -31.9025504516953 | 3.48E-16 | 16 | passed |
/grid/0/weighted_sse | tolerance | 92.737832066222751 | 92.73783206622267 | 8.54E-14 | 15 | passed |
/grid/1/log_likelihood | tolerance | -29.878893590474561 | -29.87889359047456 | 3.93E-16 | 16 | passed |
/grid/1/weighted_sse | tolerance | 40.231520523830277 | 40.231520523830284 | 6.76E-15 | 15 | passed |
/grid/2/log_likelihood | tolerance | -28.362207649610589 | -28.3622076496106 | 1.07E-14 | 15 | passed |
/grid/2/weighted_sse | tolerance | 18.316604617759346 | 18.316604617759364 | 1.75E-14 | 15 | passed |
/grid/3/log_likelihood | tolerance | -27.358015154513701 | -27.3580151545137 | 3.61E-16 | 16 | passed |
/grid/3/weighted_sse | tolerance | 8.7563060112554965 | 8.756306011255496 | 4.24E-17 | 17 | passed |
/grid/4/log_likelihood | tolerance | -26.860648097399881 | -26.86064809739988 | 3.51E-16 | 16 | passed |
/grid/4/weighted_sse | tolerance | 4.3929867126347428 | 4.392986712634743 | 2.97E-17 | 17 | passed |
/grid/5/log_likelihood | tolerance | -26.851662094538995 | -26.851662094538977 | 1.82E-14 | 15 | passed |
/grid/5/weighted_sse | tolerance | 2.3088672451548669 | 2.3088672451548633 | 3.60E-15 | 14 | passed |
/grid/6/log_likelihood | tolerance | -27.294686326020635 | -27.29468632602063 | 3.62E-15 | 15 | passed |
/grid/6/weighted_sse | tolerance | 1.266875105912951 | 1.2668751059129502 | 8.39E-16 | 15 | passed |
/coefficients/0/term | exact | (Intercept) | (Intercept) | passed | ||
/coefficients/0/estimate | tolerance | 1.9077729112929969 | 1.9077729112929969 | 3.53E-17 | 16 | passed |
/coefficients/0/standard_error | tolerance | 0.41352023484984052 | 0.4135202348498403 | 2.24E-16 | 15 | passed |
/coefficients/0/t_value | tolerance | 4.6134934895888629 | 4.6134934895888655 | 2.61E-15 | 15 | passed |
/coefficients/0/p_value | tail_probability | 0.00021575363814119606 | 0.00021575363814119468 | 1.38E-18 | 14 | passed |
/coefficients/0/lower | tolerance | 0.71747953100484207 | 0.7174795310048427 | 6.71E-16 | 15 | passed |
/coefficients/0/upper | tolerance | 3.0980662915811514 | 3.098066291581151 | 4.12E-16 | 15 | passed |
/coefficients/1/term | exact | x1 | x1 | passed | ||
/coefficients/1/estimate | tolerance | 0.80276471209763589 | 0.8027647120976357 | 2.21E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.092906912554452672 | 0.0929069125544526 | 6.89E-17 | 15 | passed |
/coefficients/1/t_value | tolerance | 8.6405272764514276 | 8.640527276451431 | 3.55E-15 | 15 | passed |
/coefficients/1/p_value | tail_probability | 8.0454982564817056e-08 | 8.045498256481657e-08 | 4.89E-22 | 14 | passed |
/coefficients/1/lower | tolerance | 0.53533769480371274 | 0.5353376948037127 | 1.92E-18 | 17 | passed |
/coefficients/1/upper | tolerance | 1.070191729391559 | 1.0701917293915586 | 4.01E-16 | 15 | passed |
/coefficients/2/term | exact | x2 | x2 | passed | ||
/coefficients/2/estimate | tolerance | -1.1339094985876883 | -1.133909498587687 | 1.33E-15 | 14 | passed |
/coefficients/2/standard_error | tolerance | 0.12190482022366811 | 0.121904820223668 | 1.12E-16 | 15 | passed |
/coefficients/2/t_value | tolerance | -9.3015969057434944 | -9.301596905743493 | 1.77E-15 | 15 | passed |
/coefficients/2/p_value | tail_probability | 2.688861583363372e-08 | 2.6888615833633733e-08 | 1.29E-23 | 15 | passed |
/coefficients/2/lower | tolerance | -1.4848052669414185 | -1.4848052669414167 | 1.82E-15 | 14 | passed |
/coefficients/2/upper | tolerance | -0.78301373023395815 | -0.7830137302339572 | 1.00E-15 | 14 | passed |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Rows 2 and 7 (0-based) are excluded; the grid -1 to 2 by 0.5 and 99% intervals.
- Weights are z^(-p); for each grid power p the profile log-likelihood is -n/2 [ln(2 pi) + ln(WSSE/n) + 1] + 1/2 sum ln w_i and the largest value selects p (docs/manual/chapters/86-regression-and-count-models.tex:71-84).
- The final fit is stats::lm(y ~ predictors, weights = z^-p_selected); s^2 = WSSE/(n-k); t intervals on n-k df; R-squared and F from weighted sums of squares about the weighted mean, as summary.lm reports for a weighted fit.
- Rows with a missing value in any role are dropped (R na.omit); excluded rows are removed before anything is computed.
- Expected computed from the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
165 r <- profile(d[-c(3, 8), ], c("x1", "x2"), grid_of(-1, 2, 0.5), 0.99)
166 emit("STAT-REG-WEIGHT-ESTIMATION-004", "axis_coverage",
167 list(response = "y", predictors = list("x1", "x2"), weight_variable = "z",
168 power_from = -1, power_to = 2, power_step = 0.5, confidence_level = 0.99),
169 c(outputs_for(r, c("(Intercept)", "x1", "x2")),
170 list("/missing_count" = exact(1L, "one row has a missing x2"),
171 "/excluded_count" = exact(2L, "two rows excluded by identity"))),
172 list("Rows 2 and 7 (0-based) are excluded; the grid -1 to 2 by 0.5 and 99% intervals."),
173 excluded = list(2L, 7L))
Parametric survival STAT-SURV-ALT-001
Case STAT-SURV-ALT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::survreg
- Citation
- R survival::survreg and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_parametric.R · sha256 7c99eb709767fd04
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
event_column= "status"high_stress= 80mode= "accelerated"stress_column= "stress"stress_type= "linear"stress_unit= "native"time_column= "time"use_stress= 50
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_n | exact | 32 | 32 | 0.00E+2 | passed | |
/fits/[family=weibull]/median_use | tolerance | 14.901891903827167 | 14.901891903829963 | 2.80E-12 | 12 | passed |
Convention
- R Weibull survreg scale=1/shape; intercept+slope*stress is log scale.
- Median at stress s is exp(beta0+beta1*s)*(log 2)^(survreg scale).
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
62 fit_aft <- survival::survreg(survival::Surv(time,status)~stress,data=d,dist="weibull",
63 control=survival::survreg.control(maxiter=200L))
64 median50 <- exp(coef(fit_aft)[[1]]+coef(fit_aft)[[2]]*50)*(log(2))^fit_aft$scale
65 emit("STAT-SURV-ALT-001","tabelz.executor.reliability","acceleratedLifeMenuItem",
66 "SURV_CORE",list(mode="accelerated",time_column="time",event_column="status",
67 stress_column="stress",stress_type="linear",stress_unit="native",
68 use_stress=50,high_stress=80),
69 list("/total_n"=exact(nrow(d),"All finite stress observations"),
70 "/fits/[family=weibull]/median_use"=tol(median50,"Weibull median at stress 50")),
71 c("R Weibull survreg scale=1/shape; intercept+slope*stress is log scale.",
72 "Median at stress s is exp(beta0+beta1*s)*(log 2)^(survreg scale)."))
Survival option STAT-SURV-ALT-ARRHENIUS-001
Case STAT-SURV-ALT-ARRHENIUS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_options.R · sha256 95af0dbeed660def
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
confidence_level= 0.9event_column= "status"high_stress= 80mode= "accelerated"stress_column= "stress"stress_type= "arrhenius"stress_unit= "celsius"time_column= "time"use_stress= 25
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[family=weibull]/median_use | tolerance | 12.452719811993985 | 12.452719811759742 | 2.34E-10 | 10 | passed |
Convention
- R Weibull survreg scale=1/shape; stress transform is 1/(C+273.15) or log(S).
- Median=exp(beta0+beta1*transformed use)*(log 2)^(survreg scale).
- R re-reads the referenced CSV.
Reference code
Survival boundary STAT-SURV-ALT-CONSTANT-001
Case STAT-SURV-ALT-CONSTANT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival and analytic boundary
- Citation
- R survival::survfit/coxph/survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_boundaries.R · sha256 528007972452fb15
- Dataset
- reference_data/datasets/SURV_CONST_STRESS.json
Settings compared
event_column= "status"high_stress= 60mode= "accelerated"stress_column= "stress"stress_type= "linear"stress_unit= "native"time_column= "time"use_stress= 40
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Constant stress cannot identify an accelerated-life stress slope.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
78 emit("STAT-SURV-ALT-CONSTANT-001","tabelz.executor.reliability",
79 "acceleratedLifeMenuItem","SURV_CONST_STRESS",
80 list(mode="accelerated",time_column="time",event_column="status",stress_column="stress",
81 stress_type="linear",stress_unit="native",use_stress=40,high_stress=60),list(),
82 c("Constant stress cannot identify an accelerated-life stress slope."),
83 error=list(error_class="ReliabilityExecutionError",message_contains="Varying stress levels"))
Hard-numeric survival STAT-SURV-ALT-HARD-001
Case STAT-SURV-ALT-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_hard.R · sha256 bc20ccd17540f4e7
- Dataset
- reference_data/datasets/SURV_HARD.json
Settings compared
event_column= "status"high_stress= 104000mode= "accelerated"stress_column= "stress"stress_type= "linear"stress_unit= "native"time_column= "time"use_stress= 102500
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[family=weibull]/median_use | tolerance | 1002928.9946306483 | 1002928.9946305646 | 8.37E-8 | 13 | passed |
Convention
- Stress is near 1e5 with a 3000-unit span; R survreg Weibull scale=1/shape.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
75 fit_alt <- survival::survreg(survival::Surv(time,status)~stress,data=d,dist="weibull",
76 control=survival::survreg.control(rel.tolerance=1e-14,maxiter=1000))
77 use_stress <- 102500
78 median_use <- exp(coef(fit_alt)[[1]]+coef(fit_alt)[[2]]*use_stress)*(log(2))^fit_alt$scale
79 emit("STAT-SURV-ALT-HARD-001","tabelz.executor.reliability","acceleratedLifeMenuItem",
80 "SURV_HARD",list(mode="accelerated",time_column="time",event_column="status",
81 stress_column="stress",stress_type="linear",stress_unit="native",
82 use_stress=use_stress,high_stress=104000),
83 list("/fits/[family=weibull]/median_use"=tol(median_use,"Large-offset linear-stress Weibull median")),
84 c("Stress is near 1e5 with a 3000-unit span; R survreg Weibull scale=1/shape."))
Survival corrected option STAT-SURV-ALT-INVERSE-001
Case STAT-SURV-ALT-INVERSE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival
- Citation
- R survival::survreg and coxph documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_corrections.R · sha256 69d4b35a58e7b5d7
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
confidence_level= 0.9event_column= "status"high_stress= 80mode= "accelerated"stress_column= "stress"stress_type= "inverse_power"stress_unit= "native"time_column= "time"use_stress= 50
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[family=weibull]/median_use | tolerance | 15.449200975100629 | 15.449200975090136 | 1.05E-11 | 12 | passed |
Convention
- R stress covariate is log(S); Weibull survreg scale=1/shape.
- Median=exp(beta0+beta1*log(50))*(log 2)^(survreg scale).
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
23 x <- log(d$stress)
24 fit <- survival::survreg(survival::Surv(d$time,d$status)~x,dist="weibull")
25 median50 <- exp(coef(fit)[[1]]+coef(fit)[[2]]*log(50))*(log(2))^fit$scale
26 emit("STAT-SURV-ALT-INVERSE-001","tabelz.executor.reliability",
27 "acceleratedLifeMenuItem",
28 list(mode="accelerated",time_column="time",event_column="status",stress_column="stress",
29 stress_type="inverse_power",stress_unit="native",use_stress=50,high_stress=80,
30 confidence_level=0.9),
31 list("/fits/[family=weibull]/median_use"=tol(median50,"R inverse-power use-stress Weibull median")),
32 c("R stress covariate is log(S); Weibull survreg scale=1/shape.",
33 "Median=exp(beta0+beta1*log(50))*(log 2)^(survreg scale)."))
Survival option STAT-SURV-ALT-INVERSE-POWER-001
Case STAT-SURV-ALT-INVERSE-POWER-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_options.R · sha256 95af0dbeed660def
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
confidence_level= 0.9event_column= "status"high_stress= 80mode= "accelerated"stress_column= "stress"stress_type= "inverse_power"stress_unit= "native"time_column= "time"use_stress= 50
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[family=weibull]/median_use | tolerance | 15.44920097509735 | 15.449200975090136 | 7.21E-12 | 12 | passed |
Convention
- R Weibull survreg scale=1/shape; stress transform is 1/(C+273.15) or log(S).
- Median=exp(beta0+beta1*transformed use)*(log 2)^(survreg scale).
- R re-reads the referenced CSV.
Reference code
Small-sample survival boundary STAT-SURV-ALT-MIN-001
Case STAT-SURV-ALT-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::survfit/coxph and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_minimum.R · sha256 2997d37929a6dae8
- Dataset
- reference_data/datasets/SURV_MIN.json
Settings compared
event_column= "status"high_stress= 60mode= "accelerated"stress_column= "stress"stress_type= "linear"stress_unit= "native"time_column= "time"use_stress= 40
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_n | exact | 5 | 5 | 0.00E+2 | passed | |
/failures | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- Five rows, three events and five stress levels meet physical ALT minimum.
- R re-reads the exported CSV and drops excluded 0-based ordinals.
Reference code
The lines of the reference script that produce this case's expected values.
58 emit("STAT-SURV-ALT-MIN-001","tabelz.executor.reliability","acceleratedLifeMenuItem",
59 "SURV_MIN",integer(),
60 list(mode="accelerated",time_column="time",event_column="status",stress_column="stress",
61 stress_type="linear",stress_unit="native",use_stress=40,high_stress=60),
62 list("/total_n"=exact(5L,"Minimum five stress/lifetime rows"),
63 "/failures"=exact(3L,"Minimum three failures")),
64 c("Five rows, three events and five stress levels meet physical ALT minimum."))
Survival population STAT-SURV-ALT-POP-001
Case STAT-SURV-ALT-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::Surv/survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_population.R · sha256 3b3b4629e272fcd9
- Dataset
- reference_data/datasets/SURV_POP.json
Settings compared
event_column= "status"high_stress= 80mode= "accelerated"stress_column= "stress"stress_type= "linear"stress_unit= "native"time_column= "time"use_stress= 50
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/input_row_count | exact | 31 | 31 | 0.00E+2 | passed | |
/omitted_row_count | exact | 3 | 3 | 0.00E+2 | passed | |
/total_n | exact | 28 | 28 | 0.00E+2 | passed |
Convention
- Physical ALT omits incomplete time/event/stress rows after exclusion.
- R re-reads the exported CSV and removes the declared ordinal before complete-case selection.
Reference code
The lines of the reference script that produce this case's expected values.
86 altdata <- eligible[stats::complete.cases(eligible[c("time","status","stress")]),,drop=FALSE]
87 emit("STAT-SURV-ALT-POP-001","tabelz.executor.reliability",
88 "acceleratedLifeMenuItem","SURV_POP",7L,
89 list(mode="accelerated",time_column="time",event_column="status",stress_column="stress",
90 stress_type="linear",stress_unit="native",use_stress=50,high_stress=80),
91 list("/input_row_count"=exact(nrow(eligible),"Rows sent to worker after exclusion"),
92 "/omitted_row_count"=exact(3L,"Missing time, status or stress"),
93 "/total_n"=exact(nrow(altdata),"Complete AFT rows")),
94 c("Physical ALT omits incomplete time/event/stress rows after exclusion."))
Survival STAT-SURV-COX-001
Case STAT-SURV-COX-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/survdiff/coxph and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, MASS 7.3.65, jsonlite 2.0.0
- Reference script
- generators/r/survival_core.R · sha256 1ed8945e6864eb84
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
censored_value= "0"duration_column= "time"event_column= "status"event_value= "1"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/log_hazard | tolerance | -0.021273688367235425 | -0.02127368836723542 | 3.44E-18 | 15 | passed |
/coefficients/0/hazard_ratio | tolerance | 0.97895100040089111 | 0.9789510004008911 | 3.71E-18 | 17 | passed |
/event_count | exact | 26 | 26 | 0.00E+2 | passed |
Convention
- R coxph uses Efron ties, eps=1e-12 and iter.max=200; independent subjects.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
55 i <- seq_len(32L)
56 raw <- data.frame(time=exp(2.2+0.025*i+0.18*sin(i*1.17)-0.31*cos(i*0.41)),
57 status=as.integer(i%%5L!=0L),
58 stress=as.double(rep(c(20,40,60,80),each=8L)),
59 x=as.double(sin(i*0.39)+0.1*cos(i*1.21)))
60 export_dataset(raw,"SURV_CORE","Constructed censored duration and stress population",
61 "R survival::coxph/survreg documentation",
62 "Constructed validation data; no third-party license.",
63 c(time="Float64",status="Int64",stress="Float64",x="Float64"))
64 d <- read_dataset("SURV_CORE")
65 cox <- survival::coxph(survival::Surv(time,status)~x,data=d,ties="efron",x=TRUE,
66 control=survival::coxph.control(eps=1e-12,iter.max=200L))
67 emit("STAT-SURV-COX-001","tabelz.executor.cox_regression","coxRegressionMenuItem",
68 "SURV_CORE",list(duration_column="time",event_column="status",event_value="1",
69 censored_value="0",predictors=list("x")),
70 list("/coefficients/0/log_hazard"=tol(coef(cox)[[1]],"Efron-tie log hazard", "1e-6"),
71 "/coefficients/0/hazard_ratio"=tol(exp(coef(cox)[[1]]),"Exponentiated Efron hazard ratio","1e-6"),
72 "/event_count"=exact(sum(d$status),"Observed failures")),
73 c("R coxph uses Efron ties, eps=1e-12 and iter.max=200; independent subjects."))
Survival option STAT-SURV-COX-CONFIDENCE-001
Case STAT-SURV-COX-CONFIDENCE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_options.R · sha256 95af0dbeed660def
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
censored_value= "0"confidence_level= 0.9duration_column= "time"event_column= "status"event_value= "1"max_diagnostic_rows= 100max_iterations= 300predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Manual chapter 14: fixed 95% asymptotic intervals; a 90% request must be refused.
- Until 2026-09-25 this case wrongly expected a 90% interval; -095-001 checks the 95% interval.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
40 emit("STAT-SURV-COX-CONFIDENCE-001","tabelz.executor.cox_regression",
41 "coxRegressionMenuItem","SURV_CORE",cox_config,structure(list(),names=character()),
42 c("Manual chapter 14: fixed 95% asymptotic intervals; a 90% request must be refused.",
43 "Until 2026-09-25 this case wrongly expected a 90% interval; -095-001 checks the 95% interval."),
44 error=list(error_class="ValidationError",message_contains="fixed at 95%"),kind="invalid_input")
Survival option STAT-SURV-COX-CONFIDENCE-095-001
Case STAT-SURV-COX-CONFIDENCE-095-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_options.R · sha256 95af0dbeed660def
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
censored_value= "0"confidence_level= 0.95duration_column= "time"event_column= "status"event_value= "1"max_diagnostic_rows= 100max_iterations= 300predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/hazard_ratio_ci_lower | tolerance | 0.547511126692934 | 0.5475111266929812 | 4.72E-14 | 13 | passed |
/analyzed_count | exact | 32 | 32 | 0.00E+2 | passed |
Convention
- R coxph Efron ties; 95% Wald interval exp(beta-z_0.975*SE).
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
45 cox_config$confidence_level <- 0.95
46 emit("STAT-SURV-COX-CONFIDENCE-095-001","tabelz.executor.cox_regression",
47 "coxRegressionMenuItem","SURV_CORE",cox_config,
48 list("/coefficients/0/hazard_ratio_ci_lower"=tol(lower95,"95% Wald hazard-ratio lower"),
49 "/analyzed_count"=exact(nrow(d),"All finite rows")),
50 c("R coxph Efron ties; 95% Wald interval exp(beta-z_0.975*SE)."))
Hard-numeric survival STAT-SURV-COX-HARD-001
Case STAT-SURV-COX-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_hard.R · sha256 bc20ccd17540f4e7
- Dataset
- reference_data/datasets/SURV_HARD.json
Settings compared
censored_value= "0"duration_column= "time"event_column= "status"event_value= "1"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/log_hazard | tolerance | -0.35940520742719329 | -0.3594052065524588 | 8.75E-10 | 8 | passed |
Convention
- Covariate is near 1e7 with O(1) spread; Cox partial likelihood is shift-invariant.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
63 cox <- survival::coxph(survival::Surv(time,status)~x,data=d,ties="efron")
64 emit("STAT-SURV-COX-HARD-001","tabelz.executor.cox_regression","coxRegressionMenuItem",
65 "SURV_HARD",list(duration_column="time",event_column="status",event_value="1",
66 censored_value="0",predictors=list("x")),
67 list("/coefficients/0/log_hazard"=tol(coef(cox)[[1]],"Large-offset covariate Efron log hazard")),
68 c("Covariate is near 1e7 with O(1) spread; Cox partial likelihood is shift-invariant."))
Invalid survival request STAT-SURV-COX-INVALID-001
Case STAT-SURV-COX-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
censored_value= "0"duration_column= "time"event_column= "status"event_value= "1"predictors= []
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A Cox design without a predictor is not identified by the menu contract.
- The declared request contract rejects this before statistical estimation.
Invalid survival request STAT-SURV-COX-INVALID-002
Case STAT-SURV-COX-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
censored_value= "0"confidence_level= 0.9duration_column= "time"event_column= "status"event_value= "1"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Cox intervals are fixed at 95% by the manual and strict config.
- The declared request contract rejects this before statistical estimation.
Small-sample survival boundary STAT-SURV-COX-MIN-001
Case STAT-SURV-COX-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::survfit/coxph and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_minimum.R · sha256 2997d37929a6dae8
- Dataset
- reference_data/datasets/SURV_MIN.json
Settings compared
censored_value= "0"duration_column= "time"event_column= "status"event_value= "1"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/analyzed_count | exact | 5 | 5 | 0.00E+2 | passed | |
/coefficients/0/log_hazard | tolerance | -0.59193918723529437 | -0.5919391872392871 | 3.99E-12 | 11 | passed |
Convention
- Five rows with three failures avoid complete separation; Efron ties pinned.
- R re-reads the exported CSV and drops excluded 0-based ordinals.
Reference code
The lines of the reference script that produce this case's expected values.
42 cox <- survival::coxph(survival::Surv(time,status)~x,data=d,ties="efron")
43 emit("STAT-SURV-COX-MIN-001","tabelz.executor.cox_regression","coxRegressionMenuItem",
44 "SURV_MIN",integer(),
45 list(duration_column="time",event_column="status",event_value="1",censored_value="0",
46 predictors=list("x")),
47 list("/analyzed_count"=exact(nrow(d),"Five identifiable rows"),
48 "/coefficients/0/log_hazard"=tol(coef(cox)[[1]],"R Efron small-sample log hazard")),
49 c("Five rows with three failures avoid complete separation; Efron ties pinned."))
Survival corrected option STAT-SURV-COX-OPTIONS-001
Case STAT-SURV-COX-OPTIONS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival
- Citation
- R survival::survreg and coxph documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_corrections.R · sha256 69d4b35a58e7b5d7
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
censored_value= "0"confidence_level= 0.95duration_column= "time"event_column= "status"event_value= "1"max_diagnostic_rows= 100max_iterations= 300predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/log_hazard | tolerance | -0.02127368836732162 | -0.02127368836723542 | 8.62E-14 | 11 | passed |
/analyzed_count | exact | 32 | 32 | 0.00E+2 | passed |
Convention
- Cox intervals are fixed at 95% by the manual; max_iterations and diagnostic bound are nondefaults.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
35 cox <- survival::coxph(survival::Surv(time,status)~x,data=d,ties="efron",
36 control=survival::coxph.control(iter.max=300L))
37 emit("STAT-SURV-COX-OPTIONS-001","tabelz.executor.cox_regression",
38 "coxRegressionMenuItem",
39 list(duration_column="time",event_column="status",event_value="1",censored_value="0",
40 predictors=list("x"),confidence_level=0.95,max_iterations=300L,max_diagnostic_rows=100L),
41 list("/coefficients/0/log_hazard"=tol(coef(cox)[[1]],"R Efron Cox log hazard"),
42 "/analyzed_count"=exact(nrow(d),"All finite rows")),
43 c("Cox intervals are fixed at 95% by the manual; max_iterations and diagnostic bound are nondefaults."))
Survival population STAT-SURV-COX-POP-001
Case STAT-SURV-COX-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::Surv/survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_population.R · sha256 3b3b4629e272fcd9
- Dataset
- reference_data/datasets/SURV_POP.json
Settings compared
censored_value= "0"duration_column= "time"event_column= "status"event_value= "1"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 32 | 32 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 3 | 3 | 0.00E+2 | passed | |
/coefficients/0/log_hazard | tolerance | -0.25036455063421509 | -0.25036455063423424 | 1.91E-14 | 13 | passed |
Convention
- R coxph Efron fit uses the same complete predictor/time/event rows.
- R re-reads the exported CSV and removes the declared ordinal before complete-case selection.
Reference code
The lines of the reference script that produce this case's expected values.
64 coxdata <- eligible[stats::complete.cases(eligible[c("time","status","x")]),,drop=FALSE]
65 cox <- survival::coxph(survival::Surv(time,status)~x,data=coxdata,ties="efron")
66 emit("STAT-SURV-COX-POP-001","tabelz.executor.cox_regression","coxRegressionMenuItem",
67 "SURV_POP",7L,list(duration_column="time",event_column="status",event_value="1",
68 censored_value="0",predictors=list("x")),
69 list("/source_count"=exact(nrow(d),"CSV population"),
70 "/excluded_count"=exact(1L,"One source row excluded"),
71 "/missing_count"=exact(3L,"Missing time, status, and predictor rows"),
72 "/coefficients/0/log_hazard"=tol(coef(cox)[[1]],"Efron-tie complete-case log hazard","1e-6")),
73 c("R coxph Efron fit uses the same complete predictor/time/event rows."))
Survival boundary STAT-SURV-COX-TIES-001
Case STAT-SURV-COX-TIES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival and analytic boundary
- Citation
- R survival::survfit/coxph/survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_boundaries.R · sha256 528007972452fb15
- Dataset
- reference_data/datasets/SURV_TIES.json
Settings compared
censored_value= "0"duration_column= "time"event_column= "status"event_value= "1"predictors= ["x"]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/log_hazard | tolerance | -0.02018576583744534 | -0.020185765837386085 | 5.93E-14 | 11 | passed |
/event_count | exact | 26 | 26 | 0.00E+2 | passed |
Convention
- Integer-rounded durations create exact ties; R coxph ties=efron matches manual.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
66 cox <- survival::coxph(survival::Surv(time,status)~x,data=ties,ties="efron")
67 emit("STAT-SURV-COX-TIES-001","tabelz.executor.cox_regression","coxRegressionMenuItem",
68 "SURV_TIES",list(duration_column="time",event_column="status",event_value="1",
69 censored_value="0",predictors=list("x")),
70 list("/coefficients/0/log_hazard"=tol(coef(cox)[[1]],"R Efron tied-event log hazard"),
71 "/event_count"=exact(as.integer(sum(ties$status)),"All failures retained")),
72 c("Integer-rounded durations create exact ties; R coxph ties=efron matches manual."))
Counting-process Cox model with Efron ties
Case STAT-SURV-COXTD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::coxph (counting process, cluster, strata, tt) and cox.zph
- Citation
- R survival package documentation: coxph, coxph.control, cox.zph; Therneau and Grambsch (2000).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_cox_time_dependent.R · sha256 4b0d7390bdbbf36e
- Dataset
- reference_data/datasets/SURV_COXTD_EPISODES.json
Settings compared
categorical_covariates= ["trt"]censored_value= "0"event_value= "1"layout= "counting_process"numeric_covariates= ["x"]start= "start"status= "status"stop= "stop"subject= "id"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | 0.98676383685164037 | 0.9867638368516416 | 1.23E-15 | 14 | passed |
/coefficients/0/standard_error | tolerance | 0.52401879200953516 | 0.5240187920095353 | 1.12E-16 | 15 | passed |
/coefficients/0/z | tolerance | 1.8830695614322264 | 1.8830695614322281 | 1.75E-15 | 15 | passed |
/coefficients/0/p_value | tail_probability | 0.059690941611302693 | 0.05969094161130249 | 2.01E-16 | 14 | passed |
/coefficients/0/hazard_ratio | tolerance | 2.6825392756523616 | 2.6825392756523647 | 3.12E-15 | 14 | passed |
/coefficients/0/lower | tolerance | 0.96050689071346951 | 0.9605068907134705 | 9.97E-16 | 14 | passed |
/coefficients/0/upper | tolerance | 7.4918952013683713 | 7.491895201368381 | 9.75E-15 | 14 | passed |
/coefficients/1/coefficient | tolerance | 1.1551698168547142 | 1.1551698168547155 | 1.34E-15 | 14 | passed |
/coefficients/1/standard_error | tolerance | 0.61530802927417649 | 0.6153080292741766 | 1.14E-16 | 15 | passed |
/coefficients/1/z | tolerance | 1.8773845974631016 | 1.8773845974631034 | 1.78E-15 | 15 | passed |
/coefficients/1/p_value | tail_probability | 0.060465400977948648 | 0.06046540097794841 | 2.36E-16 | 14 | passed |
/coefficients/1/hazard_ratio | tolerance | 3.1745624659696139 | 3.1745624659696183 | 4.43E-15 | 14 | passed |
/coefficients/1/lower | tolerance | 0.95045756790174984 | 0.950457567901751 | 1.11E-15 | 14 | passed |
/coefficients/1/upper | tolerance | 10.603152829422088 | 10.603152829422102 | 1.42E-14 | 14 | passed |
/tests/0/chisq | tolerance | 6.0516464217247261 | 6.051646421724719 | 7.10E-15 | 14 | passed |
/tests/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/tests/0/p_value | tail_probability | 0.048517864392811964 | 0.04851786439281212 | 1.53E-16 | 14 | passed |
/tests/1/chisq | tolerance | 5.9042282666944725 | 5.904228266694484 | 1.16E-14 | 14 | passed |
/log_likelihood | tolerance | -23.600482497165643 | -23.600482497165643 | 2.81E-16 | 16 | passed |
/null_log_likelihood | tolerance | -26.626305708028006 | -26.626305708028003 | 3.22E-15 | 15 | passed |
/ph_test/status | exact | computed | computed | passed | ||
/ph_test/rows/0/chisq | tolerance | 0.46580602972845836 | 0.4658060297284575 | 8.33E-16 | 14 | passed |
/ph_test/rows/0/df | exact | 1 | 1 | 0.00E+2 | passed | |
/ph_test/rows/0/p_value | tail_probability | 0.49492294477715704 | 0.4949229447771575 | 4.41E-16 | 15 | passed |
/ph_test/rows/1/chisq | tolerance | 0.014600037102362287 | 0.014600037102362372 | 8.48E-17 | 14 | passed |
/ph_test/rows/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/ph_test/rows/1/p_value | tail_probability | 0.90382520186791859 | 0.9038252018679183 | 3.30E-16 | 15 | passed |
/ph_test/rows/2/chisq | tolerance | 0.49183351650298063 | 0.4918335165029798 | 8.35E-16 | 14 | passed |
/ph_test/rows/2/df | exact | 2 | 2 | 0.00E+2 | passed | |
/ph_test/rows/2/p_value | tail_probability | 0.78198731620779716 | 0.7819873162077975 | 3.29E-16 | 15 | passed |
/subjects | exact | 16 | 16 | 0.00E+2 | passed | |
/episodes | exact | 28 | 28 | 0.00E+2 | passed | |
/events | exact | 13 | 13 | 0.00E+2 | passed | |
/gaps | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- coxph(Surv(start, stop, status) ~ x + trt, ties = 'efron'); terms in order x, trt = B (vs A).
- cox.zph(transform = 'km', terms = TRUE): rows x, trt, GLOBAL.
- Expected computed from the exported CSV.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:64-67: h(t) = h_0s(t) exp(z(t)'beta) on (start, stop] episodes; an event at t uses the covariates in force just before t.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:87-96: Efron or Breslow ties; partial likelihood; model-based covariance from the information matrix, robust covariance over whole subjects; Wald intervals on the log scale.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:97-101: the proportional-hazards score diagnostic with the KM transform; withheld for a model with a declared time interaction.
- Relative tolerance 1e-6 (1e-5 on tail probabilities): both implementations maximize the partial likelihood iteratively.
Reference code
The lines of the reference script that produce this case's expected values.
140 fit <- survival::coxph(survival::Surv(start, stop, status) ~ x + trt, data = d, ties = "efron", control = control)
141 emit("STAT-SURV-COXTD-001", "Counting-process Cox model with Efron ties", "nominal",
142 "SURV_COXTD_EPISODES", episode_config,
143 c(coefficient_outputs(fit, 0.95), zph_outputs(fit), counts(d)),
144 list("coxph(Surv(start, stop, status) ~ x + trt, ties = 'efron'); terms in order x, trt = B (vs A).",
145 "cox.zph(transform = 'km', terms = TRUE): rows x, trt, GLOBAL."))
Breslow ties with the robust sandwich variance
Case STAT-SURV-COXTD-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::coxph (counting process, cluster, strata, tt) and cox.zph
- Citation
- R survival package documentation: coxph, coxph.control, cox.zph; Therneau and Grambsch (2000).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_cox_time_dependent.R · sha256 4b0d7390bdbbf36e
- Dataset
- reference_data/datasets/SURV_COXTD_EPISODES.json
Settings compared
categorical_covariates= ["trt"]censored_value= "0"event_value= "1"layout= "counting_process"numeric_covariates= ["x"]robust= truestart= "start"status= "status"stop= "stop"subject= "id"ties= "breslow"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | 0.86013173981878621 | 0.8601317398187864 | 2.24E-16 | 15 | passed |
/coefficients/0/standard_error | tolerance | 0.49823212171245573 | 0.4982321217124556 | 1.08E-16 | 15 | passed |
/coefficients/0/robust_standard_error | tolerance | 0.37112263729515516 | 0.371122637295155 | 1.71E-16 | 15 | passed |
/coefficients/0/z | tolerance | 2.3176482741329529 | 2.3176482741329547 | 1.81E-15 | 15 | passed |
/coefficients/0/p_value | tail_probability | 0.020468444337310956 | 0.02046844433731087 | 8.70E-17 | 14 | passed |
/coefficients/0/hazard_ratio | tolerance | 2.3634720365750228 | 2.3634720365750232 | 4.50E-16 | 15 | passed |
/coefficients/0/lower | tolerance | 1.1419584612351497 | 1.1419584612351503 | 6.24E-16 | 15 | passed |
/coefficients/0/upper | tolerance | 4.8915965486434869 | 4.891596548643487 | 1.92E-17 | 17 | passed |
/coefficients/1/coefficient | tolerance | 1.0718399927503113 | 1.0718399927503117 | 4.21E-16 | 15 | passed |
/coefficients/1/standard_error | tolerance | 0.61911536382816923 | 0.6191153638281692 | 4.79E-19 | 18 | passed |
/coefficients/1/robust_standard_error | tolerance | 0.46943154704681755 | 0.4694315470468178 | 2.26E-16 | 15 | passed |
/coefficients/1/z | tolerance | 2.2832721820534445 | 2.2832721820534445 | 1.01E-17 | 17 | passed |
/coefficients/1/p_value | tail_probability | 0.022414340562235974 | 0.02241434056223598 | 7.34E-18 | 15 | passed |
/coefficients/1/hazard_ratio | tolerance | 2.9207487152651406 | 2.920748715265142 | 1.30E-15 | 15 | passed |
/coefficients/1/lower | tolerance | 1.1638937526273627 | 1.1638937526273627 | 2.10E-17 | 16 | passed |
/coefficients/1/upper | tolerance | 7.3295118548971336 | 7.32951185489714 | 6.26E-15 | 15 | passed |
/tests/0/chisq | tolerance | 4.9543254368553633 | 4.954325436855356 | 7.10E-15 | 14 | passed |
/tests/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/tests/0/p_value | tail_probability | 0.083981166095456097 | 0.0839811660954564 | 3.06E-16 | 14 | passed |
/tests/1/chisq | tolerance | 9.1663327935549752 | 9.16633279355498 | 5.34E-15 | 15 | passed |
/log_likelihood | tolerance | -25.50863915756549 | -25.508639157565486 | 3.50E-15 | 15 | passed |
/null_log_likelihood | tolerance | -27.985801875993172 | -27.985801875993165 | 7.40E-15 | 15 | passed |
/subjects | exact | 16 | 16 | 0.00E+2 | passed | |
/episodes | exact | 28 | 28 | 0.00E+2 | passed | |
/events | exact | 13 | 13 | 0.00E+2 | passed | |
/gaps | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- coxph(..., ties = 'breslow', cluster = id): fit$var is the robust sandwich with the subject as the cluster, fit$naive.var the model-based covariance; z, p, the interval and the Wald test use the robust SE.
- Expected computed from the exported CSV.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:64-67: h(t) = h_0s(t) exp(z(t)'beta) on (start, stop] episodes; an event at t uses the covariates in force just before t.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:87-96: Efron or Breslow ties; partial likelihood; model-based covariance from the information matrix, robust covariance over whole subjects; Wald intervals on the log scale.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:97-101: the proportional-hazards score diagnostic with the KM transform; withheld for a model with a declared time interaction.
- Relative tolerance 1e-6 (1e-5 on tail probabilities): both implementations maximize the partial likelihood iteratively.
Reference code
The lines of the reference script that produce this case's expected values.
148 fit2 <- survival::coxph(survival::Surv(start, stop, status) ~ x + trt, data = d, ties = "breslow",
149 cluster = id, control = control)
150 emit("STAT-SURV-COXTD-002", "Breslow ties with the robust sandwich variance", "axis_coverage",
151 "SURV_COXTD_EPISODES", c(episode_config, list(ties = "breslow", robust = TRUE)),
152 c(coefficient_outputs(fit2, 0.95, robust = TRUE), counts(d)),
153 list("coxph(..., ties = 'breslow', cluster = id): fit$var is the robust sandwich with the subject as the cluster, fit$naive.var the model-based covariance; z, p, the interval and the Wald test use the robust SE."))
Stratified baseline hazards by sex with 90% intervals
Case STAT-SURV-COXTD-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::coxph (counting process, cluster, strata, tt) and cox.zph
- Citation
- R survival package documentation: coxph, coxph.control, cox.zph; Therneau and Grambsch (2000).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_cox_time_dependent.R · sha256 4b0d7390bdbbf36e
- Dataset
- reference_data/datasets/SURV_COXTD_EPISODES.json
Settings compared
categorical_covariates= ["trt"]censored_value= "0"confidence_level= 0.9event_value= "1"layout= "counting_process"numeric_covariates= ["x"]start= "start"status= "status"stop= "stop"strata= "sex"subject= "id"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | 0.93629731836914976 | 0.9362973183691538 | 3.99E-15 | 14 | passed |
/coefficients/0/standard_error | tolerance | 0.5459031577714224 | 0.5459031577714231 | 6.64E-16 | 14 | passed |
/coefficients/0/z | tolerance | 1.7151344611953885 | 1.7151344611953938 | 5.31E-15 | 14 | passed |
/coefficients/0/p_value | tail_probability | 0.086320577431958978 | 0.08632057743195802 | 9.58E-16 | 13 | passed |
/coefficients/0/hazard_ratio | tolerance | 2.5505201489997615 | 2.5505201489997718 | 1.03E-14 | 14 | passed |
/coefficients/0/lower | tolerance | 1.0391120281385184 | 1.0391120281385215 | 3.15E-15 | 14 | passed |
/coefficients/0/upper | tolerance | 6.2603000006719185 | 6.2603000006719505 | 3.20E-14 | 14 | passed |
/coefficients/1/coefficient | tolerance | 1.3459460760339004 | 1.3459460760339066 | 6.19E-15 | 14 | passed |
/coefficients/1/standard_error | tolerance | 0.7595124863940188 | 0.7595124863940199 | 1.11E-15 | 14 | passed |
/coefficients/1/z | tolerance | 1.7721184314218796 | 1.7721184314218854 | 5.81E-15 | 14 | passed |
/coefficients/1/p_value | tail_probability | 0.076374899982117064 | 0.07637489998211612 | 9.43E-16 | 13 | passed |
/coefficients/1/hazard_ratio | tolerance | 3.8418194751448236 | 3.8418194751448476 | 2.40E-14 | 14 | passed |
/coefficients/1/lower | tolerance | 1.1014849324791345 | 1.1014849324791394 | 4.87E-15 | 14 | passed |
/coefficients/1/upper | tolerance | 13.39970837947131 | 13.399708379471416 | 1.06E-13 | 14 | passed |
/tests/0/chisq | tolerance | 5.6702555980345082 | 5.670255598034512 | 3.53E-15 | 15 | passed |
/tests/0/df | exact | 2 | 2 | 0.00E+2 | passed | |
/tests/0/p_value | tail_probability | 0.058711022143468447 | 0.05871102214346833 | 1.18E-16 | 14 | passed |
/tests/1/chisq | tolerance | 4.9087685053433034 | 4.90876850534333 | 2.67E-14 | 14 | passed |
/log_likelihood | tolerance | -15.378345732919254 | -15.378345732919252 | 2.11E-15 | 15 | passed |
/null_log_likelihood | tolerance | -18.213473531936508 | -18.213473531936508 | 2.46E-16 | 16 | passed |
/ph_test/status | exact | computed | computed | passed | ||
/ph_test/rows/0/chisq | tolerance | 0.39149613206413642 | 0.3914961320641457 | 9.27E-15 | 13 | passed |
/ph_test/rows/0/df | exact | 1 | 1 | 0.00E+2 | passed | |
/ph_test/rows/0/p_value | tail_probability | 0.5315140178793788 | 0.5315140178793737 | 5.11E-15 | 14 | passed |
/ph_test/rows/1/chisq | tolerance | 0.77262492558592588 | 0.7726249255859352 | 9.33E-15 | 13 | passed |
/ph_test/rows/1/df | exact | 1 | 1 | 0.00E+2 | passed | |
/ph_test/rows/1/p_value | tail_probability | 0.3794062335739089 | 0.3794062335739061 | 2.77E-15 | 14 | passed |
/ph_test/rows/2/chisq | tolerance | 1.3778006806800822 | 1.3778006806801055 | 2.33E-14 | 13 | passed |
/ph_test/rows/2/df | exact | 2 | 2 | 0.00E+2 | passed | |
/ph_test/rows/2/p_value | tail_probability | 0.50212793541257561 | 0.5021279354125696 | 6.00E-15 | 13 | passed |
/subjects | exact | 16 | 16 | 0.00E+2 | passed | |
/episodes | exact | 28 | 28 | 0.00E+2 | passed | |
/events | exact | 13 | 13 | 0.00E+2 | passed | |
/gaps | exact | 1 | 1 | 0.00E+2 | passed | |
/strata_levels/0 | exact | F | F | passed | ||
/strata_levels/1 | exact | M | M | passed |
Convention
- coxph(... + strata(sex)): separate baseline hazards, common coefficients; 90% Wald limits on the log scale.
- Expected computed from the exported CSV.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:64-67: h(t) = h_0s(t) exp(z(t)'beta) on (start, stop] episodes; an event at t uses the covariates in force just before t.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:87-96: Efron or Breslow ties; partial likelihood; model-based covariance from the information matrix, robust covariance over whole subjects; Wald intervals on the log scale.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:97-101: the proportional-hazards score diagnostic with the KM transform; withheld for a model with a declared time interaction.
- Relative tolerance 1e-6 (1e-5 on tail probabilities): both implementations maximize the partial likelihood iteratively.
Reference code
The lines of the reference script that produce this case's expected values.
156 fit3 <- survival::coxph(survival::Surv(start, stop, status) ~ x + trt + survival::strata(sex), data = d,
157 ties = "efron", control = control)
158 emit("STAT-SURV-COXTD-003", "Stratified baseline hazards by sex with 90% intervals", "axis_coverage",
159 "SURV_COXTD_EPISODES", c(episode_config, list(strata = "sex", confidence_level = 0.90)),
160 c(coefficient_outputs(fit3, 0.90), zph_outputs(fit3), counts(d),
161 list("/strata_levels/0" = exact("F", "strata levels sorted naturally"),
162 "/strata_levels/1" = exact("M", "strata levels sorted naturally"))),
163 list("coxph(... + strata(sex)): separate baseline hazards, common coefficients; 90% Wald limits on the log scale."))
One row per subject with the covariate-by-time term x t
Case STAT-SURV-COXTD-004 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::coxph (counting process, cluster, strata, tt) and cox.zph
- Citation
- R survival package documentation: coxph, coxph.control, cox.zph; Therneau and Grambsch (2000).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_cox_time_dependent.R · sha256 4b0d7390bdbbf36e
- Dataset
- reference_data/datasets/SURV_COXTD_ONE.json
Settings compared
categorical_covariates= ["trt"]censored_value= "0"event_value= "1"layout= "one_row"numeric_covariates= ["x"]status= "status"stop= "time"time_covariates= ["x"]time_function= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | 0.37502225806326484 | 0.3750222580642295 | 9.65E-13 | 11 | passed |
/coefficients/0/standard_error | tolerance | 2.3242177725462785 | 2.324217772546371 | 9.24E-14 | 13 | passed |
/coefficients/0/z | tolerance | 0.16135418225135253 | 0.16135418225176118 | 4.09E-13 | 11 | passed |
/coefficients/0/p_value | tail_probability | 0.87181445101028854 | 0.8718144510099667 | 3.22E-13 | 12 | passed |
/coefficients/0/hazard_ratio | tolerance | 1.4550238002695772 | 1.455023800270981 | 1.40E-12 | 12 | passed |
/coefficients/0/lower | tolerance | 0.015292987815472312 | 0.015292987815484306 | 1.20E-14 | 12 | passed |
/coefficients/0/upper | tolerance | 138.43562061881735 | 138.43562061897586 | 1.59E-10 | 11 | passed |
/coefficients/1/coefficient | tolerance | 1.2865932124801374 | 1.286593212480069 | 6.84E-14 | 13 | passed |
/coefficients/1/standard_error | tolerance | 0.63533745567580802 | 0.6353374556758029 | 5.11E-15 | 14 | passed |
/coefficients/1/z | tolerance | 2.0250548759345364 | 2.025054875934445 | 9.15E-14 | 13 | passed |
/coefficients/1/p_value | tail_probability | 0.042861729688444011 | 0.042861729688453414 | 9.40E-15 | 12 | passed |
/coefficients/1/hazard_ratio | tolerance | 3.6204314813585934 | 3.6204314813583456 | 2.48E-13 | 13 | passed |
/coefficients/1/lower | tolerance | 1.0422216965716646 | 1.0422216965716038 | 6.08E-14 | 13 | passed |
/coefficients/1/upper | tolerance | 12.576522014777581 | 12.576522014776593 | 9.88E-13 | 13 | passed |
/coefficients/2/coefficient | tolerance | 0.10608898228594028 | 0.10608898228582904 | 1.11E-13 | 11 | passed |
/coefficients/2/standard_error | tolerance | 0.31343190699254397 | 0.31343190699255385 | 9.88E-15 | 13 | passed |
/coefficients/2/z | tolerance | 0.33847537509467396 | 0.33847537509430836 | 3.66E-13 | 11 | passed |
/coefficients/2/p_value | tail_probability | 0.73500498099000611 | 0.7350049809902816 | 2.75E-13 | 12 | passed |
/coefficients/2/hazard_ratio | tolerance | 1.1119208133604093 | 1.1119208133602856 | 1.24E-13 | 12 | passed |
/coefficients/2/lower | tolerance | 0.60156164279857982 | 0.6015616427985012 | 7.86E-14 | 12 | passed |
/coefficients/2/upper | tolerance | 2.0552638453347098 | 2.055263845334521 | 1.89E-13 | 13 | passed |
/tests/0/chisq | tolerance | 7.296144606801235 | 7.296144606801242 | 7.11E-15 | 15 | passed |
/tests/0/df | exact | 3 | 3 | 0.00E+2 | passed | |
/tests/0/p_value | tail_probability | 0.063034336686102532 | 0.06303433668610232 | 2.08E-16 | 14 | passed |
/tests/1/chisq | tolerance | 6.9700002329033595 | 6.970000232904086 | 7.26E-13 | 12 | passed |
/log_likelihood | tolerance | -23.111764797251904 | -23.111764797251904 | 4.69E-16 | 16 | passed |
/null_log_likelihood | tolerance | -26.759837100652522 | -26.759837100652526 | 3.52E-15 | 15 | passed |
/ph_test/status | exact | withheld | withheld | passed | ||
/split/cut_count | exact | 6 | 6 | 0.00E+2 | passed | |
/split/function | exact | time | time | passed | ||
/subjects | exact | 16 | 16 | 0.00E+2 | passed | |
/events | exact | 13 | 13 | 0.00E+2 | passed |
Convention
- coxph(Surv(time, status) ~ x + trt + tt(x), tt = function(x, t, ...) x * t): survival expands the data at each event time, the same expansion the product performs; terms x, trt = B (vs A), x x t.
- Expected computed from the exported CSV.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:64-67: h(t) = h_0s(t) exp(z(t)'beta) on (start, stop] episodes; an event at t uses the covariates in force just before t.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:87-96: Efron or Breslow ties; partial likelihood; model-based covariance from the information matrix, robust covariance over whole subjects; Wald intervals on the log scale.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:97-101: the proportional-hazards score diagnostic with the KM transform; withheld for a model with a declared time interaction.
- Relative tolerance 1e-6 (1e-5 on tail probabilities): both implementations maximize the partial likelihood iteratively.
Reference code
The lines of the reference script that produce this case's expected values.
166 fit4 <- survival::coxph(survival::Surv(time, status) ~ x + trt + tt(x), data = d1, ties = "efron",
167 tt = function(x, t, ...) x * t, control = control)
168 one_config <- list(layout = "one_row", stop = "time", status = "status", event_value = "1",
169 censored_value = "0", numeric_covariates = list("x"),
170 categorical_covariates = list("trt"))
171 cuts <- length(unique(d1$time[d1$status == 1L]))
172 emit("STAT-SURV-COXTD-004", "One row per subject with the covariate-by-time term x t", "axis_coverage",
173 "SURV_COXTD_ONE", c(one_config, list(time_function = "time", time_covariates = list("x"))),
174 c(coefficient_outputs(fit4, 0.95, names = c("x", "trt = B (vs A)", "x * t")),
175 list("/ph_test/status" = exact("withheld", "the model already has a declared time interaction"),
176 "/split/cut_count" = exact(cuts, "distinct event times"),
177 "/split/function" = exact("time", "g(t) = t"),
178 "/subjects" = exact(nrow(d1), "16 subjects"),
179 "/events" = exact(as.integer(sum(d1$status)), "events"))),
180 list("coxph(Surv(time, status) ~ x + trt + tt(x), tt = function(x, t, ...) x * t): survival expands the data at each event time, the same expansion the product performs; terms x, trt = B (vs A), x x t."))
One row per subject with the step function x 1{t > 8}
Case STAT-SURV-COXTD-005 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::coxph (counting process, cluster, strata, tt) and cox.zph
- Citation
- R survival package documentation: coxph, coxph.control, cox.zph; Therneau and Grambsch (2000).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_cox_time_dependent.R · sha256 4b0d7390bdbbf36e
- Dataset
- reference_data/datasets/SURV_COXTD_ONE.json
Settings compared
categorical_covariates= ["trt"]censored_value= "0"event_value= "1"layout= "one_row"numeric_covariates= ["x"]status= "status"step_time= 8stop= "time"time_covariates= ["x"]time_function= "step"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/coefficient | tolerance | 1.2246907536356919 | 1.2246907536376976 | 2.01E-12 | 11 | passed |
/coefficients/0/standard_error | tolerance | 0.68250261659951639 | 0.6825026165997251 | 2.09E-13 | 12 | passed |
/coefficients/0/z | tolerance | 1.7944118071481687 | 1.7944118071505588 | 2.39E-12 | 11 | passed |
/coefficients/0/p_value | tail_probability | 0.072747463741914084 | 0.07274746374153286 | 3.81E-13 | 11 | passed |
/coefficients/0/hazard_ratio | tolerance | 3.4031135195652786 | 3.4031135195721043 | 6.83E-12 | 11 | passed |
/coefficients/0/lower | tolerance | 0.89315977543156666 | 0.8931597754329929 | 1.43E-12 | 11 | passed |
/coefficients/0/upper | tolerance | 12.966528437145589 | 12.966528437176903 | 3.13E-11 | 11 | passed |
/coefficients/1/coefficient | tolerance | 1.2347410997278134 | 1.2347410997279382 | 1.25E-13 | 12 | passed |
/coefficients/1/standard_error | tolerance | 0.62365254478489895 | 0.6236525447848978 | 1.11E-15 | 14 | passed |
/coefficients/1/z | tolerance | 1.9798541833156187 | 1.9798541833158223 | 2.04E-13 | 12 | passed |
/coefficients/1/p_value | tail_probability | 0.047719915927424535 | 0.047719915927401685 | 2.29E-14 | 12 | passed |
/coefficients/1/hazard_ratio | tolerance | 3.4374884387964295 | 3.4374884387968585 | 4.29E-13 | 12 | passed |
/coefficients/1/lower | tolerance | 1.0124818289107109 | 1.0124818289108393 | 1.28E-13 | 12 | passed |
/coefficients/1/upper | tolerance | 11.670655639886233 | 11.670655639887668 | 1.44E-12 | 12 | passed |
/coefficients/2/coefficient | tolerance | -0.21624794810601 | -0.21624794810793527 | 1.93E-12 | 11 | passed |
/coefficients/2/standard_error | tolerance | 1.0910698744049492 | 1.0910698744050775 | 1.28E-13 | 12 | passed |
/coefficients/2/z | tolerance | -0.19819807436617928 | -0.19819807436792053 | 1.74E-12 | 11 | passed |
/coefficients/2/p_value | tail_probability | 0.84289009403597148 | 0.8428900940346091 | 1.36E-12 | 11 | passed |
/coefficients/2/hazard_ratio | tolerance | 0.8055355460969913 | 0.8055355460954404 | 1.55E-12 | 11 | passed |
/coefficients/2/lower | tolerance | 0.094921446673286877 | 0.09492144667308024 | 2.07E-13 | 11 | passed |
/coefficients/2/upper | tolerance | 6.8360474768068418 | 6.836047476795401 | 1.14E-11 | 11 | passed |
/tests/0/chisq | tolerance | 7.2223272871555935 | 7.222327287155601 | 7.07E-15 | 15 | passed |
/tests/0/df | exact | 3 | 3 | 0.00E+2 | passed | |
/tests/0/p_value | tail_probability | 0.065139123564258633 | 0.0651391235642584 | 2.36E-16 | 14 | passed |
/tests/1/chisq | tolerance | 6.9908666851247041 | 6.9908666851332155 | 8.51E-12 | 11 | passed |
/log_likelihood | tolerance | -23.148673457074725 | -23.148673457074725 | 2.35E-16 | 16 | passed |
/null_log_likelihood | tolerance | -26.759837100652522 | -26.759837100652526 | 3.52E-15 | 15 | passed |
/ph_test/status | exact | withheld | withheld | passed | ||
/split/cut_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- coxph(..., tt = function(x, t, ...) x * (t > 8)): the step is in force strictly after 8, so an event at exactly 8 uses the pre-step value; the product splits each episode once at the step time.
- Expected computed from the exported CSV.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:64-67: h(t) = h_0s(t) exp(z(t)'beta) on (start, stop] episodes; an event at t uses the covariates in force just before t.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:87-96: Efron or Breslow ties; partial likelihood; model-based covariance from the information matrix, robust covariance over whole subjects; Wald intervals on the log scale.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:97-101: the proportional-hazards score diagnostic with the KM transform; withheld for a model with a declared time interaction.
- Relative tolerance 1e-6 (1e-5 on tail probabilities): both implementations maximize the partial likelihood iteratively.
Reference code
The lines of the reference script that produce this case's expected values.
183 fit5 <- survival::coxph(survival::Surv(time, status) ~ x + trt + tt(x), data = d1, ties = "efron",
184 tt = function(x, t, ...) x * (t > 8), control = control)
185 emit("STAT-SURV-COXTD-005", "One row per subject with the step function x 1{t > 8}", "axis_coverage",
186 "SURV_COXTD_ONE", c(one_config, list(time_function = "step", time_covariates = list("x"), step_time = 8)),
187 c(coefficient_outputs(fit5, 0.95, names = c("x", "trt = B (vs A)", "x * 1{t > 8}")),
188 list("/ph_test/status" = exact("withheld", "the model already has a declared time interaction"),
189 "/split/cut_count" = exact(1L, "one cut at the step time"))),
190 list("coxph(..., tt = function(x, t, ...) x * (t > 8)): the step is in force strictly after 8, so an event at exactly 8 uses the pre-step value; the product splits each episode once at the step time."))
Degradation-based lifetime: repeated measurements, lognormal rates, no temperature axis
Case STAT-SURV-DEG-001 · status: imprecise_reference
Reference
- Evidence type
- R
- Source
- R survival::survreg lognormal pseudo-failure fits and base R delta-method algebra
- Citation
- Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, chapter 21 (pseudo-failure limits); Therneau T (2024), A Package for Survival Analysis in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_degradation.R · sha256 b4e6ab8a59ddbd26
- Dataset
- reference_data/datasets/SURV_DEG_B9.json
Settings compared
baseline= 0confidence_level= 0.95direction= "increasing"dropout_ignorable_declared= truelifetime_probabilities= [0.1, 0.5, 0.9]mode= "repeated"reliability_times= [10, 15, 20]response_column= "response"temperature_column= nullthreshold= 25time_column= "time"time_unit= "hours"unit_column= "unit"use_temperature= null
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/distance | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/unit_count | exact | 10 | 10 | 0.00E+2 | passed | |
/analyzed_count | exact | 40 | 40 | 0.00E+2 | passed | |
/source_count | exact | 40 | 40 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/unobserved_count | exact | 0 | 0 | 0.00E+2 | passed | |
/parameters/[name=beta0]/estimate | tolerance | 0.17000636587653029 | 0.17000636590860546 | imprecise_reference | ||
/parameters/[name=beta0]/standard_error | tolerance | 0.19149545678111374 | 0.19149545773885918 | imprecise_reference | ||
/parameters/[name=beta0]/lower | tolerance | -0.20531783261749903 | -0.20531783446257051 | imprecise_reference | ||
/parameters/[name=beta0]/upper | tolerance | 0.5453305643705596 | 0.5453305662797814 | imprecise_reference | ||
/parameters/[name=tau]/estimate | tolerance | 0.60556180500265533 | 0.6055618052716375 | imprecise_reference | ||
/parameters/[name=tau]/standard_error | tolerance | 0.22360679774781284 | 0.2236067996189082 | imprecise_reference | ||
/parameters/[name=tau]/lower | tolerance | 0.39068255880312558 | 0.3906825575439193 | imprecise_reference | ||
/parameters/[name=tau]/upper | tolerance | 0.93862674802144297 | 0.9386267518805747 | imprecise_reference | ||
/parameters/[name=sigma_e]/estimate | tolerance | 0.0010971163008572803 | 0.0010971162997829417 | imprecise_reference | ||
/lifetime/distance | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/lifetime/eta_use | tolerance | 0.17000636587653029 | 0.17000636590860546 | imprecise_reference | ||
/lifetime/tau | tolerance | 0.60556180500265533 | 0.6055618052716375 | imprecise_reference | ||
/lifetime/median/probability | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/lifetime/median/estimate | tolerance | 21.091486148685565 | 21.09148614800905 | imprecise_reference | ||
/lifetime/median/lower | tolerance | 14.491253499567261 | 14.491253471900238 | imprecise_reference | ||
/lifetime/median/upper | tolerance | 30.697881861874766 | 30.697881918514557 | imprecise_reference | ||
/lifetime/quantiles/0/probability | tolerance | 0.10000000000000001 | 0.1 | 4.45E-18 | 16 | passed |
/lifetime/quantiles/0/estimate | tolerance | 9.7066457497556158 | 9.706645746098252 | imprecise_reference | ||
/lifetime/quantiles/0/lower | tolerance | 5.8492042981335963 | 5.849204293392352 | imprecise_reference | ||
/lifetime/quantiles/0/upper | tolerance | 16.107998098358916 | 16.107998099277065 | imprecise_reference | ||
/lifetime/quantiles/1/probability | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/lifetime/quantiles/1/estimate | tolerance | 21.091486148685565 | 21.09148614800905 | imprecise_reference | ||
/lifetime/quantiles/1/lower | tolerance | 14.491253499567261 | 14.491253471900238 | imprecise_reference | ||
/lifetime/quantiles/1/upper | tolerance | 30.697881861874766 | 30.697881918514557 | imprecise_reference | ||
/lifetime/quantiles/2/probability | tolerance | 0.90000000000000002 | 0.9 | 2.20E-18 | 17 | passed |
/lifetime/quantiles/2/estimate | tolerance | 45.829506858370209 | 45.82950687269831 | imprecise_reference | ||
/lifetime/quantiles/2/lower | tolerance | 27.616764370335783 | 27.616764202961203 | imprecise_reference | ||
/lifetime/quantiles/2/upper | tolerance | 76.053214298249259 | 76.05321480673297 | imprecise_reference | ||
/lifetime/reliability/0/time | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/lifetime/reliability/0/reliability | tolerance | 0.89109706593229632 | 0.8910970658202142 | imprecise_reference | ||
/lifetime/reliability/0/lower | tolerance | 0.62725681443136538 | 0.6272568141643394 | imprecise_reference | ||
/lifetime/reliability/0/upper | tolerance | 0.97548205347619998 | 0.9754820534482685 | imprecise_reference | ||
/lifetime/reliability/1/time | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/lifetime/reliability/1/reliability | tolerance | 0.71321956218865967 | 0.7132195620854989 | imprecise_reference | ||
/lifetime/reliability/1/lower | tolerance | 0.45030218133483352 | 0.45030218095934355 | imprecise_reference | ||
/lifetime/reliability/1/upper | tolerance | 0.88304580054830917 | 0.8830458006007963 | imprecise_reference | ||
/lifetime/reliability/2/time | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/lifetime/reliability/2/reliability | tolerance | 0.53496174437056276 | 0.5349617443340232 | imprecise_reference | ||
/lifetime/reliability/2/lower | tolerance | 0.29903052801847685 | 0.29903052718979084 | imprecise_reference | ||
/lifetime/reliability/2/upper | tolerance | 0.75622067114727554 | 0.7562206718219427 | imprecise_reference | ||
/units/0/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/0/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/0/least_squares_rate | tolerance | 0.75624022253349976 | 0.7562402225334998 | 1.86E-18 | 17 | passed |
/units/0/empirical_bayes_rate | tolerance | 0.75624022253349976 | 0.7562402265972118 | imprecise_reference | ||
/units/1/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/1/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/1/least_squares_rate | tolerance | 0.76389243136369911 | 0.7638924313636991 | 7.52E-19 | 18 | passed |
/units/1/empirical_bayes_rate | tolerance | 0.76389243136369911 | 0.7638924352965764 | imprecise_reference | ||
/units/2/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/2/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/2/least_squares_rate | tolerance | 0.47685729150680095 | 0.47685729150680095 | 1.01E-18 | 17 | passed |
/units/2/empirical_bayes_rate | tolerance | 0.47685729150680095 | 0.47685730456429426 | imprecise_reference | ||
/units/3/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/3/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/3/least_squares_rate | tolerance | 0.57238702159626775 | 0.572387021596268 | 2.25E-16 | 15 | passed |
/units/3/empirical_bayes_rate | tolerance | 0.57238702159626775 | 0.5723870302930119 | imprecise_reference | ||
/units/4/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/4/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/4/least_squares_rate | tolerance | 1.2077437469737904 | 1.2077437469737902 | 2.33E-16 | 15 | passed |
/units/4/empirical_bayes_rate | tolerance | 1.2077437469737904 | 1.2077437468676409 | imprecise_reference | ||
/units/5/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/5/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/5/least_squares_rate | tolerance | 1.9606290237692825 | 1.9606290237692825 | 2.63E-18 | 17 | passed |
/units/5/empirical_bayes_rate | tolerance | 1.9606290237692825 | 1.960629022014015 | imprecise_reference | ||
/units/6/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/6/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/6/least_squares_rate | tolerance | 1.9904696804431705 | 1.9904696804431707 | 2.41E-16 | 15 | passed |
/units/6/empirical_bayes_rate | tolerance | 1.9904696804431705 | 1.9904696786623235 | imprecise_reference | ||
/units/7/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/7/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/7/least_squares_rate | tolerance | 3.2346183864343936 | 3.2346183864343936 | 1.12E-17 | 17 | passed |
/units/7/empirical_bayes_rate | tolerance | 3.2346183864343936 | 3.2346183843120464 | imprecise_reference | ||
/units/8/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/8/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/8/least_squares_rate | tolerance | 2.1736011642121134 | 2.1736011642121134 | 4.31E-17 | 16 | passed |
/units/8/empirical_bayes_rate | tolerance | 2.1736011642121134 | 2.1736011623044074 | imprecise_reference | ||
/units/9/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/9/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/9/least_squares_rate | tolerance | 1.0476817528456135 | 1.0476817528456135 | 1.02E-17 | 17 | passed |
/units/9/empirical_bayes_rate | tolerance | 1.0476817528456135 | 1.0476817536512257 | imprecise_reference | ||
/readings/0/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/0/response | tolerance | 3.0263316020586242 | 3.026331602058624 | 2.94E-17 | 17 | passed |
/readings/0/fitted | tolerance | 3.024960890133999 | 3.024960906388847 | imprecise_reference | ||
/readings/0/residual | tolerance | 0.0013707119246251231 | 0.001370695669776989 | imprecise_reference | ||
/readings/1/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/1/response | tolerance | 6.0518179747794854 | 6.051817974779485 | 4.60E-17 | 17 | passed |
/readings/1/fitted | tolerance | 6.0499217802679981 | 6.049921812777694 | imprecise_reference | ||
/readings/1/residual | tolerance | 0.0018961945114872591 | 0.0018961620017909908 | imprecise_reference | ||
/readings/2/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/2/response | tolerance | 9.0748034164743032 | 9.074803416474303 | 1.93E-17 | 17 | passed |
/readings/2/fitted | tolerance | 9.0748826704019976 | 9.074882719166542 | imprecise_reference | ||
/readings/2/residual | tolerance | -7.9253927694367121e-05 | -7.930269223876962e-05 | imprecise_reference | ||
/readings/3/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/3/response | tolerance | 12.098612225744867 | 12.098612225744867 | 3.88E-16 | 16 | passed |
/readings/3/fitted | tolerance | 12.099843560535996 | 12.099843625555389 | imprecise_reference | ||
/readings/3/residual | tolerance | -0.001231334791128802 | -0.0012313998105213386 | imprecise_reference | ||
/readings/4/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/4/response | tolerance | 3.0558858801117541 | 3.055885880111754 | 4.86E-18 | 17 | passed |
/readings/4/fitted | tolerance | 3.0555697254547964 | 3.0555697411863054 | imprecise_reference | ||
/readings/4/residual | tolerance | 0.00031615465695766787 | 0.0003161389254486835 | imprecise_reference | ||
/readings/5/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/5/response | tolerance | 6.1110851370290096 | 6.11108513702901 | 2.70E-17 | 17 | passed |
/readings/5/fitted | tolerance | 6.1111394509095929 | 6.111139482372611 | imprecise_reference | ||
/readings/5/residual | tolerance | -5.4313880583301e-05 | -5.434534360126975e-05 | imprecise_reference | ||
/readings/6/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/6/response | tolerance | 9.1663114782843369 | 9.166311478284337 | 5.35E-20 | 20 | passed |
/readings/6/fitted | tolerance | 9.1667091763643889 | 9.166709223558916 | imprecise_reference | ||
/readings/6/residual | tolerance | -0.00039769808005196694 | -0.00039774527457936415 | imprecise_reference | ||
/readings/7/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/7/response | tolerance | 12.222525293655279 | 12.222525293655279 | 1.56E-16 | 16 | passed |
/readings/7/fitted | tolerance | 12.222278901819186 | 12.222278964745222 | imprecise_reference | ||
/readings/7/residual | tolerance | 0.00024639183609309612 | 0.0002463289100571586 | imprecise_reference | ||
/readings/8/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/8/response | tolerance | 1.9073240451166302 | 1.9073240451166305 | 2.51E-16 | 15 | passed |
/readings/8/fitted | tolerance | 1.9074291660272038 | 1.907429218257177 | imprecise_reference | ||
/readings/8/residual | tolerance | -0.00010512091057357509 | -0.00010517314054658833 | imprecise_reference | ||
/readings/9/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/9/response | tolerance | 3.8155710757846069 | 3.8155710757846073 | 4.02E-16 | 15 | passed |
/readings/9/fitted | tolerance | 3.8148583320544076 | 3.814858436514354 | imprecise_reference | ||
/readings/9/residual | tolerance | 0.00071274373019925008 | 0.0007126392702532236 | imprecise_reference | ||
/readings/10/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/10/response | tolerance | 5.7219998532000007 | 5.721999853200001 | 7.43E-18 | 17 | passed |
/readings/10/fitted | tolerance | 5.7222874980816112 | 5.722287654771531 | imprecise_reference | ||
/readings/10/residual | tolerance | -0.00028764488161048263 | -0.0002878015715301885 | imprecise_reference | ||
/readings/11/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/11/response | tolerance | 7.6296023061325666 | 7.629602306132567 | 2.48E-17 | 17 | passed |
/readings/11/fitted | tolerance | 7.6297166641088152 | 7.629716873028708 | imprecise_reference | ||
/readings/11/residual | tolerance | -0.00011435797624859134 | -0.00011456689614153248 | imprecise_reference | ||
/readings/12/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/12/response | tolerance | 2.2897193014693644 | 2.2897193014693644 | 2.09E-17 | 17 | passed |
/readings/12/fitted | tolerance | 2.289548086385071 | 2.2895481211720474 | imprecise_reference | ||
/readings/12/residual | tolerance | 0.00017121508429340793 | 0.00017118029731699735 | imprecise_reference | ||
/readings/13/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/13/response | tolerance | 4.5804935952554091 | 4.580493595255409 | 1.16E-17 | 17 | passed |
/readings/13/fitted | tolerance | 4.579096172770142 | 4.579096242344095 | imprecise_reference | ||
/readings/13/residual | tolerance | 0.0013974224852670858 | 0.0013973529113142646 | imprecise_reference | ||
/readings/14/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/14/response | tolerance | 6.8685706392734813 | 6.868570639273481 | 2.64E-17 | 17 | passed |
/readings/14/fitted | tolerance | 6.8686442591552126 | 6.868644363516142 | imprecise_reference | ||
/readings/14/residual | tolerance | -7.3619881731268322e-05 | -7.372424266094413e-05 | imprecise_reference | ||
/readings/15/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/15/response | tolerance | 9.1575060454378789 | 9.157506045437879 | 3.87E-17 | 17 | passed |
/readings/15/fitted | tolerance | 9.1581923455402841 | 9.15819248468819 | imprecise_reference | ||
/readings/15/residual | tolerance | -0.00068630010240511297 | -0.0006864392503107553 | imprecise_reference | ||
/readings/16/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/16/response | tolerance | 4.8317240290115784 | 4.831724029011578 | 1.93E-17 | 17 | passed |
/readings/16/fitted | tolerance | 4.8309749878951616 | 4.830974987470563 | imprecise_reference | ||
/readings/16/residual | tolerance | 0.00074904111641682647 | 0.0007490415410149609 | imprecise_reference | ||
/readings/17/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/17/response | tolerance | 9.6630002761790088 | 9.663000276179009 | 7.28E-18 | 18 | passed |
/readings/17/fitted | tolerance | 9.6619499757903231 | 9.661949974941127 | imprecise_reference | ||
/readings/17/residual | tolerance | 0.0010503003886856987 | 0.0010503012378819676 | imprecise_reference | ||
/readings/18/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/18/response | tolerance | 14.492182910187827 | 14.492182910187827 | 5.19E-18 | 18 | passed |
/readings/18/fitted | tolerance | 14.492924963685486 | 14.49292496241169 | imprecise_reference | ||
/readings/18/residual | tolerance | -0.00074205349765854578 | -0.0007420522238632543 | imprecise_reference | ||
/readings/19/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/19/response | tolerance | 19.323744081230441 | 19.32374408123044 | 3.72E-16 | 16 | passed |
/readings/19/fitted | tolerance | 19.323899951580646 | 19.323899949882254 | imprecise_reference | ||
/readings/19/residual | tolerance | -0.00015587035020558915 | -0.00015586865181305143 | imprecise_reference | ||
/readings/20/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/20/response | tolerance | 7.8410217720602491 | 7.84102177206025 | 8.72E-16 | 15 | passed |
/readings/20/fitted | tolerance | 7.84251609507713 | 7.84251608805606 | imprecise_reference | ||
/readings/20/residual | tolerance | -0.0014943230168809052 | -0.0014943159958100694 | imprecise_reference | ||
/readings/21/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/21/response | tolerance | 15.684001997220079 | 15.68400199722008 | 2.61E-16 | 16 | passed |
/readings/21/fitted | tolerance | 15.68503219015426 | 15.68503217611212 | imprecise_reference | ||
/readings/21/residual | tolerance | -0.0010301929341807181 | -0.0010301788920408228 | imprecise_reference | ||
/readings/22/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/22/response | tolerance | 23.529066935769219 | 23.52906693576922 | 1.84E-16 | 17 | passed |
/readings/22/fitted | tolerance | 23.52754828523139 | 23.527548264168182 | imprecise_reference | ||
/readings/22/residual | tolerance | 0.0015186505378288473 | 0.001518671601036914 | imprecise_reference | ||
/readings/23/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/23/response | tolerance | 31.369814069626457 | 31.369814069626457 | 3.53E-16 | 16 | passed |
/readings/23/fitted | tolerance | 31.37006438030852 | 31.37006435222424 | imprecise_reference | ||
/readings/23/residual | tolerance | -0.00025031068206260443 | -0.0002502825977828138 | imprecise_reference | ||
/readings/24/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/24/response | tolerance | 7.9594971403220924 | 7.959497140322092 | 3.44E-17 | 17 | passed |
/readings/24/fitted | tolerance | 7.9618787217726821 | 7.961878714649294 | imprecise_reference | ||
/readings/24/residual | tolerance | -0.0023815814505896427 | -0.002381574327201541 | imprecise_reference | ||
/readings/25/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/25/response | tolerance | 15.923427778099033 | 15.923427778099034 | 1.31E-15 | 16 | passed |
/readings/25/fitted | tolerance | 15.923757443545364 | 15.923757429298588 | imprecise_reference | ||
/readings/25/residual | tolerance | -0.00032966544633161732 | -0.00032965119955363775 | imprecise_reference | ||
/readings/26/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/26/response | tolerance | 23.885503287327818 | 23.88550328732782 | 3.56E-16 | 16 | passed |
/readings/26/fitted | tolerance | 23.885636165318047 | 23.88563614394788 | imprecise_reference | ||
/readings/26/residual | tolerance | -0.00013287799022876357 | -0.0001328566200626824 | imprecise_reference | ||
/readings/27/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/27/response | tolerance | 31.848374773669214 | 31.848374773669217 | 3.32E-15 | 15 | passed |
/readings/27/fitted | tolerance | 31.847514887090728 | 31.847514858597176 | imprecise_reference | ||
/readings/27/residual | tolerance | 0.00085988657848545813 | 0.0008599150720414173 | imprecise_reference | ||
/readings/28/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/28/response | tolerance | 12.937876191598324 | 12.937876191598324 | 2.72E-17 | 17 | passed |
/readings/28/fitted | tolerance | 12.938473545737574 | 12.938473537248186 | imprecise_reference | ||
/readings/28/residual | tolerance | -0.00059735413925032788 | -0.0005973456498615803 | imprecise_reference | ||
/readings/29/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/29/response | tolerance | 25.876420168261962 | 25.876420168261962 | 1.18E-16 | 17 | passed |
/readings/29/fitted | tolerance | 25.876947091475149 | 25.87694707449637 | imprecise_reference | ||
/readings/29/residual | tolerance | -0.00052692321318659197 | -0.0005269062344090969 | imprecise_reference | ||
/readings/30/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/30/response | tolerance | 38.814448533720828 | 38.81444853372083 | 3.84E-17 | 18 | passed |
/readings/30/fitted | tolerance | 38.815420637212725 | 38.81542061174456 | imprecise_reference | ||
/readings/30/residual | tolerance | -0.00097210349189680301 | -0.000972078023728784 | imprecise_reference | ||
/readings/31/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/31/response | tolerance | 51.755036060710623 | 51.75503606071062 | 2.08E-16 | 17 | passed |
/readings/31/fitted | tolerance | 51.753894182950297 | 51.75389414899274 | imprecise_reference | ||
/readings/31/residual | tolerance | 0.0011418777603253716 | 0.0011419117178803617 | imprecise_reference | ||
/readings/32/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/32/response | tolerance | 8.6920891410898165 | 8.692089141089816 | 4.91E-17 | 17 | passed |
/readings/32/fitted | tolerance | 8.6944046568484534 | 8.69440464921763 | imprecise_reference | ||
/readings/32/residual | tolerance | -0.0023155157586369768 | -0.002315508127813004 | imprecise_reference | ||
/readings/33/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/33/response | tolerance | 17.390225896871446 | 17.390225896871446 | 4.01E-16 | 16 | passed |
/readings/33/fitted | tolerance | 17.388809313696907 | 17.38880929843526 | imprecise_reference | ||
/readings/33/residual | tolerance | 0.0014165831745387436 | 0.001416598436186689 | imprecise_reference | ||
/readings/34/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/34/response | tolerance | 26.083569075459302 | 26.0835690754593 | 3.00E-16 | 16 | passed |
/readings/34/fitted | tolerance | 26.083213970545359 | 26.083213947652887 | imprecise_reference | ||
/readings/34/residual | tolerance | 0.00035510491394319388 | 0.000355127806415112 | imprecise_reference | ||
/readings/35/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/35/response | tolerance | 34.777222886060741 | 34.77722288606074 | 3.03E-16 | 17 | passed |
/readings/35/fitted | tolerance | 34.777618627393814 | 34.77761859687052 | imprecise_reference | ||
/readings/35/residual | tolerance | -0.000395741333072408 | -0.0003957108097765172 | imprecise_reference | ||
/readings/36/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/36/response | tolerance | 4.1905707230989337 | 4.190570723098934 | 4.75E-17 | 16 | passed |
/readings/36/fitted | tolerance | 4.190727011382454 | 4.190727014604903 | imprecise_reference | ||
/readings/36/residual | tolerance | -0.00015628828352021173 | -0.00015629150596918606 | imprecise_reference | ||
/readings/37/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/37/response | tolerance | 8.3810038917830791 | 8.38100389178308 | 4.05E-17 | 17 | passed |
/readings/37/fitted | tolerance | 8.3814540227649079 | 8.381454029209806 | imprecise_reference | ||
/readings/37/residual | tolerance | -0.00045013098182877798 | -0.00045013742672672663 | imprecise_reference | ||
/readings/38/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/38/response | tolerance | 12.571758353896577 | 12.571758353896577 | 7.92E-17 | 17 | passed |
/readings/38/fitted | tolerance | 12.572181034147363 | 12.572181043814709 | imprecise_reference | ||
/readings/38/residual | tolerance | -0.00042268025078584515 | -0.00042268991813187995 | imprecise_reference | ||
/readings/39/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/39/response | tolerance | 16.7634891932797 | 16.7634891932797 | 3.37E-16 | 16 | passed |
/readings/39/fitted | tolerance | 16.762908045529816 | 16.76290805841961 | imprecise_reference | ||
/readings/39/residual | tolerance | 0.00058114774988382578 | 0.0005811348600879285 | imprecise_reference |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:97-104: y_ij = y0 + s exp(eta_i + u_i) t_ij + e_ij with u ~ N(0, tau^2) and log T ~ N(log D - eta, tau^2); failure is threshold crossing of the noise-free trajectory.
- docs/manual/chapters/96-repairable-degradation-warranty.tex:110-122: inverse-kelvin temperature acceleration and delta-method lifetime intervals for population quantities.
- Oracle: per-unit least-squares rates r_ls,i = sum(t z) / sum(t^2) with z = s (y - y0), pseudo-failure times t~_i = D / r_ls,i, then R survival::survreg(Surv(t~) ~ 1, dist = "lognormal") for STAT-SURV-DEG-001. survreg's intercept a and Log(scale) map to the engine's beta0 = log D - a and log tau; the lifetime covariance of (eta_use, log tau) is survreg's (Intercept, Log(scale)) covariance with the intercept signs flipped. survreg fits the observed information of the uncensored lognormal, which at the ML point equals the engine's marginal-likelihood information in this limit.
- Pseudo-failure limit: the data carry measurement noise SD 0.001 while the log rates spread over about 0.3, so sigma_e^2 / (tau^2 S_tt r^2) is below 2e-8 and the engine's direct marginal ML, its covariance, the empirical-Bayes rates and the fitted trajectories agree with the two-stage reference to well under 1e-6 relative (1e-7 absolute); the per-unit LS rates are closed-form algebra and allow 1e-9.
- Engine contract note: repeated-measurement mode estimates sigma_e and refuses a supplied measurement_sd (degradation_reliability_contracts), so the small calibrated error is carried by the data and the ML sigma_e is compared with its pseudo-failure limit sqrt(RSS / (N - g)).
- Not compared: the quadrature log-likelihood and its diagnostics (integration constants and search internals without a two-stage counterpart), the raw covariance matrix (its entries are covered through the parameter and lifetime intervals), the reliability curve (plot data) and text/boolean labels.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
246 BASE_NOTES <- c(
247 paste0(MANUAL, ":97-104: y_ij = y0 + s exp(eta_i + u_i) t_ij + e_ij with u ~ N(0, tau^2) and ",
248 "log T ~ N(log D - eta, tau^2); failure is threshold crossing of the noise-free trajectory."),
249 paste0(MANUAL, ":110-122: inverse-kelvin temperature acceleration and delta-method lifetime intervals ",
250 "for population quantities."),
251 paste0("Oracle: per-unit least-squares rates r_ls,i = sum(t z) / sum(t^2) with z = s (y - y0), ",
252 "pseudo-failure times t~_i = D / r_ls,i, then R survival::survreg(Surv(t~) ~ 1, dist = \"lognormal\") ",
253 "for STAT-SURV-DEG-001. survreg's intercept a and Log(scale) map to the engine's ",
254 "beta0 = log D - a and log tau; the lifetime covariance of (eta_use, log tau) is survreg's ",
255 "(Intercept, Log(scale)) covariance with the intercept signs flipped. survreg fits the ",
256 "observed information of the uncensored lognormal, which at the ML point equals the ",
257 "engine's marginal-likelihood information in this limit."),
258 paste0("Pseudo-failure limit: the data carry measurement noise SD 0.001 while the log rates spread ",
259 "over about 0.3, so sigma_e^2 / (tau^2 S_tt r^2) is below 2e-8 and the engine's direct ",
260 "marginal ML, its covariance, the empirical-Bayes rates and the fitted trajectories agree with ",
261 "the two-stage reference to well under 1e-6 relative (1e-7 absolute); the per-unit LS rates are ",
262 "closed-form algebra and allow 1e-9."),
263 paste0("Engine contract note: repeated-measurement mode estimates sigma_e and refuses a supplied ",
264 "measurement_sd (degradation_reliability_contracts), so the small calibrated error is carried by ",
265 "the data and the ML sigma_e is compared with its pseudo-failure limit sqrt(RSS / (N - g))."),
266 paste0("Not compared: the quadrature log-likelihood and its diagnostics (integration constants and ",
267 "search internals without a two-stage counterpart), the raw covariance matrix (its entries are ",
268 "covered through the parameter and lifetime intervals), the reliability curve (plot data) and ",
269 "text/boolean labels.")
Degradation-based lifetime: inverse-kelvin temperature acceleration to a use temperature
Case STAT-SURV-DEG-002 · status: imprecise_reference
Reference
- Evidence type
- R
- Source
- R survival::survreg lognormal pseudo-failure fits and base R delta-method algebra
- Citation
- Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, chapter 21 (pseudo-failure limits); Therneau T (2024), A Package for Survival Analysis in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_degradation.R · sha256 b4e6ab8a59ddbd26
- Dataset
- reference_data/datasets/SURV_DEG_B9.json
Settings compared
baseline= 0confidence_level= 0.95direction= "increasing"dropout_ignorable_declared= truelifetime_probabilities= [0.1, 0.5, 0.9]mode= "repeated"reliability_times= [10, 15, 20]response_column= "response"temperature_column= "temp_k"threshold= 25time_column= "time"time_unit= "hours"unit_column= "unit"use_temperature= 348
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/distance | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/unit_count | exact | 10 | 10 | 0.00E+2 | passed | |
/analyzed_count | exact | 40 | 40 | 0.00E+2 | passed | |
/source_count | exact | 40 | 40 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/unobserved_count | exact | 0 | 0 | 0.00E+2 | passed | |
/parameters/[name=beta0]/estimate | tolerance | 0.18442291929401433 | 0.18442291959155713 | imprecise_reference | ||
/parameters/[name=beta0]/standard_error | tolerance | 0.10728519418877107 | 0.10728519510674801 | imprecise_reference | ||
/parameters/[name=beta0]/lower | tolerance | -0.025852197390362819 | -0.02585219889202181 | imprecise_reference | ||
/parameters/[name=beta0]/upper | tolerance | 0.39469803597839148 | 0.39469803807513604 | imprecise_reference | ||
/parameters/[name=beta1]/estimate | tolerance | 6070.7229914576328 | 6070.722998408129 | imprecise_reference | ||
/parameters/[name=beta1]/standard_error | tolerance | 1297.6581124447355 | 1297.6581243496578 | imprecise_reference | ||
/parameters/[name=beta1]/lower | tolerance | 3527.3598268197243 | 3527.3598104370003 | imprecise_reference | ||
/parameters/[name=beta1]/upper | tolerance | 8614.0861560955418 | 8614.086186379256 | imprecise_reference | ||
/parameters/[name=tau]/estimate | tolerance | 0.33912558754423405 | 0.3391255857275501 | imprecise_reference | ||
/parameters/[name=tau]/standard_error | tolerance | 0.22360679773672509 | 0.22360680311450437 | imprecise_reference | ||
/parameters/[name=tau]/lower | tolerance | 0.21878931465912554 | 0.2187893111809839 | imprecise_reference | ||
/parameters/[name=tau]/upper | tolerance | 0.52564799293970055 | 0.5256479956642859 | imprecise_reference | ||
/parameters/[name=sigma_e]/estimate | tolerance | 0.0010971163008572803 | 0.0010971162989607591 | imprecise_reference | ||
/lifetime/distance | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/lifetime/eta_use | tolerance | 0.18442291929401433 | 0.18442291959155713 | imprecise_reference | ||
/lifetime/tau | tolerance | 0.33912558754423405 | 0.3391255857275501 | imprecise_reference | ||
/lifetime/median/probability | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/lifetime/median/estimate | tolerance | 20.789600912842172 | 20.789600906656375 | imprecise_reference | ||
/lifetime/median/lower | tolerance | 16.84708742749315 | 16.847087392169104 | imprecise_reference | ||
/lifetime/median/upper | tolerance | 25.654731595321259 | 25.654731633845927 | imprecise_reference | ||
/lifetime/quantiles/0/probability | tolerance | 0.10000000000000001 | 0.1 | 4.45E-18 | 16 | passed |
/lifetime/quantiles/0/estimate | tolerance | 13.461664482033413 | 13.46166450936909 | imprecise_reference | ||
/lifetime/quantiles/0/lower | tolerance | 10.136366676489601 | 10.136366690369554 | imprecise_reference | ||
/lifetime/quantiles/0/upper | tolerance | 17.877846807491213 | 17.877846855617303 | imprecise_reference | ||
/lifetime/quantiles/1/probability | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/lifetime/quantiles/1/estimate | tolerance | 20.789600912842172 | 20.789600906656375 | imprecise_reference | ||
/lifetime/quantiles/1/lower | tolerance | 16.84708742749315 | 16.847087392169104 | imprecise_reference | ||
/lifetime/quantiles/1/upper | tolerance | 25.654731595321259 | 25.654731633845927 | imprecise_reference | ||
/lifetime/quantiles/2/probability | tolerance | 0.90000000000000002 | 0.9 | 2.20E-18 | 17 | passed |
/lifetime/quantiles/2/estimate | tolerance | 32.1065427452967 | 32.106542660994 | imprecise_reference | ||
/lifetime/quantiles/2/lower | tolerance | 24.175590649660538 | 24.175590422119463 | imprecise_reference | ||
/lifetime/quantiles/2/upper | tolerance | 42.639292747539898 | 42.63929292494423 | imprecise_reference | ||
/lifetime/reliability/0/time | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/lifetime/reliability/0/reliability | tolerance | 0.98454007221096607 | 0.9845400726261883 | imprecise_reference | ||
/lifetime/reliability/0/lower | tolerance | 0.7800800370064539 | 0.780080032819208 | imprecise_reference | ||
/lifetime/reliability/0/upper | tolerance | 0.99912613779064918 | 0.9991261378595953 | imprecise_reference | ||
/lifetime/reliability/1/time | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/lifetime/reliability/1/reliability | tolerance | 0.83209654848720471 | 0.832096549561325 | imprecise_reference | ||
/lifetime/reliability/1/lower | tolerance | 0.56292257374820431 | 0.5629225725146134 | imprecise_reference | ||
/lifetime/reliability/1/upper | tolerance | 0.95017299567562441 | 0.9501729966409735 | imprecise_reference | ||
/lifetime/reliability/2/time | tolerance | 20 | 20.0 | 0.00E+2 | passed | |
/lifetime/reliability/2/reliability | tolerance | 0.54545159671335519 | 0.5454515966080308 | imprecise_reference | ||
/lifetime/reliability/2/lower | tolerance | 0.30743610155641549 | 0.307436098879358 | imprecise_reference | ||
/lifetime/reliability/2/upper | tolerance | 0.76436340439614947 | 0.7643634065076927 | imprecise_reference | ||
/units/0/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/0/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/0/least_squares_rate | tolerance | 0.75624022253349976 | 0.7562402225334998 | 1.86E-18 | 17 | passed |
/units/0/empirical_bayes_rate | tolerance | 0.75624022253349976 | 0.7562402210257444 | imprecise_reference | ||
/units/0/temperature | tolerance | 338 | 338.0 | 0.00E+2 | passed | |
/units/1/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/1/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/1/least_squares_rate | tolerance | 0.76389243136369911 | 0.7638924313636991 | 7.52E-19 | 18 | passed |
/units/1/empirical_bayes_rate | tolerance | 0.76389243136369911 | 0.763892429583672 | imprecise_reference | ||
/units/1/temperature | tolerance | 338 | 338.0 | 0.00E+2 | passed | |
/units/2/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/2/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/2/least_squares_rate | tolerance | 0.47685729150680095 | 0.47685729150680095 | 1.01E-18 | 17 | passed |
/units/2/empirical_bayes_rate | tolerance | 0.47685729150680095 | 0.47685731020142397 | imprecise_reference | ||
/units/2/temperature | tolerance | 338 | 338.0 | 0.00E+2 | passed | |
/units/3/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/3/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/3/least_squares_rate | tolerance | 0.57238702159626775 | 0.572387021596268 | 2.25E-16 | 15 | passed |
/units/3/empirical_bayes_rate | tolerance | 0.57238702159626775 | 0.5723870302149758 | imprecise_reference | ||
/units/3/temperature | tolerance | 338 | 338.0 | 0.00E+2 | passed | |
/units/4/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/4/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/4/least_squares_rate | tolerance | 1.2077437469737904 | 1.2077437469737902 | 2.33E-16 | 15 | passed |
/units/4/empirical_bayes_rate | tolerance | 1.2077437469737904 | 1.2077437375778144 | imprecise_reference | ||
/units/4/temperature | tolerance | 338 | 338.0 | 0.00E+2 | passed | |
/units/5/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/5/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/5/least_squares_rate | tolerance | 1.9606290237692825 | 1.9606290237692825 | 2.63E-18 | 17 | passed |
/units/5/empirical_bayes_rate | tolerance | 1.9606290237692825 | 1.960629023751901 | imprecise_reference | ||
/units/5/temperature | tolerance | 358 | 358.0 | 0.00E+2 | passed | |
/units/6/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/6/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/6/least_squares_rate | tolerance | 1.9904696804431705 | 1.9904696804431707 | 2.41E-16 | 15 | passed |
/units/6/empirical_bayes_rate | tolerance | 1.9904696804431705 | 1.990469680260581 | imprecise_reference | ||
/units/6/temperature | tolerance | 358 | 358.0 | 0.00E+2 | passed | |
/units/7/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/7/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/7/least_squares_rate | tolerance | 3.2346183864343936 | 3.2346183864343936 | 1.12E-17 | 17 | passed |
/units/7/empirical_bayes_rate | tolerance | 3.2346183864343936 | 3.2346183830490394 | imprecise_reference | ||
/units/7/temperature | tolerance | 358 | 358.0 | 0.00E+2 | passed | |
/units/8/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/8/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/8/least_squares_rate | tolerance | 2.1736011642121134 | 2.1736011642121134 | 4.31E-17 | 16 | passed |
/units/8/empirical_bayes_rate | tolerance | 2.1736011642121134 | 2.1736011631619934 | imprecise_reference | ||
/units/8/temperature | tolerance | 358 | 358.0 | 0.00E+2 | passed | |
/units/9/readings | exact | 4 | 4 | 0.00E+2 | passed | |
/units/9/distinct_positive_times | exact | 4 | 4 | 0.00E+2 | passed | |
/units/9/least_squares_rate | tolerance | 1.0476817528456135 | 1.0476817528456135 | 1.02E-17 | 17 | passed |
/units/9/empirical_bayes_rate | tolerance | 1.0476817528456135 | 1.0476817658556574 | imprecise_reference | ||
/units/9/temperature | tolerance | 358 | 358.0 | 0.00E+2 | passed | |
/readings/0/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/0/response | tolerance | 3.0263316020586242 | 3.026331602058624 | 2.94E-17 | 17 | passed |
/readings/0/fitted | tolerance | 3.024960890133999 | 3.0249608841029776 | imprecise_reference | ||
/readings/0/residual | tolerance | 0.0013707119246251231 | 0.0013707179556465832 | imprecise_reference | ||
/readings/1/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/1/response | tolerance | 6.0518179747794854 | 6.051817974779485 | 4.60E-17 | 17 | passed |
/readings/1/fitted | tolerance | 6.0499217802679981 | 6.049921768205955 | imprecise_reference | ||
/readings/1/residual | tolerance | 0.0018961945114872591 | 0.0018962065735301792 | imprecise_reference | ||
/readings/2/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/2/response | tolerance | 9.0748034164743032 | 9.074803416474303 | 1.93E-17 | 17 | passed |
/readings/2/fitted | tolerance | 9.0748826704019976 | 9.074882652308933 | imprecise_reference | ||
/readings/2/residual | tolerance | -7.9253927694367121e-05 | -7.923583462954298e-05 | imprecise_reference | ||
/readings/3/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/3/response | tolerance | 12.098612225744867 | 12.098612225744867 | 3.88E-16 | 16 | passed |
/readings/3/fitted | tolerance | 12.099843560535996 | 12.09984353641191 | imprecise_reference | ||
/readings/3/residual | tolerance | -0.001231334791128802 | -0.0012313106670429619 | imprecise_reference | ||
/readings/4/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/4/response | tolerance | 3.0558858801117541 | 3.055885880111754 | 4.86E-18 | 17 | passed |
/readings/4/fitted | tolerance | 3.0555697254547964 | 3.055569718334688 | imprecise_reference | ||
/readings/4/residual | tolerance | 0.00031615465695766787 | 0.00031616177706617066 | imprecise_reference | ||
/readings/5/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/5/response | tolerance | 6.1110851370290096 | 6.11108513702901 | 2.70E-17 | 17 | passed |
/readings/5/fitted | tolerance | 6.1111394509095929 | 6.111139436669376 | imprecise_reference | ||
/readings/5/residual | tolerance | -5.4313880583301e-05 | -5.429964036629542e-05 | imprecise_reference | ||
/readings/6/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/6/response | tolerance | 9.1663114782843369 | 9.166311478284337 | 5.35E-20 | 20 | passed |
/readings/6/fitted | tolerance | 9.1667091763643889 | 9.166709155004064 | imprecise_reference | ||
/readings/6/residual | tolerance | -0.00039769808005196694 | -0.00039767671972690266 | imprecise_reference | ||
/readings/7/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/7/response | tolerance | 12.222525293655279 | 12.222525293655279 | 1.56E-16 | 16 | passed |
/readings/7/fitted | tolerance | 12.222278901819186 | 12.222278873338752 | imprecise_reference | ||
/readings/7/residual | tolerance | 0.00024639183609309612 | 0.0002464203165271073 | imprecise_reference | ||
/readings/8/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/8/response | tolerance | 1.9073240451166302 | 1.9073240451166305 | 2.51E-16 | 15 | passed |
/readings/8/fitted | tolerance | 1.9074291660272038 | 1.9074292408056959 | imprecise_reference | ||
/readings/8/residual | tolerance | -0.00010512091057357509 | -0.00010519568906541821 | imprecise_reference | ||
/readings/9/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/9/response | tolerance | 3.8155710757846069 | 3.8155710757846073 | 4.02E-16 | 15 | passed |
/readings/9/fitted | tolerance | 3.8148583320544076 | 3.8148584816113917 | imprecise_reference | ||
/readings/9/residual | tolerance | 0.00071274373019925008 | 0.0007125941732155638 | imprecise_reference | ||
/readings/10/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/10/response | tolerance | 5.7219998532000007 | 5.721999853200001 | 7.43E-18 | 17 | passed |
/readings/10/fitted | tolerance | 5.7222874980816112 | 5.722287722417088 | imprecise_reference | ||
/readings/10/residual | tolerance | -0.00028764488161048263 | -0.00028786921708690016 | imprecise_reference | ||
/readings/11/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/11/response | tolerance | 7.6296023061325666 | 7.629602306132567 | 2.48E-17 | 17 | passed |
/readings/11/fitted | tolerance | 7.6297166641088152 | 7.6297169632227835 | imprecise_reference | ||
/readings/11/residual | tolerance | -0.00011435797624859134 | -0.000114657090216852 | imprecise_reference | ||
/readings/12/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/12/response | tolerance | 2.2897193014693644 | 2.2897193014693644 | 2.09E-17 | 17 | passed |
/readings/12/fitted | tolerance | 2.289548086385071 | 2.2895481208599033 | imprecise_reference | ||
/readings/12/residual | tolerance | 0.00017121508429340793 | 0.0001711806094610857 | imprecise_reference | ||
/readings/13/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/13/response | tolerance | 4.5804935952554091 | 4.580493595255409 | 1.16E-17 | 17 | passed |
/readings/13/fitted | tolerance | 4.579096172770142 | 4.579096241719807 | imprecise_reference | ||
/readings/13/residual | tolerance | 0.0013974224852670858 | 0.0013973535356024414 | imprecise_reference | ||
/readings/14/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/14/response | tolerance | 6.8685706392734813 | 6.868570639273481 | 2.64E-17 | 17 | passed |
/readings/14/fitted | tolerance | 6.8686442591552126 | 6.86864436257971 | imprecise_reference | ||
/readings/14/residual | tolerance | -7.3619881731268322e-05 | -7.372330622867906e-05 | imprecise_reference | ||
/readings/15/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/15/response | tolerance | 9.1575060454378789 | 9.157506045437879 | 3.87E-17 | 17 | passed |
/readings/15/fitted | tolerance | 9.1581923455402841 | 9.158192483439613 | imprecise_reference | ||
/readings/15/residual | tolerance | -0.00068630010240511297 | -0.0006864380017344018 | imprecise_reference | ||
/readings/16/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/16/response | tolerance | 4.8317240290115784 | 4.831724029011578 | 1.93E-17 | 17 | passed |
/readings/16/fitted | tolerance | 4.8309749878951616 | 4.830974950311258 | imprecise_reference | ||
/readings/16/residual | tolerance | 0.00074904111641682647 | 0.0007490787003208155 | imprecise_reference | ||
/readings/17/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/17/response | tolerance | 9.6630002761790088 | 9.663000276179009 | 7.28E-18 | 18 | passed |
/readings/17/fitted | tolerance | 9.6619499757903231 | 9.661949900622515 | imprecise_reference | ||
/readings/17/residual | tolerance | 0.0010503003886856987 | 0.0010503755564936768 | imprecise_reference | ||
/readings/18/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/18/response | tolerance | 14.492182910187827 | 14.492182910187827 | 5.19E-18 | 18 | passed |
/readings/18/fitted | tolerance | 14.492924963685486 | 14.492924850933772 | imprecise_reference | ||
/readings/18/residual | tolerance | -0.00074205349765854578 | -0.0007419407459448024 | imprecise_reference | ||
/readings/19/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/19/response | tolerance | 19.323744081230441 | 19.32374408123044 | 3.72E-16 | 16 | passed |
/readings/19/fitted | tolerance | 19.323899951580646 | 19.32389980124503 | imprecise_reference | ||
/readings/19/residual | tolerance | -0.00015587035020558915 | -0.00015572001458963314 | imprecise_reference | ||
/readings/20/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/20/response | tolerance | 7.8410217720602491 | 7.84102177206025 | 8.72E-16 | 15 | passed |
/readings/20/fitted | tolerance | 7.84251609507713 | 7.842516095007604 | imprecise_reference | ||
/readings/20/residual | tolerance | -0.0014943230168809052 | -0.0014943229473542985 | imprecise_reference | ||
/readings/21/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/21/response | tolerance | 15.684001997220079 | 15.68400199722008 | 2.61E-16 | 16 | passed |
/readings/21/fitted | tolerance | 15.68503219015426 | 15.685032190015209 | imprecise_reference | ||
/readings/21/residual | tolerance | -0.0010301929341807181 | -0.001030192795129281 | imprecise_reference | ||
/readings/22/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/22/response | tolerance | 23.529066935769219 | 23.52906693576922 | 1.84E-16 | 17 | passed |
/readings/22/fitted | tolerance | 23.52754828523139 | 23.527548285022814 | imprecise_reference | ||
/readings/22/residual | tolerance | 0.0015186505378288473 | 0.0015186507464051147 | imprecise_reference | ||
/readings/23/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/23/response | tolerance | 31.369814069626457 | 31.369814069626457 | 3.53E-16 | 16 | passed |
/readings/23/fitted | tolerance | 31.37006438030852 | 31.370064380030417 | imprecise_reference | ||
/readings/23/residual | tolerance | -0.00025031068206260443 | -0.00025031040395973037 | imprecise_reference | ||
/readings/24/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/24/response | tolerance | 7.9594971403220924 | 7.959497140322092 | 3.44E-17 | 17 | passed |
/readings/24/fitted | tolerance | 7.9618787217726821 | 7.961878721042324 | imprecise_reference | ||
/readings/24/residual | tolerance | -0.0023815814505896427 | -0.0023815807202316464 | imprecise_reference | ||
/readings/25/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/25/response | tolerance | 15.923427778099033 | 15.923427778099034 | 1.31E-15 | 16 | passed |
/readings/25/fitted | tolerance | 15.923757443545364 | 15.923757442084648 | imprecise_reference | ||
/readings/25/residual | tolerance | -0.00032966544633161732 | -0.00032966398561384835 | imprecise_reference | ||
/readings/26/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/26/response | tolerance | 23.885503287327818 | 23.88550328732782 | 3.56E-16 | 16 | passed |
/readings/26/fitted | tolerance | 23.885636165318047 | 23.88563616312697 | imprecise_reference | ||
/readings/26/residual | tolerance | -0.00013287799022876357 | -0.0001328757991529983 | imprecise_reference | ||
/readings/27/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/27/response | tolerance | 31.848374773669214 | 31.848374773669217 | 3.32E-15 | 15 | passed |
/readings/27/fitted | tolerance | 31.847514887090728 | 31.847514884169296 | imprecise_reference | ||
/readings/27/residual | tolerance | 0.00085988657848545813 | 0.0008598894999209961 | imprecise_reference | ||
/readings/28/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/28/response | tolerance | 12.937876191598324 | 12.937876191598324 | 2.72E-17 | 17 | passed |
/readings/28/fitted | tolerance | 12.938473545737574 | 12.938473532196157 | imprecise_reference | ||
/readings/28/residual | tolerance | -0.00059735413925032788 | -0.0005973405978334512 | imprecise_reference | ||
/readings/29/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/29/response | tolerance | 25.876420168261962 | 25.876420168261962 | 1.18E-16 | 17 | passed |
/readings/29/fitted | tolerance | 25.876947091475149 | 25.876947064392315 | imprecise_reference | ||
/readings/29/residual | tolerance | -0.00052692321318659197 | -0.0005268961303528386 | imprecise_reference | ||
/readings/30/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/30/response | tolerance | 38.814448533720828 | 38.81444853372083 | 3.84E-17 | 18 | passed |
/readings/30/fitted | tolerance | 38.815420637212725 | 38.815420596588474 | imprecise_reference | ||
/readings/30/residual | tolerance | -0.00097210349189680301 | -0.0009720628676461729 | imprecise_reference | ||
/readings/31/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/31/response | tolerance | 51.755036060710623 | 51.75503606071062 | 2.08E-16 | 17 | passed |
/readings/31/fitted | tolerance | 51.753894182950297 | 51.75389412878463 | imprecise_reference | ||
/readings/31/residual | tolerance | 0.0011418777603253716 | 0.0011419319259928784 | imprecise_reference | ||
/readings/32/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/32/response | tolerance | 8.6920891410898165 | 8.692089141089816 | 4.91E-17 | 17 | passed |
/readings/32/fitted | tolerance | 8.6944046568484534 | 8.694404652647973 | imprecise_reference | ||
/readings/32/residual | tolerance | -0.0023155157586369768 | -0.002315511558157013 | imprecise_reference | ||
/readings/33/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/33/response | tolerance | 17.390225896871446 | 17.390225896871446 | 4.01E-16 | 16 | passed |
/readings/33/fitted | tolerance | 17.388809313696907 | 17.388809305295947 | imprecise_reference | ||
/readings/33/residual | tolerance | 0.0014165831745387436 | 0.0014165915754986713 | imprecise_reference | ||
/readings/34/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/34/response | tolerance | 26.083569075459302 | 26.0835690754593 | 3.00E-16 | 16 | passed |
/readings/34/fitted | tolerance | 26.083213970545359 | 26.08321395794392 | imprecise_reference | ||
/readings/34/residual | tolerance | 0.00035510491394319388 | 0.00035511751538308545 | imprecise_reference | ||
/readings/35/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/35/response | tolerance | 34.777222886060741 | 34.77722288606074 | 3.03E-16 | 17 | passed |
/readings/35/fitted | tolerance | 34.777618627393814 | 34.777618610591894 | imprecise_reference | ||
/readings/35/residual | tolerance | -0.000395741333072408 | -0.00039572453115255257 | imprecise_reference | ||
/readings/36/time | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/readings/36/response | tolerance | 4.1905707230989337 | 4.190570723098934 | 4.75E-17 | 16 | passed |
/readings/36/fitted | tolerance | 4.190727011382454 | 4.19072706342263 | imprecise_reference | ||
/readings/36/residual | tolerance | -0.00015628828352021173 | -0.00015634032369593598 | imprecise_reference | ||
/readings/37/time | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/readings/37/response | tolerance | 8.3810038917830791 | 8.38100389178308 | 4.05E-17 | 17 | passed |
/readings/37/fitted | tolerance | 8.3814540227649079 | 8.38145412684526 | imprecise_reference | ||
/readings/37/residual | tolerance | -0.00045013098182877798 | -0.00045023506218022646 | imprecise_reference | ||
/readings/38/time | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/readings/38/response | tolerance | 12.571758353896577 | 12.571758353896577 | 7.92E-17 | 17 | passed |
/readings/38/fitted | tolerance | 12.572181034147363 | 12.572181190267889 | imprecise_reference | ||
/readings/38/residual | tolerance | -0.00042268025078584515 | -0.0004228363713121297 | imprecise_reference | ||
/readings/39/time | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/readings/39/response | tolerance | 16.7634891932797 | 16.7634891932797 | 3.37E-16 | 16 | passed |
/readings/39/fitted | tolerance | 16.762908045529816 | 16.76290825369052 | imprecise_reference | ||
/readings/39/residual | tolerance | 0.00058114774988382578 | 0.0005809395891809288 | imprecise_reference |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:97-104: y_ij = y0 + s exp(eta_i + u_i) t_ij + e_ij with u ~ N(0, tau^2) and log T ~ N(log D - eta, tau^2); failure is threshold crossing of the noise-free trajectory.
- docs/manual/chapters/96-repairable-degradation-warranty.tex:110-122: inverse-kelvin temperature acceleration and delta-method lifetime intervals for population quantities.
- Oracle: per-unit least-squares rates r_ls,i = sum(t z) / sum(t^2) with z = s (y - y0), pseudo-failure times t~_i = D / r_ls,i, then R survival::survreg(Surv(t~) ~ 1, dist = "lognormal") for STAT-SURV-DEG-001. survreg's intercept a and Log(scale) map to the engine's beta0 = log D - a and log tau; the lifetime covariance of (eta_use, log tau) is survreg's (Intercept, Log(scale)) covariance with the intercept signs flipped. survreg fits the observed information of the uncensored lognormal, which at the ML point equals the engine's marginal-likelihood information in this limit.
- Pseudo-failure limit: the data carry measurement noise SD 0.001 while the log rates spread over about 0.3, so sigma_e^2 / (tau^2 S_tt r^2) is below 2e-8 and the engine's direct marginal ML, its covariance, the empirical-Bayes rates and the fitted trajectories agree with the two-stage reference to well under 1e-6 relative (1e-7 absolute); the per-unit LS rates are closed-form algebra and allow 1e-9.
- Engine contract note: repeated-measurement mode estimates sigma_e and refuses a supplied measurement_sd (degradation_reliability_contracts), so the small calibrated error is carried by the data and the ML sigma_e is compared with its pseudo-failure limit sqrt(RSS / (N - g)).
- Not compared: the quadrature log-likelihood and its diagnostics (integration constants and search internals without a two-stage counterpart), the raw covariance matrix (its entries are covered through the parameter and lifetime intervals), the reliability curve (plot data) and text/boolean labels.
- Temperature oracle: x_i = 1/348 - 1/temp_k_i and R survival::survreg(Surv(t~) ~ x_i, dist = "lognormal"); the engine's beta0 = log D - a and beta1 = -b, with the covariance of (eta_use, log tau) taken from the (Intercept, Log(scale)) block with the intercept signs flipped; beta1's own covariance enters only through the parameter table.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
292 emit("STAT-SURV-DEG-002",
293 "Degradation-based lifetime: inverse-kelvin temperature acceleration to a use temperature",
294 list(
295 mode = "repeated", response_column = "response", time_column = "time",
296 unit_column = "unit", direction = "increasing", baseline = 0, threshold = 25,
297 time_unit = "hours", temperature_column = "temp_k", use_temperature = 348,
298 dropout_ignorable_declared = TRUE,
299 lifetime_probabilities = as.list(probabilities),
300 reliability_times = as.list(r_times),
301 confidence_level = 0.95
302 ),
303 c(counts_outputs,
304 parameter_outputs(TRUE, sqrt(V2[1, 1]), sqrt(V2[2, 2]), eta2, tau2),
305 lifetime_outputs(eta2, tau2, cov2),
306 units_outputs(TRUE),
307 readings_outputs()),
308 c(BASE_NOTES,
309 paste0("Temperature oracle: x_i = 1/348 - 1/temp_k_i and R survival::survreg(Surv(t~) ~ x_i, ",
310 "dist = \"lognormal\"); the engine's beta0 = log D - a and beta1 = -b, with the ",
311 "covariance of (eta_use, log tau) taken from the (Intercept, Log(scale)) block with the ",
312 "intercept signs flipped; beta1's own covariance enters only through the parameter table.")),
Distribution identification of complete data across the seven families
Case STAT-SURV-DISTID-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_COMPLETE_B9.json
Settings compared
confidence_level= 0.95end= "time"families= ["weibull", "lognormal", "exponential", "loglogistic", "logistic", "normal", "sev"]frequency= "freq"layout= "arbitrary"start= "time"threshold= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/plotted_points | exact | 29 | 29 | 0.00E+2 | passed | |
/families/0/parameters/0/estimate | tolerance | 1.4595326611918638 | 1.4595326610849495 | 1.07E-10 | 10 | passed |
/families/0/parameters/0/standard_error | tolerance | 0.18723284231648502 | 0.18723283409389968 | 8.22E-9 | 7 | passed |
/families/0/parameters/0/lower | tolerance | 1.1350614018356773 | 1.1350614142648274 | 1.24E-8 | 7 | passed |
/families/0/parameters/0/upper | tolerance | 1.8767580199984615 | 1.8767579991726309 | 2.08E-8 | 7 | passed |
/families/0/parameters/1/estimate | tolerance | 102.80061609192241 | 102.8006160820555 | 9.87E-9 | 10 | passed |
/families/0/parameters/1/standard_error | tolerance | 13.929072918301591 | 13.929072309316787 | 6.09E-7 | 7 | passed |
/families/0/parameters/1/lower | tolerance | 78.824515103739557 | 78.82451600937345 | 9.06E-7 | 7 | passed |
/families/0/parameters/1/upper | tolerance | 134.06954238754912 | 134.0695408214555 | 1.57E-6 | 7 | passed |
/families/0/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/families/0/log_likelihood | tolerance | -156.6748912336796 | -156.67489123367957 | 2.60E-14 | 15 | passed |
/families/0/anderson_darling | tolerance | 1.9386424431683142 | 1.938642442892537 | 2.76E-10 | 9 | passed |
/families/0/correlation | tolerance | 0.91574892089630389 | 0.9157489208963039 | 3.75E-18 | 17 | passed |
/families/0/percentiles/0/estimate | tolerance | 4.39732028874701 | 4.397320287309709 | 1.44E-9 | 9 | passed |
/families/0/percentiles/0/standard_error | tolerance | 2.0602750385974726 | 2.0602749355258534 | 1.03E-7 | 7 | passed |
/families/0/percentiles/0/lower | tolerance | 1.7553952489030149 | 1.7553953284467223 | 7.95E-8 | 7 | passed |
/families/0/percentiles/0/upper | tolerance | 11.015425576610083 | 11.015425070257848 | 5.06E-7 | 7 | passed |
/families/0/percentiles/1/estimate | tolerance | 13.433608110157257 | 13.433608106865318 | 3.29E-9 | 9 | passed |
/families/0/percentiles/1/standard_error | tolerance | 4.4724770656227655 | 4.472476834883403 | 2.31E-7 | 7 | passed |
/families/0/percentiles/1/lower | tolerance | 6.9952059083392601 | 6.995206140999287 | 2.33E-7 | 7 | passed |
/families/0/percentiles/1/upper | tolerance | 25.797929213512809 | 25.79792834283194 | 8.71E-7 | 7 | passed |
/families/0/percentiles/2/estimate | tolerance | 21.997973290135619 | 21.997973285539697 | 4.60E-9 | 9 | passed |
/families/0/percentiles/2/standard_error | tolerance | 6.0610771034545223 | 6.061076786150473 | 3.17E-7 | 7 | passed |
/families/0/percentiles/2/lower | tolerance | 12.81893827414455 | 12.818938632424153 | 3.58E-7 | 7 | passed |
/families/0/percentiles/2/upper | tolerance | 37.749680864721462 | 37.74967979387285 | 1.07E-6 | 7 | passed |
/families/0/percentiles/3/estimate | tolerance | 79.971851614984203 | 79.9718516058374 | 9.15E-9 | 9 | passed |
/families/0/percentiles/3/standard_error | tolerance | 11.968945681281818 | 11.968945101914214 | 5.79E-7 | 7 | passed |
/families/0/percentiles/3/lower | tolerance | 59.640670068925537 | 59.64067090695542 | 8.38E-7 | 7 | passed |
/families/0/percentiles/3/upper | tolerance | 107.23382288190092 | 107.23382135059487 | 1.53E-6 | 7 | passed |
/families/1/parameters/0/estimate | tolerance | 4.3109265209806535 | 4.3109265209806535 | 4.24E-17 | 17 | passed |
/families/1/parameters/0/standard_error | tolerance | 0.11224120293950285 | 0.11224119186732778 | 1.11E-8 | 7 | passed |
/families/1/parameters/0/lower | tolerance | 4.0909378056377772 | 4.090937827338841 | 2.17E-8 | 8 | passed |
/families/1/parameters/0/upper | tolerance | 4.5309152363235299 | 4.530915214622466 | 2.17E-8 | 8 | passed |
/families/1/parameters/1/estimate | tolerance | 0.60443737598025249 | 0.6044373759639441 | 1.63E-11 | 10 | passed |
/families/1/parameters/1/standard_error | tolerance | 0.079366515726289083 | 0.07936651180992675 | 3.92E-9 | 7 | passed |
/families/1/parameters/1/lower | tolerance | 0.46728632665049924 | 0.46728633256885405 | 5.92E-9 | 7 | passed |
/families/1/parameters/1/upper | tolerance | 0.78184299570817062 | 0.7818429857636491 | 9.94E-9 | 7 | passed |
/families/1/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/families/1/log_likelihood | tolerance | -151.56582746173058 | -151.56582746173055 | 3.06E-14 | 15 | passed |
/families/1/anderson_darling | tolerance | 0.93903047193802291 | 0.9390304719296438 | 8.38E-12 | 11 | passed |
/families/1/correlation | tolerance | 0.95875239412569058 | 0.9587523941256908 | 2.19E-16 | 15 | passed |
/families/1/percentiles/0/estimate | tolerance | 18.261498133972708 | 18.26149813466553 | 6.93E-10 | 10 | passed |
/families/1/percentiles/0/standard_error | tolerance | 3.9458296370325532 | 3.9458294103456772 | 2.27E-7 | 7 | passed |
/families/1/percentiles/0/lower | tolerance | 11.956776973390184 | 11.9567772649416 | 2.92E-7 | 7 | passed |
/families/1/percentiles/0/upper | tolerance | 27.890652710111912 | 27.890652032148683 | 6.78E-7 | 7 | passed |
/families/1/percentiles/1/estimate | tolerance | 27.569649471701236 | 27.569649472440783 | 7.40E-10 | 10 | passed |
/families/1/percentiles/1/standard_error | tolerance | 4.7464996513163245 | 4.746499345047304 | 3.06E-7 | 7 | passed |
/families/1/percentiles/1/lower | tolerance | 19.673653928495821 | 19.67365435755773 | 4.29E-7 | 7 | passed |
/families/1/percentiles/1/upper | tolerance | 38.634692607434197 | 38.634691766924526 | 8.41E-7 | 7 | passed |
/families/1/percentiles/2/estimate | tolerance | 34.339931321791205 | 34.33993132250891 | 7.18E-10 | 10 | passed |
/families/1/percentiles/2/standard_error | tolerance | 5.2015051205988279 | 5.201504753321065 | 3.67E-7 | 7 | passed |
/families/1/percentiles/2/lower | tolerance | 25.519199026157828 | 25.519199561796018 | 5.36E-7 | 7 | passed |
/families/1/percentiles/2/upper | tolerance | 46.209557046700205 | 46.20955607871094 | 9.68E-7 | 7 | passed |
/families/1/percentiles/3/estimate | tolerance | 74.509491576417588 | 74.50949157641759 | 2.13E-17 | 18 | passed |
/families/1/percentiles/3/standard_error | tolerance | 8.3630349649478646 | 8.36303413996573 | 8.25E-7 | 7 | passed |
/families/1/percentiles/3/lower | tolerance | 59.795942389602011 | 59.7959436872376 | 1.30E-6 | 7 | passed |
/families/1/percentiles/3/upper | tolerance | 92.843495948340944 | 92.84349393353831 | 2.01E-6 | 7 | passed |
/families/2/parameters/0/estimate | tolerance | 91.910344827586158 | 91.91034522211537 | 3.95E-7 | 8 | passed |
/families/2/parameters/0/standard_error | tolerance | 17.067322564728059 | 17.067321515461632 | 1.05E-6 | 7 | passed |
/families/2/parameters/0/lower | tolerance | 63.870488394146662 | 63.87049019722167 | 1.80E-6 | 7 | passed |
/families/2/parameters/0/upper | tolerance | 132.26001082371491 | 132.2600082254557 | 2.60E-6 | 7 | passed |
/families/2/parameters/1/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/families/2/log_likelihood | tolerance | -160.10359408561541 | -160.10359408561538 | 2.57E-14 | 15 | passed |
/families/2/anderson_darling | tolerance | 3.0630278137696507 | 3.0630277987367185 | 1.50E-8 | 8 | passed |
/families/2/correlation | tolerance | 0.91574892089630389 | 0.9157489208963039 | 3.75E-18 | 17 | passed |
/families/2/percentiles/0/estimate | tolerance | 0.92372983392837094 | 0.9237298378935213 | 3.97E-9 | 8 | passed |
/families/2/percentiles/0/standard_error | tolerance | 0.17153232389556075 | 0.17153231335008065 | 1.05E-8 | 7 | passed |
/families/2/percentiles/0/lower | tolerance | 0.64191985948834085 | 0.6419198776098493 | 1.81E-8 | 7 | passed |
/families/2/percentiles/0/upper | tolerance | 1.3292575287660715 | 1.3292575026526936 | 2.61E-8 | 7 | passed |
/families/2/percentiles/1/estimate | tolerance | 4.7143843745026635 | 4.714384394739362 | 2.02E-8 | 8 | passed |
/families/2/percentiles/1/standard_error | tolerance | 0.87543920071988113 | 0.8754391468995486 | 5.38E-8 | 7 | passed |
/families/2/percentiles/1/lower | tolerance | 3.2761277638775987 | 3.2761278563632508 | 9.25E-8 | 7 | passed |
/families/2/percentiles/1/upper | tolerance | 6.7840516708814311 | 6.784051537608156 | 1.33E-7 | 7 | passed |
/families/2/percentiles/2/estimate | tolerance | 9.6837213253231056 | 9.683721366890907 | 4.16E-8 | 8 | passed |
/families/2/percentiles/2/standard_error | tolerance | 1.7982219063182026 | 1.798221795766951 | 1.11E-7 | 7 | passed |
/families/2/percentiles/2/lower | tolerance | 6.7294275925245044 | 6.729427782497413 | 1.90E-7 | 7 | passed |
/families/2/percentiles/2/upper | tolerance | 13.934982941296283 | 13.934982667542366 | 2.74E-7 | 7 | passed |
/families/2/percentiles/3/estimate | tolerance | 63.707396381533698 | 63.70739665500051 | 2.73E-7 | 8 | passed |
/families/2/percentiles/3/standard_error | tolerance | 11.830166515448388 | 11.830165788152323 | 7.27E-7 | 7 | passed |
/families/2/percentiles/3/lower | tolerance | 44.27164895138948 | 44.27165020118581 | 1.25E-6 | 7 | passed |
/families/2/percentiles/3/upper | tolerance | 91.675653603285824 | 91.67565180230979 | 1.80E-6 | 7 | passed |
/families/3/parameters/0/estimate | tolerance | 4.2606212988226764 | 4.260621298860236 | 3.76E-11 | 11 | passed |
/families/3/parameters/0/standard_error | tolerance | 0.10082303110555134 | 0.1008230282926573 | 2.81E-9 | 7 | passed |
/families/3/parameters/0/lower | tolerance | 4.0630117890436344 | 4.063011794594365 | 5.55E-9 | 8 | passed |
/families/3/parameters/0/upper | tolerance | 4.4582308086017184 | 4.458230803126106 | 5.48E-9 | 8 | passed |
/families/3/parameters/1/estimate | tolerance | 0.31981833239045437 | 0.3198183323885435 | 1.91E-12 | 11 | passed |
/families/3/parameters/1/standard_error | tolerance | 0.051426970436022811 | 0.05142696821533871 | 2.22E-9 | 7 | passed |
/families/3/parameters/1/lower | tolerance | 0.2333617432214373 | 0.23336174639546234 | 3.17E-9 | 7 | passed |
/families/3/parameters/1/upper | tolerance | 0.43830562936768058 | 0.4383056234009131 | 5.97E-9 | 7 | passed |
/families/3/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/families/3/log_likelihood | tolerance | -150.69088825062573 | -150.69088825062573 | 2.78E-15 | 16 | passed |
/families/3/anderson_darling | tolerance | 0.67991582048463384 | 0.679915820484315 | 3.19E-13 | 12 | passed |
/families/3/correlation | tolerance | 0.96601633516655727 | 0.9660163351665576 | 3.35E-16 | 15 | passed |
/families/3/percentiles/0/estimate | tolerance | 16.297597938520106 | 16.297597939275335 | 7.55E-10 | 10 | passed |
/families/3/percentiles/0/standard_error | tolerance | 4.0819920410959947 | 4.081991877827583 | 1.63E-7 | 7 | passed |
/families/3/percentiles/0/lower | tolerance | 9.975316058349895 | 9.97531625490249 | 1.97E-7 | 7 | passed |
/families/3/percentiles/0/upper | tolerance | 26.626895530124386 | 26.626895007938575 | 5.22E-7 | 7 | passed |
/families/3/percentiles/1/estimate | tolerance | 27.630928266024078 | 27.63092826721733 | 1.19E-9 | 10 | passed |
/families/3/percentiles/1/standard_error | tolerance | 4.8645500729056197 | 4.864549891611753 | 1.81E-7 | 7 | passed |
/families/3/percentiles/1/lower | tolerance | 19.567601184467108 | 19.567601437240043 | 2.53E-7 | 7 | passed |
/families/3/percentiles/1/upper | tolerance | 39.016954078572212 | 39.0169535779238 | 5.01E-7 | 7 | passed |
/families/3/percentiles/2/estimate | tolerance | 35.089733633402155 | 35.08973363486742 | 1.47E-9 | 10 | passed |
/families/3/percentiles/2/standard_error | tolerance | 5.1292313608578928 | 5.129231181639326 | 1.79E-7 | 7 | passed |
/families/3/percentiles/2/lower | tolerance | 26.348502625926312 | 26.34850289110059 | 2.65E-7 | 7 | passed |
/families/3/percentiles/2/upper | tolerance | 46.73090626605682 | 46.730905799654515 | 4.66E-7 | 8 | passed |
/families/3/percentiles/3/estimate | tolerance | 70.853991283220964 | 70.8539912858822 | 2.66E-9 | 10 | passed |
/families/3/percentiles/3/standard_error | tolerance | 7.1437141671006508 | 7.143713968064195 | 1.99E-7 | 7 | passed |
/families/3/percentiles/3/lower | tolerance | 58.149180676863693 | 58.149180999634126 | 3.23E-7 | 8 | passed |
/families/3/percentiles/3/upper | tolerance | 86.334631413993733 | 86.3346309412588 | 4.73E-7 | 8 | passed |
/families/4/parameters/0/estimate | tolerance | 76.745789866434151 | 76.74578978842892 | 7.80E-8 | 8 | passed |
/families/4/parameters/0/standard_error | tolerance | 9.7096622449476122 | 9.709662075594196 | 1.69E-7 | 7 | passed |
/families/4/parameters/0/lower | tolerance | 57.715201564288506 | 57.71520181820987 | 2.54E-7 | 8 | passed |
/families/4/parameters/0/upper | tolerance | 95.776378168579797 | 95.77637775864798 | 4.10E-7 | 8 | passed |
/families/4/parameters/1/estimate | tolerance | 31.860861105603224 | 31.86086114958954 | 4.40E-8 | 8 | passed |
/families/4/parameters/1/standard_error | tolerance | 5.3330058542923116 | 5.333005775046561 | 7.92E-8 | 7 | passed |
/families/4/parameters/1/lower | tolerance | 22.94984678030427 | 22.949846934261156 | 1.54E-7 | 8 | passed |
/families/4/parameters/1/upper | tolerance | 44.231862639785433 | 44.23186246519097 | 1.75E-7 | 8 | passed |
/families/4/log_likelihood | tolerance | -161.20621692962214 | -161.20621692962212 | 2.43E-14 | 15 | passed |
/families/4/anderson_darling | tolerance | 2.2850821374490211 | 2.285082138196159 | 7.47E-10 | 9 | passed |
/families/4/correlation | tolerance | 0.828083962829812 | 0.8280839628298118 | 2.18E-16 | 15 | passed |
/families/4/percentiles/0/estimate | tolerance | -69.658685442304304 | -69.65868572243194 | 2.80E-7 | 8 | passed |
/families/4/percentiles/0/standard_error | tolerance | 25.019235168012774 | 25.019234866860174 | 3.01E-7 | 7 | passed |
/families/4/percentiles/0/lower | tolerance | -118.69548529234726 | -118.69548498222665 | 3.10E-7 | 8 | passed |
/families/4/percentiles/0/upper | tolerance | -20.62188559226135 | -20.621886462637228 | 8.70E-7 | 7 | passed |
/families/4/percentiles/1/estimate | tolerance | -17.06657148271195 | -17.066571690232195 | 2.08E-7 | 7 | passed |
/families/4/percentiles/1/standard_error | tolerance | 17.226011462101358 | 17.22601126677909 | 1.95E-7 | 7 | passed |
/families/4/percentiles/1/lower | tolerance | -50.828933545704764 | -50.8289333704004 | 1.75E-7 | 8 | passed |
/families/4/percentiles/1/upper | tolerance | 16.695790580280864 | 16.69578998993601 | 5.90E-7 | 7 | passed |
/families/4/percentiles/2/estimate | tolerance | 6.740322790107129 | 6.74032261545409 | 1.75E-7 | 7 | passed |
/families/4/percentiles/2/standard_error | tolerance | 14.094791438309462 | 14.094791279795755 | 1.59E-7 | 7 | passed |
/families/4/percentiles/2/lower | tolerance | -20.884960798582917 | -20.884960662554807 | 1.36E-7 | 8 | passed |
/families/4/percentiles/2/upper | tolerance | 34.365606378797175 | 34.365605893462984 | 4.85E-7 | 7 | passed |
/families/4/percentiles/3/estimate | tolerance | 76.745789866434151 | 76.74578978842892 | 7.80E-8 | 8 | passed |
/families/4/percentiles/3/standard_error | tolerance | 9.7096622449476122 | 9.709662075594196 | 1.69E-7 | 7 | passed |
/families/4/percentiles/3/lower | tolerance | 57.715201564288506 | 57.71520181820987 | 2.54E-7 | 8 | passed |
/families/4/percentiles/3/upper | tolerance | 95.776378168579797 | 95.77637775864798 | 4.10E-7 | 8 | passed |
/families/5/parameters/0/estimate | tolerance | 91.910344827586201 | 91.91034482165585 | 5.93E-9 | 10 | passed |
/families/5/parameters/0/standard_error | tolerance | 13.608356131127607 | 13.608355236229201 | 8.95E-7 | 7 | passed |
/families/5/parameters/0/lower | tolerance | 65.238456921781264 | 65.23845866981956 | 1.75E-6 | 7 | passed |
/families/5/parameters/0/upper | tolerance | 118.58223273339114 | 118.58223097349214 | 1.76E-6 | 7 | passed |
/families/5/parameters/1/estimate | tolerance | 73.283240520301447 | 73.28324052397654 | 3.68E-9 | 10 | passed |
/families/5/parameters/1/standard_error | tolerance | 9.6225609010286473 | 9.622560585163434 | 3.16E-7 | 7 | passed |
/families/5/parameters/1/lower | tolerance | 56.654762972327305 | 56.65476345450954 | 4.82E-7 | 8 | passed |
/families/5/parameters/1/upper | tolerance | 94.792265634921264 | 94.7922648376626 | 7.97E-7 | 8 | passed |
/families/5/log_likelihood | tolerance | -165.68484373661835 | -165.68484373661832 | 3.09E-14 | 15 | passed |
/families/5/anderson_darling | tolerance | 3.4323566267857415 | 3.43235662642073 | 3.65E-10 | 9 | passed |
/families/5/correlation | tolerance | 0.81705983567554019 | 0.8170598356755402 | 1.42E-18 | 17 | passed |
/families/5/percentiles/0/estimate | tolerance | -78.571965959640679 | -78.57196597412056 | 1.45E-8 | 9 | passed |
/families/5/percentiles/0/standard_error | tolerance | 26.19722444271077 | 26.197223349954445 | 1.09E-6 | 7 | passed |
/families/5/percentiles/0/lower | tolerance | -129.91758236226616 | -129.917580234983 | 2.13E-6 | 7 | passed |
/families/5/percentiles/0/upper | tolerance | -27.22634955701519 | -27.226351713258104 | 2.16E-6 | 7 | passed |
/families/5/percentiles/1/estimate | tolerance | -28.629859136988756 | -28.629859148964115 | 1.20E-8 | 9 | passed |
/families/5/percentiles/1/standard_error | tolerance | 20.873513762434943 | 20.8735127850522 | 9.77E-7 | 7 | passed |
/families/5/percentiles/1/lower | tolerance | -69.541194342162385 | -69.54119243850278 | 1.90E-6 | 7 | passed |
/families/5/percentiles/1/upper | tolerance | 12.28147606818488 | 12.281474140574552 | 1.93E-6 | 6 | passed |
/families/5/percentiles/2/estimate | tolerance | -2.0059067893876517 | -2.0059068000277875 | 1.06E-8 | 8 | passed |
/families/5/percentiles/2/standard_error | tolerance | 18.364662937998226 | 18.36466200305147 | 9.35E-7 | 7 | passed |
/families/5/percentiles/2/lower | tolerance | -37.9999847360817 | -37.99998291425988 | 1.82E-6 | 7 | passed |
/families/5/percentiles/2/upper | tolerance | 33.988171157306397 | 33.988169314204306 | 1.84E-6 | 7 | passed |
/families/5/percentiles/3/estimate | tolerance | 91.910344827586201 | 91.91034482165585 | 5.93E-9 | 10 | passed |
/families/5/percentiles/3/standard_error | tolerance | 13.608356131127607 | 13.608355236229201 | 8.95E-7 | 7 | passed |
/families/5/percentiles/3/lower | tolerance | 65.238456921781264 | 65.23845866981956 | 1.75E-6 | 7 | passed |
/families/5/percentiles/3/upper | tolerance | 118.58223273339114 | 118.58223097349214 | 1.76E-6 | 7 | passed |
/families/6/parameters/0/estimate | tolerance | 135.08981907760682 | 135.08981900933614 | 6.83E-8 | 9 | passed |
/families/6/parameters/0/standard_error | tolerance | 20.503230834965581 | 20.50322775594901 | 3.08E-6 | 6 | passed |
/families/6/parameters/0/lower | tolerance | 94.904225074363183 | 94.90423104085409 | 5.97E-6 | 7 | passed |
/families/6/parameters/0/upper | tolerance | 175.27541308085046 | 175.2754069778182 | 6.10E-6 | 7 | passed |
/families/6/parameters/1/estimate | tolerance | 103.32865952037881 | 103.32865957331981 | 5.29E-8 | 9 | passed |
/families/6/parameters/1/standard_error | tolerance | 12.413524997715685 | 12.413524585621605 | 4.12E-7 | 7 | passed |
/families/6/parameters/1/lower | tolerance | 81.650824320989486 | 81.6508250109145 | 6.90E-7 | 8 | passed |
/families/6/parameters/1/upper | tolerance | 130.76183819412765 | 130.76183722322236 | 9.71E-7 | 8 | passed |
/families/6/log_likelihood | tolerance | -175.6181871797304 | -175.61818717973037 | 3.00E-14 | 15 | passed |
/families/6/anderson_darling | tolerance | 4.7015942824491228 | 4.70159428082696 | 1.62E-9 | 9 | passed |
/families/6/correlation | tolerance | 0.71563575238792587 | 0.715635752387926 | 1.13E-16 | 15 | passed |
/families/6/percentiles/0/estimate | tolerance | -340.23743411892411 | -340.23743443073147 | 3.12E-7 | 9 | passed |
/families/6/percentiles/0/standard_error | tolerance | 67.13074260752856 | 67.13073884178078 | 3.77E-6 | 7 | passed |
/families/6/percentiles/0/lower | tolerance | -471.81127188510857 | -471.81126481618594 | 7.07E-6 | 7 | passed |
/families/6/percentiles/0/upper | tolerance | -208.66359635273969 | -208.66360404527703 | 7.69E-6 | 7 | passed |
/families/6/percentiles/1/estimate | tolerance | -171.81647451971764 | -171.81647474523353 | 2.26E-7 | 8 | passed |
/families/6/percentiles/1/standard_error | tolerance | 48.090377620529779 | 48.09037427625514 | 3.34E-6 | 7 | passed |
/families/6/percentiles/1/lower | tolerance | -266.07188265888703 | -266.07187632974507 | 6.33E-6 | 7 | passed |
/families/6/percentiles/1/upper | tolerance | -77.561066380548283 | -77.56107316072199 | 6.78E-6 | 7 | passed |
/families/6/percentiles/2/estimate | tolerance | -97.437620282045714 | -97.4376204694531 | 1.87E-7 | 8 | passed |
/families/6/percentiles/2/standard_error | tolerance | 40.055815822493663 | 40.05581260538721 | 3.22E-6 | 7 | passed |
/families/6/percentiles/2/lower | tolerance | -175.94557666550293 | -175.94557054749754 | 6.12E-6 | 7 | passed |
/families/6/percentiles/2/upper | tolerance | -18.929663898588515 | -18.92967039140865 | 6.49E-6 | 6 | passed |
/families/6/percentiles/3/estimate | tolerance | 97.218530297004378 | 97.21853020933014 | 8.77E-8 | 9 | passed |
/families/6/percentiles/3/standard_error | tolerance | 22.513014974902102 | 22.513011852099535 | 3.12E-6 | 6 | passed |
/families/6/percentiles/3/lower | tolerance | 53.093831762785356 | 53.09383779569168 | 6.03E-6 | 6 | passed |
/families/6/percentiles/3/upper | tolerance | 141.3432288312234 | 141.3432226229686 | 6.21E-6 | 7 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:53-62: probability-plot positions follow Benard median ranks (i - 0.3)/(n + 0.4) for complete data, with frequencies expanding ranks; the Anderson-Darling statistic is the complete-data form; no family is selected automatically.
- R: survreg per family; A2 computed from its definition by the exact piecewise closed form c^2 log(u2/u1) - (1-c)^2 log((1-u2)/(1-u1)) - (u2-u1); the correlation is exact arithmetic on the plotted points (1e-9 tolerance).
- Iterative maximum likelihood: 1e-7 absolute or 1e-6 relative elsewhere.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
526 ALL7 <- c("weibull", "lognormal", "exponential", "loglogistic", "logistic", "normal", "sev")
527 DISTID_NOTES <- c(
528 paste0(MANUAL, ":53-62: probability-plot positions follow Benard median ranks (i - 0.3)/(n + 0.4) for complete data, with frequencies expanding ranks; the Anderson-Darling statistic is the complete-data form; no family is selected automatically."),
529 "R: survreg per family; A2 computed from its definition by the exact piecewise closed form c^2 log(u2/u1) - (1-c)^2 log((1-u2)/(1-u1)) - (u2-u1); the correlation is exact arithmetic on the plotted points (1e-9 tolerance).",
530 "Iterative maximum likelihood: 1e-7 absolute or 1e-6 relative elsewhere."
531 )
532 emit("STAT-SURV-DISTID-001",
533 "Distribution identification of complete data across the seven families",
534 DISTID, "lifeDistributionIdMenuItem", DISTID_REQ, "SURV_COMPLETE_B9",
535 list(layout = "arbitrary", start = "time", end = "time", frequency = "freq",
536 families = as.list(ALL7), threshold = 0.0, confidence_level = 0.95),
537 c(list("/plotted_points" = exact(sum(cd$freq), "frequencies expand the ranks")),
538 ident_complete(ALL7, 0.0, 0.95)),
539 DISTID_NOTES, "nominal")
Distribution identification of right-censored data with the restricted-domain AD
Case STAT-SURV-DISTID-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_KM_B9.json
Settings compared
confidence_level= 0.95families= ["weibull", "lognormal", "exponential", "loglogistic", "logistic", "normal", "sev"]frequency= "freq"layout= "right_censored"start= "time"status= "status"threshold= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/plotted_points | exact | 13 | 13 | 0.00E+2 | passed | |
/families/0/parameters/0/estimate | tolerance | 1.776699100737525 | 1.7766991003853603 | 3.52E-10 | 9 | passed |
/families/0/parameters/0/standard_error | tolerance | 0.37847126482734345 | 0.378471234743612 | 3.01E-8 | 7 | passed |
/families/0/parameters/0/lower | tolerance | 1.1702846104380873 | 1.1702846489473235 | 3.85E-8 | 7 | passed |
/families/0/parameters/0/upper | tolerance | 2.69734359181213 | 2.6973435019843928 | 8.98E-8 | 7 | passed |
/families/0/parameters/1/estimate | tolerance | 156.74130136193452 | 156.74130134371723 | 1.82E-8 | 9 | passed |
/families/0/parameters/1/standard_error | tolerance | 23.984650000443729 | 23.984648127357556 | 1.87E-6 | 7 | passed |
/families/0/parameters/1/lower | tolerance | 116.12669508527753 | 116.12669778764241 | 2.70E-6 | 7 | passed |
/families/0/parameters/1/upper | tolerance | 211.56061949917211 | 211.56061452680308 | 4.97E-6 | 7 | passed |
/families/0/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/families/0/log_likelihood | tolerance | -84.270365465784479 | -84.27036546578447 | 1.38E-14 | 15 | passed |
/families/0/anderson_darling | tolerance | 0.90503565763681471 | 0.9050356570196434 | 6.17E-10 | 9 | passed |
/families/0/ad_domain_probability | tolerance | 0.91606628160699788 | 0.9160662816125402 | 5.54E-12 | 11 | passed |
/families/0/correlation | tolerance | 0.9730952048403384 | 0.9730952048403384 | 1.38E-18 | 17 | passed |
/families/0/percentiles/0/estimate | tolerance | 11.768679928194297 | 11.768679920786738 | 7.41E-9 | 9 | passed |
/families/0/percentiles/0/standard_error | tolerance | 6.4099711655046967 | 6.409970741046227 | 4.24E-7 | 7 | passed |
/families/0/percentiles/0/lower | tolerance | 4.0467771066279248 | 4.0467773874266895 | 2.81E-7 | 7 | passed |
/families/0/percentiles/0/upper | tolerance | 34.225217649235276 | 34.22521523132289 | 2.42E-6 | 7 | passed |
/families/0/percentiles/1/estimate | tolerance | 29.454523956410004 | 29.45452394322652 | 1.32E-8 | 9 | passed |
/families/0/percentiles/1/standard_error | tolerance | 10.630078726827216 | 10.630078093152829 | 6.34E-7 | 7 | passed |
/families/0/percentiles/1/lower | tolerance | 14.519614145152721 | 14.519614746290832 | 6.01E-7 | 7 | passed |
/families/0/percentiles/1/upper | tolerance | 59.751517693627108 | 59.75151516631888 | 2.53E-6 | 7 | passed |
/families/0/percentiles/2/estimate | tolerance | 44.167823357041499 | 44.167823340819446 | 1.62E-8 | 9 | passed |
/families/0/percentiles/2/standard_error | tolerance | 12.575868454656089 | 12.575867761417971 | 6.93E-7 | 7 | passed |
/families/0/percentiles/2/lower | tolerance | 25.27807939103096 | 25.27808015418777 | 7.63E-7 | 7 | passed |
/families/0/percentiles/2/upper | tolerance | 77.173450954149317 | 77.17344856755865 | 2.39E-6 | 7 | passed |
/families/0/percentiles/3/estimate | tolerance | 127.52443580132935 | 127.52443578129343 | 2.00E-8 | 9 | passed |
/families/0/percentiles/3/standard_error | tolerance | 19.289585589168581 | 19.28958434976075 | 1.24E-6 | 7 | passed |
/families/0/percentiles/3/lower | tolerance | 94.806708109206454 | 94.80670989585431 | 1.79E-6 | 7 | passed |
/families/0/percentiles/3/upper | tolerance | 171.53302810297828 | 171.5330248165099 | 3.29E-6 | 7 | passed |
/families/1/parameters/0/estimate | tolerance | 4.7943475918216594 | 4.79434759211441 | 2.93E-10 | 10 | passed |
/families/1/parameters/0/standard_error | tolerance | 0.17313181243713938 | 0.1731317587698606 | 5.37E-8 | 6 | passed |
/families/1/parameters/0/lower | tolerance | 4.4550154748667223 | 4.455015580345407 | 1.05E-7 | 7 | passed |
/families/1/parameters/0/upper | tolerance | 5.1336797087765964 | 5.133679603883413 | 1.05E-7 | 7 | passed |
/families/1/parameters/1/estimate | tolerance | 0.73601574170731332 | 0.736015741822257 | 1.15E-10 | 9 | passed |
/families/1/parameters/1/standard_error | tolerance | 0.14512024147738337 | 0.1451202243354728 | 1.71E-8 | 6 | passed |
/families/1/parameters/1/lower | tolerance | 0.50009864089952649 | 0.5000986638362308 | 2.29E-8 | 7 | passed |
/families/1/parameters/1/upper | tolerance | 1.08322464357547 | 1.0832245942324015 | 4.93E-8 | 7 | passed |
/families/1/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/families/1/log_likelihood | tolerance | -83.589329184123116 | -83.58932918412309 | 2.83E-14 | 15 | passed |
/families/1/anderson_darling | tolerance | 0.82783480086823724 | 0.8278348017195045 | 8.51E-10 | 8 | passed |
/families/1/ad_domain_probability | tolerance | 0.85255368277548516 | 0.8525536826460995 | 1.29E-10 | 9 | passed |
/families/1/correlation | tolerance | 0.96643137373268984 | 0.96643137373269 | 1.07E-16 | 15 | passed |
/families/1/percentiles/0/estimate | tolerance | 21.804555935787054 | 21.80455593633984 | 5.53E-10 | 10 | passed |
/families/1/percentiles/0/standard_error | tolerance | 7.0640854864188691 | 7.064085135438089 | 3.51E-7 | 7 | passed |
/families/1/percentiles/0/lower | tolerance | 11.555294103622128 | 11.555294468657877 | 3.65E-7 | 7 | passed |
/families/1/percentiles/0/upper | tolerance | 41.144661078581741 | 41.144659780893846 | 1.30E-6 | 7 | passed |
/families/1/percentiles/1/estimate | tolerance | 36.006858333701402 | 36.006858337434764 | 3.73E-9 | 9 | passed |
/families/1/percentiles/1/standard_error | tolerance | 8.774523903796549 | 8.77452336946398 | 5.34E-7 | 7 | passed |
/families/1/percentiles/1/lower | tolerance | 22.333440305827864 | 22.333440958825758 | 6.53E-7 | 7 | passed |
/families/1/percentiles/1/upper | tolerance | 58.051685244611669 | 58.05168355930147 | 1.69E-6 | 7 | passed |
/families/1/percentiles/2/estimate | tolerance | 47.045041179092337 | 47.0450411859348 | 6.84E-9 | 9 | passed |
/families/1/percentiles/2/standard_error | tolerance | 9.7649667858349538 | 9.764965944936622 | 8.41E-7 | 7 | passed |
/families/1/percentiles/2/lower | tolerance | 31.32081599989284 | 31.320817103564732 | 1.10E-6 | 7 | passed |
/families/1/percentiles/2/upper | tolerance | 70.663417567092282 | 70.66341509763501 | 2.47E-6 | 7 | passed |
/families/1/percentiles/3/estimate | tolerance | 120.82552850064192 | 120.82552853601368 | 3.54E-8 | 9 | passed |
/families/1/percentiles/3/standard_error | tolerance | 20.918742737991373 | 20.918736259738026 | 6.48E-6 | 6 | passed |
/families/1/percentiles/3/lower | tolerance | 86.057482562907381 | 86.05749164013791 | 9.08E-6 | 6 | passed |
/families/1/percentiles/3/upper | tolerance | 169.64019748994878 | 169.6401796958494 | 1.78E-5 | 6 | passed |
/families/2/parameters/0/estimate | tolerance | 184.23571428571086 | 184.23571429927384 | 1.36E-8 | 10 | passed |
/families/2/parameters/0/standard_error | tolerance | 49.239065804621212 | 49.23906580824653 | 3.63E-9 | 10 | passed |
/families/2/parameters/0/lower | tolerance | 109.11404122323711 | 109.11404123126924 | 8.03E-9 | 10 | passed |
/families/2/parameters/0/upper | tolerance | 311.07635679006972 | 311.07635681297205 | 2.29E-8 | 10 | passed |
/families/2/parameters/1/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/families/2/log_likelihood | tolerance | -87.027023911206484 | -87.02702391120648 | 2.86E-16 | 17 | passed |
/families/2/anderson_darling | tolerance | 1.7737272980031595 | 1.7737272980614345 | 5.83E-11 | 10 | passed |
/families/2/ad_domain_probability | tolerance | 0.75774127241247635 | 0.7577412723871916 | 2.53E-11 | 10 | passed |
/families/2/correlation | tolerance | 0.9730952048403384 | 0.9730952048403384 | 1.38E-18 | 17 | passed |
/families/2/percentiles/0/estimate | tolerance | 1.8516308047811296 | 1.8516308049174406 | 1.36E-10 | 10 | passed |
/families/2/percentiles/0/standard_error | tolerance | 0.4948691484491019 | 0.4948691484855372 | 3.64E-11 | 10 | passed |
/families/2/percentiles/0/lower | tolerance | 1.0966327606263351 | 1.09663276070706 | 8.07E-11 | 10 | passed |
/families/2/percentiles/0/upper | tolerance | 3.1264218618238484 | 3.126421862054021 | 2.30E-10 | 10 | passed |
/families/2/percentiles/1/estimate | tolerance | 9.450056729557625 | 9.450056730253307 | 6.96E-10 | 10 | passed |
/families/2/percentiles/1/standard_error | tolerance | 2.5256338976844113 | 2.5256338978703634 | 1.86E-10 | 10 | passed |
/families/2/percentiles/1/lower | tolerance | 5.5968186382788279 | 5.59681863869082 | 4.12E-10 | 10 | passed |
/families/2/percentiles/1/upper | tolerance | 15.956131145839771 | 15.956131147014487 | 1.17E-9 | 10 | passed |
/families/2/percentiles/2/estimate | tolerance | 19.41116985973045 | 19.411169861159454 | 1.43E-9 | 10 | passed |
/families/2/percentiles/2/standard_error | tolerance | 5.1878533636845319 | 5.187853364066498 | 3.82E-10 | 10 | passed |
/families/2/percentiles/2/lower | tolerance | 11.496311648789577 | 11.496311649635846 | 8.46E-10 | 10 | passed |
/families/2/percentiles/2/upper | tolerance | 32.775165360359701 | 32.775165362772704 | 2.41E-9 | 10 | passed |
/families/2/percentiles/3/estimate | tolerance | 127.70246591558811 | 127.70246592498926 | 9.40E-9 | 10 | passed |
/families/2/percentiles/3/standard_error | tolerance | 34.129919635878807 | 34.129919638391684 | 2.51E-9 | 10 | passed |
/families/2/percentiles/3/lower | tolerance | 75.632090033388451 | 75.6320900389559 | 5.57E-9 | 10 | passed |
/families/2/percentiles/3/upper | tolerance | 215.62169964789643 | 215.62169966377112 | 1.59E-8 | 10 | passed |
/families/3/parameters/0/estimate | tolerance | 4.796647315796883 | 4.796647315421243 | 3.76E-10 | 10 | passed |
/families/3/parameters/0/standard_error | tolerance | 0.16636331287468156 | 0.1663632956718721 | 1.72E-8 | 6 | passed |
/families/3/parameters/0/lower | tolerance | 4.4705812142137384 | 4.4705812475549855 | 3.33E-8 | 8 | passed |
/families/3/parameters/0/upper | tolerance | 5.1227134173800275 | 5.1227133832875005 | 3.41E-8 | 8 | passed |
/families/3/parameters/1/estimate | tolerance | 0.42849873448180092 | 0.4284987347464175 | 2.65E-10 | 9 | passed |
/families/3/parameters/1/standard_error | tolerance | 0.093955310015031088 | 0.09395530656273757 | 3.45E-9 | 7 | passed |
/families/3/parameters/1/lower | tolerance | 0.27881091679795539 | 0.27881092144679637 | 4.65E-9 | 7 | passed |
/families/3/parameters/1/upper | tolerance | 0.65855084715194834 | 0.6585508369847626 | 1.02E-8 | 7 | passed |
/families/3/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/families/3/log_likelihood | tolerance | -83.790055320148738 | -83.79005532014872 | 1.39E-14 | 15 | passed |
/families/3/anderson_darling | tolerance | 0.7905024608656166 | 0.7905024600364251 | 8.29E-10 | 8 | passed |
/families/3/ad_domain_probability | tolerance | 0.85739198006724215 | 0.8573919800389849 | 2.83E-11 | 10 | passed |
/families/3/correlation | tolerance | 0.9679832789574232 | 0.9679832789574233 | 1.10E-16 | 15 | passed |
/families/3/percentiles/0/estimate | tolerance | 16.905588964605229 | 16.905588937698546 | 2.69E-8 | 8 | passed |
/families/3/percentiles/0/standard_error | tolerance | 7.2504554555350786 | 7.250455279954594 | 1.76E-7 | 7 | passed |
/families/3/percentiles/0/lower | tolerance | 7.2940320854407581 | 7.2940322125511 | 1.27E-7 | 7 | passed |
/families/3/percentiles/0/upper | tolerance | 39.182572120933038 | 39.18257131338839 | 8.08E-7 | 7 | passed |
/families/3/percentiles/1/estimate | tolerance | 34.293606571492674 | 34.293606531890866 | 3.96E-8 | 8 | passed |
/families/3/percentiles/1/standard_error | tolerance | 9.9923143629776803 | 9.992314102136454 | 2.61E-7 | 7 | passed |
/families/3/percentiles/1/lower | tolerance | 19.372869164277645 | 19.37286941793532 | 2.54E-7 | 7 | passed |
/families/3/percentiles/1/upper | tolerance | 60.706106137798628 | 60.70610520274114 | 9.35E-7 | 7 | passed |
/families/3/percentiles/2/estimate | tolerance | 47.235199417848008 | 47.235199372641 | 4.52E-8 | 9 | passed |
/families/3/percentiles/2/standard_error | tolerance | 11.166402476215701 | 11.166402110986178 | 3.65E-7 | 7 | passed |
/families/3/percentiles/2/lower | tolerance | 29.719512711764477 | 29.719513120533417 | 4.09E-7 | 7 | passed |
/families/3/percentiles/2/upper | tolerance | 75.074045987324055 | 75.07404481103755 | 1.18E-6 | 7 | passed |
/families/3/percentiles/3/estimate | tolerance | 121.10371361724117 | 121.10371357174978 | 4.55E-8 | 9 | passed |
/families/3/percentiles/3/standard_error | tolerance | 20.147214998790925 | 20.14721290789872 | 2.09E-6 | 6 | passed |
/families/3/percentiles/3/lower | tolerance | 87.407510740366703 | 87.40751365464216 | 2.91E-6 | 7 | passed |
/families/3/percentiles/3/upper | tolerance | 167.79003689340436 | 167.7900311730181 | 5.72E-6 | 7 | passed |
/families/4/parameters/0/estimate | tolerance | 126.99970836938374 | 126.99970875617413 | 3.87E-7 | 8 | passed |
/families/4/parameters/0/standard_error | tolerance | 15.903850516780091 | 15.90384964771231 | 8.69E-7 | 7 | passed |
/families/4/parameters/0/lower | tolerance | 95.828734140986043 | 95.82873623111797 | 2.09E-6 | 7 | passed |
/families/4/parameters/0/upper | tolerance | 158.17068259778142 | 158.1706812812303 | 1.32E-6 | 8 | passed |
/families/4/parameters/1/estimate | tolerance | 40.350079994814841 | 40.350080168177406 | 1.73E-7 | 8 | passed |
/families/4/parameters/1/standard_error | tolerance | 8.8128271142704691 | 8.812826501104592 | 6.13E-7 | 7 | passed |
/families/4/parameters/1/lower | tolerance | 26.298694205297352 | 26.298695149935213 | 9.45E-7 | 7 | passed |
/families/4/parameters/1/upper | tolerance | 61.909117725700717 | 61.90911603393199 | 1.69E-6 | 7 | passed |
/families/4/log_likelihood | tolerance | -86.419610492035673 | -86.41961049203567 | 1.33E-16 | 17 | passed |
/families/4/anderson_darling | tolerance | 0.91003488609182703 | 0.9100348952639139 | 9.17E-9 | 7 | passed |
/families/4/ad_domain_probability | tolerance | 0.96530669105846034 | 0.9653066902588786 | 8.00E-10 | 9 | passed |
/families/4/correlation | tolerance | 0.94685777993288545 | 0.9468577799328853 | 1.15E-16 | 15 | passed |
/families/4/percentiles/0/estimate | tolerance | -58.413745169308555 | -58.41374557913991 | 4.10E-7 | 8 | passed |
/families/4/percentiles/0/standard_error | tolerance | 39.481853119475957 | 39.48185064357394 | 2.48E-6 | 7 | passed |
/families/4/percentiles/0/lower | tolerance | -135.7967553263818 | -135.7967508835344 | 4.44E-6 | 7 | passed |
/families/4/percentiles/0/upper | tolerance | 18.969264987764689 | 18.969259725254574 | 5.26E-6 | 6 | passed |
/families/4/percentiles/1/estimate | tolerance | 8.1913600201669254 | 8.191359896501822 | 1.24E-7 | 7 | passed |
/families/4/percentiles/1/standard_error | tolerance | 26.68761532707887 | 26.687613778083907 | 1.55E-6 | 7 | passed |
/families/4/percentiles/1/lower | tolerance | -44.115404854166783 | -44.115401941857556 | 2.91E-6 | 7 | passed |
/families/4/percentiles/1/upper | tolerance | 60.498124894500634 | 60.4981217348612 | 3.16E-6 | 7 | passed |
/families/4/percentiles/2/estimate | tolerance | 38.341520907294068 | 38.34152091316797 | 5.87E-9 | 9 | passed |
/families/4/percentiles/2/standard_error | tolerance | 21.637023611361883 | 21.637022433565228 | 1.18E-6 | 7 | passed |
/families/4/percentiles/2/lower | tolerance | -4.0662661036179912 | -4.066263789305076 | 2.31E-6 | 6 | passed |
/families/4/percentiles/2/upper | tolerance | 80.749307918206128 | 80.74930561564102 | 2.30E-6 | 7 | passed |
/families/4/percentiles/3/estimate | tolerance | 126.99970836938374 | 126.99970875617413 | 3.87E-7 | 8 | passed |
/families/4/percentiles/3/standard_error | tolerance | 15.903850516780091 | 15.90384964771231 | 8.69E-7 | 7 | passed |
/families/4/percentiles/3/lower | tolerance | 95.828734140986043 | 95.82873623111797 | 2.09E-6 | 7 | passed |
/families/4/percentiles/3/upper | tolerance | 158.17068259778142 | 158.1706812812303 | 1.32E-6 | 8 | passed |
/families/5/parameters/0/estimate | tolerance | 131.829561272468 | 131.82956131336346 | 4.09E-8 | 9 | passed |
/families/5/parameters/0/standard_error | tolerance | 16.420970640639638 | 16.42096988562607 | 7.55E-7 | 7 | passed |
/families/5/parameters/0/lower | tolerance | 99.645050225624701 | 99.64505174631955 | 1.52E-6 | 7 | passed |
/families/5/parameters/0/upper | tolerance | 164.01407231931131 | 164.01407088040736 | 1.44E-6 | 8 | passed |
/families/5/parameters/1/estimate | tolerance | 69.794895644387282 | 69.79489567057026 | 2.62E-8 | 9 | passed |
/families/5/parameters/1/standard_error | tolerance | 13.710238286005248 | 13.710237581275715 | 7.05E-7 | 7 | passed |
/families/5/parameters/1/lower | tolerance | 47.491614766708707 | 47.49161573124557 | 9.65E-7 | 7 | passed |
/families/5/parameters/1/upper | tolerance | 102.57236950017706 | 102.57236749392915 | 2.01E-6 | 7 | passed |
/families/5/log_likelihood | tolerance | -86.276874204252863 | -86.27687420425286 | 9.01E-17 | 17 | passed |
/families/5/anderson_darling | tolerance | 1.1382296448561633 | 1.1382296464543318 | 1.60E-9 | 8 | passed |
/families/5/ad_domain_probability | tolerance | 0.96810038091953898 | 0.9681003808278129 | 9.17E-11 | 10 | passed |
/families/5/correlation | tolerance | 0.96055136852495715 | 0.9605513685249571 | 1.70E-19 | 18 | passed |
/families/5/percentiles/0/estimate | tolerance | -30.537645828754677 | -30.537645848769927 | 2.00E-8 | 9 | passed |
/families/5/percentiles/0/standard_error | tolerance | 30.717713068387248 | 30.717712129656558 | 9.39E-7 | 7 | passed |
/families/5/percentiles/0/lower | tolerance | -90.743257130229026 | -90.74325531036595 | 1.82E-6 | 7 | passed |
/families/5/percentiles/0/upper | tolerance | 29.667965472719672 | 29.667963612826092 | 1.86E-6 | 7 | passed |
/families/5/percentiles/1/estimate | tolerance | 17.027174029098035 | 17.027174026926318 | 2.17E-9 | 9 | passed |
/families/5/percentiles/1/standard_error | tolerance | 23.13969937715634 | 23.139698807156712 | 5.70E-7 | 7 | passed |
/families/5/percentiles/1/lower | tolerance | -28.325803363212302 | -28.325802248205285 | 1.12E-6 | 7 | passed |
/families/5/percentiles/1/upper | tolerance | 62.380151421408371 | 62.38015030205792 | 1.12E-6 | 7 | passed |
/families/5/percentiles/2/estimate | tolerance | 42.383803492381432 | 42.38380349972209 | 7.34E-9 | 9 | passed |
/families/5/percentiles/2/standard_error | tolerance | 19.728689284940494 | 19.728688853272306 | 4.32E-7 | 7 | passed |
/families/5/percentiles/2/lower | tolerance | 3.7162830317167987 | 3.716283885111551 | 8.53E-7 | 6 | passed |
/families/5/percentiles/2/upper | tolerance | 81.051323953046065 | 81.05132311433263 | 8.39E-7 | 7 | passed |
/families/5/percentiles/3/estimate | tolerance | 131.829561272468 | 131.82956131336346 | 4.09E-8 | 9 | passed |
/families/5/percentiles/3/standard_error | tolerance | 16.420970640639638 | 16.42096988562607 | 7.55E-7 | 7 | passed |
/families/5/percentiles/3/lower | tolerance | 99.645050225624701 | 99.64505174631955 | 1.52E-6 | 7 | passed |
/families/5/percentiles/3/upper | tolerance | 164.01407231931131 | 164.01407088040736 | 1.44E-6 | 8 | passed |
/families/6/parameters/0/estimate | tolerance | 168.31672858951427 | 168.31672859716417 | 7.65E-9 | 10 | passed |
/families/6/parameters/0/standard_error | tolerance | 18.598922166145083 | 18.598921447744374 | 7.18E-7 | 7 | passed |
/families/6/parameters/0/lower | tolerance | 131.86351099260622 | 131.86351240829563 | 1.42E-6 | 7 | passed |
/families/6/parameters/0/upper | tolerance | 204.76994618642232 | 204.7699447860327 | 1.40E-6 | 8 | passed |
/families/6/parameters/1/estimate | tolerance | 69.252195135506753 | 69.25219513720242 | 1.70E-9 | 10 | passed |
/families/6/parameters/1/standard_error | tolerance | 13.00591433378311 | 13.005913818940815 | 5.15E-7 | 7 | passed |
/families/6/parameters/1/lower | tolerance | 47.926262999878766 | 47.92626369981685 | 7.00E-7 | 7 | passed |
/families/6/parameters/1/upper | tolerance | 100.06760867415089 | 100.06760721761603 | 1.46E-6 | 7 | passed |
/families/6/log_likelihood | tolerance | -89.301118539969181 | -89.30111853996915 | 2.83E-14 | 15 | passed |
/families/6/anderson_darling | tolerance | 2.025748872669384 | 2.02574887299979 | 3.30E-10 | 9 | passed |
/families/6/ad_domain_probability | tolerance | 0.97815431994701074 | 0.9781543199350401 | 1.20E-11 | 10 | passed |
/families/6/correlation | tolerance | 0.93059328165756305 | 0.9305932816575629 | 1.07E-16 | 15 | passed |
/families/6/percentiles/0/estimate | tolerance | -150.25370331566788 | -150.25370331581837 | 1.50E-10 | 11 | passed |
/families/6/percentiles/0/standard_error | tolerance | 60.878357188052448 | 60.878355666633915 | 1.52E-6 | 7 | passed |
/families/6/percentiles/0/lower | tolerance | -269.57309084221578 | -269.57308786044075 | 2.98E-6 | 7 | passed |
/families/6/percentiles/0/upper | tolerance | -30.934315789119992 | -30.93431877119599 | 2.98E-6 | 7 | passed |
/families/6/percentiles/1/estimate | tolerance | -37.37581238770872 | -37.375812385095344 | 2.61E-9 | 10 | passed |
/families/6/percentiles/1/standard_error | tolerance | 41.190126748033542 | 41.19012596822612 | 7.80E-7 | 7 | passed |
/families/6/percentiles/1/lower | tolerance | -118.10697733249438 | -118.10697580148656 | 1.53E-6 | 7 | passed |
/families/6/percentiles/1/upper | tolerance | 43.355352557076941 | 43.35535103129587 | 1.53E-6 | 7 | passed |
/families/6/percentiles/2/estimate | tolerance | 12.473851311904014 | 12.473851315738045 | 3.83E-9 | 9 | passed |
/families/6/percentiles/2/standard_error | tolerance | 33.094922332929961 | 33.09492182749128 | 5.05E-7 | 7 | passed |
/families/6/percentiles/2/lower | tolerance | -52.391004531788994 | -52.39100353731337 | 9.94E-7 | 7 | passed |
/families/6/percentiles/2/upper | tolerance | 77.338707155597021 | 77.33870616878946 | 9.87E-7 | 7 | passed |
/families/6/percentiles/3/estimate | tolerance | 142.93490429370837 | 142.93490430073678 | 7.03E-9 | 10 | passed |
/families/6/percentiles/3/standard_error | tolerance | 18.739591611441345 | 18.739591115892004 | 4.96E-7 | 7 | passed |
/families/6/percentiles/3/lower | tolerance | 106.20597965029444 | 106.20598062858168 | 9.78E-7 | 8 | passed |
/families/6/percentiles/3/upper | tolerance | 179.6638289371223 | 179.66382797289185 | 9.64E-7 | 8 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:53-62: probability-plot positions follow Benard median ranks (i - 0.3)/(n + 0.4) for complete data, with frequencies expanding ranks; the Anderson-Darling statistic is the complete-data form; no family is selected automatically.
- R: survreg per family; A2 computed from its definition by the exact piecewise closed form c^2 log(u2/u1) - (1-c)^2 log((1-u2)/(1-u1)) - (u2-u1); the correlation is exact arithmetic on the plotted points (1e-9 tolerance).
- Iterative maximum likelihood: 1e-7 absolute or 1e-6 relative elsewhere.
- docs/manual/chapters/98-life-model-extensions.tex:56-62: under right censoring the discrepancy integrates only to the largest observation; the covered fitted probability is reported and no p-value is given.
- Plotting positions are the Kaplan-Meier midpoints (F(t-) + F(t))/2 at failure times.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
589 emit("STAT-SURV-DISTID-002",
590 "Distribution identification of right-censored data with the restricted-domain AD",
591 DISTID, "lifeDistributionIdMenuItem", DISTID_REQ, "SURV_KM_B9",
592 list(layout = "right_censored", start = "time", status = "status", frequency = "freq",
593 families = as.list(ALL7), threshold = 0.0, confidence_level = 0.95),
594 c(list("/plotted_points" = exact(km_failure_times(), "one point per failure time")),
595 ident_censored(ALL7, 0.0, 0.95)),
596 c(DISTID_NOTES,
597 paste0(MANUAL, ":56-62: under right censoring the discrepancy integrates only to the largest observation; the covered fitted probability is reported and no p-value is given."),
598 "Plotting positions are the Kaplan-Meier midpoints (F(t-) + F(t))/2 at failure times."), "axis_coverage")
Parametric survival STAT-SURV-FAMILIES-001
Case STAT-SURV-FAMILIES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::survreg
- Citation
- R survival::survreg and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_parametric.R · sha256 7c99eb709767fd04
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
event_column= "status"mode= "families"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_n | exact | 32 | 32 | 0.00E+2 | passed | |
/failures | exact | 26 | 26 | 0.00E+2 | passed | |
/fits/[family=exponential]/param1_val | tolerance | 17.380796236648514 | 17.380796236648514 | 2.52E-16 | 16 | passed |
Convention
- The exponential MLE is analytic; right-censored records contribute survival probability.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
24 exp_scale <- sum(d$time)/sum(d$status)
25 emit("STAT-SURV-FAMILIES-001","tabelz.executor.reliability","reliabilityFamiliesMenuItem",
26 "SURV_CORE",list(mode="families",time_column="time",event_column="status"),
27 list("/total_n"=exact(nrow(d),"All finite right-censored observations"),
28 "/failures"=exact(sum(d$status),"Observed failures"),
29 "/fits/[family=exponential]/param1_val"=tol(exp_scale,
30 "Right-censored exponential scale=sum time on test/failures","1e-9")),
31 c("The exponential MLE is analytic; right-censored records contribute survival probability."))
Hard-numeric survival STAT-SURV-FAMILIES-HARD-001
Case STAT-SURV-FAMILIES-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_hard.R · sha256 bc20ccd17540f4e7
- Dataset
- reference_data/datasets/SURV_HARD.json
Settings compared
event_column= "status"mode= "families"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[family=exponential]/param1_val | tolerance | 1253510.8750567641 | 1253510.875056764 | 1.09E-11 | 17 | passed |
Convention
- Exponential scale=sum time on test/failures remains analytic at large lifetime offset.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
69 emit("STAT-SURV-FAMILIES-HARD-001","tabelz.executor.reliability",
70 "reliabilityFamiliesMenuItem","SURV_HARD",
71 list(mode="families",time_column="time",event_column="status"),
72 list("/fits/[family=exponential]/param1_val"=tol(sum(d$time)/sum(d$status),
73 "Large-offset exponential time-on-test scale","1e-9")),
74 c("Exponential scale=sum time on test/failures remains analytic at large lifetime offset."))
Small-sample survival boundary STAT-SURV-FAMILIES-MIN-001
Case STAT-SURV-FAMILIES-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::survfit/coxph and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_minimum.R · sha256 2997d37929a6dae8
- Dataset
- reference_data/datasets/SURV_MIN.json
Settings compared
event_column= "status"mode= "families"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_n | exact | 3 | 3 | 0.00E+2 | passed | |
/failures | exact | 2 | 2 | 0.00E+2 | passed | |
/fits/[family=exponential]/param1_val | tolerance | 3 | 3.0 | 0.00E+2 | passed |
Convention
- Three rows and two failures meet censored-families minimum.
- R re-reads the exported CSV and drops excluded 0-based ordinals.
Reference code
The lines of the reference script that produce this case's expected values.
50 emit("STAT-SURV-FAMILIES-MIN-001","tabelz.executor.reliability",
51 "reliabilityFamiliesMenuItem","SURV_MIN",3:4,
52 list(mode="families",time_column="time",event_column="status"),
53 list("/total_n"=exact(3L,"Minimum three retained lifetimes"),
54 "/failures"=exact(2L,"Minimum two observed failures"),
55 "/fits/[family=exponential]/param1_val"=tol(sum(d$time[1:3])/sum(d$status[1:3]),
56 "Analytic exponential total-time/failure scale","1e-9")),
57 c("Three rows and two failures meet censored-families minimum."))
Survival boundary STAT-SURV-FAMILIES-ONE-FAIL-001
Case STAT-SURV-FAMILIES-ONE-FAIL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival and analytic boundary
- Citation
- R survival::survfit/coxph/survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_boundaries.R · sha256 528007972452fb15
- Dataset
- reference_data/datasets/SURV_ONE_FAIL.json
Settings compared
event_column= "status"mode= "families"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Censored life families require at least two failures for parameter estimation.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
73 emit("STAT-SURV-FAMILIES-ONE-FAIL-001","tabelz.executor.reliability",
74 "reliabilityFamiliesMenuItem","SURV_ONE_FAIL",
75 list(mode="families",time_column="time",event_column="status"),list(),
76 c("Censored life families require at least two failures for parameter estimation."),
77 error=list(error_class="ReliabilityExecutionError",message_contains="At least two observed failures"))
Survival population STAT-SURV-FAMILIES-POP-001
Case STAT-SURV-FAMILIES-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::Surv/survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_population.R · sha256 3b3b4629e272fcd9
- Dataset
- reference_data/datasets/SURV_POP.json
Settings compared
event_column= "status"mode= "families"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/input_row_count | exact | 31 | 31 | 0.00E+2 | passed | |
/omitted_row_count | exact | 2 | 2 | 0.00E+2 | passed | |
/total_n | exact | 29 | 29 | 0.00E+2 | passed | |
/fits/[family=exponential]/param1_val | tolerance | 17.976771239039561 | 17.97677123903956 | 1.32E-16 | 17 | passed |
Convention
- The exponential right-censored MLE is total time on test divided by observed failures.
- R re-reads the exported CSV and removes the declared ordinal before complete-case selection.
Reference code
The lines of the reference script that produce this case's expected values.
75 exp_scale <- sum(kmdata$time)/sum(kmdata$status)
76 emit("STAT-SURV-FAMILIES-POP-001","tabelz.executor.reliability",
77 "reliabilityFamiliesMenuItem","SURV_POP",7L,
78 list(mode="families",time_column="time",event_column="status"),
79 list("/input_row_count"=exact(nrow(eligible),"Rows sent to worker after exclusion"),
80 "/omitted_row_count"=exact(2L,"Rows with missing lifetime or status"),
81 "/total_n"=exact(nrow(kmdata),"Finite complete lifetimes"),
82 "/fits/[family=exponential]/param1_val"=tol(exp_scale,
83 "Exponential total time/failures","1e-9")),
84 c("The exponential right-censored MLE is total time on test divided by observed failures."))
Parametric survival STAT-SURV-INTERVAL-001
Case STAT-SURV-INTERVAL-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::survreg
- Citation
- R survival::survreg and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_parametric.R · sha256 7c99eb709767fd04
- Dataset
- reference_data/datasets/SURV_INTERVAL.json
Settings compared
lower_column= "lower"mode= "interval"upper_column= "upper"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_n | exact | 20 | 20 | 0.00E+2 | passed | |
/exact_count | exact | 5 | 5 | 0.00E+2 | passed | |
/right_count | exact | 5 | 5 | 0.00E+2 | passed | |
/left_count | exact | 5 | 5 | 0.00E+2 | passed | |
/interval_count | exact | 5 | 5 | 0.00E+2 | passed | |
/fits/[family=exponential]/param1_val | tolerance | 5.0430857922623877 | 5.043085727603668 | 6.47E-8 | 7 | passed |
Convention
- R Surv(type=interval2): NA lower is left censoring, NA upper is right censoring.
- survreg exponential intercept is log scale, so exp(intercept) is Tabelz scale.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
42 interval <- data.frame(lower=lower,upper=upper)
43 export_dataset(interval,"SURV_INTERVAL","Constructed exact/right/left/interval lifetime matrix",
44 "R survival::Surv(type=interval2) and survreg exponential model",
45 "Constructed validation data; no third-party license.",
46 c(lower="Float64",upper="Float64"))
47 interval <- read_dataset("SURV_INTERVAL")
48 fit_int <- survival::survreg(survival::Surv(lower,upper,type="interval2")~1,
49 data=interval,dist="exponential",control=survival::survreg.control(maxiter=200L))
50 emit("STAT-SURV-INTERVAL-001","tabelz.executor.reliability","intervalLifeMenuItem",
51 "SURV_INTERVAL",list(mode="interval",lower_column="lower",upper_column="upper"),
52 list("/total_n"=exact(nrow(interval),"All four censoring types retained"),
53 "/exact_count"=exact(5L,"Five exact failures"),
54 "/right_count"=exact(5L,"Five right-censored rows"),
55 "/left_count"=exact(5L,"Five left-censored rows"),
56 "/interval_count"=exact(5L,"Five interval-censored rows"),
57 "/fits/[family=exponential]/param1_val"=tol(exp(coef(fit_int)[[1]]),
58 "Interval2 exponential scale MLE")),
59 c("R Surv(type=interval2): NA lower is left censoring, NA upper is right censoring.",
60 "survreg exponential intercept is log scale, so exp(intercept) is Tabelz scale."))
Hard-numeric survival STAT-SURV-INTERVAL-HARD-001
Case STAT-SURV-INTERVAL-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_hard.R · sha256 bc20ccd17540f4e7
- Dataset
- reference_data/datasets/SURV_INTERVAL_HARD.json
Settings compared
lower_column= "lower"mode= "interval"upper_column= "upper"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/fits/[family=exponential]/param1_val | tolerance | 1142666.7679460864 | 1142666.7679491574 | 3.07E-6 | 11 | passed |
Convention
- All positive endpoints have a 1e6 offset but retain their censoring interval widths.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
98 fit_int <- survival::survreg(survival::Surv(lower,upper,type="interval2")~1,
99 data=interval,dist="exponential",control=survival::survreg.control(rel.tolerance=1e-14,maxiter=1000))
100 emit("STAT-SURV-INTERVAL-HARD-001","tabelz.executor.reliability","intervalLifeMenuItem",
101 "SURV_INTERVAL_HARD",list(mode="interval",lower_column="lower",upper_column="upper"),
102 list("/fits/[family=exponential]/param1_val"=tol(exp(coef(fit_int)[[1]]),
103 "Large-offset mixed-censoring exponential scale")),
104 c("All positive endpoints have a 1e6 offset but retain their censoring interval widths."))
Small-sample survival boundary STAT-SURV-INTERVAL-MIN-001
Case STAT-SURV-INTERVAL-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::survfit/coxph and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_minimum.R · sha256 2997d37929a6dae8
- Dataset
- reference_data/datasets/SURV_INTERVAL.json
Settings compared
lower_column= "lower"mode= "interval"upper_column= "upper"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/total_n | exact | 3 | 3 | 0.00E+2 | passed | |
/exact_count | exact | 1 | 1 | 0.00E+2 | passed | |
/left_count | exact | 1 | 1 | 0.00E+2 | passed | |
/right_count | exact | 1 | 1 | 0.00E+2 | passed |
Convention
- Exact plus left censoring supplies two failure-indicative records.
- R re-reads the exported CSV and drops excluded 0-based ordinals.
Reference code
The lines of the reference script that produce this case's expected values.
78 valid_int <- inter[1:3,,drop=FALSE]
79 emit("STAT-SURV-INTERVAL-MIN-001","tabelz.executor.reliability","intervalLifeMenuItem",
80 "SURV_INTERVAL",3:19,
81 list(mode="interval",lower_column="lower",upper_column="upper"),
82 list("/total_n"=exact(nrow(valid_int),"Minimum three retained interval records"),
83 "/exact_count"=exact(1L,"One exact failure"),
84 "/left_count"=exact(1L,"One left-censored failure-indicative row"),
85 "/right_count"=exact(1L,"One right-censored row")),
86 c("Exact plus left censoring supplies two failure-indicative records."))
Survival boundary STAT-SURV-INTERVAL-NARROW-001
Case STAT-SURV-INTERVAL-NARROW-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival and analytic boundary
- Citation
- R survival::survfit/coxph/survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_boundaries.R · sha256 528007972452fb15
- Dataset
- reference_data/datasets/SURV_NARROW.json
Settings compared
lower_column= "lower"mode= "interval"upper_column= "upper"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/interval_count | exact | 5 | 5 | 0.00E+2 | passed | |
/fits/[family=exponential]/param1_val | tolerance | 5.0282680777039834 | 5.028268077613061 | 9.09E-11 | 10 | passed |
Convention
- A 1e-8 interval width is not rounded to an exact failure.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
105 narrow_scale <- stats::uniroot(exp_score, c(1, 20), tol = 1e-15)$root
106 emit("STAT-SURV-INTERVAL-NARROW-001","tabelz.executor.reliability",
107 "intervalLifeMenuItem","SURV_NARROW",
108 list(mode="interval",lower_column="lower",upper_column="upper"),
109 list("/interval_count"=exact(5L,"Narrow positive interval remains interval-censored"),
110 "/fits/[family=exponential]/param1_val"=tol(narrow_scale,
111 "Exponential MLE from the width-first score equation (uniroot)")),
112 c("A 1e-8 interval width is not rounded to an exact failure."))
Survival population STAT-SURV-INTERVAL-POP-001
Case STAT-SURV-INTERVAL-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::Surv/survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_population.R · sha256 3b3b4629e272fcd9
- Dataset
- reference_data/datasets/SURV_INTERVAL_POP.json
Settings compared
lower_column= "lower"mode= "interval"upper_column= "upper"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/input_row_count | exact | 19 | 19 | 0.00E+2 | passed | |
/omitted_row_count | exact | 1 | 1 | 0.00E+2 | passed | |
/exact_count | exact | 5 | 5 | 0.00E+2 | passed | |
/right_count | exact | 4 | 4 | 0.00E+2 | passed | |
/left_count | exact | 4 | 4 | 0.00E+2 | passed | |
/interval_count | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- R interval2 endpoint types match the worker's missing-bound decoding.
- R re-reads the exported CSV and removes the declared ordinal before complete-case selection.
Reference code
The lines of the reference script that produce this case's expected values.
118 inter_eligible <- inter[-10L,,drop=FALSE]
119 valid <- !(is.na(inter_eligible$lower)&is.na(inter_eligible$upper))
120 inter_complete <- inter_eligible[valid,,drop=FALSE]
121 exact_n <- sum(!is.na(inter_complete$lower)&!is.na(inter_complete$upper)&inter_complete$lower==inter_complete$upper)
122 right_n <- sum(!is.na(inter_complete$lower)&is.na(inter_complete$upper))
123 left_n <- sum(is.na(inter_complete$lower)&!is.na(inter_complete$upper))
124 interval_n <- nrow(inter_complete)-exact_n-right_n-left_n
125 emit("STAT-SURV-INTERVAL-POP-001","tabelz.executor.reliability","intervalLifeMenuItem",
126 "SURV_INTERVAL_POP",9L,
127 list(mode="interval",lower_column="lower",upper_column="upper"),
128 list("/input_row_count"=exact(nrow(inter_eligible),"Rows after exclusion"),
129 "/omitted_row_count"=exact(1L,"Both endpoints missing"),
130 "/exact_count"=exact(exact_n,"Exact endpoint pairs"),
131 "/right_count"=exact(right_n,"Finite lower, absent upper"),
132 "/left_count"=exact(left_n,"Absent lower, finite upper"),
133 "/interval_count"=exact(interval_n,"Finite ordered interval pairs")),
134 c("R interval2 endpoint types match the worker's missing-bound decoding."))
Survival STAT-SURV-KM-001
Case STAT-SURV-KM-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/survdiff/coxph and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, MASS 7.3.65, jsonlite 2.0.0
- Reference script
- generators/r/survival_core.R · sha256 1ed8945e6864eb84
- Dataset
- reference_data/datasets/HARVEST_GEHAN_MP.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/curves/0/n | exact | 21 | 21 | 0.00E+2 | passed | |
/curves/0/events | exact | 9 | 9 | 0.00E+2 | passed | |
/curves/0/survival/0 | tolerance | 0.8571428571428571 | 0.8571428571428572 | 1.06E-16 | 15 | passed |
/curves/0/lower/0 | tolerance | 0.61971795526598394 | 0.6197179552659838 | 1.07E-16 | 15 | passed |
/curves/0/upper/0 | tolerance | 0.95155174764699701 | 0.951551747646997 | 4.84E-18 | 17 | passed |
Convention
- R survfit conf.type=log-log matches Tabelz; this independently checks V14 Gehan values.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
24 mp <- read_dataset("HARVEST_GEHAN_MP")
25 both <- read_dataset("HARVEST_GEHAN_BOTH")
26 stopifnot(nrow(mp)==21L,nrow(both)==42L)
27 km <- survival::survfit(survival::Surv(time,status)~1,data=mp,conf.type="log-log")
28 config <- list(time_column="time",event_column="status",event_value="1",censored_value="0")
29 emit("STAT-SURV-KM-001","tabelz.executor.survival","survivalMenuItem",
30 "HARVEST_GEHAN_MP",config,
31 list("/curves/0/n"=exact(nrow(mp),"Gehan 6-MP row count"),
32 "/curves/0/events"=exact(sum(mp$status),"Gehan 6-MP failures"),
33 "/curves/0/survival/0"=tol(km$surv[1],"Kaplan-Meier first failure survival"),
34 "/curves/0/lower/0"=tol(km$lower[1],"Greenwood log-log lower pointwise limit"),
35 "/curves/0/upper/0"=tol(km$upper[1],"Greenwood log-log upper pointwise limit")),
36 c("R survfit conf.type=log-log matches Tabelz; this independently checks V14 Gehan values."))
Survival boundary STAT-SURV-KM-ALL-CENS-001
Case STAT-SURV-KM-ALL-CENS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival and analytic boundary
- Citation
- R survival::survfit/coxph/survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_boundaries.R · sha256 528007972452fb15
- Dataset
- reference_data/datasets/SURV_ALL_CENS.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/curves/0/survival/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/curves/0/inference_available | exact | False | False | passed |
Convention
- R survfit(Surv(time,status)~1) stays at survival 1 when all rows are censored.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
54 cfg <- list(time_column="time",event_column="status",event_value="1",censored_value="0")
55 emit("STAT-SURV-KM-ALL-CENS-001","tabelz.executor.survival","survivalMenuItem",
56 "SURV_ALL_CENS",cfg,
57 list("/curves/0/survival/0"=tol(1,"R all-censored KM remains at one","1e-9"),
58 "/curves/0/inference_available"=exact(FALSE,"No event means no Greenwood inference")),
59 c("R survfit(Surv(time,status)~1) stays at survival 1 when all rows are censored."))
Survival option STAT-SURV-KM-CONFIDENCE-001
Case STAT-SURV-KM-CONFIDENCE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_options.R · sha256 95af0dbeed660def
- Dataset
- reference_data/datasets/HARVEST_GEHAN_MP.json
Settings compared
censored_value= "0"confidence_level= 0.9event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/curves/0/lower/0 | tolerance | 0.67110678059217288 | 0.6711067805921728 | 1.11E-16 | 15 | passed |
/curves/0/upper/0 | tolerance | 0.94215940572012136 | 0.9421594057201214 | 3.21E-18 | 17 | passed |
Convention
- R survfit conf.type=log-log and conf.int=0.9; pointwise, not simultaneous.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
24 mp <- read_dataset("HARVEST_GEHAN_MP")
25 km90 <- survival::survfit(survival::Surv(time,status)~1,data=mp,
26 conf.type="log-log",conf.int=0.9)
27 emit("STAT-SURV-KM-CONFIDENCE-001","tabelz.executor.survival","survivalMenuItem",
28 "HARVEST_GEHAN_MP",list(time_column="time",event_column="status",event_value="1",
29 censored_value="0",confidence_level=0.9),
30 list("/curves/0/lower/0"=tol(km90$lower[1],"90% Greenwood log-log lower", "1e-9"),
31 "/curves/0/upper/0"=tol(km90$upper[1],"90% Greenwood log-log upper", "1e-9")),
32 c("R survfit conf.type=log-log and conf.int=0.9; pointwise, not simultaneous."))
Hard-numeric survival STAT-SURV-KM-HARD-001
Case STAT-SURV-KM-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_hard.R · sha256 bc20ccd17540f4e7
- Dataset
- reference_data/datasets/SURV_HARD.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/curves/0/survival/0 | tolerance | 0.97499999999999998 | 0.975 | 2.20E-18 | 17 | passed |
/curves/0/median/time | tolerance | 1003154.6679214258 | 1003154.6679214258 | 2.53E-11 | 16 | passed |
Convention
- Lifetimes are near 1e6 with small relative spread; events remain distinct.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
47 km <- survival::survfit(survival::Surv(time,status)~1,data=d,conf.type="log-log")
48 cfg <- list(time_column="time",event_column="status",event_value="1",censored_value="0")
49 emit("STAT-SURV-KM-HARD-001","tabelz.executor.survival","survivalMenuItem",
50 "SURV_HARD",cfg,
51 list("/curves/0/survival/0"=tol(km$surv[1],"Large-offset first KM step","1e-9"),
52 "/curves/0/median/time"=tol(summary(km)$table[["median"]],
53 "First crossing of one-half survival","1e-9")),
54 c("Lifetimes are near 1e6 with small relative spread; events remain distinct."))
Invalid survival request STAT-SURV-KM-INVALID-001
Case STAT-SURV-KM-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/HARVEST_GEHAN_MP.json
Settings compared
censored_value= "1"event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Event and censoring labels must be distinct.
- The declared request contract rejects this before statistical estimation.
Invalid survival request STAT-SURV-KM-INVALID-002
Case STAT-SURV-KM-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/HARVEST_GEHAN_MP.json
Settings compared
censored_value= "0"confidence_level= 0.4event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Survival confidence must exceed 0.5.
- The declared request contract rejects this before statistical estimation.
Small-sample survival boundary STAT-SURV-KM-MIN-001
Case STAT-SURV-KM-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::survfit/coxph and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_minimum.R · sha256 2997d37929a6dae8
- Dataset
- reference_data/datasets/SURV_MIN.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/analyzed_count | exact | 1 | 1 | 0.00E+2 | passed | |
/curves/0/survival/0 | tolerance | 0 | 0.0 | 0.00E+2 | passed |
Convention
- R survfit on the first row has one event at time 1 and S(1)=0.
- R re-reads the exported CSV and drops excluded 0-based ordinals.
Reference code
The lines of the reference script that produce this case's expected values.
30 cfg <- list(time_column="time",event_column="status",event_value="1",censored_value="0")
31 emit("STAT-SURV-KM-MIN-001","tabelz.executor.survival","survivalMenuItem",
32 "SURV_MIN",1:4,cfg,
33 list("/analyzed_count"=exact(1L,"One observed failure is the smallest KM sample"),
34 "/curves/0/survival/0"=tol(0,"Single event reduces survival to zero","1e-9")),
35 c("R survfit on the first row has one event at time 1 and S(1)=0."))
Survival population STAT-SURV-KM-POP-001
Case STAT-SURV-KM-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::Surv/survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_population.R · sha256 3b3b4629e272fcd9
- Dataset
- reference_data/datasets/SURV_POP.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 32 | 32 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 2 | 2 | 0.00E+2 | passed | |
/curves/0/survival/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed |
Convention
- Kaplan-Meier removes missing time/status after exclusion; log-log Greenwood bands.
- R re-reads the exported CSV and removes the declared ordinal before complete-case selection.
Reference code
The lines of the reference script that produce this case's expected values.
44 eligible <- d[-8L,,drop=FALSE]
45 kmdata <- eligible[stats::complete.cases(eligible[c("time","status")]),,drop=FALSE]
46 km <- survival::survfit(survival::Surv(time,status)~1,data=kmdata,conf.type="log-log")
47 cfg <- list(time_column="time",event_column="status",event_value="1",censored_value="0")
48 emit("STAT-SURV-KM-POP-001","tabelz.executor.survival","survivalMenuItem",
49 "SURV_POP",7L,cfg,
50 list("/source_count"=exact(nrow(d),"CSV population"),
51 "/excluded_count"=exact(1L,"One source row excluded"),
52 "/missing_count"=exact(2L,"Missing time and status rows"),
53 "/curves/0/survival/0"=tol(km$surv[1],"First complete-case Kaplan-Meier step")),
54 c("Kaplan-Meier removes missing time/status after exclusion; log-log Greenwood bands."))
Parametric Weibull life distribution under mixed censoring
Case STAT-SURV-LIFE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_LIFE_B9.json
Settings compared
confidence_level= 0.95end= "end"family= "weibull"frequency= "freq"layout= "arbitrary"percents= [1, 5, 10, 50]start= "start"threshold= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/exact | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/log_likelihood | tolerance | -105.02050939613645 | -105.02050939613645 | 3.13E-15 | 16 | passed |
/aic | tolerance | 214.04101879227289 | 214.0410187922729 | 3.73E-15 | 16 | passed |
/bic | tolerance | 216.7054278126233 | 216.7054278126233 | 1.32E-15 | 17 | passed |
/covariance/0/0 | tolerance | 0.020220770581809211 | 0.020220767877547827 | 2.70E-9 | 6 | passed |
/covariance/0/1 | tolerance | -0.0035441834844420019 | -0.0035441830123824833 | 4.72E-10 | 6 | passed |
/covariance/1/1 | tolerance | 0.02745597166104019 | 0.02745596999713588 | 1.66E-9 | 7 | passed |
/parameters/0/estimate | tolerance | 1.4853571239166339 | 1.4853571239257648 | 9.13E-12 | 11 | passed |
/parameters/0/standard_error | tolerance | 0.24612135219188686 | 0.24612134473559816 | 7.46E-9 | 7 | passed |
/parameters/0/lower | tolerance | 1.073465568925235 | 1.0734655794955363 | 1.06E-8 | 8 | passed |
/parameters/0/upper | tolerance | 2.0552925491395597 | 2.055292528926582 | 2.02E-8 | 8 | passed |
/parameters/1/estimate | tolerance | 88.163395586396376 | 88.16339558996552 | 3.57E-9 | 10 | passed |
/parameters/1/standard_error | tolerance | 12.53681333287548 | 12.536812495066263 | 8.38E-7 | 7 | passed |
/parameters/1/lower | tolerance | 66.718712489328581 | 66.71871373544307 | 1.25E-6 | 7 | passed |
/parameters/1/upper | tolerance | 116.50081410918483 | 116.50081194271591 | 2.17E-6 | 7 | passed |
/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/percentiles/0/estimate | tolerance | 3.9836284038347052 | 3.983628404071816 | 2.37E-10 | 10 | passed |
/percentiles/0/standard_error | tolerance | 2.2018861739413578 | 2.2018860962686917 | 7.77E-8 | 7 | passed |
/percentiles/0/lower | tolerance | 1.3483136572197831 | 1.3483137089132147 | 5.17E-8 | 7 | passed |
/percentiles/0/upper | tolerance | 11.769735606298804 | 11.769735156456235 | 4.50E-7 | 7 | passed |
/percentiles/1/estimate | tolerance | 11.935787869179054 | 11.935787869808966 | 6.30E-10 | 10 | passed |
/percentiles/1/standard_error | tolerance | 4.5321515298453203 | 4.5321513533177695 | 1.77E-7 | 7 | passed |
/percentiles/1/lower | tolerance | 5.6707485396186037 | 5.67074870452095 | 1.65E-7 | 7 | passed |
/percentiles/1/upper | tolerance | 25.122438609775401 | 25.122437881879968 | 7.28E-7 | 7 | passed |
/percentiles/2/estimate | tolerance | 19.378366869960228 | 19.378366870925205 | 9.65E-10 | 10 | passed |
/percentiles/2/standard_error | tolerance | 5.9406752141510921 | 5.940674963031746 | 2.51E-7 | 7 | passed |
/percentiles/2/lower | tolerance | 10.626027533289761 | 10.626027804023874 | 2.71E-7 | 7 | passed |
/percentiles/2/upper | tolerance | 35.339744920697832 | 35.33974402381753 | 8.97E-7 | 7 | passed |
/percentiles/3/estimate | tolerance | 68.885186421895739 | 68.88518642478893 | 2.89E-9 | 10 | passed |
/percentiles/3/standard_error | tolerance | 10.591646128014483 | 10.5916454478052 | 6.80E-7 | 7 | passed |
/percentiles/3/lower | tolerance | 50.962041879971892 | 50.96204286906324 | 9.89E-7 | 7 | passed |
/percentiles/3/upper | tolerance | 93.111828595003388 | 93.11182679567386 | 1.80E-6 | 7 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:4-18: the likelihood uses f(t), S(L), F(U) and F(U)-F(L) for exact, right-, left- and interval-censored records; R reads the same records as Surv(start, end, type = 'interval2') with frequency weights.
- survreg's location is the engine's mu, survreg's scale the engine's sigma; Weibull shape is 1/scale and the characteristic life exp(mu); the exponential fixes sigma = 1.
- Percentiles and their standard errors are survreg predict(type = 'quantile', se.fit = TRUE); intervals are estimate +/- z * SE as the engine reports.
- Iterative maximum likelihood: outputs allow 1e-7 absolute or 1e-6 relative.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
221 life_case("STAT-SURV-LIFE-001", "Parametric Weibull life distribution under mixed censoring",
222 "weibull", 0.0, 0.95, c(1, 5, 10, 50), LIFE_NOTES, "nominal")
Lognormal life distribution with a declared threshold at 90%
Case STAT-SURV-LIFE-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_LIFE_B9.json
Settings compared
confidence_level= 0.9end= "end"family= "lognormal"frequency= "freq"layout= "arbitrary"percents= [5, 50]start= "start"threshold= 5
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/exact | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/log_likelihood | tolerance | -101.50970779291677 | -101.50970779291677 | 1.04E-15 | 16 | passed |
/aic | tolerance | 207.01941558583354 | 207.01941558583354 | 2.08E-15 | 16 | passed |
/bic | tolerance | 209.68382460618395 | 209.68382460618395 | 2.97E-15 | 16 | passed |
/covariance/0/0 | tolerance | 0.021086684772603753 | 0.021086684838030584 | 6.54E-11 | 8 | passed |
/covariance/0/1 | tolerance | 0.0013573391589775689 | 0.0013573390957751135 | 6.32E-11 | 7 | passed |
/covariance/1/1 | tolerance | 0.026386566868059475 | 0.026386566401997276 | 4.66E-10 | 7 | passed |
/parameters/0/estimate | tolerance | 4.0742202214680807 | 4.074220222958252 | 1.49E-9 | 9 | passed |
/parameters/0/standard_error | tolerance | 0.14521255032745536 | 0.14521255055273488 | 2.25E-10 | 8 | passed |
/parameters/0/lower | tolerance | 3.8353668313830926 | 3.835366832502712 | 1.12E-9 | 9 | passed |
/parameters/0/upper | tolerance | 4.3130736115530688 | 4.313073613413792 | 1.86E-9 | 9 | passed |
/parameters/1/estimate | tolerance | 0.74097684532290475 | 0.7409768464938267 | 1.17E-9 | 8 | passed |
/parameters/1/standard_error | tolerance | 0.1203638528607258 | 0.1203638519879448 | 8.73E-10 | 8 | passed |
/parameters/1/lower | tolerance | 0.56723875467866969 | 0.5672387569135351 | 2.23E-9 | 8 | passed |
/parameters/1/upper | tolerance | 0.96792872626573045 | 0.967928725511307 | 7.54E-10 | 9 | passed |
/parameters/2/estimate | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/percentiles/0/estimate | tolerance | 22.381766768782779 | 22.38176676120739 | 7.58E-9 | 9 | passed |
/percentiles/0/standard_error | tolerance | 4.1489109871263175 | 4.148910972422298 | 1.47E-8 | 8 | passed |
/percentiles/0/lower | tolerance | 16.737704374421025 | 16.73770438362949 | 9.21E-9 | 9 | passed |
/percentiles/0/upper | tolerance | 30.739770432688548 | 30.73977039005916 | 4.26E-8 | 8 | passed |
/percentiles/1/estimate | tolerance | 63.804608134493243 | 63.8046082221222 | 8.76E-8 | 8 | passed |
/percentiles/1/standard_error | tolerance | 8.5391671182163904 | 8.539167144188688 | 2.60E-8 | 8 | passed |
/percentiles/1/lower | tolerance | 51.31041266517451 | 51.310412717024555 | 5.19E-8 | 8 | passed |
/percentiles/1/upper | tolerance | 79.669642070620455 | 79.66964220955998 | 1.39E-7 | 8 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:4-18: the likelihood uses f(t), S(L), F(U) and F(U)-F(L) for exact, right-, left- and interval-censored records; R reads the same records as Surv(start, end, type = 'interval2') with frequency weights.
- survreg's location is the engine's mu, survreg's scale the engine's sigma; Weibull shape is 1/scale and the characteristic life exp(mu); the exponential fixes sigma = 1.
- Percentiles and their standard errors are survreg predict(type = 'quantile', se.fit = TRUE); intervals are estimate +/- z * SE as the engine reports.
- Iterative maximum likelihood: outputs allow 1e-7 absolute or 1e-6 relative.
- Threshold 5 shifts the data before fitting; survreg fits the shifted records.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
223 life_case("STAT-SURV-LIFE-002", "Lognormal life distribution with a declared threshold at 90%",
224 "lognormal", 5.0, 0.90, c(5, 50), c(LIFE_NOTES,
225 "Threshold 5 shifts the data before fitting; survreg fits the shifted records."), "axis_coverage")
Exponential life distribution from time-and-status data
Case STAT-SURV-LIFE-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_LIFE_B9.json
Settings compared
confidence_level= 0.95family= "exponential"frequency= "freq"layout= "right_censored"percents= [1, 5, 50]start= "start"status= "status"threshold= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/missing_count | exact | 6 | 6 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 18 | 18 | 0.00E+2 | passed | |
/counts/exact | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/log_likelihood | tolerance | -90.51945764131159 | -90.51945764131158 | 1.45E-14 | 15 | passed |
/aic | tolerance | 183.03891528262318 | 183.03891528262315 | 2.91E-14 | 15 | passed |
/bic | tolerance | 184.08343772034661 | 184.08343772034658 | 2.94E-14 | 15 | passed |
/covariance/0/0 | tolerance | 0.062500000000000014 | 0.06249999254942029 | 7.45E-9 | 6 | passed |
/parameters/0/estimate | tolerance | 105.36875000000001 | 105.3687499989262 | 1.07E-9 | 10 | passed |
/parameters/0/standard_error | tolerance | 26.342187500000001 | 26.342185929614963 | 1.57E-6 | 7 | passed |
/parameters/0/lower | tolerance | 64.552258589423516 | 64.55226047406195 | 1.88E-6 | 7 | passed |
/parameters/0/upper | tolerance | 171.99357108755896 | 171.99356606260733 | 5.02E-6 | 7 | passed |
/parameters/1/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/percentiles/0/estimate | tolerance | 1.0589913259636312 | 1.058991325952838 | 1.08E-11 | 10 | passed |
/percentiles/0/standard_error | tolerance | 0.2647478314909078 | 0.2647478157080105 | 1.58E-8 | 7 | passed |
/percentiles/0/lower | tolerance | 0.64877187892578014 | 0.6487718978670288 | 1.89E-8 | 7 | passed |
/percentiles/0/upper | tolerance | 1.7285931540730448 | 1.7285931035705915 | 5.05E-8 | 7 | passed |
/percentiles/1/estimate | tolerance | 5.4047103129982208 | 5.404710312943137 | 5.51E-11 | 10 | passed |
/percentiles/1/standard_error | tolerance | 1.3511775782495552 | 1.3511774976993318 | 8.06E-8 | 7 | passed |
/percentiles/1/lower | tolerance | 3.3110980032085902 | 3.311098099877902 | 9.67E-8 | 7 | passed |
/percentiles/1/upper | tolerance | 8.8221168745602689 | 8.822116616813938 | 2.58E-7 | 7 | passed |
/percentiles/2/estimate | tolerance | 73.036051981625732 | 73.03605198088142 | 7.44E-10 | 10 | passed |
/percentiles/2/standard_error | tolerance | 18.259012995406433 | 18.25901190689847 | 1.09E-6 | 7 | passed |
/percentiles/2/lower | tolerance | 44.744216040035418 | 44.744217346367236 | 1.31E-6 | 7 | passed |
/percentiles/2/upper | tolerance | 119.21685887377801 | 119.21685539074696 | 3.48E-6 | 7 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:4-18: the likelihood uses f(t), S(L), F(U) and F(U)-F(L) for exact, right-, left- and interval-censored records; R reads the same records as Surv(start, end, type = 'interval2') with frequency weights.
- survreg's location is the engine's mu, survreg's scale the engine's sigma; Weibull shape is 1/scale and the characteristic life exp(mu); the exponential fixes sigma = 1.
- Percentiles and their standard errors are survreg predict(type = 'quantile', se.fit = TRUE); intervals are estimate +/- z * SE as the engine reports.
- Iterative maximum likelihood: outputs allow 1e-7 absolute or 1e-6 relative.
- The time-and-status layout reads only rows with a status code; the interval and left-censored rows count as missing.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
231 dk <- d[!is.na(d$status), ]
232 fit3 <- survreg(Surv(start, status) ~ 1, data = dk, weights = dk$freq, dist = "exponential")
233 outputs3 <- c(
234 list("/counts/source_count" = exact(nrow(d), "source rows"),
235 "/counts/missing_count" = exact(sum(is.na(d$status)), "rows without a status code"),
236 "/counts/zero_frequency_rows" = exact(0, "no zero-frequency rows"),
237 "/counts/rows_used" = exact(nrow(dk), "rows with a status code"),
238 "/counts/exact" = tol(sum(dk$freq[dk$status == 1]), "weighted failures"),
239 "/counts/right" = tol(sum(dk$freq[dk$status == 0]), "weighted right-censored rows"),
240 "/counts/left" = tol(0, "no left censoring in this layout"),
241 "/counts/interval" = tol(0, "no interval records in this layout")),
242 fit_info_outputs(fit3, dk$freq),
243 family_params_outputs(fit3, "exponential", 0.0, 0.95),
244 percentile_outputs(fit3, "exponential", c(1, 5, 50), 0.0, 0.95)
245 )
246 emit("STAT-SURV-LIFE-003", "Exponential life distribution from time-and-status data",
247 LIFE, "lifeDistributionMenuItem", LIFE_REQ, "SURV_LIFE_B9",
248 list(layout = "right_censored", start = "start", status = "status", frequency = "freq",
249 family = "exponential", threshold = 0.0, confidence_level = 0.95,
250 percents = list(1, 5, 50)),
251 outputs3, c(LIFE_NOTES,
252 "The time-and-status layout reads only rows with a status code; the interval and left-censored rows count as missing."), "axis_coverage")
Smallest-extreme-value life distribution with interval records
Case STAT-SURV-LIFE-004 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_LIFE_B9.json
Settings compared
confidence_level= 0.95end= "end"family= "sev"frequency= "freq"layout= "arbitrary"percents= [1, 10, 50]start= "start"threshold= 0
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/exact | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/log_likelihood | tolerance | -116.88243551898506 | -116.88243551898508 | 1.63E-14 | 15 | passed |
/aic | tolerance | 237.76487103797012 | 237.76487103797015 | 3.27E-14 | 15 | passed |
/bic | tolerance | 240.42928005832053 | 240.42928005832056 | 2.76E-14 | 15 | passed |
/covariance/0/0 | tolerance | 202.2294633367369 | 202.2294480224989 | 1.53E-5 | 7 | passed |
/covariance/0/1 | tolerance | -0.38289316377223187 | -0.38289312121634367 | 4.26E-8 | 6 | passed |
/covariance/1/1 | tolerance | 0.023488291109616519 | 0.02348829046249059 | 6.47E-10 | 7 | passed |
/parameters/0/estimate | tolerance | 104.78839065699613 | 104.78839068209325 | 2.51E-8 | 9 | passed |
/parameters/0/standard_error | tolerance | 14.220740604368567 | 14.220740065921284 | 5.38E-7 | 7 | passed |
/parameters/0/lower | tolerance | 76.916251238947382 | 76.91625231938178 | 1.08E-6 | 7 | passed |
/parameters/0/upper | tolerance | 132.66053007504487 | 132.66052904480472 | 1.03E-6 | 8 | passed |
/parameters/1/estimate | tolerance | 67.068697821181829 | 67.06869783913729 | 1.80E-8 | 9 | passed |
/parameters/1/standard_error | tolerance | 10.278875001385448 | 10.278874862540633 | 1.39E-7 | 7 | passed |
/parameters/1/lower | tolerance | 49.66674060870109 | 49.66674082751431 | 2.19E-7 | 8 | passed |
/parameters/1/upper | tolerance | 90.567856321962083 | 90.56785597144692 | 3.51E-7 | 8 | passed |
/percentiles/0/estimate | tolerance | -203.73762776602547 | -203.7376278235262 | 5.75E-8 | 9 | passed |
/percentiles/0/standard_error | tolerance | 51.713683542676598 | 51.71368255732934 | 9.85E-7 | 7 | passed |
/percentiles/0/lower | tolerance | -305.09458501757331 | -305.0945831438289 | 1.87E-6 | 8 | passed |
/percentiles/0/upper | tolerance | -102.38067051447764 | -102.3806725032235 | 1.99E-6 | 7 | passed |
/percentiles/1/estimate | tolerance | -46.140815605182851 | -46.140815620492106 | 1.53E-8 | 9 | passed |
/percentiles/1/standard_error | tolerance | 29.203826057602285 | 29.20382532852062 | 7.29E-7 | 7 | passed |
/percentiles/1/lower | tolerance | -103.37926288885566 | -103.37926147519113 | 1.41E-6 | 7 | passed |
/percentiles/1/upper | tolerance | 11.097631678489968 | 11.097630234206918 | 1.44E-6 | 6 | passed |
/percentiles/2/estimate | tolerance | 80.206846338945667 | 80.20684635746188 | 1.85E-8 | 9 | passed |
/percentiles/2/standard_error | tolerance | 15.337748475775495 | 15.337747896003123 | 5.80E-7 | 7 | passed |
/percentiles/2/lower | tolerance | 50.145411722491595 | 50.145412877340775 | 1.15E-6 | 7 | passed |
/percentiles/2/upper | tolerance | 110.26828095539975 | 110.268279837583 | 1.12E-6 | 7 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:4-18: the likelihood uses f(t), S(L), F(U) and F(U)-F(L) for exact, right-, left- and interval-censored records; R reads the same records as Surv(start, end, type = 'interval2') with frequency weights.
- survreg's location is the engine's mu, survreg's scale the engine's sigma; Weibull shape is 1/scale and the characteristic life exp(mu); the exponential fixes sigma = 1.
- Percentiles and their standard errors are survreg predict(type = 'quantile', se.fit = TRUE); intervals are estimate +/- z * SE as the engine reports.
- Iterative maximum likelihood: outputs allow 1e-7 absolute or 1e-6 relative.
- The SEV family has real support: survreg dist = 'extreme' on the unshifted records.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
226 life_case("STAT-SURV-LIFE-004", "Smallest-extreme-value life distribution with interval records",
227 "sev", 0.0, 0.95, c(1, 10, 50), c(LIFE_NOTES,
228 "The SEV family has real support: survreg dist = 'extreme' on the unshifted records."), "axis_coverage")
Weibull life regression on a numeric stress predictor with predictions
Case STAT-SURV-LIFEREG-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_LIFE_B9.json
Settings compared
categorical_predictors= []confidence_level= 0.95end= "end"family= "weibull"frequency= "freq"layout= "arbitrary"numeric_predictors= ["stress"]percents= [10, 50]prediction_rows= ["stress=80", "stress=150"]start= "start"temperature_unit= "celsius"threshold= 0transform= "none"transform_column= null
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/exact | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/coefficients/0/estimate | tolerance | 4.326478464580938 | 4.326478464149508 | 4.31E-10 | 10 | passed |
/coefficients/0/standard_error | tolerance | 0.41503372537261368 | 0.4150337217988502 | 3.57E-9 | 8 | passed |
/coefficients/0/z_value | tolerance | 10.424402163213756 | 10.424402251936469 | 8.87E-8 | 8 | passed |
/coefficients/0/lower | tolerance | 3.5130273104811276 | 3.5130273170541453 | 6.57E-9 | 8 | passed |
/coefficients/0/upper | tolerance | 5.1399296186807479 | 5.13992961124487 | 7.44E-9 | 8 | passed |
/coefficients/1/estimate | tolerance | 0.0012747097434960132 | 0.001274709760900509 | 1.74E-11 | 7 | passed |
/coefficients/1/standard_error | tolerance | 0.0032918546095884842 | 0.003291854585450656 | 2.41E-11 | 8 | passed |
/coefficients/1/z_value | tolerance | 0.38723148336595736 | 0.38723149149250796 | 8.13E-9 | 7 | passed |
/coefficients/1/lower | tolerance | -0.0051772067336395746 | -0.005177206668925807 | 6.47E-11 | 7 | passed |
/coefficients/1/upper | tolerance | 0.0077266262206316019 | 0.007726626190726825 | 2.99E-11 | 8 | passed |
/dispersion/estimate | tolerance | 0.67042603586626226 | 0.6704260372908608 | 1.42E-9 | 8 | passed |
/dispersion/standard_error | tolerance | 0.11099825838024786 | 0.11099825733774403 | 1.04E-9 | 8 | passed |
/dispersion/z_value | tolerance | -2.4150326324810378 | -2.41503264746052 | 1.50E-8 | 8 | passed |
/dispersion/lower | tolerance | 0.48464388765256672 | 0.4846438904936301 | 2.84E-9 | 8 | passed |
/dispersion/upper | tolerance | 0.92742543756080398 | 0.9274254360654822 | 1.50E-9 | 8 | passed |
/shape/estimate | tolerance | 1.4915888502269947 | 1.4915888470574947 | 3.17E-9 | 8 | passed |
/shape/standard_error | tolerance | 0.24695306527090147 | 0.24695306190199134 | 3.37E-9 | 7 | passed |
/shape/z_value | tolerance | 2.4150326324810378 | 2.41503264746052 | 1.50E-8 | 8 | passed |
/shape/lower | tolerance | 1.0782537975560305 | 1.078253799294538 | 1.74E-9 | 8 | passed |
/shape/upper | tolerance | 2.0633707047119176 | 2.063370692616094 | 1.21E-8 | 8 | passed |
/log_likelihood | tolerance | -104.94585463698002 | -104.94585463698002 | 3.96E-15 | 16 | passed |
/predictions/0/estimate | tolerance | 18.536660086822533 | 18.536660045208823 | 4.16E-8 | 8 | passed |
/predictions/0/standard_error | tolerance | 6.1242244011228069 | 6.124224248009255 | 1.53E-7 | 7 | passed |
/predictions/0/lower | tolerance | 9.7008038992357069 | 9.700804020405991 | 1.21E-7 | 7 | passed |
/predictions/0/upper | tolerance | 35.420545631426613 | 35.42054502996348 | 6.01E-7 | 7 | passed |
/predictions/1/estimate | tolerance | 65.544902336155729 | 65.54490236491655 | 2.88E-8 | 9 | passed |
/predictions/1/standard_error | tolerance | 13.028459040406648 | 13.028458687860269 | 3.53E-7 | 7 | passed |
/predictions/1/lower | tolerance | 44.396047444032149 | 44.3960479391281 | 4.95E-7 | 7 | passed |
/predictions/1/upper | tolerance | 96.768394251134922 | 96.76839325691596 | 9.94E-7 | 7 | passed |
/predictions/2/estimate | tolerance | 20.266718940715432 | 20.266718919909092 | 2.08E-8 | 8 | passed |
/predictions/2/standard_error | tolerance | 6.5280866929725532 | 6.528086511349834 | 1.82E-7 | 7 | passed |
/predictions/2/lower | tolerance | 10.779633955328526 | 10.779634126613717 | 1.71E-7 | 7 | passed |
/predictions/2/upper | tolerance | 38.103325059467259 | 38.103324375781 | 6.84E-7 | 7 | passed |
/predictions/3/estimate | tolerance | 71.662322523130172 | 71.66232264188258 | 1.19E-7 | 8 | passed |
/predictions/3/standard_error | tolerance | 13.246144462298799 | 13.246143936331437 | 5.26E-7 | 7 | passed |
/predictions/3/lower | tolerance | 49.883144981844744 | 49.88314581203274 | 8.30E-7 | 7 | passed |
/predictions/3/upper | tolerance | 102.95037474638418 | 102.95037337421698 | 1.37E-6 | 7 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:64-79: log(T - gamma) = x'beta + sigma W with common dispersion; Weibull shape 1/sigma; percentile intervals use the full fitted covariance including the dispersion cross terms.
- R: survreg(Surv(start, end, type = 'interval2') ~ predictors, weights = freq); factor columns use contr.sum on sorted levels, matching the engine's sum-coded design (level order is alphabetical; the last level is the -1 reference).
- Iterative maximum likelihood: 1e-7 absolute or 1e-6 relative.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
722 regression_case("STAT-SURV-LIFEREG-001",
723 "Weibull life regression on a numeric stress predictor with predictions",
724 "weibull", 0.0, "stress", character(0), "none", NULL, "celsius",
725 c("stress=80", "stress=150"), c(10, 50), 0.95, REG_NOTES, "nominal")
Lognormal life regression with a sum-coded three-level factor
Case STAT-SURV-LIFEREG-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_LIFE_B9.json
Settings compared
categorical_predictors= ["temp3"]confidence_level= 0.95end= "end"family= "lognormal"frequency= "freq"layout= "arbitrary"numeric_predictors= []percents= [10, 50]prediction_rows= ["temp3=low", "temp3=high"]start= "start"temperature_unit= "celsius"threshold= 0transform= "none"transform_column= null
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/exact | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/coefficients/0/estimate | tolerance | 4.137690636510496 | 4.137690636528915 | 1.84E-11 | 11 | passed |
/coefficients/0/standard_error | tolerance | 0.1312866560248003 | 0.13128665331708805 | 2.71E-9 | 7 | passed |
/coefficients/0/z_value | tolerance | 31.516459949508334 | 31.51646059965762 | 6.50E-7 | 7 | passed |
/coefficients/0/lower | tolerance | 3.8803735190511888 | 3.880373524376626 | 5.33E-9 | 8 | passed |
/coefficients/0/upper | tolerance | 4.3950077539698027 | 4.395007748681204 | 5.29E-9 | 8 | passed |
/coefficients/1/estimate | tolerance | 0.19606090889918226 | 0.1960609089053873 | 6.21E-12 | 10 | passed |
/coefficients/1/standard_error | tolerance | 0.17508778633060762 | 0.1750877765565857 | 9.77E-9 | 7 | passed |
/coefficients/1/z_value | tolerance | 1.1197863255234284 | 1.1197863880693202 | 6.25E-8 | 7 | passed |
/coefficients/1/lower | tolerance | -0.147104846441653 | -0.14710482727871704 | 1.92E-8 | 6 | passed |
/coefficients/1/upper | tolerance | 0.53922666424001753 | 0.5392266450894916 | 1.92E-8 | 7 | passed |
/coefficients/2/estimate | tolerance | -0.021682242701141122 | -0.021682242707045614 | 5.90E-12 | 9 | passed |
/coefficients/2/standard_error | tolerance | 0.17837325192647088 | 0.17837324760287382 | 4.32E-9 | 7 | passed |
/coefficients/2/z_value | tolerance | -0.12155546006460087 | -0.12155546304409096 | 2.98E-9 | 7 | passed |
/coefficients/2/lower | tolerance | -0.37128739228231378 | -0.3712873838141238 | 8.47E-9 | 7 | passed |
/coefficients/2/upper | tolerance | 0.32792290688003156 | 0.3279228984000326 | 8.48E-9 | 7 | passed |
/dispersion/estimate | tolerance | 0.65059360180353198 | 0.6505936018159596 | 1.24E-11 | 10 | passed |
/dispersion/standard_error | tolerance | 0.1056182027647552 | 0.10561820145037178 | 1.31E-9 | 7 | passed |
/dispersion/z_value | tolerance | -2.6479406852749996 | -2.6479407181606565 | 3.29E-8 | 7 | passed |
/dispersion/lower | tolerance | 0.47328706330212822 | 0.4732870651881121 | 1.89E-9 | 8 | passed |
/dispersion/upper | tolerance | 0.89432411643479093 | 0.8943241129051991 | 3.53E-9 | 8 | passed |
/log_likelihood | tolerance | -101.13057111966242 | -101.13057111966242 | 1.88E-16 | 17 | passed |
/predictions/0/estimate | tolerance | 26.635346377529903 | 26.635346377439024 | 9.09E-11 | 11 | passed |
/predictions/0/standard_error | tolerance | 6.5472486138492778 | 6.547248547393142 | 6.65E-8 | 7 | passed |
/predictions/0/lower | tolerance | 16.452202499001309 | 16.452202579372358 | 8.04E-8 | 8 | passed |
/predictions/0/upper | tolerance | 43.121380051945039 | 43.1213798409975 | 2.11E-7 | 8 | passed |
/predictions/1/estimate | tolerance | 61.314011769298709 | 61.31401177006602 | 7.67E-10 | 10 | passed |
/predictions/1/standard_error | tolerance | 12.849973516191032 | 12.849973229943485 | 2.86E-7 | 7 | passed |
/predictions/1/lower | tolerance | 40.66005174408135 | 40.660052116846416 | 3.73E-7 | 8 | passed |
/predictions/1/upper | tolerance | 92.459499631427164 | 92.45949878608694 | 8.45E-7 | 8 | passed |
/predictions/2/estimate | tolerance | 33.114865703983241 | 33.11486570427129 | 2.88E-10 | 11 | passed |
/predictions/2/standard_error | tolerance | 7.7761503774402003 | 7.776150155886098 | 2.22E-7 | 7 | passed |
/predictions/2/lower | tolerance | 20.899737362505999 | 20.899737636831503 | 2.74E-7 | 7 | passed |
/predictions/2/upper | tolerance | 52.469287607418885 | 52.46928691963098 | 6.88E-7 | 7 | passed |
/predictions/3/estimate | tolerance | 76.229730101263627 | 76.22973010314077 | 1.88E-9 | 10 | passed |
/predictions/3/standard_error | tolerance | 15.329287483881679 | 15.32928694121361 | 5.43E-7 | 7 | passed |
/predictions/3/lower | tolerance | 51.398856891070679 | 51.39885760998757 | 7.19E-7 | 7 | passed |
/predictions/3/upper | tolerance | 113.05643943846182 | 113.05643786270699 | 1.58E-6 | 7 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:64-79: log(T - gamma) = x'beta + sigma W with common dispersion; Weibull shape 1/sigma; percentile intervals use the full fitted covariance including the dispersion cross terms.
- R: survreg(Surv(start, end, type = 'interval2') ~ predictors, weights = freq); factor columns use contr.sum on sorted levels, matching the engine's sum-coded design (level order is alphabetical; the last level is the -1 reference).
- Iterative maximum likelihood: 1e-7 absolute or 1e-6 relative.
- contr.sum on sorted levels high, low, mid: the engine's grp[sum:high] and grp[sum:low] are R's temp31 and temp32 (mid is the -1 reference).
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
726 regression_case("STAT-SURV-LIFEREG-002",
727 "Lognormal life regression with a sum-coded three-level factor",
728 "lognormal", 0.0, character(0), "temp3", "none", NULL, "celsius",
729 c("temp3=low", "temp3=high"), c(10, 50), 0.95,
730 c(REG_NOTES,
731 "contr.sum on sorted levels high, low, mid: the engine's grp[sum:high] and grp[sum:low] are R's temp31 and temp32 (mid is the -1 reference)."), "axis_coverage")
SEV life regression with the Arrhenius temperature preset at 90%
Case STAT-SURV-LIFEREG-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_LIFE_B9.json
Settings compared
categorical_predictors= []confidence_level= 0.9end= "end"family= "sev"frequency= "freq"layout= "arbitrary"numeric_predictors= ["temp_c"]percents= [10, 90]prediction_rows= ["temp_c=45", "temp_c=75"]start= "start"temperature_unit= "celsius"threshold= 0transform= "arrhenius"transform_column= "temp_c"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 24 | 24 | 0.00E+2 | passed | |
/counts/exact | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/coefficients/0/estimate | tolerance | 735.39201635573295 | 735.3920157178942 | 6.38E-7 | 9 | passed |
/coefficients/0/standard_error | tolerance | 383.36146908118963 | 383.36145629750774 | 1.28E-5 | 7 | passed |
/coefficients/0/z_value | tolerance | 1.9182731590586353 | 1.9182732213621212 | 6.23E-8 | 7 | passed |
/coefficients/0/lower | tolerance | 104.81851350409374 | 104.81853389354023 | 2.04E-5 | 6 | passed |
/coefficients/0/upper | tolerance | 1365.9655192073722 | 1365.9654975422482 | 2.17E-5 | 7 | passed |
/coefficients/1/estimate | tolerance | -210907.61355408074 | -210907.6133727213 | 1.81E-4 | 9 | passed |
/coefficients/1/standard_error | tolerance | 127639.44945493984 | 127639.44513307666 | 4.32E-3 | 7 | passed |
/coefficients/1/z_value | tolerance | -1.6523701289430648 | -1.6523701834713351 | 5.45E-8 | 7 | passed |
/coefficients/1/lower | tolerance | -420855.82493212755 | -420855.8176419359 | 7.29E-3 | 7 | passed |
/coefficients/1/upper | tolerance | -959.4021760339383 | -959.4091035067104 | 6.93E-3 | 5 | passed |
/dispersion/estimate | tolerance | 61.186660490333828 | 61.18666056028455 | 7.00E-8 | 8 | passed |
/dispersion/standard_error | tolerance | 10.034561810099005 | 10.034561876287011 | 6.62E-8 | 8 | passed |
/dispersion/z_value | tolerance | 25.085060414217608 | 25.085060284405557 | 1.30E-7 | 8 | passed |
/dispersion/lower | tolerance | 46.720103925123972 | 46.72010390981495 | 1.53E-8 | 9 | passed |
/dispersion/upper | tolerance | 80.132686090754348 | 80.13268630023276 | 2.09E-7 | 8 | passed |
/log_likelihood | tolerance | -115.74183856168878 | -115.7418385616888 | 1.46E-14 | 15 | passed |
/predictions/0/estimate | tolerance | -65.219236899632335 | -65.21923712484204 | 2.25E-7 | 8 | passed |
/predictions/0/standard_error | tolerance | 30.642782831036971 | 30.642782588306012 | 2.43E-7 | 8 | passed |
/predictions/0/lower | tolerance | -115.62212937914978 | -115.6221292051026 | 1.74E-7 | 8 | passed |
/predictions/0/upper | tolerance | -14.816344420114895 | -14.816345044581475 | 6.24E-7 | 7 | passed |
/predictions/1/estimate | tolerance | 123.50488480048381 | 123.50488479103012 | 9.45E-9 | 10 | passed |
/predictions/1/standard_error | tolerance | 24.219717638126145 | 24.219716975656258 | 6.62E-7 | 7 | passed |
/predictions/1/lower | tolerance | 83.666994399671495 | 83.66699547988378 | 1.08E-6 | 7 | passed |
/predictions/1/upper | tolerance | 163.34277520129612 | 163.34277410217646 | 1.10E-6 | 8 | passed |
/predictions/2/estimate | tolerance | -8.0956874278047621 | -8.095687702135137 | 2.74E-7 | 7 | passed |
/predictions/2/standard_error | tolerance | 34.381207106361053 | 34.38120695685629 | 1.50E-7 | 8 | passed |
/predictions/2/lower | tolerance | -64.647740635672449 | -64.64774066408938 | 2.84E-8 | 9 | passed |
/predictions/2/upper | tolerance | 48.456365780062924 | 48.456365259819115 | 5.20E-7 | 7 | passed |
/predictions/3/estimate | tolerance | 180.62843427231138 | 180.62843421373702 | 5.86E-8 | 9 | passed |
/predictions/3/standard_error | tolerance | 20.59392757217843 | 20.59392729377488 | 2.78E-7 | 7 | passed |
/predictions/3/lower | tolerance | 146.75443781203779 | 146.7544382113965 | 3.99E-7 | 8 | passed |
/predictions/3/upper | tolerance | 214.50243073258497 | 214.50243021607756 | 5.17E-7 | 8 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:64-79: log(T - gamma) = x'beta + sigma W with common dispersion; Weibull shape 1/sigma; percentile intervals use the full fitted covariance including the dispersion cross terms.
- R: survreg(Surv(start, end, type = 'interval2') ~ predictors, weights = freq); factor columns use contr.sum on sorted levels, matching the engine's sum-coded design (level order is alphabetical; the last level is the -1 reference).
- Iterative maximum likelihood: 1e-7 absolute or 1e-6 relative.
- The Arrhenius preset maps Celsius to 1/(temp_c + 273.15); predictions are entered in Celsius and transformed identically.
- The Arrhenius coefficient is about -2.1e5 on the 1/K covariate and its z is -1.65, so each Wald bound is the small difference of two O(2e5) quantities: last-digit round-off in the estimate or its SE (each within 1e-6 relative of itself) moves the bound by up to a few 1e-3 absolute. The coefficient interval outputs therefore carry a 5e-2 absolute tolerance alongside 1e-6 relative; estimate, SE and z stay at the default.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
732 regression_case("STAT-SURV-LIFEREG-003",
733 "SEV life regression with the Arrhenius temperature preset at 90%",
734 "sev", 0.0, "temp_c", character(0), "arrhenius", "temp_c", "celsius",
735 c("temp_c=45", "temp_c=75"), c(10, 90), 0.90,
736 c(REG_NOTES,
737 "The Arrhenius preset maps Celsius to 1/(temp_c + 273.15); predictions are entered in Celsius and transformed identically.",
738 "The Arrhenius coefficient is about -2.1e5 on the 1/K covariate and its z is -1.65, so each Wald bound is the small difference of two O(2e5) quantities: last-digit round-off in the estimate or its SE (each within 1e-6 relative of itself) moves the bound by up to a few 1e-3 absolute. The coefficient interval outputs therefore carry a 5e-2 absolute tolerance alongside 1e-6 relative; estimate, SE and z stay at the default."),
739 "axis_coverage", ci_atol = "5e-2")
Actuarial life table with 2-unit intervals to 10
Case STAT-SURV-LIFETAB-001 · status: passed
Reference
- Evidence type
- R
- Source
- Base R arithmetic of the actuarial, Gehan and grouped PH formulas
- Citation
- Cutler and Ederer (1958) J Chronic Dis 8:699-712; Greenwood (1926); Lee and Desu (1972) Computer Programs in Biomedicine 2:315-321; Gehan (1965) Biometrika 52:203-223; Prentice and Gloeckler (1978) Biometrics 34:57-67; R stats: pchisq, glm (cloglog cross-check), anova(test = 'Rao').
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_tables.R · sha256 e7bfcfb4270e21ec
- Dataset
- reference_data/datasets/SURV_LIFETAB.json
Settings compared
censored_value= "0"event_value= "1"interval_width= 2last_boundary= 10status= "status"time= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/analyzed_count | exact | 30 | 30 | 0.00E+2 | passed | |
/strata/0/subjects | exact | 30 | 30 | 0.00E+2 | passed | |
/strata/0/events | exact | 21 | 21 | 0.00E+2 | passed | |
/strata/0/withdrawn | exact | 9 | 9 | 0.00E+2 | passed | |
/strata/0/median/status | exact | estimated | estimated | passed | ||
/strata/0/median/value | tolerance | 6.3622049832358183 | 6.362204983235818 | 1.03E-17 | 17 | passed |
/strata/0/rows/0/entering | exact | 30 | 30 | 0.00E+2 | passed | |
/strata/0/rows/0/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/0/rows/0/events | exact | 3 | 3 | 0.00E+2 | passed | |
/strata/0/rows/0/at_risk | tolerance | 29.5 | 29.5 | 0.00E+1 | passed | |
/strata/0/rows/0/q | tolerance | 0.10169491525423729 | 0.1016949152542373 | 4.72E-18 | 16 | passed |
/strata/0/rows/0/survival_start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/strata/0/rows/0/survival_end | tolerance | 0.89830508474576276 | 0.8983050847457628 | 7.89E-19 | 18 | passed |
/strata/0/rows/0/survival_end_se | tolerance | 0.05564812557662864 | 0.05564812557662864 | 3.43E-19 | 17 | passed |
/strata/0/rows/0/hazard | tolerance | 0.053571428571428575 | 0.053571428571428575 | 3.94E-19 | 17 | passed |
/strata/0/rows/0/density | tolerance | 0.050847457627118647 | 0.05084745762711865 | 3.61E-19 | 17 | passed |
/strata/0/rows/0/hazard_se | tolerance | 0.030885064593788945 | 0.030885064593788945 | 3.64E-19 | 16 | passed |
/strata/0/rows/0/density_se | tolerance | 0.027824062788314317 | 0.027824062788314317 | 2.98E-19 | 16 | passed |
/strata/0/rows/1/entering | exact | 26 | 26 | 0.00E+2 | passed | |
/strata/0/rows/1/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/0/rows/1/events | exact | 5 | 5 | 0.00E+2 | passed | |
/strata/0/rows/1/at_risk | tolerance | 25.5 | 25.5 | 0.00E+1 | passed | |
/strata/0/rows/1/q | tolerance | 0.19607843137254902 | 0.19607843137254902 | 3.11E-18 | 16 | passed |
/strata/0/rows/1/survival_start | tolerance | 0.89830508474576276 | 0.8983050847457628 | 7.89E-19 | 18 | passed |
/strata/0/rows/1/survival_start_se | tolerance | 0.05564812557662864 | 0.05564812557662864 | 3.43E-19 | 17 | passed |
/strata/0/rows/1/survival_end | tolerance | 0.72216683283482896 | 0.722166832834829 | 4.49E-18 | 17 | passed |
/strata/0/rows/1/survival_end_se | tolerance | 0.0836041707062537 | 0.0836041707062537 | 1.59E-19 | 17 | passed |
/strata/0/rows/1/hazard | tolerance | 0.10869565217391304 | 0.10869565217391304 | 4.61E-19 | 17 | passed |
/strata/0/rows/1/density | tolerance | 0.08806912595546694 | 0.08806912595546694 | 2.19E-19 | 17 | passed |
/strata/0/rows/1/hazard_se | tolerance | 0.048322161803436375 | 0.048322161803436375 | 3.49E-19 | 17 | passed |
/strata/0/rows/1/density_se | tolerance | 0.035732831819503062 | 0.03573283181950306 | 2.54E-19 | 17 | passed |
/strata/0/rows/2/entering | exact | 20 | 20 | 0.00E+2 | passed | |
/strata/0/rows/2/withdrawn | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/0/rows/2/events | exact | 5 | 5 | 0.00E+2 | passed | |
/strata/0/rows/2/at_risk | tolerance | 19 | 19.0 | 0.00E+2 | passed | |
/strata/0/rows/2/q | tolerance | 0.26315789473684209 | 0.2631578947368421 | 6.55E-19 | 17 | passed |
/strata/0/rows/2/survival_start | tolerance | 0.72216683283482896 | 0.722166832834829 | 4.49E-18 | 17 | passed |
/strata/0/rows/2/survival_start_se | tolerance | 0.0836041707062537 | 0.0836041707062537 | 1.59E-19 | 17 | passed |
/strata/0/rows/2/survival_end | tolerance | 0.53212292945724249 | 0.5321229294572425 | 1.62E-18 | 17 | passed |
/strata/0/rows/2/survival_end_se | tolerance | 0.095485064250730889 | 0.09548506425073089 | 1.20E-19 | 17 | passed |
/strata/0/rows/2/hazard | tolerance | 0.15151515151515149 | 0.1515151515151515 | 1.60E-18 | 16 | passed |
/strata/0/rows/2/density | tolerance | 0.09502195168879328 | 0.09502195168879328 | 3.11E-19 | 17 | passed |
/strata/0/rows/2/hazard_se | tolerance | 0.06697734629498793 | 0.06697734629498793 | 1.99E-20 | 18 | passed |
/strata/0/rows/2/density_se | tolerance | 0.038100220362851156 | 0.038100220362851156 | 1.37E-20 | 18 | passed |
/strata/0/rows/3/entering | exact | 13 | 13 | 0.00E+2 | passed | |
/strata/0/rows/3/withdrawn | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/0/rows/3/events | exact | 4 | 4 | 0.00E+2 | passed | |
/strata/0/rows/3/at_risk | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/strata/0/rows/3/q | tolerance | 0.33333333333333331 | 0.3333333333333333 | 4.83E-18 | 16 | passed |
/strata/0/rows/3/survival_start | tolerance | 0.53212292945724249 | 0.5321229294572425 | 1.62E-18 | 17 | passed |
/strata/0/rows/3/survival_start_se | tolerance | 0.095485064250730889 | 0.09548506425073089 | 1.20E-19 | 17 | passed |
/strata/0/rows/3/survival_end | tolerance | 0.35474861963816168 | 0.3547486196381617 | 2.57E-18 | 17 | passed |
/strata/0/rows/3/survival_end_se | tolerance | 0.096414647720468136 | 0.09641464772046814 | 3.06E-19 | 17 | passed |
/strata/0/rows/3/hazard | tolerance | 0.19999999999999998 | 0.19999999999999998 | 3.35E-18 | 16 | passed |
/strata/0/rows/3/density | tolerance | 0.088687154909540405 | 0.0886871549095404 | 4.79E-19 | 17 | passed |
/strata/0/rows/3/hazard_se | tolerance | 0.097979589711327114 | 0.09797958971132711 | 1.43E-19 | 17 | passed |
/strata/0/rows/3/density_se | tolerance | 0.03954949998653555 | 0.03954949998653555 | 4.55E-19 | 16 | passed |
/strata/0/rows/4/entering | exact | 7 | 7 | 0.00E+2 | passed | |
/strata/0/rows/4/withdrawn | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/0/rows/4/events | exact | 3 | 3 | 0.00E+2 | passed | |
/strata/0/rows/4/at_risk | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/strata/0/rows/4/q | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/strata/0/rows/4/survival_start | tolerance | 0.35474861963816168 | 0.3547486196381617 | 2.57E-18 | 17 | passed |
/strata/0/rows/4/survival_start_se | tolerance | 0.096414647720468136 | 0.09641464772046814 | 3.06E-19 | 17 | passed |
/strata/0/rows/4/survival_end | tolerance | 0.17737430981908084 | 0.17737430981908084 | 1.29E-18 | 17 | passed |
/strata/0/rows/4/survival_end_se | tolerance | 0.086991687559203265 | 0.08699168755920327 | 1.23E-19 | 17 | passed |
/strata/0/rows/4/hazard | tolerance | 0.33333333333333331 | 0.3333333333333333 | 4.83E-18 | 16 | passed |
/strata/0/rows/4/density | tolerance | 0.088687154909540419 | 0.08868715490954042 | 3.56E-19 | 17 | passed |
/strata/0/rows/4/hazard_se | tolerance | 0.18144368465060579 | 0.18144368465060579 | 4.56E-18 | 16 | passed |
/strata/0/rows/4/density_se | tolerance | 0.043495843779601633 | 0.04349584377960163 | 4.38E-19 | 16 | passed |
/strata/0/rows/5/entering | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/0/rows/5/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/0/rows/5/events | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/0/rows/5/at_risk | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/strata/0/rows/5/q | tolerance | 0.66666666666666663 | 0.6666666666666666 | 3.41E-19 | 18 | passed |
/strata/0/rows/5/survival_start | tolerance | 0.17737430981908084 | 0.17737430981908084 | 1.29E-18 | 17 | passed |
/strata/0/rows/5/survival_start_se | tolerance | 0.086991687559203265 | 0.08699168755920327 | 1.23E-19 | 17 | passed |
Convention
- Edges 0, 2, ..., 10 and the open interval [10, inf): findInterval places an event at exactly 2.0 and 4.0 in the interval that starts there.
- The open terminal row reports entering, withdrawn, events, n - w/2, q and the survival at its start only.
- Expected computed from the exported CSV.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:9-22: intervals closed on the left, open on the right; n' = n - w/2, q = d/n', p = 1 - q, S = prod p with Greenwood SE; midpoint hazard 2q/[b(1 + p)] and density S_{i-1} q/b.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:38-51: open last interval has no hazard or density; Gehan (Lee-Desu) on interval starts, event before withdrawal at a tie, (N - 1) sum U_j^2/n_j / sum S_i^2 on g - 1 df.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:53-58: actuarial median by linear interpolation in the first finite interval whose end survival reaches one half.
Reference code
The lines of the reference script that produce this case's expected values.
217 edges1 <- seq(0, 10, by = 2)
218 event <- d$status == 1L
219 rows1 <- life_table(d$time, event, edges1)
220 stopifnot(length(rows1) == 6L)
221 outputs <- c(
222 list("/analyzed_count" = exact(nrow(d), "30 rows analysed"),
223 "/strata/0/subjects" = exact(nrow(d), "30 subjects"),
224 "/strata/0/events" = exact(as.integer(sum(event)), "events"),
225 "/strata/0/withdrawn" = exact(as.integer(sum(!event)), "withdrawals"),
226 "/strata/0/median/status" = exact("estimated", "the median lies in a finite interval"),
227 "/strata/0/median/value" = tol(actuarial_median(rows1), "actuarial median by linear interpolation")),
228 row_outputs(rows1, "/strata/0", 1:6)
229 )
230 emit("STAT-SURV-LIFETAB-001", "Actuarial life table with 2-unit intervals to 10", "nominal",
231 "SURV_LIFETAB", list(time = "time", status = "status", event_value = "1", censored_value = "0",
232 interval_width = 2, last_boundary = 10),
233 outputs,
234 list("Edges 0, 2, ..., 10 and the open interval [10, inf): findInterval places an event at exactly 2.0 and 4.0 in the interval that starts there.",
235 "The open terminal row reports entering, withdrawn, events, n - w/2, q and the survival at its start only."))
Unequal boundaries with two strata and the grouped Gehan test
Case STAT-SURV-LIFETAB-002 · status: passed
Reference
- Evidence type
- R
- Source
- Base R arithmetic of the actuarial, Gehan and grouped PH formulas
- Citation
- Cutler and Ederer (1958) J Chronic Dis 8:699-712; Greenwood (1926); Lee and Desu (1972) Computer Programs in Biomedicine 2:315-321; Gehan (1965) Biometrika 52:203-223; Prentice and Gloeckler (1978) Biometrics 34:57-67; R stats: pchisq, glm (cloglog cross-check), anova(test = 'Rao').
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_tables.R · sha256 e7bfcfb4270e21ec
- Dataset
- reference_data/datasets/SURV_LIFETAB.json
Settings compared
boundaries= [0, 1, 3, 6, 12]censored_value= "0"event_value= "1"status= "status"strata= "group"time= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/strata/[stratum=A]/subjects | exact | 15 | 15 | 0.00E+2 | passed | |
/strata/[stratum=A]/events | exact | 11 | 11 | 0.00E+2 | passed | |
/strata/[stratum=A]/median/value | tolerance | 5.3380434782608699 | 5.33804347826087 | 1.04E-17 | 17 | passed |
/strata/[stratum=A]/rows/0/entering | exact | 15 | 15 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/withdrawn | exact | 0 | 0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/events | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/at_risk | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/q | tolerance | 0.066666666666666666 | 0.06666666666666667 | 2.59E-19 | 17 | passed |
/strata/[stratum=A]/rows/0/survival_start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/survival_end | tolerance | 0.93333333333333335 | 0.9333333333333333 | 1.86E-18 | 17 | passed |
/strata/[stratum=A]/rows/0/survival_end_se | tolerance | 0.064406118871953064 | 0.06440611887195306 | 3.80E-19 | 17 | passed |
/strata/[stratum=A]/rows/0/hazard | tolerance | 0.068965517241379309 | 0.06896551724137931 | 3.88E-19 | 17 | passed |
/strata/[stratum=A]/rows/0/density | tolerance | 0.066666666666666666 | 0.06666666666666667 | 2.59E-19 | 17 | passed |
/strata/[stratum=A]/rows/0/hazard_se | tolerance | 0.06892450295452765 | 0.06892450295452765 | 3.28E-20 | 18 | passed |
/strata/[stratum=A]/rows/0/density_se | tolerance | 0.064406118871953064 | 0.06440611887195306 | 3.80E-19 | 17 | passed |
/strata/[stratum=A]/rows/1/entering | exact | 14 | 14 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/events | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/at_risk | tolerance | 13.5 | 13.5 | 0.00E+1 | passed | |
/strata/[stratum=A]/rows/1/q | tolerance | 0.14814814814814814 | 0.14814814814814814 | 7.57E-20 | 18 | passed |
/strata/[stratum=A]/rows/1/survival_start | tolerance | 0.93333333333333335 | 0.9333333333333333 | 1.86E-18 | 17 | passed |
/strata/[stratum=A]/rows/1/survival_start_se | tolerance | 0.064406118871953064 | 0.06440611887195306 | 3.80E-19 | 17 | passed |
/strata/[stratum=A]/rows/1/survival_end | tolerance | 0.79506172839506173 | 0.7950617283950617 | 1.33E-18 | 17 | passed |
/strata/[stratum=A]/rows/1/survival_end_se | tolerance | 0.10560967602638514 | 0.10560967602638514 | 3.62E-18 | 16 | passed |
/strata/[stratum=A]/rows/1/hazard | tolerance | 0.080000000000000002 | 0.08 | 3.35E-19 | 17 | passed |
/strata/[stratum=A]/rows/1/density | tolerance | 0.069135802469135796 | 0.0691358024691358 | 1.44E-19 | 17 | passed |
/strata/[stratum=A]/rows/1/hazard_se | tolerance | 0.056387232597459508 | 0.05638723259745951 | 1.12E-19 | 17 | passed |
/strata/[stratum=A]/rows/1/density_se | tolerance | 0.045371622339945364 | 0.045371622339945364 | 1.34E-19 | 17 | passed |
/strata/[stratum=A]/rows/2/entering | exact | 11 | 11 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/2/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/2/events | exact | 5 | 5 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/2/at_risk | tolerance | 10.5 | 10.5 | 0.00E+1 | passed | |
/strata/[stratum=A]/rows/2/q | tolerance | 0.47619047619047616 | 0.47619047619047616 | 4.04E-18 | 17 | passed |
/strata/[stratum=A]/rows/2/survival_start | tolerance | 0.79506172839506173 | 0.7950617283950617 | 1.33E-18 | 17 | passed |
/strata/[stratum=A]/rows/2/survival_start_se | tolerance | 0.10560967602638514 | 0.10560967602638514 | 3.62E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/survival_end | tolerance | 0.41646090534979424 | 0.41646090534979424 | 1.47E-18 | 17 | passed |
/strata/[stratum=A]/rows/2/survival_end_se | tolerance | 0.13444944753346463 | 0.13444944753346463 | 3.29E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/hazard | tolerance | 0.20833333333333334 | 0.20833333333333334 | 2.59E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/density | tolerance | 0.12620027434842249 | 0.1262002743484225 | 3.52E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/hazard_se | tolerance | 0.088503361812325154 | 0.08850336181232515 | 2.01E-19 | 17 | passed |
/strata/[stratum=A]/rows/2/density_se | tolerance | 0.044153192261034278 | 0.04415319226103428 | 3.54E-19 | 17 | passed |
/strata/[stratum=A]/rows/3/entering | exact | 5 | 5 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/3/withdrawn | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/3/events | exact | 3 | 3 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/3/at_risk | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/3/q | tolerance | 0.75 | 0.75 | 0.00E+0 | passed | |
/strata/[stratum=A]/rows/3/survival_start | tolerance | 0.41646090534979424 | 0.41646090534979424 | 1.47E-18 | 17 | passed |
/strata/[stratum=A]/rows/3/survival_start_se | tolerance | 0.13444944753346463 | 0.13444944753346463 | 3.29E-18 | 16 | passed |
/strata/[stratum=A]/rows/3/survival_end | tolerance | 0.10411522633744856 | 0.10411522633744856 | 3.68E-19 | 17 | passed |
/strata/[stratum=A]/rows/3/survival_end_se | tolerance | 0.096227730607408454 | 0.09622773060740845 | 3.00E-19 | 17 | passed |
/strata/[stratum=A]/rows/3/hazard | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/strata/[stratum=A]/rows/3/density | tolerance | 0.05205761316872428 | 0.05205761316872428 | 1.84E-19 | 17 | passed |
/strata/[stratum=A]/rows/3/hazard_se | tolerance | 0.092376043070340114 | 0.09237604307034011 | 3.61E-19 | 17 | passed |
/strata/[stratum=A]/rows/3/density_se | tolerance | 0.022545080215277631 | 0.02254508021527763 | 1.19E-19 | 17 | passed |
/strata/[stratum=B]/subjects | exact | 15 | 15 | 0.00E+2 | passed | |
/strata/[stratum=B]/events | exact | 10 | 10 | 0.00E+2 | passed | |
/strata/[stratum=B]/median/value | tolerance | 7.8084705882352932 | 7.808470588235293 | 3.62E-17 | 17 | passed |
/strata/[stratum=B]/rows/0/entering | exact | 15 | 15 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/withdrawn | exact | 0 | 0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/events | exact | 0 | 0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/at_risk | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/q | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/survival_start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/survival_end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/survival_end_se | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/hazard | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/0/density | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/1/entering | exact | 15 | 15 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/1/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/1/events | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/1/at_risk | tolerance | 14.5 | 14.5 | 0.00E+1 | passed | |
/strata/[stratum=B]/rows/1/q | tolerance | 0.13793103448275862 | 0.13793103448275862 | 1.22E-18 | 17 | passed |
/strata/[stratum=B]/rows/1/survival_start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/1/survival_end | tolerance | 0.86206896551724133 | 0.8620689655172413 | 4.29E-18 | 17 | passed |
/strata/[stratum=B]/rows/1/survival_end_se | tolerance | 0.090556160592912105 | 0.0905561605929121 | 4.37E-20 | 18 | passed |
/strata/[stratum=B]/rows/1/hazard | tolerance | 0.07407407407407407 | 0.07407407407407407 | 3.79E-20 | 18 | passed |
/strata/[stratum=B]/rows/1/density | tolerance | 0.068965517241379309 | 0.06896551724137931 | 3.88E-19 | 17 | passed |
/strata/[stratum=B]/rows/1/hazard_se | tolerance | 0.052234383442139286 | 0.052234383442139286 | 1.97E-19 | 17 | passed |
/strata/[stratum=B]/rows/1/density_se | tolerance | 0.045278080296456046 | 0.045278080296456046 | 4.61E-19 | 16 | passed |
/strata/[stratum=B]/rows/2/entering | exact | 12 | 12 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/2/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/2/events | exact | 3 | 3 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/2/at_risk | tolerance | 11.5 | 11.5 | 0.00E+1 | passed | |
/strata/[stratum=B]/rows/2/q | tolerance | 0.2608695652173913 | 0.2608695652173913 | 2.89E-18 | 16 | passed |
/strata/[stratum=B]/rows/2/survival_start | tolerance | 0.86206896551724133 | 0.8620689655172413 | 4.29E-18 | 17 | passed |
/strata/[stratum=B]/rows/2/survival_start_se | tolerance | 0.090556160592912105 | 0.0905561605929121 | 4.37E-20 | 18 | passed |
/strata/[stratum=B]/rows/2/survival_end | tolerance | 0.63718140929535227 | 0.6371814092953523 | 4.57E-18 | 17 | passed |
/strata/[stratum=B]/rows/2/survival_end_se | tolerance | 0.130155154512758 | 0.130155154512758 | 2.15E-18 | 16 | passed |
/strata/[stratum=B]/rows/2/hazard | tolerance | 0.09999999999999999 | 0.09999999999999999 | 1.67E-18 | 16 | passed |
/strata/[stratum=B]/rows/2/density | tolerance | 0.074962518740629674 | 0.07496251874062967 | 4.63E-19 | 17 | passed |
/strata/[stratum=B]/rows/2/hazard_se | tolerance | 0.057081812631812362 | 0.05708181263181236 | 2.00E-20 | 18 | passed |
/strata/[stratum=B]/rows/2/density_se | tolerance | 0.03803277109854445 | 0.03803277109854445 | 3.17E-19 | 17 | passed |
/strata/[stratum=B]/rows/3/entering | exact | 8 | 8 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/3/withdrawn | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/3/events | exact | 5 | 5 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/3/at_risk | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/3/q | tolerance | 0.7142857142857143 | 0.7142857142857143 | 1.57E-18 | 17 | passed |
/strata/[stratum=B]/rows/3/survival_start | tolerance | 0.63718140929535227 | 0.6371814092953523 | 4.57E-18 | 17 | passed |
/strata/[stratum=B]/rows/3/survival_start_se | tolerance | 0.130155154512758 | 0.130155154512758 | 2.15E-18 | 16 | passed |
/strata/[stratum=B]/rows/3/survival_end | tolerance | 0.1820518312272435 | 0.1820518312272435 | 9.11E-19 | 17 | passed |
/strata/[stratum=B]/rows/3/survival_end_se | tolerance | 0.11497663195728725 | 0.11497663195728725 | 4.72E-18 | 16 | passed |
/strata/[stratum=B]/rows/3/hazard | tolerance | 0.1851851851851852 | 0.1851851851851852 | 2.66E-18 | 16 | passed |
/strata/[stratum=B]/rows/3/density | tolerance | 0.075854929678018129 | 0.07585492967801813 | 2.47E-19 | 17 | passed |
/strata/[stratum=B]/rows/3/hazard_se | tolerance | 0.068860907533668775 | 0.06886090753366877 | 1.84E-19 | 17 | passed |
/strata/[stratum=B]/rows/3/density_se | tolerance | 0.023851264817249834 | 0.023851264817249834 | 2.71E-19 | 16 | passed |
/strata/[stratum=B]/rows/4/entering | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/4/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/4/events | exact | 0 | 0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/4/at_risk | tolerance | 0.5 | 0.5 | 0.00E+1 | passed | |
/strata/[stratum=B]/rows/4/q | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=B]/rows/4/survival_start | tolerance | 0.1820518312272435 | 0.1820518312272435 | 9.11E-19 | 17 | passed |
/strata/[stratum=B]/rows/4/survival_start_se | tolerance | 0.11497663195728725 | 0.11497663195728725 | 4.72E-18 | 16 | passed |
/comparison/statistic | tolerance | 1.0141087470449173 | 1.0141087470449173 | 3.08E-17 | 16 | passed |
/comparison/df | exact | 1 | 1 | 0.00E+2 | passed | |
/comparison/p_value | tail_probability | 0.31392051856554515 | 0.3139205185655422 | 2.94E-15 | 14 | passed |
/comparison/strata/[stratum=A]/score_sum | tolerance | -43 | -43.0 | 0.00E+2 | passed | |
/comparison/strata/[stratum=B]/mean_score | tolerance | 2.8666666666666667 | 2.8666666666666667 | 3.73E-18 | 17 | passed |
Convention
- Explicit boundaries 0, 1, 3, 6, 12; each stratum gets its own table and median.
- Gehan scores by the pairwise definition on interval starts (open interval -> 12): case a scores +1 against an uncensored b with an earlier grouped time, or an uncensored b at the same grouped time when a is censored; -1 symmetrically; the scores sum to zero (asserted).
- Expected computed from the exported CSV.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:9-22: intervals closed on the left, open on the right; n' = n - w/2, q = d/n', p = 1 - q, S = prod p with Greenwood SE; midpoint hazard 2q/[b(1 + p)] and density S_{i-1} q/b.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:38-51: open last interval has no hazard or density; Gehan (Lee-Desu) on interval starts, event before withdrawal at a tie, (N - 1) sum U_j^2/n_j / sum S_i^2 on g - 1 df.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:53-58: actuarial median by linear interpolation in the first finite interval whose end survival reaches one half.
Reference code
The lines of the reference script that produce this case's expected values.
249 grouped <- edges2[findInterval(d$time, edges2)]
250 cmp <- gehan(grouped, event, d$group)
251 outputs[["/comparison/statistic"]] <- tol(cmp$statistic, "Lee-Desu chi-square on grouped times")
252 outputs[["/comparison/df"]] <- exact(as.integer(cmp$df), "strata minus one")
253 outputs[["/comparison/p_value"]] <- prob(cmp$p, "Lee-Desu chi-square tail")
254 outputs[["/comparison/strata/[stratum=A]/score_sum"]] <- tol(cmp$sums[["A"]], "Gehan score sum of stratum A")
255 outputs[["/comparison/strata/[stratum=B]/mean_score"]] <- tol(cmp$means[["B"]], "mean Gehan score of stratum B")
256 emit("STAT-SURV-LIFETAB-002", "Unequal boundaries with two strata and the grouped Gehan test", "axis_coverage",
257 "SURV_LIFETAB", list(time = "time", status = "status", event_value = "1", censored_value = "0",
258 boundaries = list(0, 1, 3, 6, 12), strata = "group"),
259 outputs,
260 list("Explicit boundaries 0, 1, 3, 6, 12; each stratum gets its own table and median.",
261 "Gehan scores by the pairwise definition on interval starts (open interval -> 12): case a scores +1 against an uncensored b with an earlier grouped time, or an uncensored b at the same grouped time when a is censored; -1 symmetrically; the scores sum to zero (asserted)."))
Scheduled visits with text status values and the grouped PH score test
Case STAT-SURV-LIFETAB-003 · status: passed
Reference
- Evidence type
- R
- Source
- Base R arithmetic of the actuarial, Gehan and grouped PH formulas
- Citation
- Cutler and Ederer (1958) J Chronic Dis 8:699-712; Greenwood (1926); Lee and Desu (1972) Computer Programs in Biomedicine 2:315-321; Gehan (1965) Biometrika 52:203-223; Prentice and Gloeckler (1978) Biometrics 34:57-67; R stats: pchisq, glm (cloglog cross-check), anova(test = 'Rao').
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_tables.R · sha256 e7bfcfb4270e21ec
- Dataset
- reference_data/datasets/SURV_LIFETAB_VISITS.json
Settings compared
boundaries= [0, 1, 2, 3, 4, 5, 6]censored_value= "censored"event_value= "event"grouped_ph_test= trueobservation_model= "scheduled_visits"status= "status"strata= "group"time= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/strata/[stratum=A]/rows/0/entering | exact | 15 | 15 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/withdrawn | exact | 0 | 0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/events | exact | 0 | 0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/at_risk | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/q | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/survival_start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/survival_end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/survival_end_se | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/hazard | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/0/density | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/entering | exact | 15 | 15 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/withdrawn | exact | 0 | 0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/events | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/at_risk | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/q | tolerance | 0.13333333333333333 | 0.13333333333333333 | 1.48E-18 | 16 | passed |
/strata/[stratum=A]/rows/1/survival_start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/1/survival_end | tolerance | 0.8666666666666667 | 0.8666666666666667 | 3.73E-18 | 17 | passed |
/strata/[stratum=A]/rows/1/survival_end_se | tolerance | 0.087770745147251111 | 0.08777074514725111 | 3.18E-19 | 17 | passed |
/strata/[stratum=A]/rows/1/hazard | tolerance | 0.14285714285714285 | 0.14285714285714285 | 7.87E-19 | 17 | passed |
/strata/[stratum=A]/rows/1/density | tolerance | 0.13333333333333333 | 0.13333333333333333 | 1.48E-18 | 16 | passed |
/strata/[stratum=A]/rows/1/hazard_se | tolerance | 0.1007572329496505 | 0.1007572329496505 | 7.46E-19 | 17 | passed |
/strata/[stratum=A]/rows/1/density_se | tolerance | 0.087770745147251111 | 0.08777074514725111 | 3.18E-19 | 17 | passed |
/strata/[stratum=A]/rows/2/entering | exact | 13 | 13 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/2/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/2/events | exact | 2 | 2 | 0.00E+2 | passed | |
/strata/[stratum=A]/rows/2/at_risk | tolerance | 12.5 | 12.5 | 0.00E+1 | passed | |
/strata/[stratum=A]/rows/2/q | tolerance | 0.16 | 0.16 | 3.33E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/survival_start | tolerance | 0.8666666666666667 | 0.8666666666666667 | 3.73E-18 | 17 | passed |
/strata/[stratum=A]/rows/2/survival_start_se | tolerance | 0.087770745147251111 | 0.08777074514725111 | 3.18E-19 | 17 | passed |
/strata/[stratum=A]/rows/2/survival_end | tolerance | 0.72799999999999998 | 0.728 | 4.60E-19 | 18 | passed |
/strata/[stratum=A]/rows/2/survival_end_se | tolerance | 0.11623975223648748 | 0.11623975223648748 | 4.12E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/hazard | tolerance | 0.17391304347826089 | 0.1739130434782609 | 2.49E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/density | tolerance | 0.13866666666666669 | 0.1386666666666667 | 1.94E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/hazard_se | tolerance | 0.12250927596234142 | 0.12250927596234142 | 4.30E-18 | 16 | passed |
/strata/[stratum=A]/rows/2/density_se | tolerance | 0.090956921020236198 | 0.0909569210202362 | 2.61E-19 | 17 | passed |
/strata/[stratum=B]/rows/0/withdrawn | exact | 1 | 1 | 0.00E+2 | passed | |
/grouped_ph/statistic | tolerance | 0.18949737118618118 | 0.18949737118618118 | 6.30E-19 | 17 | passed |
/grouped_ph/df | exact | 1 | 1 | 0.00E+2 | passed | |
/grouped_ph/p_value | tail_probability | 0.66333528069243131 | 0.6633352806924313 | 3.91E-18 | 17 | passed |
/grouped_ph/groups/[group=A]/score | tolerance | 0.92023291727649281 | 0.9202329172764928 | 2.24E-18 | 17 | passed |
/grouped_ph/groups/[group=B]/lost_before_first_visit | exact | 1 | 1 | 0.00E+2 | passed | |
/grouped_ph/information/0/0 | tolerance | 4.4688146159410058 | 4.468814615941006 | 1.89E-17 | 17 | passed |
/grouped_ph/zero_information_intervals | exact | 0 | 0 | 0.00E+2 | passed | |
/grouped_ph/intervals/0/at_risk/1 | exact | 14 | 14 | 0.00E+2 | passed | |
/grouped_ph/intervals/2/events/0 | exact | 2 | 2 | 0.00E+2 | passed | |
/comparison/statistic | tolerance | 0.50013329232031167 | 0.5001332923203117 | 3.15E-18 | 17 | passed |
Convention
- Status values are the texts 'event' and 'censored'.
- Grouped PH score test (docs/manual/chapters/107-grouped-ph.tex): r[g, j] subjects of group g with visit index m >= j, d[g, j] events detected at visit j; under H0 q_j = d_j/r_j, a_j = -log(1 - q_j); U[g] = sum_j (a_j/q_j)(d[g, j] - r[g, j] q_j), I[g, h] = sum_j a_j^2 (1 - q_j)/q_j (delta r[g, j] - r[g, j] r[h, j]/r_j); Q = U' I^-1 U on the first G - 1 coordinates.
- The by-hand statistic is cross-checked in the generator against the expected-information score test of the group term computed from the null complementary log-log binomial GLM fit (one intercept per visit interval; glm fitted values, mu.eta and model matrix) to 1e-9 relative, and against anova(test = 'Rao') to 1e-3; the generator stops if either differs more.
- Expected computed from the exported CSV.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:9-22: intervals closed on the left, open on the right; n' = n - w/2, q = d/n', p = 1 - q, S = prod p with Greenwood SE; midpoint hazard 2q/[b(1 + p)] and density S_{i-1} q/b.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:38-51: open last interval has no hazard or density; Gehan (Lee-Desu) on interval starts, event before withdrawal at a tie, (N - 1) sum U_j^2/n_j / sum S_i^2 on g - 1 df.
- docs/manual/chapters/93-grouped-and-changing-survival.tex:53-58: actuarial median by linear interpolation in the first finite interval whose end survival reaches one half.
Reference code
The lines of the reference script that produce this case's expected values.
264 edges3 <- 0:6
265 eventv <- dv$status == "event"
266 outputs <- list()
267 rows_a <- life_table(dv$time[dv$group == "A"], eventv[dv$group == "A"], edges3)
268 outputs <- c(outputs, row_outputs(rows_a, "/strata/[stratum=A]", 1:3))
269 outputs[["/strata/[stratum=B]/rows/0/withdrawn"]] <- exact(1L, "the subject censored at the origin is withdrawn in [0, 1)")
270 ph <- grouped_ph(dv$time, eventv, dv$group, length(edges3) - 1)
271 outputs[["/grouped_ph/statistic"]] <- tol(ph$statistic, "Prentice-Gloeckler score statistic U' I^-1 U")
272 outputs[["/grouped_ph/df"]] <- exact(as.integer(ph$df), "groups minus one")
273 outputs[["/grouped_ph/p_value"]] <- prob(ph$p, "grouped PH chi-square tail")
274 outputs[["/grouped_ph/groups/[group=A]/score"]] <- tol(ph$scores[1], "score of group A")
275 outputs[["/grouped_ph/groups/[group=B]/lost_before_first_visit"]] <- exact(1L, "one subject of B censored at the origin")
276 outputs[["/grouped_ph/information/0/0"]] <- tol(ph$information[1, 1], "information of the first group coordinate")
277 outputs[["/grouped_ph/zero_information_intervals"]] <- exact(0L, "every visit interval has 0 < q < 1")
278 outputs[["/grouped_ph/intervals/0/at_risk/1"]] <- exact(as.integer(ph$r[2, 1]), "B at risk in (0, 1]: 14 (the origin-censored subject is not)")
279 outputs[["/grouped_ph/intervals/2/events/0"]] <- exact(as.integer(ph$d[1, 3]), "A events detected at visit 3")
280 cmp3 <- gehan(edges3[findInterval(dv$time, edges3)], eventv, dv$group)
281 outputs[["/comparison/statistic"]] <- tol(cmp3$statistic, "Lee-Desu chi-square on the visit times")
282 emit("STAT-SURV-LIFETAB-003", "Scheduled visits with text status values and the grouped PH score test", "axis_coverage",
283 "SURV_LIFETAB_VISITS", list(time = "time", status = "status", event_value = "event",
284 censored_value = "censored", boundaries = as.list(as.numeric(edges3)),
285 strata = "group", observation_model = "scheduled_visits",
286 grouped_ph_test = TRUE),
287 outputs,
288 list("Status values are the texts 'event' and 'censored'.",
289 "Grouped PH score test (docs/manual/chapters/107-grouped-ph.tex): r[g, j] subjects of group g with visit index m >= j, d[g, j] events detected at visit j; under H0 q_j = d_j/r_j, a_j = -log(1 - q_j); U[g] = sum_j (a_j/q_j)(d[g, j] - r[g, j] q_j), I[g, h] = sum_j a_j^2 (1 - q_j)/q_j (delta r[g, j] - r[g, j] r[h, j]/r_j); Q = U' I^-1 U on the first G - 1 coordinates.",
290 "The by-hand statistic is cross-checked in the generator against the expected-information score test of the group term computed from the null complementary log-log binomial GLM fit (one intercept per visit interval; glm fitted values, mu.eta and model matrix) to 1e-9 relative, and against anova(test = 'Rao') to 1e-3; the generator stops if either differs more."))
Survival STAT-SURV-LOGRANK-001
Case STAT-SURV-LOGRANK-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/survdiff/coxph and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, MASS 7.3.65, jsonlite 2.0.0
- Reference script
- generators/r/survival_core.R · sha256 1ed8945e6864eb84
- Dataset
- reference_data/datasets/HARVEST_GEHAN_BOTH.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"group_column= "arm"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/log_rank/statistic | tolerance | 16.79294098921654 | 16.79294098921654 | 4.51E-16 | 16 | passed |
/log_rank/observed | sequence | [9, 21] | [9, 21] | passed |
Convention
- R survdiff rho=0 gives the log-rank statistic; checks V14 Gehan grouping.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
48 group_fit <- survival::survdiff(survival::Surv(time,status)~arm,data=both)
49 emit("STAT-SURV-LOGRANK-001","tabelz.executor.survival","survivalMenuItem",
50 "HARVEST_GEHAN_BOTH",c(config,list(group_column="arm")),
51 list("/log_rank/statistic"=tol(group_fit$chisq,"R two-group log-rank chi-square"),
52 "/log_rank/observed"=seqexact(group_fit$obs,"R observed failures by arm")),
53 c("R survdiff rho=0 gives the log-rank statistic; checks V14 Gehan grouping."))
Kaplan-Meier life estimation with frequencies at 95%
Case STAT-SURV-NP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_KM_B9.json
Settings compared
confidence_level= 0.95frequency= "freq"layout= "right_censored"start= "time"status= "status"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 22 | 22 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 22 | 22 | 0.00E+2 | passed | |
/counts/exact | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/0/time | tolerance | 28.5 | 28.5 | 0.00E+1 | passed | |
/estimate/kaplan_meier/0/at_risk | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/0/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/0/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/0/survival | tolerance | 0.95999999999999996 | 0.96 | 4.47E-18 | 17 | passed |
/estimate/kaplan_meier/0/lower | tolerance | 0.74838502419475794 | 0.7483850241947579 | 1.81E-18 | 17 | passed |
/estimate/kaplan_meier/0/upper | tolerance | 0.99426695074883775 | 0.9942669507488378 | 2.27E-18 | 17 | passed |
/estimate/kaplan_meier/1/time | tolerance | 31.5 | 31.5 | 0.00E+1 | passed | |
/estimate/kaplan_meier/1/at_risk | tolerance | 24 | 24.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/1/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/1/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/1/survival | tolerance | 0.92000000000000004 | 0.92 | 3.20E-20 | 19 | passed |
/estimate/kaplan_meier/1/lower | tolerance | 0.71639033725806345 | 0.7163903372580634 | 2.34E-18 | 17 | passed |
/estimate/kaplan_meier/1/upper | tolerance | 0.97937058542804956 | 0.9793705854280496 | 4.04E-18 | 17 | passed |
/estimate/kaplan_meier/2/time | tolerance | 50.200000000000003 | 50.2 | 1.58E-16 | 17 | passed |
/estimate/kaplan_meier/2/at_risk | tolerance | 23 | 23.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/2/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/2/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/2/survival | tolerance | 0.88000000000000012 | 0.8800000000000001 | 4.54E-18 | 17 | passed |
/estimate/kaplan_meier/2/lower | tolerance | 0.67256145286335922 | 0.6725614528633592 | 1.51E-18 | 17 | passed |
/estimate/kaplan_meier/2/upper | tolerance | 0.95963983233203254 | 0.9596398323320325 | 1.47E-18 | 17 | passed |
/estimate/kaplan_meier/3/time | tolerance | 51.600000000000001 | 51.6 | 4.21E-16 | 17 | passed |
/estimate/kaplan_meier/3/at_risk | tolerance | 22 | 22.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/3/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/3/censored | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/3/survival | tolerance | 0.84000000000000019 | 0.8400000000000002 | 9.58E-19 | 17 | passed |
/estimate/kaplan_meier/3/lower | tolerance | 0.62805608155617798 | 0.6280560815561779 | 1.10E-16 | 15 | passed |
/estimate/kaplan_meier/3/upper | tolerance | 0.93673324025134008 | 0.9367332402513401 | 2.42E-18 | 17 | passed |
/estimate/kaplan_meier/4/time | tolerance | 57.100000000000001 | 57.1 | 4.21E-16 | 17 | passed |
/estimate/kaplan_meier/4/at_risk | tolerance | 19 | 19.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/4/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/4/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/4/survival | tolerance | 0.79578947368421071 | 0.7957894736842107 | 3.07E-18 | 17 | passed |
/estimate/kaplan_meier/4/lower | tolerance | 0.57621641968068271 | 0.5762164196806826 | 1.09E-16 | 15 | passed |
/estimate/kaplan_meier/4/upper | tolerance | 0.90969443356369484 | 0.9096944335636948 | 2.45E-18 | 17 | passed |
/estimate/kaplan_meier/5/time | tolerance | 73.799999999999997 | 73.8 | 1.58E-16 | 17 | passed |
/estimate/kaplan_meier/5/at_risk | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/5/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/5/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/5/survival | tolerance | 0.74605263157894752 | 0.7460526315789475 | 2.68E-18 | 17 | passed |
/estimate/kaplan_meier/5/lower | tolerance | 0.51712150301985571 | 0.5171215030198557 | 5.48E-19 | 17 | passed |
/estimate/kaplan_meier/5/upper | tolerance | 0.87797162670472406 | 0.8779716267047241 | 1.87E-18 | 17 | passed |
/estimate/kaplan_meier/6/time | tolerance | 77.599999999999994 | 77.6 | 3.16E-16 | 17 | passed |
/estimate/kaplan_meier/6/at_risk | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/6/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/6/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/6/survival | tolerance | 0.69631578947368433 | 0.6963157894736843 | 2.30E-18 | 17 | passed |
/estimate/kaplan_meier/6/lower | tolerance | 0.46275228280784469 | 0.4627522828078446 | 1.06E-16 | 15 | passed |
/estimate/kaplan_meier/6/upper | tolerance | 0.84365006447252466 | 0.8436500644725248 | 1.14E-16 | 15 | passed |
/estimate/kaplan_meier/7/time | tolerance | 83.400000000000006 | 83.4 | 3.16E-16 | 17 | passed |
/estimate/kaplan_meier/7/at_risk | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/7/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/7/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/7/survival | tolerance | 0.64657894736842114 | 0.6465789473684211 | 1.92E-18 | 17 | passed |
/estimate/kaplan_meier/7/lower | tolerance | 0.41184237299776144 | 0.41184237299776144 | 1.14E-18 | 17 | passed |
/estimate/kaplan_meier/7/upper | tolerance | 0.80707015000544269 | 0.8070701500054428 | 1.09E-16 | 15 | passed |
/estimate/kaplan_meier/8/time | tolerance | 97.700000000000003 | 97.7 | 1.58E-16 | 17 | passed |
/estimate/kaplan_meier/8/at_risk | tolerance | 13 | 13.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/8/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/8/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/8/survival | tolerance | 0.59684210526315806 | 0.5968421052631581 | 2.56E-18 | 17 | passed |
/estimate/kaplan_meier/8/lower | tolerance | 0.36374538146942675 | 0.36374538146942675 | 3.98E-18 | 16 | passed |
/estimate/kaplan_meier/8/upper | tolerance | 0.76844566812946369 | 0.7684456681294638 | 1.09E-16 | 15 | passed |
/estimate/kaplan_meier/9/time | tolerance | 116.5 | 116.5 | 0.00E+1 | passed | |
/estimate/kaplan_meier/9/at_risk | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/9/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/9/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/9/survival | tolerance | 0.54710526315789487 | 0.5471052631578949 | 2.17E-18 | 17 | passed |
/estimate/kaplan_meier/9/lower | tolerance | 0.31810565969803806 | 0.31810565969803806 | 3.14E-18 | 17 | passed |
/estimate/kaplan_meier/9/upper | tolerance | 0.72790881052736456 | 0.7279088105273646 | 1.86E-18 | 17 | passed |
/estimate/kaplan_meier/10/time | tolerance | 135.30000000000001 | 135.3 | 1.37E-15 | 16 | passed |
/estimate/kaplan_meier/10/at_risk | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/10/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/10/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/10/survival | tolerance | 0.49239473684210538 | 0.4923947368421054 | 4.96E-18 | 16 | passed |
/estimate/kaplan_meier/10/lower | tolerance | 0.26829369759954291 | 0.2682936975995429 | 2.97E-18 | 16 | passed |
/estimate/kaplan_meier/10/upper | tolerance | 0.68283277005026077 | 0.6828327700502609 | 1.14E-16 | 15 | passed |
/estimate/kaplan_meier/11/time | tolerance | 147.69999999999999 | 147.7 | 1.37E-15 | 17 | passed |
/estimate/kaplan_meier/11/at_risk | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/11/failures | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/11/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/11/survival | tolerance | 0.24619736842105269 | 0.2461973684210527 | 2.48E-18 | 16 | passed |
/estimate/kaplan_meier/11/lower | tolerance | 0.04904271544687918 | 0.04904271544687912 | 6.23E-17 | 14 | passed |
/estimate/kaplan_meier/11/upper | tolerance | 0.52122360275218238 | 0.5212236027521825 | 1.11E-16 | 15 | passed |
/estimate/kaplan_meier/12/time | tolerance | 151.69999999999999 | 151.7 | 1.37E-15 | 17 | passed |
/estimate/kaplan_meier/12/at_risk | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/12/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/12/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/12/survival | tolerance | 0.12309868421052635 | 0.12309868421052635 | 3.76E-18 | 16 | passed |
/estimate/kaplan_meier/12/lower | tolerance | 0.0079289073145356447 | 0.007928907314535636 | 8.65E-18 | 14 | passed |
/estimate/kaplan_meier/12/upper | tolerance | 0.40367684445923863 | 0.4036768444592387 | 5.18E-17 | 15 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:44-51: Kaplan-Meier for exact and right-censored records; failures precede censorings at tied times; log-minus-log intervals are unavailable at survival 0 or 1.
- R: survfit(Surv(time, status) ~ 1, weights = freq, conf.type = 'log-log'); steps are compared at failure times only, as the engine reports them.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
327 km_case("STAT-SURV-NP-001", "Kaplan-Meier life estimation with frequencies at 95%",
328 0.95, NP_NOTES, "nominal")
Turnbull nonparametric life estimation from interval data
Case STAT-SURV-NP-002 · status: passed
Reference
- Evidence type
- R
- Source
- Retained R reference with independently reviewed analytical corrections
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- not recorded
- Reference script
- generators/analytic/reviewed_reference_corrections.py · sha256 49e3645836bb3ac3
- Dataset
- reference_data/datasets/SURV_INTERVAL_B9.json
Settings compared
confidence_level= 0.95end= "end"frequency= "freq"layout= "arbitrary"start= "start"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 12 | 12 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 12 | 12 | 0.00E+2 | passed | |
/counts/exact | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/estimate/turnbull/0/low | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/estimate/turnbull/0/high | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/estimate/turnbull/0/mass | tolerance | 0.3175954681666806869060550887512482509706254426925649517152 | 0.31759546816668066 | 2.57E-17 | 16 | passed |
/estimate/turnbull/0/survival_before | tolerance | 1.0000000000000000000000000000000000000000000000000000000000 | 1.0 | 0.00E-67 | passed | |
/estimate/turnbull/0/survival_after | tolerance | 0.6824045318333193130939449112487517490293745573074350482847 | 0.6824045318333194 | 8.13E-17 | 15 | passed |
/estimate/turnbull/1/low | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/estimate/turnbull/1/high | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/estimate/turnbull/1/mass | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/turnbull/1/survival_before | tolerance | 0.6824045318333193130939449112487517490293745573074350482847 | 0.6824045318333194 | 8.13E-17 | 15 | passed |
/estimate/turnbull/1/survival_after | tolerance | 0.6824045318333193130939449112487517490293745573074350482847 | 0.6824045318333194 | 8.13E-17 | 15 | passed |
/estimate/turnbull/2/low | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/estimate/turnbull/2/high | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/estimate/turnbull/2/mass | tolerance | 0.0981423969999719595212231558308368313920824479482034299027 | 0.09814239699997238 | 4.16E-16 | 14 | passed |
/estimate/turnbull/2/survival_before | tolerance | 0.6824045318333193130939449112487517490293745573074350482847 | 0.6824045318333194 | 8.13E-17 | 15 | passed |
/estimate/turnbull/2/survival_after | tolerance | 0.5842621348333473535727217554179149176372921093592316183819 | 0.584262134833347 | 3.63E-16 | 15 | passed |
/estimate/turnbull/3/low | tolerance | 24 | 24.0 | 0.00E+2 | passed | |
/estimate/turnbull/3/high | tolerance | 24 | 24.0 | 0.00E+2 | passed | |
/estimate/turnbull/3/mass | tolerance | 0.3175954681666806869060550887512482509706254426925649517152 | 0.31759546816667916 | 1.52E-15 | 14 | passed |
/estimate/turnbull/3/survival_before | tolerance | 0.5842621348333473535727217554179149176372921093592316183819 | 0.584262134833347 | 3.63E-16 | 15 | passed |
/estimate/turnbull/3/survival_after | tolerance | 0.2666666666666666666666666666666666666666666666666666666666 | 0.26666666666666783 | 1.16E-15 | 14 | passed |
/estimate/turnbull/4/low | tolerance | 28 | 28.0 | 0.00E+2 | passed | |
/estimate/turnbull/4/high | tolerance | 30 | 30.0 | 0.00E+2 | passed | |
/estimate/turnbull/4/mass | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/turnbull/4/survival_before | tolerance | 0.2666666666666666666666666666666666666666666666666666666666 | 0.26666666666666783 | 1.16E-15 | 14 | passed |
/estimate/turnbull/4/survival_after | tolerance | 0.2666666666666666666666666666666666666666666666666666666666 | 0.26666666666666783 | 1.16E-15 | 14 | passed |
/estimate/turnbull/5/low | tolerance | 30 | 30.0 | 0.00E+2 | passed | |
/estimate/turnbull/5/high | tolerance | 40 | 40.0 | 0.00E+2 | passed | |
/estimate/turnbull/5/mass | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/turnbull/5/survival_before | tolerance | 0.2666666666666666666666666666666666666666666666666666666666 | 0.26666666666666783 | 1.16E-15 | 14 | passed |
/estimate/turnbull/5/survival_after | tolerance | 0.2666666666666666666666666666666666666666666666666666666666 | 0.26666666666666783 | 1.16E-15 | 14 | passed |
/estimate/turnbull/6/low | tolerance | 40 | 40.0 | 0.00E+2 | passed | |
/estimate/turnbull/6/high | tolerance | 50 | 50.0 | 0.00E+2 | passed | |
/estimate/turnbull/6/mass | tolerance | 0.1333333333333333333333333333333333333333333333333333333333 | 0.13333333333333444 | 1.11E-15 | 14 | passed |
/estimate/turnbull/6/survival_before | tolerance | 0.2666666666666666666666666666666666666666666666666666666666 | 0.26666666666666783 | 1.16E-15 | 14 | passed |
/estimate/turnbull/6/survival_after | tolerance | 0.1333333333333333333333333333333333333333333333333333333333 | 0.1333333333333334 | 5.37E-17 | 15 | passed |
/estimate/turnbull/7/low | tolerance | 55 | 55.0 | 0.00E+2 | passed | |
/estimate/turnbull/7/high | tolerance | 55 | 55.0 | 0.00E+2 | passed | |
/estimate/turnbull/7/mass | tolerance | 0.1333333333333333333333333333333333333333333333333333333333 | 0.13333333333333347 | 1.37E-16 | 14 | passed |
/estimate/turnbull/7/survival_before | tolerance | 0.1333333333333333333333333333333333333333333333333333333333 | 0.1333333333333334 | 5.37E-17 | 15 | passed |
/estimate/turnbull/7/survival_after | tolerance | 0 | 0.0 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:48-51: Turnbull masses on maximal intersection intervals; no Greenwood band; likelihood optimality is checked, not assumed.
- Reference: an independent R implementation of Turnbull's (1976) EM self-consistency algorithm on the innermost intervals, iterated until the masses change by less than 1e-14. survival::survfit's interval-censored estimate places its drops at interval midpoints and a different support enumeration, so it cannot be compared row by row; the total mass and the shared exact-time steps were checked against it during development.
- The dataset has a unique NPMLE (no overlapping-support ambiguity) and no open tail: the largest observation is an exact failure beyond every interval and censoring bound.
- Every innermost interval (zero-mass rows included) is compared positionally in lower- then upper-end order, as the engine reports them.
- R re-reads the exported CSV before calculating the reference.
- Versioned analytical correction from accuracy_adjudications.json: exact MDS rank/inertia or Turnbull KKT proof. Original R expectations and generator identities are preserved in accuracy_reference_revisions.json and history.
Reference code
The lines of the reference script that produce this case's expected values.
39 def corrected_reference(root: Path, case_id: str) -> dict[str, Any]:
40 revisions = json.loads((root / REVISION_PATH).read_bytes())
41 proof = _read_bound(root, revisions["proof"])
42 revision = revisions["cases"][case_id]
43 original = _read_bound(root, revision["original_expected"])
44 data = (root / revision["csv"]["path"]).read_bytes()
45 if hashlib.sha256(data).hexdigest() != revision["csv"]["sha256"]:
46 raise ValueError("Analytical correction applies only to the reviewed dataset")
47 result = copy.deepcopy(original)
48 entries = [
49 item
50 for item in proof["entries"]
51 if item["case_id"] == case_id
52 and item["disposition"] == "approved_mathematical_zero_reference_correction"
53 ]
54 if not entries:
55 raise ValueError("No approved correction for this case")
56 for item in entries:
57 if result["outputs"][item["path"]] != item["retained_reference"]:
58 raise ValueError("Analytical correction preimage differs")
59 result["outputs"][item["path"]].update(
60 value="0",
61 rationale=correction_rationale(item["proof"]),
62 )
63 if case_id == "STAT-SURV-NP-002":
64 solution = proof["proofs"]["turnbull_exact_kkt"]
65 with localcontext() as context:
66 context.prec = 70
67 sqrt5 = Decimal(5).sqrt()Whole script generators/analytic/reviewed_reference_corrections.py
Kaplan-Meier life estimation with a tied failure and censoring at 90%
Case STAT-SURV-NP-003 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package: survreg, survfit, predict.survreg
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley; Kalbfleisch and Prentice (2002).
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_life_families.R · sha256 5e01f9659bbd2ca2
- Dataset
- reference_data/datasets/SURV_KM_B9.json
Settings compared
confidence_level= 0.9frequency= "freq"layout= "right_censored"start= "time"status= "status"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/counts/source_count | exact | 22 | 22 | 0.00E+2 | passed | |
/counts/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/zero_frequency_rows | exact | 0 | 0 | 0.00E+2 | passed | |
/counts/rows_used | exact | 22 | 22 | 0.00E+2 | passed | |
/counts/exact | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/counts/right | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/counts/left | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/counts/interval | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/0/time | tolerance | 28.5 | 28.5 | 0.00E+1 | passed | |
/estimate/kaplan_meier/0/at_risk | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/0/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/0/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/0/survival | tolerance | 0.95999999999999996 | 0.96 | 4.47E-18 | 17 | passed |
/estimate/kaplan_meier/0/lower | tolerance | 0.80937546773028068 | 0.8093754677302806 | 1.07E-16 | 15 | passed |
/estimate/kaplan_meier/0/upper | tolerance | 0.99215155000518418 | 0.9921515500051842 | 3.96E-19 | 18 | passed |
/estimate/kaplan_meier/1/time | tolerance | 31.5 | 31.5 | 0.00E+1 | passed | |
/estimate/kaplan_meier/1/at_risk | tolerance | 24 | 24.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/1/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/1/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/1/survival | tolerance | 0.92000000000000004 | 0.92 | 3.20E-20 | 19 | passed |
/estimate/kaplan_meier/1/lower | tolerance | 0.76575417430470938 | 0.7657541743047093 | 1.13E-16 | 15 | passed |
/estimate/kaplan_meier/1/upper | tolerance | 0.97428673228239393 | 0.9742867322823939 | 2.27E-19 | 18 | passed |
/estimate/kaplan_meier/2/time | tolerance | 50.200000000000003 | 50.2 | 1.58E-16 | 17 | passed |
/estimate/kaplan_meier/2/at_risk | tolerance | 23 | 23.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/2/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/2/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/2/survival | tolerance | 0.88000000000000012 | 0.8800000000000001 | 4.54E-18 | 17 | passed |
/estimate/kaplan_meier/2/lower | tolerance | 0.71846355822860053 | 0.7184635582286005 | 4.68E-19 | 18 | passed |
/estimate/kaplan_meier/2/upper | tolerance | 0.95177805185495934 | 0.9517780518549593 | 6.27E-19 | 18 | passed |
/estimate/kaplan_meier/3/time | tolerance | 51.600000000000001 | 51.6 | 4.21E-16 | 17 | passed |
/estimate/kaplan_meier/3/at_risk | tolerance | 22 | 22.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/3/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/3/censored | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/3/survival | tolerance | 0.84000000000000019 | 0.8400000000000002 | 9.58E-19 | 17 | passed |
/estimate/kaplan_meier/3/lower | tolerance | 0.67216935048843895 | 0.6721693504884388 | 1.06E-16 | 15 | passed |
/estimate/kaplan_meier/3/upper | tolerance | 0.92632991198581038 | 0.9263299119858104 | 3.61E-18 | 17 | passed |
/estimate/kaplan_meier/4/time | tolerance | 57.100000000000001 | 57.1 | 4.21E-16 | 17 | passed |
/estimate/kaplan_meier/4/at_risk | tolerance | 19 | 19.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/4/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/4/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/4/survival | tolerance | 0.79578947368421071 | 0.7957894736842107 | 3.07E-18 | 17 | passed |
/estimate/kaplan_meier/4/lower | tolerance | 0.61973474036445819 | 0.6197347403644581 | 1.09E-16 | 15 | passed |
/estimate/kaplan_meier/4/upper | tolerance | 0.89668651066449412 | 0.8966865106644941 | 1.43E-18 | 17 | passed |
/estimate/kaplan_meier/5/time | tolerance | 73.799999999999997 | 73.8 | 1.58E-16 | 17 | passed |
/estimate/kaplan_meier/5/at_risk | tolerance | 16 | 16.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/5/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/5/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/5/survival | tolerance | 0.74605263157894752 | 0.7460526315789475 | 2.68E-18 | 17 | passed |
/estimate/kaplan_meier/5/lower | tolerance | 0.56055873078075336 | 0.5605587307807532 | 1.15E-16 | 15 | passed |
/estimate/kaplan_meier/5/upper | tolerance | 0.86219348834121856 | 0.8621934883412187 | 1.12E-16 | 15 | passed |
/estimate/kaplan_meier/6/time | tolerance | 77.599999999999994 | 77.6 | 3.16E-16 | 17 | passed |
/estimate/kaplan_meier/6/at_risk | tolerance | 15 | 15.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/6/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/6/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/6/survival | tolerance | 0.69631578947368433 | 0.6963157894736843 | 2.30E-18 | 17 | passed |
/estimate/kaplan_meier/6/lower | tolerance | 0.50539436712940022 | 0.5053943671294001 | 1.07E-16 | 15 | passed |
/estimate/kaplan_meier/6/upper | tolerance | 0.8253246043759892 | 0.8253246043759893 | 1.12E-16 | 15 | passed |
/estimate/kaplan_meier/7/time | tolerance | 83.400000000000006 | 83.4 | 3.16E-16 | 17 | passed |
/estimate/kaplan_meier/7/at_risk | tolerance | 14 | 14.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/7/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/7/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/7/survival | tolerance | 0.64657894736842114 | 0.6465789473684211 | 1.92E-18 | 17 | passed |
/estimate/kaplan_meier/7/lower | tolerance | 0.453213383369584 | 0.4532133833695839 | 1.11E-16 | 15 | passed |
/estimate/kaplan_meier/7/upper | tolerance | 0.78641501164954086 | 0.786415011649541 | 1.14E-16 | 15 | passed |
/estimate/kaplan_meier/8/time | tolerance | 97.700000000000003 | 97.7 | 1.58E-16 | 17 | passed |
/estimate/kaplan_meier/8/at_risk | tolerance | 13 | 13.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/8/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/8/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/8/survival | tolerance | 0.59684210526315806 | 0.5968421052631581 | 2.56E-18 | 17 | passed |
/estimate/kaplan_meier/8/lower | tolerance | 0.40347716815553275 | 0.40347716815553275 | 4.93E-19 | 17 | passed |
/estimate/kaplan_meier/8/upper | tolerance | 0.74567305257847716 | 0.7456730525784772 | 2.06E-18 | 17 | passed |
/estimate/kaplan_meier/9/time | tolerance | 116.5 | 116.5 | 0.00E+1 | passed | |
/estimate/kaplan_meier/9/at_risk | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/9/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/9/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/9/survival | tolerance | 0.54710526315789487 | 0.5471052631578949 | 2.17E-18 | 17 | passed |
/estimate/kaplan_meier/9/lower | tolerance | 0.35588409328629311 | 0.35588409328629306 | 5.27E-17 | 15 | passed |
/estimate/kaplan_meier/9/upper | tolerance | 0.70322723056313163 | 0.7032272305631317 | 1.14E-16 | 15 | passed |
/estimate/kaplan_meier/10/time | tolerance | 135.30000000000001 | 135.3 | 1.37E-15 | 16 | passed |
/estimate/kaplan_meier/10/at_risk | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/10/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/10/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/10/survival | tolerance | 0.49239473684210538 | 0.4923947368421054 | 4.96E-18 | 16 | passed |
/estimate/kaplan_meier/10/lower | tolerance | 0.30390347130804229 | 0.30390347130804224 | 5.10E-17 | 15 | passed |
/estimate/kaplan_meier/10/upper | tolerance | 0.65611118596381302 | 0.6561111859638131 | 1.06E-16 | 15 | passed |
/estimate/kaplan_meier/11/time | tolerance | 147.69999999999999 | 147.7 | 1.37E-15 | 17 | passed |
/estimate/kaplan_meier/11/at_risk | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/11/failures | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/11/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/11/survival | tolerance | 0.24619736842105269 | 0.2461973684210527 | 2.48E-18 | 16 | passed |
/estimate/kaplan_meier/11/lower | tolerance | 0.069550065260983174 | 0.06955006526098312 | 5.57E-17 | 15 | passed |
/estimate/kaplan_meier/11/upper | tolerance | 0.47856240836546388 | 0.478562408365464 | 1.07E-16 | 15 | passed |
/estimate/kaplan_meier/12/time | tolerance | 151.69999999999999 | 151.7 | 1.37E-15 | 17 | passed |
/estimate/kaplan_meier/12/at_risk | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/12/failures | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/12/censored | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/estimate/kaplan_meier/12/survival | tolerance | 0.12309868421052635 | 0.12309868421052635 | 3.76E-18 | 16 | passed |
/estimate/kaplan_meier/12/lower | tolerance | 0.014577597694140432 | 0.01457759769414042 | 1.21E-17 | 15 | passed |
/estimate/kaplan_meier/12/upper | tolerance | 0.35423657518439122 | 0.3542365751843913 | 5.80E-17 | 15 | passed |
Convention
- docs/manual/chapters/98-life-model-extensions.tex:44-51: Kaplan-Meier for exact and right-censored records; failures precede censorings at tied times; log-minus-log intervals are unavailable at survival 0 or 1.
- R: survfit(Surv(time, status) ~ 1, weights = freq, conf.type = 'log-log'); steps are compared at failure times only, as the engine reports them.
- Rows 3 and 9 share a time; the failure precedes the censoring in both implementations.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
329 km_case("STAT-SURV-NP-003", "Kaplan-Meier life estimation with a tied failure and censoring at 90%",
330 0.90, c(NP_NOTES, "Rows 3 and 9 share a time; the failure precedes the censoring in both implementations."), "axis_coverage")
Invalid survival request STAT-SURV-RELIABILITY-INVALID-001
Case STAT-SURV-RELIABILITY-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
event_column= "status"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The shared reliability executor requires an explicit menu mode.
- The declared request contract rejects this before statistical estimation.
Invalid survival request STAT-SURV-RELIABILITY-INVALID-002
Case STAT-SURV-RELIABILITY-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
mode= "unsupported"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The shared reliability executor supports only families, interval and accelerated modes.
- The declared request contract rejects this before statistical estimation.
Repairable-system MCF with a constant-rate HPP overlay
Case STAT-SURV-REPAIR-001 · status: passed
Reference
- Evidence type
- R
- Source
- base R MCF and Poisson rate algebra
- Citation
- Turnbull (1976); Nelson (1988); Crow (1975); Meeker, Hahn and Escobar (1998); Therneau T (2024), A Package for Survival Analysis in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_repairable.R · sha256 1f118d2994e4269d
- Dataset
- reference_data/datasets/SURV_REPAIR_B9.json
Settings compared
confidence_level= 0.95evaluation_ages= [3, 6, 12]event_age_column= "age"event_unit_column= "unit"events_tab= "events"models= ["mcf", "hpp"]tab_column= "table"time_unit= "months"window_end_column= "end"window_entry_column= "start"window_unit_column= "unit"windows_tab= "windows"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/unit_count | exact | 5 | 5 | 0.00E+2 | passed | |
/zero_event_unit_count | exact | 1 | 1 | 0.00E+2 | passed | |
/event_count | exact | 12 | 12 | 0.00E+2 | passed | |
/distinct_event_age_count | exact | 10 | 10 | 0.00E+2 | passed | |
/total_exposure | tolerance | 58 | 58.0 | 0.00E+2 | passed | |
/earliest_entry | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/latest_end | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/event_source_count | exact | 12 | 12 | 0.00E+2 | passed | |
/event_excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/window_source_count | exact | 5 | 5 | 0.00E+2 | passed | |
/window_excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/0/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/0/age | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/mcf_steps/0/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/0/at_risk | exact | 4 | 4 | 0.00E+2 | passed | |
/mcf_steps/0/increment | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/mcf_steps/0/mcf | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/mcf_steps/0/variance | tolerance | 0.05859375 | 0.05859375 | 0.00E-6 | passed | |
/mcf_steps/0/standard_error | tolerance | 0.24206145913796356 | 0.24206145913796356 | 3.84E-18 | 16 | passed |
/mcf_steps/0/lower | tolerance | 0.037477245046510059 | 0.037477245046510045 | 1.39E-17 | 15 | passed |
/mcf_steps/0/upper | tolerance | 1.6676786119800473 | 1.667678611980048 | 6.65E-16 | 15 | passed |
/mcf_steps/1/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/1/age | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/mcf_steps/1/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/1/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/1/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/1/mcf | tolerance | 0.45000000000000001 | 0.45 | 1.10E-18 | 17 | passed |
/mcf_steps/1/variance | tolerance | 0.067343749999999994 | 0.06734375 | 1.06E-19 | 17 | passed |
/mcf_steps/1/standard_error | tolerance | 0.25950674365033366 | 0.25950674365033366 | 2.15E-20 | 19 | passed |
/mcf_steps/1/lower | tolerance | 0.14532495634751097 | 0.14532495634751094 | 2.82E-17 | 15 | passed |
/mcf_steps/1/upper | tolerance | 1.3934289408335907 | 1.3934289408335907 | 1.23E-18 | 18 | passed |
/mcf_steps/2/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/2/age | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/mcf_steps/2/events | exact | 2 | 2 | 0.00E+2 | passed | |
/mcf_steps/2/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/2/increment | tolerance | 0.40000000000000002 | 0.4 | 2.20E-18 | 17 | passed |
/mcf_steps/2/mcf | tolerance | 0.85000000000000009 | 0.8500000000000001 | 1.18E-18 | 17 | passed |
/mcf_steps/2/variance | tolerance | 0.37484375000000003 | 0.37484375000000003 | 1.09E-18 | 17 | passed |
/mcf_steps/2/standard_error | tolerance | 0.61224484481292285 | 0.6122448448129229 | 4.30E-19 | 18 | passed |
/mcf_steps/2/lower | tolerance | 0.20716129808952041 | 0.20716129808952027 | 1.36E-16 | 15 | passed |
/mcf_steps/2/upper | tolerance | 3.4876205481575377 | 3.48762054815754 | 2.27E-15 | 15 | passed |
/mcf_steps/3/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/3/age | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/mcf_steps/3/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/3/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/3/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/3/mcf | tolerance | 1.05 | 1.05 | 4.44E-17 | 16 | passed |
/mcf_steps/3/variance | tolerance | 0.35484375000000007 | 0.35484375 | 5.67E-17 | 15 | passed |
/mcf_steps/3/standard_error | tolerance | 0.59568762787219287 | 0.5956876278721928 | 1.10E-16 | 15 | passed |
/mcf_steps/3/lower | tolerance | 0.34536976883783344 | 0.34536976883783344 | 4.83E-18 | 16 | passed |
/mcf_steps/3/upper | tolerance | 3.1922307609896023 | 3.1922307609896023 | 4.50E-17 | 16 | passed |
/mcf_steps/4/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/4/age | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/mcf_steps/4/events | exact | 2 | 2 | 0.00E+2 | passed | |
/mcf_steps/4/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/4/increment | tolerance | 0.40000000000000002 | 0.4 | 2.20E-18 | 17 | passed |
/mcf_steps/4/mcf | tolerance | 1.4500000000000002 | 1.4500000000000002 | 2.24E-17 | 16 | passed |
/mcf_steps/4/variance | tolerance | 0.29234375000000001 | 0.29234375 | 3.32E-18 | 16 | passed |
/mcf_steps/4/standard_error | tolerance | 0.5406882188470542 | 0.5406882188470542 | 2.78E-18 | 17 | passed |
/mcf_steps/4/lower | tolerance | 0.69817581056883804 | 0.6981758105688379 | 1.11E-16 | 15 | passed |
/mcf_steps/4/upper | tolerance | 3.0114191413864519 | 3.011419141386453 | 9.36E-16 | 15 | passed |
/mcf_steps/5/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/5/age | tolerance | 6.5 | 6.5 | 0.00E+1 | passed | |
/mcf_steps/5/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/5/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/5/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/5/mcf | tolerance | 1.6500000000000001 | 1.6500000000000001 | 3.32E-17 | 16 | passed |
/mcf_steps/5/variance | tolerance | 0.38109375000000001 | 0.38109375 | 1.12E-18 | 17 | passed |
/mcf_steps/5/standard_error | tolerance | 0.61732791124328734 | 0.6173279112432873 | 1.67E-18 | 17 | passed |
/mcf_steps/5/lower | tolerance | 0.79253233859734729 | 0.7925323385973471 | 2.26E-16 | 15 | passed |
/mcf_steps/5/upper | tolerance | 3.4351910545611051 | 3.435191054561106 | 8.61E-16 | 15 | passed |
/mcf_steps/6/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/6/age | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/mcf_steps/6/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/6/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/6/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/6/mcf | tolerance | 1.8500000000000001 | 1.85 | 1.12E-17 | 17 | passed |
/mcf_steps/6/variance | tolerance | 0.34984375000000006 | 0.34984375 | 5.11E-17 | 15 | passed |
/mcf_steps/6/standard_error | tolerance | 0.59147590821604901 | 0.591475908216049 | 3.32E-18 | 17 | passed |
/mcf_steps/6/lower | tolerance | 0.98861768220029711 | 0.9886176822002969 | 2.22E-16 | 15 | passed |
/mcf_steps/6/upper | tolerance | 3.461904497179114 | 3.4619044971791144 | 4.15E-16 | 15 | passed |
/mcf_steps/7/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/7/age | tolerance | 9.5 | 9.5 | 0.00E+1 | passed | |
/mcf_steps/7/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/7/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/7/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/7/mcf | tolerance | 2.0500000000000003 | 2.0500000000000003 | 3.35E-17 | 16 | passed |
/mcf_steps/7/variance | tolerance | 0.52359375000000008 | 0.52359375 | 1.11E-16 | 15 | passed |
/mcf_steps/7/standard_error | tolerance | 0.72359778192031521 | 0.7235977819203152 | 1.62E-18 | 17 | passed |
/mcf_steps/7/lower | tolerance | 1.0263639708614596 | 1.0263639708614596 | 1.53E-17 | 16 | passed |
/mcf_steps/7/upper | tolerance | 4.0945513670678739 | 4.094551367067874 | 2.60E-17 | 17 | passed |
/mcf_steps/8/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/8/age | tolerance | 10.5 | 10.5 | 0.00E+1 | passed | |
/mcf_steps/8/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/8/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/8/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/8/mcf | tolerance | 2.2500000000000004 | 2.2500000000000004 | 4.41E-17 | 16 | passed |
/mcf_steps/8/variance | tolerance | 0.48359375000000004 | 0.48359375000000004 | 4.41E-18 | 17 | passed |
/mcf_steps/8/standard_error | tolerance | 0.69540905228505623 | 0.6954090522850562 | 1.63E-18 | 17 | passed |
/mcf_steps/8/lower | tolerance | 1.2277249165740776 | 1.2277249165740773 | 2.59E-16 | 15 | passed |
/mcf_steps/8/upper | tolerance | 4.1234807013013359 | 4.123480701301337 | 9.15E-16 | 15 | passed |
/mcf_steps/9/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/9/age | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/mcf_steps/9/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/9/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/9/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/9/mcf | tolerance | 2.4500000000000006 | 2.4500000000000006 | 2.17E-17 | 17 | passed |
/mcf_steps/9/variance | tolerance | 0.59234375000000006 | 0.59234375 | 1.13E-16 | 15 | passed |
/mcf_steps/9/standard_error | tolerance | 0.76963871394310723 | 0.7696387139431071 | 1.08E-16 | 15 | passed |
/mcf_steps/9/lower | tolerance | 1.3236437724013337 | 1.3236437724013337 | 1.53E-17 | 16 | passed |
/mcf_steps/9/upper | tolerance | 4.5348303865097801 | 4.53483038650978 | 2.02E-18 | 18 | passed |
/mcf_evaluations/0/age | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/mcf_evaluations/0/mcf | tolerance | 0.45000000000000001 | 0.45 | 1.10E-18 | 17 | passed |
/mcf_evaluations/0/standard_error | tolerance | 0.25950674365033366 | 0.25950674365033366 | 2.15E-20 | 19 | passed |
/mcf_evaluations/0/lower | tolerance | 0.14532495634751097 | 0.14532495634751094 | 2.82E-17 | 15 | passed |
/mcf_evaluations/0/upper | tolerance | 1.3934289408335907 | 1.3934289408335907 | 1.23E-18 | 18 | passed |
/mcf_evaluations/1/age | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/mcf_evaluations/1/mcf | tolerance | 1.4500000000000002 | 1.4500000000000002 | 2.24E-17 | 16 | passed |
/mcf_evaluations/1/standard_error | tolerance | 0.5406882188470542 | 0.5406882188470542 | 2.78E-18 | 17 | passed |
/mcf_evaluations/1/lower | tolerance | 0.69817581056883804 | 0.6981758105688379 | 1.11E-16 | 15 | passed |
/mcf_evaluations/1/upper | tolerance | 3.0114191413864519 | 3.011419141386453 | 9.36E-16 | 15 | passed |
/mcf_evaluations/2/age | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/mcf_evaluations/2/mcf | tolerance | 2.4500000000000006 | 2.4500000000000006 | 2.17E-17 | 17 | passed |
/mcf_evaluations/2/standard_error | tolerance | 0.76963871394310723 | 0.7696387139431071 | 1.08E-16 | 15 | passed |
/mcf_evaluations/2/lower | tolerance | 1.3236437724013337 | 1.3236437724013337 | 1.53E-17 | 16 | passed |
/mcf_evaluations/2/upper | tolerance | 4.5348303865097801 | 4.53483038650978 | 2.02E-18 | 18 | passed |
/hpp/rate | tolerance | 0.20689655172413793 | 0.20689655172413793 | 1.84E-18 | 17 | passed |
/hpp/rate_lower | tolerance | 0.10690646739176236 | 0.1069064673917624 | 4.53E-17 | 15 | passed |
/hpp/rate_upper | tolerance | 0.36140663876167162 | 0.36140663876167173 | 1.08E-16 | 15 | passed |
/hpp/events | exact | 12 | 12 | 0.00E+2 | passed | |
/hpp/exposure | tolerance | 58 | 58.0 | 0.00E+2 | passed | |
/hpp/log_likelihood | tolerance | -30.906436329101027 | -30.906436329101027 | 3.28E-16 | 16 | passed |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:13-23: M(t) = sum dN(u) / Y(u) over units at risk entry < u <= end; the robust variance aggregates psi_i = sum [dN_i - Y_i dN / Y] / Y over independent units with the G/(G-1) factor; log-scale pointwise intervals.
- Reference: an independent base-R implementation of those formulas. HPP limits are the exact central Poisson (Garwood) interval chi2(2N) / (2 exposure).
- The events and windows share one dataset split by the tab column; the binding passes both frames to the engine as the desktop service does.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
177 emit("STAT-SURV-REPAIR-001", "Repairable-system MCF with a constant-rate HPP overlay",
178 REPAIR, "repairableMenuItem", REPAIR_REQ, "SURV_REPAIR_B9",
179 c(REPAIR_TABS, REPAIR_BASE,
180 list(models = list("mcf", "hpp"), evaluation_ages = list(3, 6, 12),
181 confidence_level = 0.95)),
182 c(list("/unit_count" = exact(5, "units"),
183 "/zero_event_unit_count" = exact(1, "u5 has no events"),
184 "/event_count" = exact(nrow(rp_events), "events"),
185 "/distinct_event_age_count" = exact(length(mref95$steps), "distinct event ages"),
186 "/total_exposure" = tol(sum(rp_windows$end - rp_windows$start), "exposure"),
187 "/earliest_entry" = tol(min(rp_windows$start), "earliest entry"),
188 "/latest_end" = tol(max(rp_windows$end), "latest end"),
189 "/event_source_count" = exact(nrow(rp_events), "source events"),
190 "/event_excluded_count" = exact(0, "none excluded"),
191 "/window_source_count" = exact(5, "source windows"),
192 "/window_excluded_count" = exact(0, "none excluded")),
193 mcf_outputs(mref95, c(3, 6, 12), 0.95),
194 hpp_outputs(0.95)),
195 REPAIR_NOTES, "base R MCF and Poisson rate algebra")
Repairable-system MCF with a power-law NHPP fit and forecast
Case STAT-SURV-REPAIR-002 · status: passed
Reference
- Evidence type
- R
- Source
- base R Crow-AMSAA profile likelihood and MCF algebra
- Citation
- Turnbull (1976); Nelson (1988); Crow (1975); Meeker, Hahn and Escobar (1998); Therneau T (2024), A Package for Survival Analysis in R.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_repairable.R · sha256 1f118d2994e4269d
- Dataset
- reference_data/datasets/SURV_REPAIR_B9.json
Settings compared
confidence_level= 0.9evaluation_ages= [4, 8]event_age_column= "age"event_unit_column= "unit"events_tab= "events"forecast_horizon= 2models= ["mcf", "power_law"]tab_column= "table"time_unit= "months"window_end_column= "end"window_entry_column= "start"window_unit_column= "unit"windows_tab= "windows"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/unit_count | exact | 5 | 5 | 0.00E+2 | passed | |
/event_count | exact | 12 | 12 | 0.00E+2 | passed | |
/mcf_steps/0/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/0/age | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/mcf_steps/0/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/0/at_risk | exact | 4 | 4 | 0.00E+2 | passed | |
/mcf_steps/0/increment | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/mcf_steps/0/mcf | tolerance | 0.25 | 0.25 | 0.00E+0 | passed | |
/mcf_steps/0/variance | tolerance | 0.05859375 | 0.05859375 | 0.00E-6 | passed | |
/mcf_steps/0/standard_error | tolerance | 0.24206145913796356 | 0.24206145913796356 | 3.84E-18 | 16 | passed |
/mcf_steps/0/lower | tolerance | 0.050847870412763986 | 0.05084787041276395 | 3.46E-17 | 15 | passed |
/mcf_steps/0/upper | tolerance | 1.2291566882280101 | 1.229156688228011 | 8.41E-16 | 15 | passed |
/mcf_steps/1/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/1/age | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/mcf_steps/1/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/1/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/1/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/1/mcf | tolerance | 0.45000000000000001 | 0.45 | 1.10E-18 | 17 | passed |
/mcf_steps/1/variance | tolerance | 0.067343749999999994 | 0.06734375 | 1.06E-19 | 17 | passed |
/mcf_steps/1/standard_error | tolerance | 0.25950674365033366 | 0.25950674365033366 | 2.15E-20 | 19 | passed |
/mcf_steps/1/lower | tolerance | 0.17428478818421989 | 0.17428478818421977 | 1.16E-16 | 15 | passed |
/mcf_steps/1/upper | tolerance | 1.1618914198407064 | 1.161891419840707 | 6.96E-16 | 15 | passed |
/mcf_steps/2/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/2/age | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/mcf_steps/2/events | exact | 2 | 2 | 0.00E+2 | passed | |
/mcf_steps/2/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/2/increment | tolerance | 0.40000000000000002 | 0.4 | 2.20E-18 | 17 | passed |
/mcf_steps/2/mcf | tolerance | 0.85000000000000009 | 0.8500000000000001 | 1.18E-18 | 17 | passed |
/mcf_steps/2/variance | tolerance | 0.37484375000000003 | 0.37484375000000003 | 1.09E-18 | 17 | passed |
/mcf_steps/2/standard_error | tolerance | 0.61224484481292285 | 0.6122448448129229 | 4.30E-19 | 18 | passed |
/mcf_steps/2/lower | tolerance | 0.25994444458643134 | 0.25994444458643123 | 1.06E-16 | 15 | passed |
/mcf_steps/2/upper | tolerance | 2.7794400497748257 | 2.779440049774827 | 1.36E-15 | 15 | passed |
/mcf_steps/3/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/3/age | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/mcf_steps/3/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/3/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/3/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/3/mcf | tolerance | 1.05 | 1.05 | 4.44E-17 | 16 | passed |
/mcf_steps/3/variance | tolerance | 0.35484375000000007 | 0.35484375 | 5.67E-17 | 15 | passed |
/mcf_steps/3/standard_error | tolerance | 0.59568762787219287 | 0.5956876278721928 | 1.10E-16 | 15 | passed |
/mcf_steps/3/lower | tolerance | 0.41297395722378311 | 0.41297395722378305 | 5.97E-17 | 15 | passed |
/mcf_steps/3/upper | tolerance | 2.6696598676864638 | 2.6696598676864642 | 4.39E-16 | 15 | passed |
/mcf_steps/4/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/4/age | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/mcf_steps/4/events | exact | 2 | 2 | 0.00E+2 | passed | |
/mcf_steps/4/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/4/increment | tolerance | 0.40000000000000002 | 0.4 | 2.20E-18 | 17 | passed |
/mcf_steps/4/mcf | tolerance | 1.4500000000000002 | 1.4500000000000002 | 2.24E-17 | 16 | passed |
/mcf_steps/4/variance | tolerance | 0.29234375000000001 | 0.29234375 | 3.32E-18 | 16 | passed |
/mcf_steps/4/standard_error | tolerance | 0.5406882188470542 | 0.5406882188470542 | 2.78E-18 | 17 | passed |
/mcf_steps/4/lower | tolerance | 0.78522629816781608 | 0.785226298167816 | 1.07E-16 | 15 | passed |
/mcf_steps/4/upper | tolerance | 2.6775720641371854 | 2.6775720641371863 | 8.92E-16 | 15 | passed |
/mcf_steps/5/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/5/age | tolerance | 6.5 | 6.5 | 0.00E+1 | passed | |
/mcf_steps/5/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/5/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/5/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/5/mcf | tolerance | 1.6500000000000001 | 1.6500000000000001 | 3.32E-17 | 16 | passed |
/mcf_steps/5/variance | tolerance | 0.38109375000000001 | 0.38109375 | 1.12E-18 | 17 | passed |
/mcf_steps/5/standard_error | tolerance | 0.61732791124328734 | 0.6173279112432873 | 1.67E-18 | 17 | passed |
/mcf_steps/5/lower | tolerance | 0.89169853483913075 | 0.8916985348391305 | 2.20E-16 | 15 | passed |
/mcf_steps/5/upper | tolerance | 3.0531619080109405 | 3.053161908010941 | 3.95E-16 | 15 | passed |
/mcf_steps/6/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/6/age | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/mcf_steps/6/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/6/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/6/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/6/mcf | tolerance | 1.8500000000000001 | 1.85 | 1.12E-17 | 17 | passed |
/mcf_steps/6/variance | tolerance | 0.34984375000000006 | 0.34984375 | 5.11E-17 | 15 | passed |
/mcf_steps/6/standard_error | tolerance | 0.59147590821604901 | 0.591475908216049 | 3.32E-18 | 17 | passed |
/mcf_steps/6/lower | tolerance | 1.0934069390325363 | 1.093406939032536 | 2.48E-16 | 15 | passed |
/mcf_steps/6/upper | tolerance | 3.1301246387079655 | 3.130124638707966 | 4.78E-16 | 15 | passed |
/mcf_steps/7/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/7/age | tolerance | 9.5 | 9.5 | 0.00E+1 | passed | |
/mcf_steps/7/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/7/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/7/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/7/mcf | tolerance | 2.0500000000000003 | 2.0500000000000003 | 3.35E-17 | 16 | passed |
/mcf_steps/7/variance | tolerance | 0.52359375000000008 | 0.52359375 | 1.11E-16 | 15 | passed |
/mcf_steps/7/standard_error | tolerance | 0.72359778192031521 | 0.7235977819203152 | 1.62E-18 | 17 | passed |
/mcf_steps/7/lower | tolerance | 1.1471130112021763 | 1.1471130112021761 | 1.75E-16 | 15 | passed |
/mcf_steps/7/upper | tolerance | 3.6635448808969344 | 3.6635448808969353 | 9.07E-16 | 15 | passed |
/mcf_steps/8/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/8/age | tolerance | 10.5 | 10.5 | 0.00E+1 | passed | |
/mcf_steps/8/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/8/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/8/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/8/mcf | tolerance | 2.2500000000000004 | 2.2500000000000004 | 4.41E-17 | 16 | passed |
/mcf_steps/8/variance | tolerance | 0.48359375000000004 | 0.48359375000000004 | 4.41E-18 | 17 | passed |
/mcf_steps/8/standard_error | tolerance | 0.69540905228505623 | 0.6954090522850562 | 1.63E-18 | 17 | passed |
/mcf_steps/8/lower | tolerance | 1.3533109845671913 | 1.3533109845671911 | 1.78E-16 | 15 | passed |
/mcf_steps/8/upper | tolerance | 3.740825322288404 | 3.7408253222884054 | 1.36E-15 | 15 | passed |
/mcf_steps/9/segment | exact | 0 | 0 | 0.00E+2 | passed | |
/mcf_steps/9/age | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/mcf_steps/9/events | exact | 1 | 1 | 0.00E+2 | passed | |
/mcf_steps/9/at_risk | exact | 5 | 5 | 0.00E+2 | passed | |
/mcf_steps/9/increment | tolerance | 0.20000000000000001 | 0.2 | 1.10E-18 | 17 | passed |
/mcf_steps/9/mcf | tolerance | 2.4500000000000006 | 2.4500000000000006 | 2.17E-17 | 17 | passed |
/mcf_steps/9/variance | tolerance | 0.59234375000000006 | 0.59234375 | 1.13E-16 | 15 | passed |
/mcf_steps/9/standard_error | tolerance | 0.76963871394310723 | 0.7696387139431071 | 1.08E-16 | 15 | passed |
/mcf_steps/9/lower | tolerance | 1.461373261500005 | 1.4613732615000048 | 2.06E-16 | 15 | passed |
/mcf_steps/9/upper | tolerance | 4.1074379545160316 | 4.107437954516032 | 8.41E-16 | 15 | passed |
/mcf_evaluations/0/age | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/mcf_evaluations/0/mcf | tolerance | 0.85000000000000009 | 0.8500000000000001 | 1.18E-18 | 17 | passed |
/mcf_evaluations/0/standard_error | tolerance | 0.61224484481292285 | 0.6122448448129229 | 4.30E-19 | 18 | passed |
/mcf_evaluations/0/lower | tolerance | 0.25994444458643134 | 0.25994444458643123 | 1.06E-16 | 15 | passed |
/mcf_evaluations/0/upper | tolerance | 2.7794400497748257 | 2.779440049774827 | 1.36E-15 | 15 | passed |
/mcf_evaluations/1/age | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/mcf_evaluations/1/mcf | tolerance | 1.8500000000000001 | 1.85 | 1.12E-17 | 17 | passed |
/mcf_evaluations/1/standard_error | tolerance | 0.59147590821604901 | 0.591475908216049 | 3.32E-18 | 17 | passed |
/mcf_evaluations/1/lower | tolerance | 1.0934069390325363 | 1.093406939032536 | 2.48E-16 | 15 | passed |
/mcf_evaluations/1/upper | tolerance | 3.1301246387079655 | 3.130124638707966 | 4.78E-16 | 15 | passed |
/power_law/log_scale | tolerance | -2.0074001125122911 | -2.007400112228633 | 2.84E-10 | 9 | passed |
/power_law/shape | tolerance | 1.1701643635347574 | 1.1701643634226417 | 1.12E-10 | 10 | passed |
/power_law/log_likelihood | tolerance | -30.781818147938132 | -30.78181814793814 | 7.42E-15 | 15 | passed |
/power_law/log_scale_standard_error | tolerance | 0.9525208263140833 | 0.9525207960285048 | 3.03E-8 | 7 | passed |
/power_law/log_shape_standard_error | tolerance | 0.30660451748134354 | 0.30660450887101637 | 8.61E-9 | 7 | passed |
/power_law/covariance_log_scale_log_shape/0/0 | tolerance | 0.90729592456206398 | 0.9072958668667764 | 5.77E-8 | 7 | passed |
/power_law/covariance_log_scale_log_shape/0/1 | tolerance | -0.27831223393582605 | -0.2783122160449378 | 1.79E-8 | 7 | passed |
/power_law/covariance_log_scale_log_shape/1/1 | tolerance | 0.094006330139967509 | 0.09400632486003715 | 5.28E-9 | 7 | passed |
/power_law/shape_profile_lower | tolerance | 0.67500317390370101 | 0.6750031739034917 | 2.09E-13 | 12 | passed |
/power_law/shape_profile_upper | tolerance | 1.8602321095770702 | 1.8602321095770697 | 4.52E-16 | 15 | passed |
/power_law/lrt_statistic | tolerance | 0.24923636232578872 | 0.24923636232577806 | 1.07E-14 | 13 | passed |
/power_law/lrt_p_value | tail_probability | 0.61761329215330196 | 0.6176132921533093 | 7.33E-15 | 13 | passed |
/power_law/expected_counts/0/estimate | tolerance | 0.68030921667874156 | 0.6803092167659793 | 8.72E-11 | 9 | passed |
/power_law/expected_counts/0/lower | tolerance | 0.29805927309801872 | 0.2980592796879606 | 6.59E-9 | 7 | passed |
/power_law/expected_counts/0/upper | tolerance | 1.5527805106933923 | 1.5527804767604247 | 3.39E-8 | 7 | passed |
/power_law/expected_counts/1/estimate | tolerance | 0.41304798730802178 | 0.41304798731128517 | 3.26E-12 | 11 | passed |
/power_law/expected_counts/1/lower | tolerance | 0.25644596045091139 | 0.2564459593067388 | 1.14E-9 | 8 | passed |
/power_law/expected_counts/1/upper | tolerance | 0.66528105772937474 | 0.6652810607081396 | 2.98E-9 | 8 | passed |
/power_law/expected_counts/2/estimate | tolerance | 1.5309497211622625 | 1.5309497212396062 | 7.73E-11 | 10 | passed |
/power_law/expected_counts/2/lower | tolerance | 0.88840219526873299 | 0.8884021993119801 | 4.04E-9 | 8 | passed |
/power_law/expected_counts/2/upper | tolerance | 2.6382274393388125 | 2.6382274275984243 | 1.17E-8 | 8 | passed |
/power_law/expected_counts/3/estimate | tolerance | 0.45679940724185553 | 0.45679940721520457 | 2.67E-11 | 10 | passed |
/power_law/expected_counts/3/lower | tolerance | 0.25950000594553552 | 0.2595000042681238 | 1.68E-9 | 8 | passed |
/power_law/expected_counts/3/upper | tolerance | 0.8041067193667264 | 0.8041067244706559 | 5.10E-9 | 8 | passed |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:13-23: M(t) = sum dN(u) / Y(u) over units at risk entry < u <= end; the robust variance aggregates psi_i = sum [dN_i - Y_i dN / Y] / Y over independent units with the G/(G-1) factor; log-scale pointwise intervals.
- Reference: an independent base-R implementation of those formulas. HPP limits are the exact central Poisson (Garwood) interval chi2(2N) / (2 exposure).
- The events and windows share one dataset split by the tab column; the binding passes both frames to the engine as the desktop service does.
- docs/manual/chapters/96-repairable-degradation-warranty.tex:34-41: Lambda(t) = e^a t^b fitted by profile maximum likelihood (a = log(N / S(b)), S(b) = sum (end^b - entry^b)); profile-likelihood interval for b with cutoff chi2_1(level)/2; likelihood-ratio test of b = 1.
- Iterative searches (optimize, uniroot to 1e-12) and numeric second derivatives with step 1e-4: outputs allow 1e-7 absolute or 1e-6 relative.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
299 emit("STAT-SURV-REPAIR-002", "Repairable-system MCF with a power-law NHPP fit and forecast",
300 REPAIR, "repairableMenuItem", REPAIR_REQ, "SURV_REPAIR_B9",
301 c(REPAIR_TABS, REPAIR_BASE,
302 list(models = list("mcf", "power_law"), evaluation_ages = list(4, 8),
303 forecast_horizon = 2, confidence_level = 0.90)),
304 c(list("/unit_count" = exact(5, "units"),
305 "/event_count" = exact(nrow(rp_events), "events")),
306 mcf_outputs(mref90, c(4, 8), 0.90),
307 power_outputs),
308 c(REPAIR_NOTES,
309 paste0(MANUAL, ":34-41: Lambda(t) = e^a t^b fitted by profile maximum likelihood (a = log(N / S(b)), S(b) = sum (end^b - entry^b)); profile-likelihood interval for b with cutoff chi2_1(level)/2; likelihood-ratio test of b = 1."),
310 "Iterative searches (optimize, uniroot to 1e-12) and numeric second derivatives with step 1e-4: outputs allow 1e-7 absolute or 1e-6 relative."),
311 "base R Crow-AMSAA profile likelihood and MCF algebra")
Survival STAT-SURV-RISK-001
Case STAT-SURV-RISK-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/survdiff/coxph and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, MASS 7.3.65, jsonlite 2.0.0
- Reference script
- generators/r/survival_core.R · sha256 1ed8945e6864eb84
- Dataset
- reference_data/datasets/HARVEST_GEHAN_MP.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"times= [6, 7, 10, 23]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | exact | 21 | 21 | 0.00E+2 | passed | |
/1 | exact | 17 | 17 | 0.00E+2 | passed | |
/2 | exact | 15 | 15 | 0.00E+2 | passed | |
/3 | exact | 6 | 6 | 0.00E+2 | passed |
Convention
- number_at_risk is an in-process payload step after an engine survival fit; ties remain at risk at t.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
38 ticks <- c(6,7,10,23)
39 risk <- vapply(ticks,function(t) sum(mp$time>=t),0L)
40 emit("STAT-SURV-RISK-001","tabelz.analysis.survival_nonparametric:number_at_risk",
41 "survivalMenuItem","HARVEST_GEHAN_MP",c(config,list(times=as.list(ticks))),
42 list("/0"=exact(risk[1],"At risk at time 6"),
43 "/1"=exact(risk[2],"At risk at time 7"),
44 "/2"=exact(risk[3],"At risk at time 10"),
45 "/3"=exact(risk[4],"At risk at time 23")),
46 c("number_at_risk is an in-process payload step after an engine survival fit; ties remain at risk at t."))
Survival boundary STAT-SURV-RISK-ALL-CENS-001
Case STAT-SURV-RISK-ALL-CENS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival and analytic boundary
- Citation
- R survival::survfit/coxph/survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_boundaries.R · sha256 528007972452fb15
- Dataset
- reference_data/datasets/SURV_ALL_CENS.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"times= [1, 5, 6]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | exact | 5 | 5 | 0.00E+2 | passed | |
/1 | exact | 1 | 1 | 0.00E+2 | passed | |
/2 | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- Number at risk counts censoring rows through their recorded time.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
60 emit("STAT-SURV-RISK-ALL-CENS-001","tabelz.analysis.survival_nonparametric:number_at_risk",
61 "survivalMenuItem","SURV_ALL_CENS",c(cfg,list(times=list(1,5,6))),
62 list("/0"=exact(5L,"Five at risk at first time"),
63 "/1"=exact(1L,"One censored row still observed at last time"),
64 "/2"=exact(0L,"None beyond last time")),
65 c("Number at risk counts censoring rows through their recorded time."))
Hard-numeric survival STAT-SURV-RISK-HARD-001
Case STAT-SURV-RISK-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_hard.R · sha256 bc20ccd17540f4e7
- Dataset
- reference_data/datasets/SURV_HARD.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"times= [1000137, 1001370, 1005500]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | exact | 40 | 40 | 0.00E+2 | passed | |
/1 | exact | 31 | 31 | 0.00E+2 | passed | |
/2 | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- At-risk comparisons use exact stored double times, not rounded display labels.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
55 ticks <- c(1e6+137,1e6+1370,1e6+5500)
56 risk <- vapply(ticks,function(t) sum(d$time>=t),0L)
57 emit("STAT-SURV-RISK-HARD-001","tabelz.analysis.survival_nonparametric:number_at_risk",
58 "survivalMenuItem","SURV_HARD",c(cfg,list(times=as.list(ticks))),
59 list("/0"=exact(risk[1],"Risk at first large time"),
60 "/1"=exact(risk[2],"Risk at interior large time"),
61 "/2"=exact(risk[3],"Risk near largest time")),
62 c("At-risk comparisons use exact stored double times, not rounded display labels."))
Invalid survival request STAT-SURV-RISK-INVALID-001
Case STAT-SURV-RISK-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/HARVEST_GEHAN_MP.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The payload calculation requires explicit requested times.
- The declared request contract rejects this before statistical estimation.
Invalid survival request STAT-SURV-RISK-INVALID-002
Case STAT-SURV-RISK-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/HARVEST_GEHAN_MP.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"times= "six"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Requested number-at-risk times must be numeric values in a list.
- The declared request contract rejects this before statistical estimation.
Small-sample survival boundary STAT-SURV-RISK-MIN-001
Case STAT-SURV-RISK-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::survfit/coxph and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_minimum.R · sha256 2997d37929a6dae8
- Dataset
- reference_data/datasets/SURV_MIN.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"times= [0, 1, 2]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | exact | 1 | 1 | 0.00E+2 | passed | |
/1 | exact | 1 | 1 | 0.00E+2 | passed | |
/2 | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- At-risk count includes a failure at the requested instant.
- R re-reads the exported CSV and drops excluded 0-based ordinals.
Reference code
The lines of the reference script that produce this case's expected values.
36 emit("STAT-SURV-RISK-MIN-001","tabelz.analysis.survival_nonparametric:number_at_risk",
37 "survivalMenuItem","SURV_MIN",1:4,c(cfg,list(times=list(0,1,2))),
38 list("/0"=exact(1L,"One row at risk before time 1"),
39 "/1"=exact(1L,"Event row is still at risk at time 1"),
40 "/2"=exact(0L,"No observation at or after time 2")),
41 c("At-risk count includes a failure at the requested instant."))
Survival population STAT-SURV-RISK-POP-001
Case STAT-SURV-RISK-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::Surv/survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_population.R · sha256 3b3b4629e272fcd9
- Dataset
- reference_data/datasets/SURV_POP.json
Settings compared
censored_value= "0"event_column= "status"event_value= "1"time_column= "time"times= [7, 10, 15, 20]
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0 | exact | 29 | 29 | 0.00E+2 | passed | |
/1 | exact | 23 | 23 | 0.00E+2 | passed | |
/2 | exact | 10 | 10 | 0.00E+2 | passed | |
/3 | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- Number at risk counts rows still observed at or beyond each query time.
- R re-reads the exported CSV and removes the declared ordinal before complete-case selection.
Reference code
The lines of the reference script that produce this case's expected values.
56 ticks <- c(7,10,15,20)
57 risk <- vapply(ticks,function(t) sum(kmdata$time>=t),0L)
58 emit("STAT-SURV-RISK-POP-001","tabelz.analysis.survival_nonparametric:number_at_risk",
59 "survivalMenuItem","SURV_POP",7L,c(cfg,list(times=as.list(ticks))),
60 list("/0"=exact(risk[1],"Risk at 7"),"/1"=exact(risk[2],"Risk at 10"),
61 "/2"=exact(risk[3],"Risk at 15"),"/3"=exact(risk[4],"Risk at 20")),
62 c("Number at risk counts rows still observed at or beyond each query time."))
Survival STAT-SURV-STABILITY-001
Case STAT-SURV-STABILITY-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/survdiff/coxph and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, MASS 7.3.65, jsonlite 2.0.0
- Reference script
- generators/r/survival_core.R · sha256 1ed8945e6864eb84
- Dataset
- reference_data/datasets/SURV_STABILITY.json
Settings compared
lsl= 95model_type= "pooled"response_column= "response"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/estimate | tolerance | 100.00660035196987 | 100.00660035196984 | 3.30E-14 | 15 | passed |
/coefficients/1/estimate | tolerance | -0.37077323672499457 | -0.37077323672499807 | 3.50E-15 | 14 | passed |
/n | exact | 30 | 30 | 0.00E+2 | passed |
Convention
- Pooled OLS uses all batches without batch terms; lower spec limit is 95 response units.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
75 j <- seq_len(30L)
76 stability <- data.frame(time=as.double(rep(0:9,3L)),
77 response=100-0.37*rep(0:9,3L)+0.08*sin(j*1.31),
78 batch=rep(c("A","B","C"),each=10L))
79 export_dataset(stability,"SURV_STABILITY","Constructed linear shelf-life measurements",
80 "R stats::lm pooled regression",
81 "Constructed validation data; no third-party license.",
82 c(time="Float64",response="Float64",batch="String"))
83 s <- read_dataset("SURV_STABILITY")
84 lmfit <- stats::lm(response~time,data=s)
85 emit("STAT-SURV-STABILITY-001","tabelz.analysis.product_stability:compute_product_stability",
86 "productStabilityMenuItem","SURV_STABILITY",
87 list(time_column="time",response_column="response",model_type="pooled",lsl=95),
88 list("/coefficients/0/estimate"=tol(coef(lmfit)[[1]],"Pooled OLS intercept"),
89 "/coefficients/1/estimate"=tol(coef(lmfit)[[2]],"Pooled OLS time slope"),
90 "/n"=exact(nrow(s),"All complete shelf-life measurements")),
91 c("Pooled OLS uses all batches without batch terms; lower spec limit is 95 response units."))
Hard-numeric survival STAT-SURV-STABILITY-HARD-001
Case STAT-SURV-STABILITY-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_hard.R · sha256 bc20ccd17540f4e7
- Dataset
- reference_data/datasets/SURV_STABILITY_HARD.json
Settings compared
lsl= 95response_column= "response"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/1/estimate | tolerance | -0.030000796960761165 | -0.030000796960633513 | 1.28E-13 | 11 | passed |
Convention
- Time is near 1e6 with unit increments; QR regression resolves a small slope.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
91 fit_stable <- stats::lm(response~time,data=s)
92 emit("STAT-SURV-STABILITY-HARD-001","tabelz.analysis.product_stability:compute_product_stability",
93 "productStabilityMenuItem","SURV_STABILITY_HARD",
94 list(time_column="time",response_column="response",lsl=95),
95 list("/coefficients/1/estimate"=tol(coef(fit_stable)[[2]],
96 "Large-offset time OLS slope","1e-9")),
97 c("Time is near 1e6 with unit increments; QR regression resolves a small slope."))
Survival option STAT-SURV-STABILITY-INTERCEPTS-001
Case STAT-SURV-STABILITY-INTERCEPTS-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_options.R · sha256 95af0dbeed660def
- Dataset
- reference_data/datasets/SURV_STABILITY.json
Settings compared
batch_column= "batch"confidence_level= 0.9lsl= 95model_type= "separate_intercepts_pooled_slope"response_column= "response"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/3/estimate | tolerance | -0.37077323672499568 | -0.3707732367249723 | 2.34E-14 | 13 | passed |
/n | exact | 30 | 30 | 0.00E+2 | passed |
Convention
- R 0+batch+time has separate batch intercepts and one pooled slope.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
69 s <- read_dataset("SURV_STABILITY")
70 intercepts <- stats::lm(response~0+batch+time,data=s)
71 emit("STAT-SURV-STABILITY-INTERCEPTS-001",
72 "tabelz.analysis.product_stability:compute_product_stability",
73 "productStabilityMenuItem","SURV_STABILITY",
74 list(time_column="time",response_column="response",batch_column="batch",
75 model_type="separate_intercepts_pooled_slope",confidence_level=0.9,lsl=95),
76 list("/coefficients/3/estimate"=tol(coef(intercepts)[[4]],"Pooled time slope","1e-9"),
77 "/n"=exact(nrow(s),"All stability measurements")),
78 c("R 0+batch+time has separate batch intercepts and one pooled slope."))
Invalid survival request STAT-SURV-STABILITY-INVALID-001
Case STAT-SURV-STABILITY-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/SURV_STABILITY.json
Settings compared
response_column= "response"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- A shelf-life decision needs a lower or upper specification.
- The declared request contract rejects this before statistical estimation.
Invalid survival request STAT-SURV-STABILITY-INVALID-002
Case STAT-SURV-STABILITY-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/SURV_STABILITY.json
Settings compared
lsl= 100response_column= "response"time_column= "time"usl= 95
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- The lower specification must be below the upper.
- The declared request contract rejects this before statistical estimation.
Small-sample survival boundary STAT-SURV-STABILITY-MIN-001
Case STAT-SURV-STABILITY-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::survfit/coxph and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_minimum.R · sha256 2997d37929a6dae8
- Dataset
- reference_data/datasets/SURV_MIN.json
Settings compared
lsl= 95response_column= "response"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/n | exact | 3 | 3 | 0.00E+2 | passed | |
/coefficients/1/estimate | tolerance | -0.50500000000000511 | -0.5050000000000026 | 2.55E-15 | 14 | passed |
Convention
- Three distinct times are the smallest two-parameter OLS sample with residual df.
- R re-reads the exported CSV and drops excluded 0-based ordinals.
Reference code
The lines of the reference script that produce this case's expected values.
71 emit("STAT-SURV-STABILITY-MIN-001","tabelz.analysis.product_stability:compute_product_stability",
72 "productStabilityMenuItem","SURV_MIN",3:4,
73 list(time_column="time",response_column="response",lsl=95),
74 list("/n"=exact(3L,"Three rows leave one residual degree of freedom"),
75 "/coefficients/1/estimate"=tol(coef(stats::lm(response~time,data=d[1:3,]))[[2]],
76 "Three-row OLS slope","1e-9")),
77 c("Three distinct times are the smallest two-parameter OLS sample with residual df."))
Survival boundary STAT-SURV-STABILITY-OUTSIDE-001
Case STAT-SURV-STABILITY-OUTSIDE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival and analytic boundary
- Citation
- R survival::survfit/coxph/survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_boundaries.R · sha256 528007972452fb15
- Dataset
- reference_data/datasets/SURV_STABILITY.json
Settings compared
lsl= 1000response_column= "response"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/overall_shelf_life_status | exact | out_of_specification_at_zero | out_of_specification_at_zero | passed |
Convention
- R pooled lm intercept is near 100, so its one-sided lower 95% bound is certainly below 1000.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
113 emit("STAT-SURV-STABILITY-OUTSIDE-001",
114 "tabelz.analysis.product_stability:compute_product_stability",
115 "productStabilityMenuItem","SURV_STABILITY",
116 list(time_column="time",response_column="response",lsl=1000),
117 list("/overall_shelf_life_status"=exact("out_of_specification_at_zero",
118 "One-sided lower mean bound is already below LSL=1000 at time zero")),
119 c("R pooled lm intercept is near 100, so its one-sided lower 95% bound is certainly below 1000."))
Survival population STAT-SURV-STABILITY-POP-001
Case STAT-SURV-STABILITY-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::Surv/survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_population.R · sha256 3b3b4629e272fcd9
- Dataset
- reference_data/datasets/SURV_STABILITY_POP.json
Settings compared
lsl= 95response_column= "response"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 30 | 30 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_count | exact | 2 | 2 | 0.00E+2 | passed | |
/coefficients/1/estimate | tolerance | -0.37251041269502028 | -0.3725104126950196 | 6.70E-16 | 14 | passed |
Convention
- Pooled OLS excludes missing time/response and declared source exclusion.
- R re-reads the exported CSV and removes the declared ordinal before complete-case selection.
Reference code
The lines of the reference script that produce this case's expected values.
106 stability_eligible <- s[-10L,,drop=FALSE]
107 stability_complete <- stability_eligible[stats::complete.cases(stability_eligible[c("time","response")]),,drop=FALSE]
108 lmfit <- stats::lm(response~time,data=stability_complete)
109 emit("STAT-SURV-STABILITY-POP-001","tabelz.analysis.product_stability:compute_product_stability",
110 "productStabilityMenuItem","SURV_STABILITY_POP",9L,
111 list(time_column="time",response_column="response",lsl=95),
112 list("/source_count"=exact(nrow(s),"CSV population"),
113 "/excluded_count"=exact(1L,"One source row excluded"),
114 "/missing_count"=exact(2L,"Missing response and time"),
115 "/coefficients/1/estimate"=tol(coef(lmfit)[[2]],"Complete-case pooled slope")),
116 c("Pooled OLS excludes missing time/response and declared source exclusion."))
Survival option STAT-SURV-STABILITY-SLOPES-001
Case STAT-SURV-STABILITY-SLOPES-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_options.R · sha256 95af0dbeed660def
- Dataset
- reference_data/datasets/SURV_STABILITY.json
Settings compared
batch_column= "batch"lsl= 95model_type= "separate_intercepts_separate_slopes"response_column= "response"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/3/estimate | tolerance | -0.37447507711523798 | -0.3744750771152039 | 3.41E-14 | 13 | passed |
/n | exact | 30 | 30 | 0.00E+2 | passed |
Convention
- R 0+batch+batch:time has separate intercepts and slopes per batch.
- R re-reads the referenced CSV.
Reference code
The lines of the reference script that produce this case's expected values.
80 slopes <- stats::lm(response~0+batch+batch:time,data=s)
81 emit("STAT-SURV-STABILITY-SLOPES-001",
82 "tabelz.analysis.product_stability:compute_product_stability",
83 "productStabilityMenuItem","SURV_STABILITY",
84 list(time_column="time",response_column="response",batch_column="batch",
85 model_type="separate_intercepts_separate_slopes",lsl=95),
86 list("/coefficients/3/estimate"=tol(coef(slopes)[[4]],"Batch A time slope","1e-9"),
87 "/n"=exact(nrow(s),"All stability measurements")),
88 c("R 0+batch+batch:time has separate intercepts and slopes per batch."))
Weibull warranty prediction from a calendar triangle with future shipments and a limit
Case STAT-SURV-WARRPRED-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package survreg on interval2 records with frequency weights; independent base-R implementations of the warranty triangle conversion and the expected-count algebra
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_warranty.R · sha256 4e304617e4b0f92b
- Dataset
- reference_data/datasets/SURV_WARR_B9.json
Settings compared
confidence_level= 0.95family= "weibull"future_shipments= ["500@1.5", "300@6"]horizon= 12last_period= "incomplete"period_unit= "month"period_width= 1return_axis= "calendar"returns= ["r1", "r2", "r3", "r4", "r5", "r6", "r7"]shipped= "shipped"source= "triangle"unit_cost= 3.2warranty_limit= 24
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/log_likelihood | tolerance | -336.06856173438467 | -336.0685617343846 | 5.39E-14 | 15 | passed |
/field_expected | tolerance | 160.70966849733594 | 160.70966697561062 | 1.52E-6 | 8 | passed |
/future_expected | tolerance | 149.12458269274785 | 149.12458179843816 | 8.94E-7 | 8 | passed |
/expected | tolerance | 309.83425119008382 | 309.8342487740488 | 2.42E-6 | 8 | passed |
/eligible_units | tolerance | 1547 | 1547.0 | 0.00E+2 | passed | |
/lower | tolerance | 217.2083633699134 | 217.2083676416655 | 4.27E-6 | 7 | passed |
/upper | tolerance | 429.21036995102338 | 429.2103568077127 | 1.31E-5 | 7 | passed |
/cohorts/0/survivors | tolerance | 107 | 107.0 | 0.00E+2 | passed | |
/cohorts/0/age | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/cohorts/0/eligible | exact | True | True | passed | ||
/cohorts/0/expected | tolerance | 22.087154151458261 | 22.087153918131666 | 2.33E-7 | 7 | passed |
/cohorts/1/survivors | tolerance | 120 | 120.0 | 0.00E+2 | passed | |
/cohorts/1/age | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/cohorts/1/eligible | exact | True | True | passed | ||
/cohorts/1/expected | tolerance | 25.100946720575806 | 25.10094646404716 | 2.57E-7 | 7 | passed |
/cohorts/2/survivors | tolerance | 135 | 135.0 | 0.00E+2 | passed | |
/cohorts/2/age | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/cohorts/2/eligible | exact | True | True | passed | ||
/cohorts/2/expected | tolerance | 28.662777229262513 | 28.66277694746626 | 2.82E-7 | 8 | passed |
/cohorts/3/survivors | tolerance | 144 | 144.0 | 0.00E+2 | passed | |
/cohorts/3/age | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/cohorts/3/eligible | exact | True | True | passed | ||
/cohorts/3/expected | tolerance | 31.102848879442675 | 31.102848587630866 | 2.92E-7 | 8 | passed |
/cohorts/4/survivors | tolerance | 134 | 134.0 | 0.00E+2 | passed | |
/cohorts/4/age | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/cohorts/4/eligible | exact | True | True | passed | ||
/cohorts/4/expected | tolerance | 29.541409612112929 | 29.541409350915384 | 2.61E-7 | 8 | passed |
/cohorts/5/survivors | tolerance | 107 | 107.0 | 0.00E+2 | passed | |
/cohorts/5/age | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/cohorts/5/eligible | exact | True | True | passed | ||
/cohorts/5/expected | tolerance | 24.214531904483767 | 24.21453170741926 | 1.97E-7 | 8 | passed |
/future/0/units | tolerance | 500 | 500.0 | 0.00E+2 | passed | |
/future/0/time | tolerance | 1.5 | 1.5 | 0.00E+1 | passed | |
/future/0/expected | tolerance | 107.27425698755201 | 107.27425629629975 | 6.91E-7 | 8 | passed |
/future/1/units | tolerance | 300 | 300.0 | 0.00E+2 | passed | |
/future/1/time | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/future/1/expected | tolerance | 41.850325705195836 | 41.850325502138396 | 2.03E-7 | 8 | passed |
/periods/0/horizon | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/periods/0/expected | tolerance | 17.016043236914964 | 17.01604311037727 | 1.27E-7 | 8 | passed |
/periods/0/increment | tolerance | 17.016043236914964 | 17.01604311037727 | 1.27E-7 | 8 | passed |
/periods/0/lower | tolerance | 12.275334773862655 | 12.275334937271714 | 1.63E-7 | 7 | passed |
/periods/0/upper | tolerance | 23.528971769961704 | 23.528971114723518 | 6.55E-7 | 7 | passed |
/periods/1/horizon | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/periods/1/expected | tolerance | 42.014879794007243 | 42.014879569816635 | 2.24E-7 | 8 | passed |
/periods/1/increment | tolerance | 24.998836557092279 | 24.998836459439364 | 9.77E-8 | 8 | passed |
/periods/1/lower | tolerance | 32.627813526385033 | 32.62781364215715 | 1.16E-7 | 8 | passed |
/periods/1/upper | tolerance | 53.982564643767766 | 53.98256388521346 | 7.59E-7 | 7 | passed |
/periods/2/horizon | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/periods/2/expected | tolerance | 70.742615561812599 | 70.7426151651585 | 3.97E-7 | 8 | passed |
/periods/2/increment | tolerance | 28.727735767805356 | 28.727735595341862 | 1.72E-7 | 8 | passed |
/periods/2/lower | tolerance | 54.538553684349992 | 54.53855395325358 | 2.69E-7 | 8 | passed |
/periods/2/upper | tolerance | 91.392114735334331 | 91.39211329176975 | 1.44E-6 | 7 | passed |
/periods/3/horizon | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/periods/3/expected | tolerance | 97.025582421468897 | 97.02558182646388 | 5.95E-7 | 8 | passed |
/periods/3/increment | tolerance | 26.282966859656298 | 26.28296666130538 | 1.98E-7 | 8 | passed |
/periods/3/lower | tolerance | 73.534784920846931 | 73.53478549991331 | 5.79E-7 | 8 | passed |
/periods/3/upper | tolerance | 127.20707633887618 | 127.20707386373645 | 2.48E-6 | 7 | passed |
/periods/4/horizon | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/periods/4/expected | tolerance | 121.72310443282765 | 121.72310363117464 | 8.02E-7 | 8 | passed |
/periods/4/increment | tolerance | 24.697522011358757 | 24.69752180471076 | 2.07E-7 | 8 | passed |
/periods/4/lower | tolerance | 90.672448016413142 | 90.6724489794944 | 9.63E-7 | 7 | passed |
/periods/4/upper | tolerance | 161.91806401061035 | 161.91806034019297 | 3.67E-6 | 7 | passed |
/periods/5/horizon | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/periods/5/expected | tolerance | 145.18513883164255 | 145.18513782096332 | 1.01E-6 | 8 | passed |
/periods/5/increment | tolerance | 23.462034398814893 | 23.46203418978868 | 2.09E-7 | 8 | passed |
/periods/5/lower | tolerance | 106.42948055672369 | 106.42948194350812 | 1.39E-6 | 7 | passed |
/periods/5/upper | tolerance | 195.6328112284948 | 195.6328062797342 | 4.95E-6 | 7 | passed |
/periods/6/horizon | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/periods/6/expected | tolerance | 177.31589739311673 | 177.31589618670574 | 1.21E-6 | 8 | passed |
/periods/6/increment | tolerance | 32.130758561474181 | 32.13075836574242 | 1.96E-7 | 8 | passed |
/periods/6/lower | tolerance | 130.88273750697246 | 130.88273912612675 | 1.62E-6 | 7 | passed |
/periods/6/upper | tolerance | 237.45984745800803 | 237.4598416521275 | 5.81E-6 | 7 | passed |
/periods/7/horizon | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/periods/7/expected | tolerance | 206.38349851442604 | 206.383497068772 | 1.45E-6 | 8 | passed |
/periods/7/increment | tolerance | 29.067601121309309 | 29.067600882066245 | 2.39E-7 | 8 | passed |
/periods/7/lower | tolerance | 150.90568933890032 | 150.9056914202338 | 2.08E-6 | 7 | passed |
/periods/7/upper | tolerance | 278.19264827475939 | 278.19264109911927 | 7.18E-6 | 7 | passed |
/periods/8/horizon | tolerance | 9 | 9.0 | 0.00E+2 | passed | |
/periods/8/expected | tolerance | 233.90119248906103 | 233.9011907984563 | 1.69E-6 | 8 | passed |
/periods/8/increment | tolerance | 27.517693974634994 | 27.51769372968431 | 2.45E-7 | 8 | passed |
/periods/8/lower | tolerance | 169.16469953534235 | 169.16470213629714 | 2.60E-6 | 7 | passed |
/periods/8/upper | tolerance | 317.69900623431431 | 317.6989975767037 | 8.66E-6 | 7 | passed |
/periods/9/horizon | tolerance | 10 | 10.0 | 0.00E+2 | passed | |
/periods/9/expected | tolerance | 260.2047251931865 | 260.204723257716 | 1.94E-6 | 8 | passed |
/periods/9/increment | tolerance | 26.303532704125473 | 26.303532459259714 | 2.45E-7 | 8 | passed |
/periods/9/lower | tolerance | 186.14695874110816 | 186.14696188675404 | 3.15E-6 | 7 | passed |
/periods/9/upper | tolerance | 356.01797951030528 | 356.0179693430939 | 1.02E-5 | 7 | passed |
/periods/10/horizon | tolerance | 11 | 11.0 | 0.00E+2 | passed | |
/periods/10/expected | tolerance | 285.47549821117252 | 285.4754960334378 | 2.18E-6 | 8 | passed |
/periods/10/increment | tolerance | 25.270773017986016 | 25.27077277572181 | 2.42E-7 | 8 | passed |
/periods/10/lower | tolerance | 202.10667683287139 | 202.10668053563796 | 3.70E-6 | 7 | passed |
/periods/10/upper | tolerance | 393.18008089268551 | 393.1800692261434 | 1.17E-5 | 7 | passed |
/periods/11/horizon | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/periods/11/expected | tolerance | 309.83425119008382 | 309.8342487740488 | 2.42E-6 | 8 | passed |
/periods/11/increment | tolerance | 24.358752978911298 | 24.358752740610953 | 2.38E-7 | 8 | passed |
/periods/11/lower | tolerance | 217.2083633699134 | 217.2083676416655 | 4.27E-6 | 7 | passed |
/periods/11/upper | tolerance | 429.21036995102338 | 429.2103568077127 | 1.31E-5 | 7 | passed |
/parameters/0/estimate | tolerance | 0.84808516589383032 | 0.8480851622251954 | 3.67E-9 | 8 | passed |
/parameters/0/standard_error | tolerance | 0.10850192841384465 | 0.10850191869570745 | 9.72E-9 | 7 | passed |
/parameters/0/lower | tolerance | 0.65999225152713725 | 0.6599922627790642 | 1.13E-8 | 7 | passed |
/parameters/0/upper | tolerance | 1.0897831708552899 | 1.0897831428477034 | 2.80E-8 | 7 | passed |
/parameters/1/estimate | tolerance | 56.08097068603918 | 56.080971574448206 | 8.88E-7 | 7 | passed |
/parameters/1/standard_error | tolerance | 21.007923450805492 | 21.00792207818289 | 1.37E-6 | 7 | passed |
/parameters/1/lower | tolerance | 26.912593270759089 | 26.912595301152347 | 2.03E-6 | 7 | passed |
/parameters/1/upper | tolerance | 116.86258702187403 | 116.8625819078624 | 5.11E-6 | 7 | passed |
/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:159-170: a positive-support life family is fitted by maximum likelihood to the converted censored data; expected failures for n_j survivors of age a_j through horizon h before limit L are n_j [1 - S(min(a_j+h,L))/S(a_j)]; a future shipment of d units at time s contributes d F(min(h-s,L)); the interval is a delta-method confidence interval for the expected count formed on logit(mu / N_eligible) with the shared fitted-parameter covariance, not a prediction interval.
- R: survreg(Surv(start, end, type = 'interval2') ~ 1, weights = frequency) fits the family; S(t) is computed analytically from (mu, sigma) (Weibull S = exp(-exp((log t - mu)/sigma)); lognormal S = 1 - pnorm((log t - mu)/sigma)); the gradient of the total expected count uses central differences with step 1e-6 * max(1, |theta|) in (mu, log sigma), and the periods table runs at multiples of the period width capped at the horizon.
- Iterative maximum likelihood: survreg-dependent outputs allow 1e-7 absolute or 1e-6 relative; integer counts use exact and closed-form algebra 1e-9.
- The exposure cohorts are the converted shipment rows with survivors; the cap min(a_j+h, L) binds through the 24-month warranty duration and the future shipments contribute d F(min(h-s, L)).
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
435 triangle_records <- data.frame(
436 start = vapply(conv_calendar$records, function(x) x$start, 0),
437 end = vapply(conv_calendar$records, function(x) if (is.na(x$end)) NA_real_ else x$end, 0),
438 frequency = vapply(conv_calendar$records, function(x) x$frequency, 0L)
439 )
440 triangle_survivors <- vapply(conv_calendar$cohorts, function(x) x$survivors, 0)
441 triangle_ages <- vapply(conv_calendar$cohorts, function(x) x$age, 0)
442 future_units_1 <- c(500, 300)
443 future_times_1 <- c(1.5, 6)
444 pred_weibull <- warranty_prediction_reference(
445 triangle_records, "weibull", triangle_survivors, triangle_ages,
446 future_units_1, future_times_1, 12, 24, 0.95, 1
447 )
448 emit("STAT-SURV-WARRPRED-001",
449 "Weibull warranty prediction from a calendar triangle with future shipments and a limit",
450 PRED, "warrantyPredictionMenuItem", PRED_REQ, "SURV_WARR_B9",
451 list(source = "triangle", shipped = "shipped", returns = as.list(RCOLS),
452 return_axis = "calendar", period_width = 1, period_unit = "month",
453 last_period = "incomplete", family = "weibull", horizon = 12,
454 warranty_limit = 24, future_shipments = list("500@1.5", "300@6"),
455 unit_cost = 3.2, confidence_level = 0.95),
456 prediction_outputs(pred_weibull, "weibull", triangle_survivors, triangle_ages,
457 future_units_1, future_times_1, 0.95),
458 c(PREDICTION_NOTES,
459 "The exposure cohorts are the converted shipment rows with survivors; the cap min(a_j+h, L) binds through the 24-month warranty duration and the future shipments contribute d F(min(h-s, L))."),
460 "nominal")
Lognormal warranty prediction from a censoring table without a warranty limit
Case STAT-SURV-WARRPRED-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package survreg on interval2 records with frequency weights; independent base-R implementations of the warranty triangle conversion and the expected-count algebra
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_warranty.R · sha256 4e304617e4b0f92b
- Dataset
- reference_data/datasets/SURV_CENSOR_B9.json
Settings compared
confidence_level= 0.9end= "end"family= "lognormal"frequency= "freq"future_shipments= ["400@2.5"]horizon= 8period_unit= "month"period_width= 1source= "censoring_table"start= "start"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/log_likelihood | tolerance | -118.13684011875651 | -118.13684011875648 | 2.86E-14 | 15 | passed |
/field_expected | tolerance | 19.054993018185879 | 19.054992934578543 | 8.36E-8 | 8 | passed |
/future_expected | tolerance | 1.1234418895564799 | 1.1234418973008555 | 7.74E-9 | 8 | passed |
/expected | tolerance | 20.178434907742361 | 20.1784348318794 | 7.59E-8 | 8 | passed |
/eligible_units | tolerance | 540 | 540.0 | 0.00E+2 | passed | |
/lower | tolerance | 14.86783366382951 | 14.867833690529267 | 2.67E-8 | 8 | passed |
/upper | tolerance | 27.28734823230122 | 27.287347982083965 | 2.50E-7 | 8 | passed |
/cohorts/0/survivors | tolerance | 40 | 40.0 | 0.00E+2 | passed | |
/cohorts/0/age | tolerance | 12 | 12.0 | 0.00E+2 | passed | |
/cohorts/0/eligible | exact | True | True | passed | ||
/cohorts/0/expected | tolerance | 4.1747952087249294 | 4.1747951940424795 | 1.47E-8 | 8 | passed |
/cohorts/1/survivors | tolerance | 30 | 30.0 | 0.00E+2 | passed | |
/cohorts/1/age | tolerance | 18 | 18.0 | 0.00E+2 | passed | |
/cohorts/1/eligible | exact | True | True | passed | ||
/cohorts/1/expected | tolerance | 4.0316178643338985 | 4.031617846929519 | 1.74E-8 | 8 | passed |
/cohorts/2/survivors | tolerance | 45 | 45.0 | 0.00E+2 | passed | |
/cohorts/2/age | tolerance | 24 | 24.0 | 0.00E+2 | passed | |
/cohorts/2/eligible | exact | True | True | passed | ||
/cohorts/2/expected | tolerance | 6.8228547681372964 | 6.822854736205843 | 3.19E-8 | 8 | passed |
/cohorts/3/survivors | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/cohorts/3/age | tolerance | 30 | 30.0 | 0.00E+2 | passed | |
/cohorts/3/eligible | exact | True | True | passed | ||
/cohorts/3/expected | tolerance | 4.0257251769897557 | 4.025725157400702 | 1.96E-8 | 8 | passed |
/future/0/units | tolerance | 400 | 400.0 | 0.00E+2 | passed | |
/future/0/time | tolerance | 2.5 | 2.5 | 0.00E+1 | passed | |
/future/0/expected | tolerance | 1.1234418895564799 | 1.1234418973008555 | 7.74E-9 | 8 | passed |
/periods/0/horizon | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/periods/0/expected | tolerance | 2.2801461678187098 | 2.280146157852862 | 9.97E-9 | 8 | passed |
/periods/0/increment | tolerance | 2.2801461678187098 | 2.280146157852862 | 9.97E-9 | 8 | passed |
/periods/0/lower | tolerance | 1.6057000139495343 | 1.60570001790863 | 3.96E-9 | 8 | passed |
/periods/0/upper | tolerance | 3.231267295757617 | 3.231267259833253 | 3.59E-8 | 7 | passed |
/periods/1/horizon | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/periods/1/expected | tolerance | 4.6068150938054675 | 4.60681507360904 | 2.02E-8 | 8 | passed |
/periods/1/increment | tolerance | 2.3266689259867577 | 2.3266689157561777 | 1.02E-8 | 8 | passed |
/periods/1/lower | tolerance | 3.2389227106030321 | 3.238922718146534 | 7.54E-9 | 8 | passed |
/periods/1/upper | tolerance | 6.5248466659445779 | 6.524846594713412 | 7.12E-8 | 7 | passed |
/periods/2/horizon | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/periods/2/expected | tolerance | 6.9705561489331549 | 6.970556118306729 | 3.06E-8 | 8 | passed |
/periods/2/increment | tolerance | 2.3637410551276874 | 2.363741044697689 | 1.04E-8 | 8 | passed |
/periods/2/lower | tolerance | 4.9038219713110465 | 4.9038219841781086 | 1.29E-8 | 8 | passed |
/periods/2/upper | tolerance | 9.8922205857361352 | 9.892220473571923 | 1.12E-7 | 7 | passed |
/periods/3/horizon | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/periods/3/expected | tolerance | 9.3639987622509153 | 9.363998721104238 | 4.11E-8 | 8 | passed |
/periods/3/increment | tolerance | 2.3934426133177604 | 2.393442602797509 | 1.05E-8 | 8 | passed |
/periods/3/lower | tolerance | 6.5862348459737419 | 6.586234864898118 | 1.89E-8 | 8 | passed |
/periods/3/upper | tolerance | 13.284117036475124 | 13.284116882902909 | 1.54E-7 | 7 | passed |
/periods/4/horizon | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/periods/4/expected | tolerance | 11.802857758451498 | 11.802857707156031 | 5.13E-8 | 8 | passed |
/periods/4/increment | tolerance | 2.4388589962005831 | 2.438858986051793 | 1.01E-8 | 8 | passed |
/periods/4/lower | tolerance | 8.3316350200966287 | 8.33163504286275 | 2.28E-8 | 8 | passed |
/periods/4/upper | tolerance | 16.674943252163057 | 16.674943063711556 | 1.88E-7 | 7 | passed |
/periods/5/horizon | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/periods/5/expected | tolerance | 14.353165432277509 | 14.353165371817767 | 6.05E-8 | 8 | passed |
/periods/5/increment | tolerance | 2.5503076738260102 | 2.5503076646617355 | 9.16E-9 | 8 | passed |
/periods/5/lower | tolerance | 10.238086876823459 | 10.238086905695953 | 2.89E-8 | 8 | passed |
/periods/5/upper | tolerance | 20.059621819524459 | 20.059621596843577 | 2.23E-7 | 7 | passed |
/periods/6/horizon | tolerance | 7 | 7.0 | 0.00E+2 | passed | |
/periods/6/expected | tolerance | 17.112696541217296 | 17.11269647270544 | 6.85E-8 | 8 | passed |
/periods/6/increment | tolerance | 2.7595311089397878 | 2.759531100887674 | 8.05E-9 | 8 | passed |
/periods/6/lower | tolerance | 12.399933227041805 | 12.399933257110508 | 3.01E-8 | 8 | passed |
/periods/6/upper | tolerance | 23.536704891550901 | 23.536704649535046 | 2.42E-7 | 7 | passed |
/periods/7/horizon | tolerance | 8 | 8.0 | 0.00E+2 | passed | |
/periods/7/expected | tolerance | 20.178434907742361 | 20.1784348318794 | 7.59E-8 | 8 | passed |
/periods/7/increment | tolerance | 3.0657383665250642 | 3.0657383591739595 | 7.35E-9 | 8 | passed |
/periods/7/lower | tolerance | 14.86783366382951 | 14.867833690529267 | 2.67E-8 | 8 | passed |
/periods/7/upper | tolerance | 27.28734823230122 | 27.287347982083965 | 2.50E-7 | 8 | passed |
/parameters/0/estimate | tolerance | 3.8189540439883665 | 3.8189540470923857 | 3.10E-9 | 9 | passed |
/parameters/0/standard_error | tolerance | 0.15130900571100162 | 0.1513090027920221 | 2.92E-9 | 7 | passed |
/parameters/0/lower | tolerance | 3.5700728771542045 | 3.570072885059518 | 7.91E-9 | 8 | passed |
/parameters/0/upper | tolerance | 4.067835210822528 | 4.067835209125254 | 1.70E-9 | 9 | passed |
/parameters/1/estimate | tolerance | 0.76343651956673053 | 0.7634365213066794 | 1.74E-9 | 8 | passed |
/parameters/1/standard_error | tolerance | 0.11158492720078725 | 0.11158492460846108 | 2.59E-9 | 7 | passed |
/parameters/1/lower | tolerance | 0.60029182893454047 | 0.6002918339843731 | 5.05E-9 | 8 | passed |
/parameters/1/upper | tolerance | 0.97091996145048121 | 0.9709199577084642 | 3.74E-9 | 8 | passed |
/parameters/2/estimate | tolerance | 0 | 0.0 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:159-170: a positive-support life family is fitted by maximum likelihood to the converted censored data; expected failures for n_j survivors of age a_j through horizon h before limit L are n_j [1 - S(min(a_j+h,L))/S(a_j)]; a future shipment of d units at time s contributes d F(min(h-s,L)); the interval is a delta-method confidence interval for the expected count formed on logit(mu / N_eligible) with the shared fitted-parameter covariance, not a prediction interval.
- R: survreg(Surv(start, end, type = 'interval2') ~ 1, weights = frequency) fits the family; S(t) is computed analytically from (mu, sigma) (Weibull S = exp(-exp((log t - mu)/sigma)); lognormal S = 1 - pnorm((log t - mu)/sigma)); the gradient of the total expected count uses central differences with step 1e-6 * max(1, |theta|) in (mu, log sigma), and the periods table runs at multiples of the period width capped at the horizon.
- Iterative maximum likelihood: survreg-dependent outputs allow 1e-7 absolute or 1e-6 relative; integer counts use exact and closed-form algebra 1e-9.
- The censoring-table source reads start, end and frequency columns directly; the risk-set cohorts are the distinct right-censoring ages with their surviving weights; no warranty limit means the cap is infinite.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
464 censor <- data.frame(
465 start = c(8.3, 6, 12, 15.2, 12, 18, 18, 21.5, 24, 30, 24, 27.8),
466 end = c(8.3, 9, NA_real_, 15.2, 18, NA_real_, 24, 21.5, NA_real_, NA_real_, 30, 27.8),
467 freq = c(3L, 4L, 40L, 2L, 5L, 30L, 6L, 1L, 45L, 25L, 5L, 2L)
468 )
469 export_dataset(censor, "SURV_CENSOR_B9",
470 "Constructed warranty censoring table with exact, interval and right-censored records (B9)",
471 "Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley",
472 "Constructed validation data; no third-party license.",
473 c(start = "Float64", end = "Float64", freq = "Int64"))
474 cn <- read_dataset("SURV_CENSOR_B9")
475 right <- is.na(cn$end)
476 censor_ages <- sort(unique(cn$start[right]))
477 censor_survivors <- vapply(censor_ages, function(a) sum(cn$freq[right & cn$start == a]), 0)
478 censor_records <- data.frame(start = cn$start, end = cn$end, frequency = cn$freq)
479 future_units_2 <- 400
480 future_times_2 <- 2.5
481 pred_lognormal <- warranty_prediction_reference(
482 censor_records, "lognormal", censor_survivors, censor_ages,
483 future_units_2, future_times_2, 8, NULL, 0.90, 1
484 )
485 emit("STAT-SURV-WARRPRED-002",
486 "Lognormal warranty prediction from a censoring table without a warranty limit",
487 PRED, "warrantyPredictionMenuItem", PRED_REQ, "SURV_CENSOR_B9",
488 list(source = "censoring_table", start = "start", end = "end", frequency = "freq",
489 family = "lognormal", horizon = 8, future_shipments = list("400@2.5"),
490 confidence_level = 0.90, period_width = 1, period_unit = "month"),
491 prediction_outputs(pred_lognormal, "lognormal", censor_survivors, censor_ages,
492 future_units_2, future_times_2, 0.90),
493 c(PREDICTION_NOTES,
494 "The censoring-table source reads start, end and frequency columns directly; the risk-set cohorts are the distinct right-censoring ages with their surviving weights; no warranty limit means the cap is infinite."),
495 "axis_coverage")
Warranty triangle conversion on the calendar axis with the final period incomplete
Case STAT-SURV-WARRPREP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package survreg on interval2 records with frequency weights; independent base-R implementations of the warranty triangle conversion and the expected-count algebra
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_warranty.R · sha256 4e304617e4b0f92b
- Dataset
- reference_data/datasets/SURV_WARR_B9.json
Settings compared
last_period= "incomplete"period_unit= "month"period_width= 1return_axis= "calendar"returns= ["r1", "r2", "r3", "r4", "r5", "r6", "r7"]shipment_label= "label"shipped= "shipped"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/conversion/as_of_period | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/shipped_total | exact | 820 | 820 | 0.00E+2 | passed | |
/conversion/failures_used | exact | 73 | 73 | 0.00E+2 | passed | |
/conversion/survivors_total | exact | 747 | 747 | 0.00E+2 | passed | |
/conversion/excluded_failures | exact | 7 | 7 | 0.00E+2 | passed | |
/conversion/excluded_shipments | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/source_count | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/excluded_row_count | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/cohorts/0/shipment_period | exact | 1 | 1 | 0.00E+2 | passed | |
/conversion/cohorts/0/shipped | exact | 120 | 120 | 0.00E+2 | passed | |
/conversion/cohorts/0/failures | exact | 13 | 13 | 0.00E+2 | passed | |
/conversion/cohorts/0/survivors | exact | 107 | 107 | 0.00E+2 | passed | |
/conversion/cohorts/0/age | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/conversion/cohorts/0/excluded_failures | exact | 1 | 1 | 0.00E+2 | passed | |
/conversion/cohorts/1/shipment_period | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/cohorts/1/shipped | exact | 135 | 135 | 0.00E+2 | passed | |
/conversion/cohorts/1/failures | exact | 15 | 15 | 0.00E+2 | passed | |
/conversion/cohorts/1/survivors | exact | 120 | 120 | 0.00E+2 | passed | |
/conversion/cohorts/1/age | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/cohorts/1/excluded_failures | exact | 1 | 1 | 0.00E+2 | passed | |
/conversion/cohorts/2/shipment_period | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/cohorts/2/shipped | exact | 150 | 150 | 0.00E+2 | passed | |
/conversion/cohorts/2/failures | exact | 15 | 15 | 0.00E+2 | passed | |
/conversion/cohorts/2/survivors | exact | 135 | 135 | 0.00E+2 | passed | |
/conversion/cohorts/2/age | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/cohorts/2/excluded_failures | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/cohorts/3/shipment_period | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/cohorts/3/shipped | exact | 160 | 160 | 0.00E+2 | passed | |
/conversion/cohorts/3/failures | exact | 16 | 16 | 0.00E+2 | passed | |
/conversion/cohorts/3/survivors | exact | 144 | 144 | 0.00E+2 | passed | |
/conversion/cohorts/3/age | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/cohorts/3/excluded_failures | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/cohorts/4/shipment_period | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/cohorts/4/shipped | exact | 145 | 145 | 0.00E+2 | passed | |
/conversion/cohorts/4/failures | exact | 11 | 11 | 0.00E+2 | passed | |
/conversion/cohorts/4/survivors | exact | 134 | 134 | 0.00E+2 | passed | |
/conversion/cohorts/4/age | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/cohorts/4/excluded_failures | exact | 1 | 1 | 0.00E+2 | passed | |
/conversion/cohorts/5/shipment_period | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/cohorts/5/shipped | exact | 110 | 110 | 0.00E+2 | passed | |
/conversion/cohorts/5/failures | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/cohorts/5/survivors | exact | 107 | 107 | 0.00E+2 | passed | |
/conversion/cohorts/5/age | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/cohorts/5/excluded_failures | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/0/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/0/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/0/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/1/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/1/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/1/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/2/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/2/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/2/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/records/3/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/3/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/3/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/4/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/4/end | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/records/4/frequency | exact | 1 | 1 | 0.00E+2 | passed | |
/conversion/records/5/start | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/records/5/end | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/conversion/records/5/frequency | exact | 1 | 1 | 0.00E+2 | passed | |
/conversion/records/6/start | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/conversion/records/6/frequency | exact | 107 | 107 | 0.00E+2 | passed | |
/conversion/records/7/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/7/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/7/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/8/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/8/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/8/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/records/9/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/9/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/9/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/10/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/10/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/10/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/11/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/11/end | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/records/11/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/12/start | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/records/12/frequency | exact | 120 | 120 | 0.00E+2 | passed | |
/conversion/records/13/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/13/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/13/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/records/14/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/14/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/14/frequency | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/records/15/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/15/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/15/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/16/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/16/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/16/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/17/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/17/frequency | exact | 135 | 135 | 0.00E+2 | passed | |
/conversion/records/18/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/18/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/18/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/records/19/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/19/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/19/frequency | exact | 7 | 7 | 0.00E+2 | passed | |
/conversion/records/20/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/20/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/20/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/records/21/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/21/frequency | exact | 144 | 144 | 0.00E+2 | passed | |
/conversion/records/22/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/22/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/22/frequency | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/records/23/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/23/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/23/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/records/24/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/24/frequency | exact | 134 | 134 | 0.00E+2 | passed | |
/conversion/records/25/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/25/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/25/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/26/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/26/frequency | exact | 107 | 107 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:143-157: units are shipped at the start of their shipment period; the as-of date is the end of the last included calendar period J*; a return in calendar period j from shipment i is interval censored over ((j-i)w, (j-i+1)w]; units unreturned at J* are right censored at (J*-i+1)w; blank cells inside the observed region are refused, and cells before shipment or after the last period must be blank or zero.
- Reference: an independent base-R re-implementation of the conversion loops; cohorts and records follow the engine's row and return-column order, so the positional output paths align.
- The default 'incomplete' setting excludes calendar period 7: its 7 returns are reported as excluded failures, and units unreturned at the end of period 6 stay survivors right censored at (6 - i + 1) months.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
382 emit("STAT-SURV-WARRPREP-001",
383 "Warranty triangle conversion on the calendar axis with the final period incomplete",
384 PREP, "warrantyPreprocessMenuItem", PREP_REQ, "SURV_WARR_B9", PREP_CALENDAR,
385 conversion_outputs(conv_calendar),
386 c(CONVERSION_NOTES,
387 "The default 'incomplete' setting excludes calendar period 7: its 7 returns are reported as excluded failures, and units unreturned at the end of period 6 stay survivors right censored at (6 - i + 1) months."),
388 "nominal")
Warranty triangle conversion on the age axis with the final period complete
Case STAT-SURV-WARRPREP-002 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package survreg on interval2 records with frequency weights; independent base-R implementations of the warranty triangle conversion and the expected-count algebra
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_warranty.R · sha256 4e304617e4b0f92b
- Dataset
- reference_data/datasets/SURV_WARR_AGE_B9.json
Settings compared
last_period= "complete"period_unit= "month"period_width= 1return_axis= "age"returns= ["r1", "r2", "r3", "r4", "r5"]shipment_label= "label"shipped= "shipped"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/conversion/as_of_period | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/shipped_total | exact | 1040 | 1040 | 0.00E+2 | passed | |
/conversion/failures_used | exact | 78 | 78 | 0.00E+2 | passed | |
/conversion/survivors_total | exact | 962 | 962 | 0.00E+2 | passed | |
/conversion/excluded_failures | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/excluded_shipments | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/source_count | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/excluded_row_count | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/cohorts/0/shipment_period | exact | 1 | 1 | 0.00E+2 | passed | |
/conversion/cohorts/0/shipped | exact | 200 | 200 | 0.00E+2 | passed | |
/conversion/cohorts/0/failures | exact | 20 | 20 | 0.00E+2 | passed | |
/conversion/cohorts/0/survivors | exact | 180 | 180 | 0.00E+2 | passed | |
/conversion/cohorts/0/age | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/conversion/cohorts/0/excluded_failures | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/cohorts/1/shipment_period | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/cohorts/1/shipped | exact | 180 | 180 | 0.00E+2 | passed | |
/conversion/cohorts/1/failures | exact | 21 | 21 | 0.00E+2 | passed | |
/conversion/cohorts/1/survivors | exact | 159 | 159 | 0.00E+2 | passed | |
/conversion/cohorts/1/age | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/cohorts/1/excluded_failures | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/cohorts/2/shipment_period | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/cohorts/2/shipped | exact | 190 | 190 | 0.00E+2 | passed | |
/conversion/cohorts/2/failures | exact | 17 | 17 | 0.00E+2 | passed | |
/conversion/cohorts/2/survivors | exact | 173 | 173 | 0.00E+2 | passed | |
/conversion/cohorts/2/age | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/cohorts/2/excluded_failures | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/cohorts/3/shipment_period | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/cohorts/3/shipped | exact | 170 | 170 | 0.00E+2 | passed | |
/conversion/cohorts/3/failures | exact | 12 | 12 | 0.00E+2 | passed | |
/conversion/cohorts/3/survivors | exact | 158 | 158 | 0.00E+2 | passed | |
/conversion/cohorts/3/age | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/cohorts/3/excluded_failures | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/cohorts/4/shipment_period | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/cohorts/4/shipped | exact | 160 | 160 | 0.00E+2 | passed | |
/conversion/cohorts/4/failures | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/cohorts/4/survivors | exact | 154 | 154 | 0.00E+2 | passed | |
/conversion/cohorts/4/age | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/cohorts/4/excluded_failures | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/cohorts/5/shipment_period | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/cohorts/5/shipped | exact | 140 | 140 | 0.00E+2 | passed | |
/conversion/cohorts/5/failures | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/cohorts/5/survivors | exact | 138 | 138 | 0.00E+2 | passed | |
/conversion/cohorts/5/age | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/cohorts/5/excluded_failures | exact | 0 | 0 | 0.00E+2 | passed | |
/conversion/records/0/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/0/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/0/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/records/1/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/1/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/1/frequency | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/records/2/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/2/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/2/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/records/3/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/3/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/3/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/4/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/4/end | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/records/4/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/5/start | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/conversion/records/5/frequency | exact | 180 | 180 | 0.00E+2 | passed | |
/conversion/records/6/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/6/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/6/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/records/7/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/7/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/7/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/records/8/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/8/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/8/frequency | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/records/9/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/9/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/9/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/10/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/10/end | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/records/10/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/11/start | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/conversion/records/11/frequency | exact | 159 | 159 | 0.00E+2 | passed | |
/conversion/records/12/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/12/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/12/frequency | exact | 6 | 6 | 0.00E+2 | passed | |
/conversion/records/13/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/13/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/13/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/records/14/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/14/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/14/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/records/15/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/15/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/15/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/16/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/conversion/records/16/frequency | exact | 173 | 173 | 0.00E+2 | passed | |
/conversion/records/17/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/17/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/17/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/conversion/records/18/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/18/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/18/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/conversion/records/19/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/19/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/19/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/records/20/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/conversion/records/20/frequency | exact | 158 | 158 | 0.00E+2 | passed | |
/conversion/records/21/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/21/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/21/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/conversion/records/22/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/22/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/22/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/23/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/conversion/records/23/frequency | exact | 154 | 154 | 0.00E+2 | passed | |
/conversion/records/24/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/conversion/records/24/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/24/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/conversion/records/25/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/conversion/records/25/frequency | exact | 138 | 138 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:143-157: units are shipped at the start of their shipment period; the as-of date is the end of the last included calendar period J*; a return in calendar period j from shipment i is interval censored over ((j-i)w, (j-i+1)w]; units unreturned at J* are right censored at (J*-i+1)w; blank cells inside the observed region are refused, and cells before shipment or after the last period must be blank or zero.
- Reference: an independent base-R re-implementation of the conversion loops; cohorts and records follow the engine's row and return-column order, so the positional output paths align.
- Age-axis reading: column k counts returns in age period k (calendar period i + k - 1), so the last calendar period equals the number of shipment rows; the 'complete' setting includes it as a full period of exposure, and blank cells lie after the last calendar period.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
400 ACOLS <- paste0("r", 1:5)
401 warr_age <- data.frame(
402 label = c("2026-01", "2026-02", "2026-03", "2026-04", "2026-05", "2026-06"),
403 shipped = c(200L, 180L, 190L, 170L, 160L, 140L),
404 r1 = c(4L, 5L, 6L, 3L, 4L, 2L),
405 r2 = c(6L, 4L, 5L, 5L, 2L, NA_integer_),
406 r3 = c(5L, 6L, 4L, 4L, NA_integer_, NA_integer_),
407 r4 = c(3L, 3L, 2L, NA_integer_, NA_integer_, NA_integer_),
408 r5 = c(2L, 3L, NA_integer_, NA_integer_, NA_integer_, NA_integer_)
409 )
410 export_dataset(warr_age, "SURV_WARR_AGE_B9",
411 "Constructed warranty shipment-by-return triangle, age return periods (B9)",
412 "Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley",
413 "Constructed validation data; no third-party license.",
414 c(label = "String", shipped = "Int64",
415 setNames(rep("Int64", length(ACOLS)), ACOLS)))
416 wa <- read_dataset("SURV_WARR_AGE_B9")
417 conv_age <- convert_reference(wa, ACOLS, "age", 1, "complete")
418 stopifnot(
419 conv_age$failures_used + conv_age$survivors_total == conv_age$shipped_total,
420 conv_age$excluded_failures == 0, conv_age$excluded_shipments == 0
421 )
422 emit("STAT-SURV-WARRPREP-002",
423 "Warranty triangle conversion on the age axis with the final period complete",
424 PREP, "warrantyPreprocessMenuItem", PREP_REQ, "SURV_WARR_AGE_B9",
425 list(shipped = "shipped", returns = as.list(ACOLS), return_axis = "age",
426 period_width = 1, period_unit = "month", last_period = "complete",
427 shipment_label = "label"),
428 conversion_outputs(conv_age),
429 c(CONVERSION_NOTES,
430 "Age-axis reading: column k counts returns in age period k (calendar period i + k - 1), so the last calendar period equals the number of shipment rows; the 'complete' setting includes it as a full period of exposure, and blank cells lie after the last calendar period."),
431 "axis_coverage")
Derived warranty censoring table with interval records and right-censored survivors
Case STAT-SURV-WARRTAB-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival package survreg on interval2 records with frequency weights; independent base-R implementations of the warranty triangle conversion and the expected-count algebra
- Citation
- Therneau T (2024). A Package for Survival Analysis in R. R package version 3.6; Meeker, Hahn and Escobar (1998) Statistical Methods for Reliability Data, Wiley.
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, survival 3.8.6, jsonlite 2.0.0
- Reference script
- generators/r/survival_warranty.R · sha256 4e304617e4b0f92b
- Dataset
- reference_data/datasets/SURV_WARR_B9.json
Settings compared
last_period= "incomplete"period_unit= "month"period_width= 1return_axis= "calendar"returns= ["r1", "r2", "r3", "r4", "r5", "r6", "r7"]shipment_label= "label"shipped= "shipped"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/0/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/0/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/0/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/1/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/1/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/1/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/2/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/2/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/2/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/3/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/3/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/3/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/4/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/4/end | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/4/frequency | exact | 1 | 1 | 0.00E+2 | passed | |
/5/start | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/5/end | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/5/frequency | exact | 1 | 1 | 0.00E+2 | passed | |
/6/start | tolerance | 6 | 6.0 | 0.00E+2 | passed | |
/6/frequency | exact | 107 | 107 | 0.00E+2 | passed | |
/7/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/7/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/7/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/8/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/8/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/8/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/9/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/9/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/9/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/10/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/10/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/10/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/11/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/11/end | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/11/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/12/start | tolerance | 5 | 5.0 | 0.00E+2 | passed | |
/12/frequency | exact | 120 | 120 | 0.00E+2 | passed | |
/13/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/13/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/13/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/14/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/14/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/14/frequency | exact | 6 | 6 | 0.00E+2 | passed | |
/15/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/15/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/15/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/16/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/16/end | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/16/frequency | exact | 2 | 2 | 0.00E+2 | passed | |
/17/start | tolerance | 4 | 4.0 | 0.00E+2 | passed | |
/17/frequency | exact | 135 | 135 | 0.00E+2 | passed | |
/18/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/18/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/18/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/19/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/19/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/19/frequency | exact | 7 | 7 | 0.00E+2 | passed | |
/20/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/20/end | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/20/frequency | exact | 4 | 4 | 0.00E+2 | passed | |
/21/start | tolerance | 3 | 3.0 | 0.00E+2 | passed | |
/21/frequency | exact | 144 | 144 | 0.00E+2 | passed | |
/22/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/22/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/22/frequency | exact | 6 | 6 | 0.00E+2 | passed | |
/23/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/23/end | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/23/frequency | exact | 5 | 5 | 0.00E+2 | passed | |
/24/start | tolerance | 2 | 2.0 | 0.00E+2 | passed | |
/24/frequency | exact | 134 | 134 | 0.00E+2 | passed | |
/25/start | tolerance | 0 | 0.0 | 0.00E+2 | passed | |
/25/end | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/25/frequency | exact | 3 | 3 | 0.00E+2 | passed | |
/26/start | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/26/frequency | exact | 107 | 107 | 0.00E+2 | passed |
Convention
- docs/manual/chapters/96-repairable-degradation-warranty.tex:143-157: units are shipped at the start of their shipment period; the as-of date is the end of the last included calendar period J*; a return in calendar period j from shipment i is interval censored over ((j-i)w, (j-i+1)w]; units unreturned at J* are right censored at (J*-i+1)w; blank cells inside the observed region are refused, and cells before shipment or after the last period must be blank or zero.
- Reference: an independent base-R re-implementation of the conversion loops; cohorts and records follow the engine's row and return-column order, so the positional output paths align.
- The derived frequency table keeps one row per cohort and period with a frequency and never expands units into rows (manual :155-157); the result is a frame of row dicts, so numeric fields are compared positionally, the null end of right-censored rows and the string cohort and censoring columns are skipped.
- R re-reads the exported CSV before calculating the reference.
Reference code
The lines of the reference script that produce this case's expected values.
390 emit("STAT-SURV-WARRTAB-001",
391 "Derived warranty censoring table with interval records and right-censored survivors",
392 TABLE, "warrantyPreprocessMenuItem", PREP_REQ, "SURV_WARR_B9", PREP_CALENDAR,
393 table_outputs(conv_calendar),
394 c(CONVERSION_NOTES,
395 "The derived frequency table keeps one row per cohort and period with a frequency and never expands units into rows (manual :155-157); the result is a frame of row dicts, so numeric fields are compared positionally, the null end of right-censored rows and the string cohort and censoring columns are skipped."),
396 "nominal")
Parametric survival STAT-SURV-WEIBULL-AFT-001
Case STAT-SURV-WEIBULL-AFT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival::survreg
- Citation
- R survival::survreg and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_parametric.R · sha256 7c99eb709767fd04
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
event_column= "status"prediction_stresses= [50]stress_column= "stress"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/0/estimate | tolerance | 2.4382790596604771 | 2.4382790599605713 | 3.00E-10 | 9 | passed |
/coefficients/1/estimate | tolerance | 0.0071585227753400505 | 0.007158522779814208 | 4.47E-12 | 9 | passed |
/coefficients/2/estimate | tolerance | 3.8695571302481424 | 3.8695571288731716 | 1.37E-9 | 9 | passed |
/analyzed_count | exact | 32 | 32 | 0.00E+2 | passed |
Convention
- R survreg Weibull scale is inverse shape; Tabelz k=1/scale and beta0 is log scale.
- R maxiter=200; no predictor standardization.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
74 emit("STAT-SURV-WEIBULL-AFT-001","tabelz.analysis.weibull_aft:compute_weibull_aft",
75 "weibullAftMenuItem","SURV_CORE",
76 list(time_column="time",event_column="status",stress_column="stress",
77 prediction_stresses=list(50)),
78 list("/coefficients/0/estimate"=tol(coef(fit_aft)[[1]],"Log scale intercept"),
79 "/coefficients/1/estimate"=tol(coef(fit_aft)[[2]],"Log scale stress slope"),
80 "/coefficients/2/estimate"=tol(1/fit_aft$scale,"Weibull shape=1/survreg scale"),
81 "/analyzed_count"=exact(nrow(d),"All complete rows")),
82 c("R survreg Weibull scale is inverse shape; Tabelz k=1/scale and beta0 is log scale.",
83 "R maxiter=200; no predictor standardization."))
Survival boundary STAT-SURV-WEIBULL-CONSTANT-001
Case STAT-SURV-WEIBULL-CONSTANT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival and analytic boundary
- Citation
- R survival::survfit/coxph/survreg documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_boundaries.R · sha256 528007972452fb15
- Dataset
- reference_data/datasets/SURV_CONST_STRESS.json
Settings compared
event_column= "status"stress_column= "stress"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Constant stress makes the Weibull AFT stress coefficient unidentified.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
84 emit("STAT-SURV-WEIBULL-CONSTANT-001","tabelz.analysis.weibull_aft:compute_weibull_aft",
85 "weibullAftMenuItem","SURV_CONST_STRESS",
86 list(time_column="time",event_column="status",stress_column="stress"),list(),
87 c("Constant stress makes the Weibull AFT stress coefficient unidentified."),
88 error=list(error_class="ValueError",message_contains="stress covariate is constant"))
Hard-numeric survival STAT-SURV-WEIBULL-HARD-001
Case STAT-SURV-WEIBULL-HARD-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats
- Citation
- R survival::survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_hard.R · sha256 bc20ccd17540f4e7
- Dataset
- reference_data/datasets/SURV_HARD.json
Settings compared
event_column= "status"prediction_stresses= [102500]stress_column= "stress"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/coefficients/2/estimate | tolerance | 2523.5827305568059 | 2523.582730755752 | 1.99E-7 | 10 | passed |
Convention
- The independent reference uses the same censored Weibull likelihood and converted shape.
- R re-reads the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
85 emit("STAT-SURV-WEIBULL-HARD-001","tabelz.analysis.weibull_aft:compute_weibull_aft",
86 "weibullAftMenuItem","SURV_HARD",
87 list(time_column="time",event_column="status",stress_column="stress",
88 prediction_stresses=list(use_stress)),
89 list("/coefficients/2/estimate"=tol(1/fit_alt$scale,"Large-offset Weibull shape=1/survreg scale")),
90 c("The independent reference uses the same censored Weibull likelihood and converted shape."))
Invalid survival request STAT-SURV-WEIBULL-INVALID-001
Case STAT-SURV-WEIBULL-INVALID-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
event_column= "status"stress_column= "time"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Time, event and stress roles must be distinct.
- The declared request contract rejects this before statistical estimation.
Invalid survival request STAT-SURV-WEIBULL-INVALID-002
Case STAT-SURV-WEIBULL-INVALID-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Strict request-contract rejection
- Citation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · jsonlite 2.0.0
- Reference script
- none (values transcribed from the source)
- Dataset
- reference_data/datasets/SURV_CORE.json
Settings compared
event_column= "status"max_rows= 0stress_column= "stress"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Weibull AFT bounded row limit must be positive.
- The declared request contract rejects this before statistical estimation.
Small-sample survival boundary STAT-SURV-WEIBULL-MIN-001
Case STAT-SURV-WEIBULL-MIN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::survfit/coxph and Surv(type=interval2) documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_minimum.R · sha256 2997d37929a6dae8
- Dataset
- reference_data/datasets/SURV_MIN.json
Settings compared
event_column= "status"stress_column= "stress"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/failure_count | exact | 3 | 3 | 0.00E+2 | passed | |
/analyzed_count | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- Three failures and varying stress meet Weibull AFT sample condition.
- R re-reads the exported CSV and drops excluded 0-based ordinals.
Reference code
The lines of the reference script that produce this case's expected values.
65 emit("STAT-SURV-WEIBULL-MIN-001","tabelz.analysis.weibull_aft:compute_weibull_aft",
66 "weibullAftMenuItem","SURV_MIN",integer(),
67 list(time_column="time",event_column="status",stress_column="stress"),
68 list("/failure_count"=exact(3L,"Minimum three observed failures"),
69 "/analyzed_count"=exact(5L,"Five complete rows")),
70 c("Three failures and varying stress meet Weibull AFT sample condition."))
Survival population STAT-SURV-WEIBULL-POP-001
Case STAT-SURV-WEIBULL-POP-001 · status: passed
Reference
- Evidence type
- R
- Source
- R survival/stats and analytic counts
- Citation
- R survival::Surv/survfit/coxph/survreg and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · survival 3.8.6, stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/survival_population.R · sha256 3b3b4629e272fcd9
- Dataset
- reference_data/datasets/SURV_POP.json
Settings compared
event_column= "status"prediction_stresses= [50]stress_column= "stress"time_column= "time"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/source_count | exact | 32 | 32 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/missing_response_count | exact | 2 | 2 | 0.00E+2 | passed | |
/incomplete_covariate_count | exact | 1 | 1 | 0.00E+2 | passed | |
/analyzed_count | exact | 28 | 28 | 0.00E+2 | passed |
Convention
- This checks Weibull AFT population partition; seeded ML coefficients are compared in a separate case.
- R re-reads the exported CSV and removes the declared ordinal before complete-case selection.
Reference code
The lines of the reference script that produce this case's expected values.
96 emit("STAT-SURV-WEIBULL-POP-001","tabelz.analysis.weibull_aft:compute_weibull_aft",
97 "weibullAftMenuItem","SURV_POP",7L,
98 list(time_column="time",event_column="status",stress_column="stress",prediction_stresses=list(50)),
99 list("/source_count"=exact(nrow(d),"CSV population"),
100 "/excluded_count"=exact(1L,"One stable identity excluded"),
101 "/missing_response_count"=exact(2L,"Missing time and status"),
102 "/incomplete_covariate_count"=exact(1L,"Missing stress"),
103 "/analyzed_count"=exact(nrow(altdata),"Complete AFT rows")),
104 c("This checks Weibull AFT population partition; seeded ML coefficients are compared in a separate case."))
Biased sample ACF and lag-one PACF
Case STAT-TS-ACF-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::acf, stats::pacf and stats::diff documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, urca 1.3.4
- Reference script
- generators/r/timeseries_correlations.R · sha256 806e71b5ec8f6997
- Dataset
- reference_data/datasets/TS_CORRELATIONS_01.json
Settings compared
maximum_lag= 5response_column= "value"task= "correlations"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sample_count | exact | 36 | 36 | 0.00E+2 | passed | |
/correlations/acf/0 | tolerance | 1 | 1.0 | 0.00E+2 | passed | |
/correlations/acf/1 | tolerance | 0.89603873717092286 | 0.8960387371709229 | 9.97E-19 | 17 | passed |
/correlations/acf/2 | tolerance | 0.75712327456419781 | 0.7571232745641981 | 3.35E-16 | 15 | passed |
/correlations/pacf/1 | tolerance | 0.89603873717092286 | 0.8960387371709227 | 1.10E-16 | 15 | passed |
Convention
- Manual chapter 12 ACF/PACF task: autocorrelation uses a fixed n denominator.
- R acf(type=correlation) uses the biased n denominator and R pacf uses Yule-Walker.
- R re-reads the exported CSV before calculation.
Reference code
The lines of the reference script that produce this case's expected values.
166 emit("STAT-TS-ACF-001", "Biased sample ACF and lag-one PACF", "timeSeriesAcfPacfMenuItem",
167 list(response_column = "value", task = "correlations", maximum_lag = 5L),
168 list("/sample_count" = exact(length(series), "All 36 values are finite."),
169 "/correlations/acf/0" = tol(acf[1], "Lag-zero ACF equals one; owner 1e-9 tier."),
170 "/correlations/acf/1" = tol(acf[2], "Biased lag-one ACF divides by n; owner 1e-9 tier."),
171 "/correlations/acf/2" = tol(acf[3], "Biased lag-two ACF divides by n; owner 1e-9 tier."),
172 "/correlations/pacf/1" = tol(pacf[1], "Yule-Walker lag-one PACF; owner 1e-9 tier.")),
173 c("Manual chapter 12 ACF/PACF task: autocorrelation uses a fixed n denominator.",
174 "R acf(type=correlation) uses the biased n denominator and R pacf uses Yule-Walker."))
ARMA(1,0) with a constant
Case STAT-TS-ARIMA-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::arima
- Citation
- R stats::arima and stats::predict.Arima documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_MODELS_01.json
Settings compared
arima_order= [1, 0, 0]deterministic_term= "constant"horizon= 3method= "forecast"model= "arima"response_column= "ar"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/forecast_rows/0/forecast | tolerance | 10.337307449789856 | 10.337307140440803 | 3.09E-7 | 7 | passed |
/forecast_rows/0/lower | tolerance | 8.6598210036731587 | 8.659820692192437 | 3.11E-7 | 7 | passed |
/forecast_rows/0/upper | tolerance | 12.014793895906553 | 12.01479358868917 | 3.07E-7 | 7 | passed |
/forecast_rows/1/forecast | tolerance | 10.059477718243981 | 10.059477415940687 | 3.02E-7 | 7 | passed |
/forecast_rows/1/lower | tolerance | 8.2236546022409698 | 8.22365445530158 | 1.47E-7 | 7 | passed |
/forecast_rows/1/upper | tolerance | 11.895300834246992 | 11.895300376579796 | 4.58E-7 | 7 | passed |
/forecast_rows/2/forecast | tolerance | 9.9359487933451778 | 9.935948558461774 | 2.35E-7 | 7 | passed |
/forecast_rows/2/lower | tolerance | 8.070414708744611 | 8.070414688032276 | 2.07E-8 | 8 | passed |
/forecast_rows/2/upper | tolerance | 11.801482877945745 | 11.801482428891273 | 4.49E-7 | 7 | passed |
/parameters/1/term | exact | ar.L1 | ar.L1 | passed | ||
/parameters/1/estimate | tolerance | 0.44462097059041777 | 0.44462073919978573 | 2.31E-7 | 6 | passed |
/parameters/2/term | exact | sigma2 | sigma2 | passed | ||
/parameters/2/estimate | tolerance | 0.73252399888976705 | 0.7325240007514799 | 1.86E-9 | 8 | passed |
/parameters/0/term | exact | intercept | intercept | passed | ||
/parameters/0/estimate | tolerance | 5.4632940466268574 | 5.4632962738226745 | 2.23E-6 | 6 | passed |
/diagnostics/ljung_box_model_df | exact | 1 | 1 | 0.00E+2 | passed | |
/converged | exact | True | True | passed |
Convention
- Exact Gaussian maximum likelihood (R method = 'ML'); iterative-fit tier 1e-6.
- R parameterises the constant as the mean; the product labels the equation constant 'intercept'.
Reference code
The lines of the reference script that produce this case's expected values.
174 arima_case("STAT-TS-ARIMA-001", "ARMA(1,0) with a constant", "ar", c(1, 0, 0), "constant",
175 arima(d$ar, order = c(1, 0, 0), method = "ML", optim.control = tight_optim),
176 "R parameterises the constant as the mean; the product labels the equation constant 'intercept'.")
ARIMA(1,1,0) without a deterministic term
Case STAT-TS-ARIMA-002 · status: passed
Reference
- Evidence type
- R
- Source
- Closed-form exact AR(1) profile likelihood of the differenced series in R
- Citation
- Box, Jenkins and Reinsel, Time Series Analysis, exact AR(1) likelihood; statistician ruling on issue #10
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_MODELS_01.json
Settings compared
arima_order= [1, 1, 0]deterministic_term= "none"horizon= 3method= "forecast"model= "arima"response_column= "rw"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/forecast_rows/0/forecast | tolerance | 43.067665223298917 | 43.067665223066065 | 2.33E-10 | 11 | passed |
/forecast_rows/0/lower | tolerance | 40.925951321412548 | 40.925951321164035 | 2.49E-10 | 11 | passed |
/forecast_rows/0/upper | tolerance | 45.209379125185286 | 45.209379124968095 | 2.17E-10 | 11 | passed |
/forecast_rows/1/forecast | tolerance | 43.067789237580662 | 43.06778923735555 | 2.25E-10 | 11 | passed |
/forecast_rows/1/lower | tolerance | 40.063995866815354 | 40.06399586734604 | 5.31E-10 | 10 | passed |
/forecast_rows/1/upper | tolerance | 46.07158260834597 | 46.07158260736506 | 9.81E-10 | 10 | passed |
/forecast_rows/2/forecast | tolerance | 43.067787177845503 | 43.06778717762019 | 2.25E-10 | 11 | passed |
/forecast_rows/2/lower | tolerance | 39.398850034764692 | 39.3988500357651 | 1.00E-9 | 10 | passed |
/forecast_rows/2/upper | tolerance | 46.736724320926314 | 46.73672431947528 | 1.45E-9 | 10 | passed |
/parameters/0/term | exact | ar.L1 | ar.L1 | passed | ||
/parameters/0/estimate | tolerance | -0.016608854514315676 | -0.016608855032245465 | 5.18E-10 | 7 | passed |
/parameters/1/term | exact | sigma2 | sigma2 | passed | ||
/parameters/1/estimate | tolerance | 1.1940615926489369 | 1.1940615926664 | 1.75E-11 | 10 | passed |
/diagnostics/ljung_box_model_df | exact | 1 | 1 | 0.00E+2 | passed | |
/converged | exact | True | True | passed |
Convention
- Exact diffuse initialization of the integrated state (statistician ruling, issue #10): for complete data the likelihood of the differenced series.
- Certified by the closed-form profile likelihood of AR(1) on diff(rw), solved to machine precision; iterative-fit tier 1e-6.
- R stats::arima (approximate diffuse, kappa = 1e6) gave phi -0.016609067949116645, the reference before this method change.
- One ordinary difference and no drift.
Reference code
The lines of the reference script that produce this case's expected values.
203 out[["/parameters/0/term"]] <- exact("ar.L1", "The AR coefficient comes first without a constant.")
204 out[["/parameters/0/estimate"]] <- fit6(rw_phi, "Exact ML AR coefficient of the differenced series.")
205 out[["/parameters/1/term"]] <- exact("sigma2", "Innovation variance last.")
206 out[["/parameters/1/estimate"]] <- fit6(rw_sigma2, "Exact ML innovation variance of the differenced series.")
207 out[["/diagnostics/ljung_box_model_df"]] <- exact(1L, "Chapter 12: subtract the fitted AR and MA terms.")
208 out[["/converged"]] <- exact(TRUE, "The optimizer converges on these data.")
209 deferred <- list(defer("/parameters/0/standard_error", "The manual does not state how parameter standard errors are estimated (observed Hessian or outer product of gradients)."))
210 emit("STAT-TS-ARIMA-002", "timeSeriesArimaMenuItem", "ARIMA(1,1,0) without a deterministic term", "TS_MODELS_01",
211 list(method = "forecast", response_column = "rw", model = "arima", arima_order = list(1L, 1L, 0L),
212 deterministic_term = "none", horizon = 3L), out,
213 c("Exact diffuse initialization of the integrated state (statistician ruling, issue #10): for complete data the likelihood of the differenced series.",
214 "Certified by the closed-form profile likelihood of AR(1) on diff(rw), solved to machine precision; iterative-fit tier 1e-6.",
215 "R stats::arima (approximate diffuse, kappa = 1e6) gave phi -0.016609067949116645, the reference before this method change.",
216 "One ordinary difference and no drift."),
217 "Closed-form exact AR(1) profile likelihood of the differenced series in R",
218 "Box, Jenkins and Reinsel, Time Series Analysis, exact AR(1) likelihood; statistician ruling on issue #10", deferred = deferred)
First ordinary difference of the guided workflow
Case STAT-TS-DIFF-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::acf, stats::pacf and stats::diff documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, urca 1.3.4
- Reference script
- generators/r/timeseries_correlations.R · sha256 806e71b5ec8f6997
- Dataset
- reference_data/datasets/TS_CORRELATIONS_01.json
Settings compared
difference_order= 2maximum_lag= 5response_column= "value"task= "difference"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/sample_count | exact | 35 | 35 | 0.00E+2 | passed | |
/points/0/transformed | tolerance | 0.099935433003309981 | 0.09993543300330998 | 3.59E-19 | 17 | passed |
/points/1/transformed | tolerance | 0.26411968871941127 | 0.26411968871941127 | 1.90E-18 | 17 | passed |
Convention
- Manual chapter 12 guided differencing retains leading unavailable values as missing in a created column.
- Transformation arithmetic only: the reference differences once because the guided workflow selects order one on this series (selection checked by STAT-TS-DIFF-002 on a well-conditioned dataset; this deterministic construction makes the ADF regression near-singular, so lag counts and t-values here are not reproducibly defined across independent least-squares implementations).
- R re-reads the exported CSV before calculation.
Reference code
The lines of the reference script that produce this case's expected values.
180 first <- diff(series, differences = 1L)
181 emit("STAT-TS-DIFF-001", "First ordinary difference of the guided workflow", "timeSeriesStationarityMenuItem",
182 list(response_column = "value", task = "difference", difference_order = 2L,
183 maximum_lag = 5L),
184 list("/sample_count" = exact(length(first), "One leading row is unavailable after first differencing."),
185 "/points/0/transformed" = tol(first[1], "x2 - x1; owner 1e-9 tier."),
186 "/points/1/transformed" = tol(first[2], "x3 - x2; owner 1e-9 tier.")),
187 c("Manual chapter 12 guided differencing retains leading unavailable values as missing in a created column.",
188 "Transformation arithmetic only: the reference differences once because the guided workflow selects order one on this series (selection checked by STAT-TS-DIFF-002 on a well-conditioned dataset; this deterministic construction makes the ADF regression near-singular, so lag counts and t-values here are not reproducibly defined across independent least-squares implementations)."),
189 kind = "row_alignment", version = "2.0.0")
Guided selection of the first stationary difference order
Case STAT-TS-DIFF-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::acf, stats::pacf and stats::diff documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, urca 1.3.4
- Reference script
- generators/r/timeseries_correlations.R · sha256 806e71b5ec8f6997
- Dataset
- reference_data/datasets/TS_DIFF_GUIDED_01.json
Settings compared
difference_order= 2maximum_lag= 5response_column= "value"task= "difference"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/recommended_difference_order | exact | 1 | 1 | 0.00E+2 | passed | |
/difference_order | exact | 1 | 1 | 0.00E+2 | passed | |
/sample_count | exact | 59 | 59 | 0.00E+2 | passed | |
/stationarity/assessment | exact | difference_candidate | difference_candidate | passed | ||
/points/0/transformed | tolerance | -2.3107595600425452 | -2.3107595600425452 | 3.53E-17 | 16 | passed |
/differencing_stages/0/sample_count | exact | 60 | 60 | 0.00E+2 | passed | |
/differencing_stages/0/stationarity/assessment | exact | difference_candidate | difference_candidate | passed | ||
/differencing_stages/0/stationarity/adf_statistic | tolerance | -1.3980353474388854 | -1.3980353474388854 | 4.37E-17 | 16 | passed |
/differencing_stages/0/stationarity/adf_lags | exact | 1 | 1 | 0.00E+2 | passed | |
/differencing_stages/0/stationarity/kpss_statistic | tolerance | 0.93871602317142355 | 0.9387160231714238 | 2.25E-16 | 15 | passed |
/differencing_stages/0/stationarity/kpss_lags | exact | 4 | 4 | 0.00E+2 | passed | |
/differencing_stages/1/sample_count | exact | 59 | 59 | 0.00E+2 | passed | |
/differencing_stages/1/stationarity/assessment | exact | stationary | stationary | passed | ||
/differencing_stages/1/stationarity/adf_statistic | tolerance | -9.2680344058689013 | -9.268034405868905 | 3.51E-15 | 15 | passed |
/differencing_stages/1/stationarity/adf_lags | exact | 0 | 0 | 0.00E+2 | passed | |
/differencing_stages/1/stationarity/kpss_statistic | tolerance | 0.1242002652909675 | 0.12420026529096745 | 5.13E-17 | 15 | passed |
/differencing_stages/1/stationarity/kpss_lags | exact | 2 | 2 | 0.00E+2 | passed | |
/differencing_stages/2/sample_count | exact | 58 | 58 | 0.00E+2 | passed | |
/differencing_stages/2/stationarity/assessment | exact | stationary | stationary | passed | ||
/differencing_stages/2/stationarity/adf_statistic | tolerance | -4.4997292587027369 | -4.499729258702742 | 5.31E-15 | 14 | passed |
/differencing_stages/2/stationarity/adf_lags | exact | 6 | 6 | 0.00E+2 | passed | |
/differencing_stages/2/stationarity/kpss_statistic | tolerance | 0.12366352534019244 | 0.1236635253401922 | 2.36E-16 | 14 | passed |
/differencing_stages/2/stationarity/kpss_lags | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- Deterministic term: constant only, the workflow's default stationarity term (ADF regression 'c', KPSS level stationarity).
- ADF lag rule: AIC over 0..ceil(12*(n/100)^0.25) capped at n/2-2 on the common trimmed sample; final fit on the larger sample the selected lag allows.
- KPSS lag rule: automatic data-dependent Bartlett lag (Hobijn, Franes and Ooms 1998).
- Stage rule: the smallest ordinary order 0..2 whose ADF rejects a unit root and whose KPSS does not reject level stationarity at 5 percent; if none qualifies, no order is recommended and order zero is displayed.
- Stage p-values are not compared across implementations: response-surface and table versions of the published critical values differ in digits while agreeing on these decisions.
- Constructed with R seed 7: a random walk plus independent measurement noise is difference-stationary at order one.
- R re-reads the exported CSV before calculation.
Reference code
The lines of the reference script that produce this case's expected values.
177 # stage-selection oracle (STAT-TS-DIFF-002). The old version of this case
Original series selected: no differencing recommended
Case STAT-TS-DIFF-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::acf, stats::pacf and stats::diff documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, urca 1.3.4
- Reference script
- generators/r/timeseries_correlations.R · sha256 806e71b5ec8f6997
- Dataset
- reference_data/datasets/TS_DIFF_STATIONARY_01.json
Settings compared
difference_order= 2maximum_lag= 5response_column= "value"task= "stationarity"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/recommended_difference_order | exact | 0 | 0 | 0.00E+2 | passed | |
/difference_order | exact | 0 | 0 | 0.00E+2 | passed | |
/sample_count | exact | 60 | 60 | 0.00E+2 | passed | |
/stationarity/assessment | exact | stationary | stationary | passed | ||
/points/0/transformed | tolerance | 7.6512269413084955 | 7.6512269413084955 | 4.50E-17 | 17 | passed |
/differencing_stages/0/sample_count | exact | 60 | 60 | 0.00E+2 | passed | |
/differencing_stages/0/stationarity/assessment | exact | stationary | stationary | passed | ||
/differencing_stages/0/stationarity/adf_statistic | tolerance | -4.2581178142613352 | -4.258117814261334 | 9.11E-16 | 15 | passed |
/differencing_stages/0/stationarity/adf_lags | exact | 0 | 0 | 0.00E+2 | passed | |
/differencing_stages/0/stationarity/kpss_statistic | tolerance | 0.22351125819923898 | 0.22351125819923898 | 3.14E-18 | 16 | passed |
/differencing_stages/0/stationarity/kpss_lags | exact | 4 | 4 | 0.00E+2 | passed | |
/differencing_stages/1/sample_count | exact | 59 | 59 | 0.00E+2 | passed | |
/differencing_stages/1/stationarity/assessment | exact | stationary | stationary | passed | ||
/differencing_stages/1/stationarity/adf_statistic | tolerance | -5.215336522986993 | -5.2153365229869975 | 4.46E-15 | 15 | passed |
/differencing_stages/1/stationarity/adf_lags | exact | 2 | 2 | 0.00E+2 | passed | |
/differencing_stages/1/stationarity/kpss_statistic | tolerance | 0.11564275321050337 | 0.11564275321050344 | 6.50E-17 | 15 | passed |
/differencing_stages/1/stationarity/kpss_lags | exact | 1 | 1 | 0.00E+2 | passed | |
/differencing_stages/2/sample_count | exact | 58 | 58 | 0.00E+2 | passed | |
/differencing_stages/2/stationarity/assessment | exact | stationary | stationary | passed | ||
/differencing_stages/2/stationarity/adf_statistic | tolerance | -5.7917001119297398 | -5.791700111929755 | 1.51E-14 | 14 | passed |
/differencing_stages/2/stationarity/adf_lags | exact | 5 | 5 | 0.00E+2 | passed | |
/differencing_stages/2/stationarity/kpss_statistic | tolerance | 0.19368409351060104 | 0.19368409351060076 | 2.82E-16 | 14 | passed |
/differencing_stages/2/stationarity/kpss_lags | exact | 7 | 7 | 0.00E+2 | passed |
Convention
- Deterministic term: constant only, the workflow's default stationarity term (ADF regression 'c', KPSS level stationarity).
- ADF lag rule: AIC over 0..ceil(12*(n/100)^0.25) capped at n/2-2 on the common trimmed sample; final fit on the larger sample the selected lag allows.
- KPSS lag rule: automatic data-dependent Bartlett lag (Hobijn, Franes and Ooms 1998).
- Stage rule: the smallest ordinary order 0..2 whose ADF rejects a unit root and whose KPSS does not reject level stationarity at 5 percent; if none qualifies, no order is recommended and order zero is displayed.
- Stage p-values are not compared across implementations: response-surface and table versions of the published critical values differ in digits while agreeing on these decisions.
- Constructed with R seed 7: an AR(1) series with modest persistence is level-stationary at order zero.
- R re-reads the exported CSV before calculation.
Reference code
The lines of the reference script that produce this case's expected values.
226 dataset_id <- "TS_DIFF_STATIONARY_01"
227 set.seed(7L)
228 stationary_raw <- data.frame(value = as.numeric(stats::arima.sim(list(ar = 0.55), n = 60L, sd = 1.8)))
229 export_dataset(stationary_raw, dataset_id, "Constructed stationary AR(1) series",
230 "R stats::arima.sim with seed 7; manual chapter 12 guided differencing",
231 "Constructed validation data; no third-party license.", c(value = "Float64"))
232 stationary_series <- read_dataset(dataset_id)$value
233 stages_stationary <- list(
234 stage_outputs("/differencing_stages/0", stationary_series),
235 stage_outputs("/differencing_stages/1", diff(stationary_series, differences = 1L)),
236 stage_outputs("/differencing_stages/2", diff(stationary_series, differences = 2L))
237 )
238 selected_stationary <- Position(function(item) item$diagnostics$assessment == "stationary", stages_stationary) - 1L
239 outputs_stationary <- list(
240 "/recommended_difference_order" = exact(selected_stationary, "The original series is the first tested stationary stage."),
241 "/difference_order" = exact(selected_stationary, "Order zero keeps the original values as the transformed column."),
242 "/sample_count" = exact(length(stationary_series) - selected_stationary, "No observations are lost at order zero."),
243 "/stationarity/assessment" = label(stages_stationary[[1]]$diagnostics$assessment, "Source-level combined decision."),
244 "/points/0/transformed" = tol(stationary_series[1], "At order zero the transformed column equals the original series; owner 1e-9 tier.")
245 )
246 for (item in stages_stationary) outputs_stationary <- c(outputs_stationary, item$outputs)
247 emit("STAT-TS-DIFF-003", "Original series selected: no differencing recommended",
248 "timeSeriesStationarityMenuItem",
249 list(response_column = "value", task = "stationarity", difference_order = 2L, maximum_lag = 5L),
250 outputs_stationary,
251 c(selection_notes,
252 "Constructed with R seed 7: an AR(1) series with modest persistence is level-stationary at order zero."),
253 kind = "boundary")
No eligible differencing stage
Case STAT-TS-DIFF-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats
- Citation
- R stats::acf, stats::pacf and stats::diff documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, urca 1.3.4
- Reference script
- generators/r/timeseries_correlations.R · sha256 806e71b5ec8f6997
- Dataset
- reference_data/datasets/TS_DIFF_NONE_01.json
Settings compared
difference_order= 2maximum_lag= 5response_column= "value"task= "difference"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/recommended_difference_order | absent | None | passed | |||
/difference_order | exact | 0 | 0 | 0.00E+2 | passed | |
/sample_count | exact | 60 | 60 | 0.00E+2 | passed | |
/stationarity/assessment | exact | difference_candidate | difference_candidate | passed | ||
/points/0/transformed | tolerance | 2.2872471613405239 | 2.287247161340524 | 4.00E-17 | 16 | passed |
/differencing_stages/0/sample_count | exact | 60 | 60 | 0.00E+2 | passed | |
/differencing_stages/0/stationarity/assessment | exact | difference_candidate | difference_candidate | passed | ||
/differencing_stages/0/stationarity/adf_statistic | tolerance | 0.87499861657258604 | 0.874998616568669 | 3.92E-12 | 11 | passed |
/differencing_stages/0/stationarity/adf_lags | exact | 2 | 2 | 0.00E+2 | passed | |
/differencing_stages/0/stationarity/kpss_statistic | tolerance | 1.1740802583862742 | 1.1740802583862744 | 1.89E-16 | 15 | passed |
/differencing_stages/0/stationarity/kpss_lags | exact | 4 | 4 | 0.00E+2 | passed | |
/differencing_stages/1/sample_count | exact | 59 | 59 | 0.00E+2 | passed | |
/differencing_stages/1/stationarity/assessment | exact | difference_candidate | difference_candidate | passed | ||
/differencing_stages/1/stationarity/adf_statistic | tolerance | -0.272760508348389 | -0.27276050834828397 | 1.05E-13 | 12 | passed |
/differencing_stages/1/stationarity/adf_lags | exact | 1 | 1 | 0.00E+2 | passed | |
/differencing_stages/1/stationarity/kpss_statistic | tolerance | 1.2658448832524942 | 1.2658448832524942 | 2.40E-17 | 16 | passed |
/differencing_stages/1/stationarity/kpss_lags | exact | 4 | 4 | 0.00E+2 | passed | |
/differencing_stages/2/sample_count | exact | 58 | 58 | 0.00E+2 | passed | |
/differencing_stages/2/stationarity/assessment | exact | difference_candidate | difference_candidate | passed | ||
/differencing_stages/2/stationarity/adf_statistic | tolerance | -1.7700395407584297 | -1.7700395407584426 | 1.29E-14 | 14 | passed |
/differencing_stages/2/stationarity/adf_lags | exact | 0 | 0 | 0.00E+2 | passed | |
/differencing_stages/2/stationarity/kpss_statistic | tolerance | 0.85514162735189392 | 0.8551416273518939 | 1.83E-18 | 17 | passed |
/differencing_stages/2/stationarity/kpss_lags | exact | 4 | 4 | 0.00E+2 | passed |
Convention
- Deterministic term: constant only, the workflow's default stationarity term (ADF regression 'c', KPSS level stationarity).
- ADF lag rule: AIC over 0..ceil(12*(n/100)^0.25) capped at n/2-2 on the common trimmed sample; final fit on the larger sample the selected lag allows.
- KPSS lag rule: automatic data-dependent Bartlett lag (Hobijn, Franes and Ooms 1998).
- Stage rule: the smallest ordinary order 0..2 whose ADF rejects a unit root and whose KPSS does not reject level stationarity at 5 percent; if none qualifies, no order is recommended and order zero is displayed.
- Stage p-values are not compared across implementations: response-surface and table versions of the published critical values differ in digits while agreeing on these decisions.
- Constructed with R seed 7: a triple-integrated random walk stays non-stationary through ordinary difference order two.
- R re-reads the exported CSV before calculation.
Reference code
The lines of the reference script that produce this case's expected values.
257 dataset_id <- "TS_DIFF_NONE_01"
258 set.seed(7L)
259 none_raw <- data.frame(value = cumsum(cumsum(cumsum(stats::rnorm(60L, sd = 1.0)))))
260 export_dataset(none_raw, dataset_id,
261 "Constructed triple-integrated series; no tested order is stationary",
262 "R stats::rnorm with seed 7; manual chapter 12 guided differencing",
263 "Constructed validation data; no third-party license.", c(value = "Float64"))
264 none_series <- read_dataset(dataset_id)$value
265 stages_none <- list(
266 stage_outputs("/differencing_stages/0", none_series),
267 stage_outputs("/differencing_stages/1", diff(none_series, differences = 1L)),
268 stage_outputs("/differencing_stages/2", diff(none_series, differences = 2L))
269 )
270 eligible_none <- Filter(function(item) item$diagnostics$assessment == "stationary", stages_none)
271 stopifnot(length(eligible_none) == 0L)
272 outputs_none <- list(
273 "/recommended_difference_order" = absent("No order from zero through the configured maximum met the combined criteria."),
274 "/difference_order" = exact(0L, "Without a recommended order the workflow displays order zero."),
275 "/sample_count" = exact(length(none_series), "The transformed column is the original series at order zero."),
276 "/stationarity/assessment" = label(stages_none[[1]]$diagnostics$assessment, "Source-level combined decision."),
277 "/points/0/transformed" = tol(none_series[1], "At order zero the transformed column equals the original series; owner 1e-9 tier.")
278 )
279 for (item in stages_none) outputs_none <- c(outputs_none, item$outputs)
280 emit("STAT-TS-DIFF-004", "No eligible differencing stage", "timeSeriesStationarityMenuItem",
281 list(response_column = "value", task = "difference", difference_order = 2L, maximum_lag = 5L),
282 outputs_none,
283 c(selection_notes,
284 "Constructed with R seed 7: a triple-integrated random walk stays non-stationary through ordinary difference order two."),
285 kind = "boundary")
Regression with AR(1) errors on a future predictor path
Case STAT-TS-DYNREG-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::arima with xreg
- Citation
- R stats::arima documentation (xreg)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_MODELS_01.json
Settings compared
arima_order= [1, 0, 0]deterministic_term= "constant"features= [{"column": "x", "kind": "level"}]future_scenarios= [{"column": "x", "values": [4, 5, 6]}]method= "dynamic_regression"response_column= "dyn"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/parameters/1/estimate | tolerance | 1.5231114209650083 | 1.5231114179791074 | 2.99E-9 | 8 | passed |
/parameters/2/estimate | tolerance | 0.53151318556035609 | 0.5315131819024479 | 3.66E-9 | 8 | passed |
/parameters/0/estimate | tolerance | 0.65540066411472186 | 0.6554006804874501 | 1.64E-8 | 7 | passed |
/conditional_on_predictors | exact | True | True | passed | ||
/forecast_rows/0/forecast | tolerance | 6.3893092471712007 | 6.389309267524413 | 2.04E-8 | 8 | passed |
/forecast_rows/0/upper | tolerance | 8.4551868217767669 | 8.455186847223203 | 2.54E-8 | 8 | passed |
/forecast_rows/1/forecast | tolerance | 8.4287446671520794 | 8.428744684675587 | 1.75E-8 | 8 | passed |
/forecast_rows/1/upper | tolerance | 10.768305430567821 | 10.768305450312615 | 1.97E-8 | 8 | passed |
/forecast_rows/2/forecast | tolerance | 10.226289101615276 | 10.226289114347239 | 1.27E-8 | 8 | passed |
/forecast_rows/2/upper | tolerance | 12.637546199609259 | 12.637546212900395 | 1.33E-8 | 8 | passed |
Convention
- Chapter 12: the forecast is conditional on the explicit future predictor path.
- R's arima with xreg is the same regression with ARMA errors; the product's constant sits in the error equation.
Reference code
The lines of the reference script that produce this case's expected values.
253 emit("STAT-TS-DYNREG-001", "timeSeriesDynamicRegressionMenuItem", "Regression with AR(1) errors on a future predictor path",
254 "TS_MODELS_01",
255 list(method = "dynamic_regression", response_column = "dyn", features = list(list(column = "x", kind = "level")),
256 future_scenarios = list(list(column = "x", values = as.list(future_x))), arima_order = list(1L, 0L, 0L),
257 deterministic_term = "constant"),
258 dout, c("Chapter 12: the forecast is conditional on the explicit future predictor path.",
259 "R's arima with xreg is the same regression with ARMA errors; the product's constant sits in the error equation."),
260 "R stats::arima with xreg", "R stats::arima documentation (xreg)",
261 deferred = list(defer("/parameters/0/standard_error", "Standard-error method not stated in the manual.")))
Drift forecast with the manual's interval scale
Case STAT-TS-FC-DRIFT-001 · status: passed
Reference
- Evidence type
- R
- Source
- R forecast package
- Citation
- forecast::naive, snaive, meanf and rwf documentation; Hyndman and Athanasopoulos, Forecasting: Principles and Practice, section 5.5
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_MODELS_01.json
Settings compared
horizon= 3method= "forecast"model= "drift"response_column= "rw"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/forecast_rows/0/forecast | tolerance | 42.941567526908784 | 42.94156752690878 | 6.90E-15 | 15 | passed |
/forecast_rows/0/lower | tolerance | 40.779262130826083 | 40.779262130826076 | 6.68E-15 | 15 | passed |
/forecast_rows/0/upper | tolerance | 45.103872922991485 | 45.10387292299148 | 7.12E-15 | 15 | passed |
/forecast_rows/1/forecast | tolerance | 42.808003073455843 | 42.808003073455836 | 6.67E-15 | 15 | passed |
/forecast_rows/1/lower | tolerance | 39.724663746353755 | 39.72466374635375 | 6.81E-15 | 15 | passed |
/forecast_rows/1/upper | tolerance | 45.891342400557932 | 45.891342400557924 | 7.54E-15 | 15 | passed |
/forecast_rows/2/forecast | tolerance | 42.674438620002896 | 42.67443862000289 | 7.54E-15 | 15 | passed |
/forecast_rows/2/lower | tolerance | 38.867307109222374 | 38.86730710922237 | 7.47E-15 | 15 | passed |
/forecast_rows/2/upper | tolerance | 46.481570130783417 | 46.48157013078341 | 6.62E-15 | 15 | passed |
/forecast_rows/3 | absent | None | passed |
Convention
- Point forecasts follow the benchmark definitions; intervals are Gaussian.
- Chapter 12: drift fitted values are one-step forecasts plus the drift; interval scale sqrt(h(1 + h/(T-1))).
Reference code
The lines of the reference script that produce this case's expected values.
135 drift <- (y[T] - y[1]) / (T - 1)
136 bench("STAT-TS-FC-DRIFT-001", "Drift forecast with the manual's interval scale", "drift", "rw", list(),
137 y[T] + drift * 1:3, rwf(y, h = 3, drift = TRUE, level = 95),
138 "Chapter 12: drift fitted values are one-step forecasts plus the drift; interval scale sqrt(h(1 + h/(T-1))).")
Mean forecast
Case STAT-TS-FC-MEAN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R forecast package
- Citation
- forecast::naive, snaive, meanf and rwf documentation; Hyndman and Athanasopoulos, Forecasting: Principles and Practice, section 5.5
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_MODELS_01.json
Settings compared
horizon= 3method= "forecast"model= "mean"response_column= "rw"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/forecast_rows/0/forecast | tolerance | 47.499274509141905 | 47.499274509141905 | 2.98E-16 | 17 | passed |
/forecast_rows/0/lower | tolerance | 41.846914455112064 | 41.84691445511206 | 4.64E-16 | 16 | passed |
/forecast_rows/0/upper | tolerance | 53.151634563171747 | 53.15163456317175 | 6.10E-17 | 17 | passed |
/forecast_rows/1/forecast | tolerance | 47.499274509141905 | 47.499274509141905 | 2.98E-16 | 17 | passed |
/forecast_rows/1/lower | tolerance | 41.846914455112064 | 41.84691445511206 | 4.64E-16 | 16 | passed |
/forecast_rows/1/upper | tolerance | 53.151634563171747 | 53.15163456317175 | 6.10E-17 | 17 | passed |
/forecast_rows/2/forecast | tolerance | 47.499274509141905 | 47.499274509141905 | 2.98E-16 | 17 | passed |
/forecast_rows/2/lower | tolerance | 41.846914455112064 | 41.84691445511206 | 4.64E-16 | 16 | passed |
/forecast_rows/2/upper | tolerance | 53.151634563171747 | 53.15163456317175 | 6.10E-17 | 17 | passed |
/forecast_rows/3 | absent | None | passed |
Convention
- Point forecasts follow the benchmark definitions; intervals are Gaussian.
- Mean: the sample mean; forecast::meanf uses a t quantile, which the manual does not settle.
Reference code
The lines of the reference script that produce this case's expected values.
133 bench("STAT-TS-FC-MEAN-001", "Mean forecast", "mean", "rw", list(), rep(mean(y), 3),
134 meanf(y, h = 3, level = 95), "Mean: the sample mean; forecast::meanf uses a t quantile, which the manual does not settle.")
Naive forecast
Case STAT-TS-FC-NAIVE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R forecast package
- Citation
- forecast::naive, snaive, meanf and rwf documentation; Hyndman and Athanasopoulos, Forecasting: Principles and Practice, section 5.5
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_MODELS_01.json
Settings compared
horizon= 3method= "forecast"model= "naive"response_column= "rw"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/forecast_rows/0/forecast | tolerance | 43.075131980361732 | 43.075131980361725 | 7.03E-15 | 15 | passed |
/forecast_rows/0/lower | tolerance | 40.933113764963593 | 40.933113764963586 | 6.67E-15 | 15 | passed |
/forecast_rows/0/upper | tolerance | 45.217150195759871 | 45.217150195759864 | 7.39E-15 | 15 | passed |
/forecast_rows/1/forecast | tolerance | 43.075131980361732 | 43.075131980361725 | 7.03E-15 | 15 | passed |
/forecast_rows/1/lower | tolerance | 40.045860769295466 | 40.04586076929546 | 7.32E-15 | 15 | passed |
/forecast_rows/1/upper | tolerance | 46.104403191427998 | 46.10440319142799 | 6.74E-15 | 15 | passed |
/forecast_rows/2/forecast | tolerance | 43.075131980361732 | 43.075131980361725 | 7.03E-15 | 15 | passed |
/forecast_rows/2/lower | tolerance | 39.365047600554135 | 39.36504760055413 | 7.12E-15 | 15 | passed |
/forecast_rows/2/upper | tolerance | 46.785216360169329 | 46.78521636016932 | 6.94E-15 | 15 | passed |
/forecast_rows/3 | absent | None | passed |
Convention
- Point forecasts follow the benchmark definitions; intervals are Gaussian.
- Naive: the last value, interval scale sqrt(h).
Reference code
The lines of the reference script that produce this case's expected values.
130 y <- d$rw; T <- length(y)
131 bench("STAT-TS-FC-NAIVE-001", "Naive forecast", "naive", "rw", list(), rep(y[T], 3),
132 naive(y, h = 3, level = 95), "Naive: the last value, interval scale sqrt(h).")
Seasonal naive forecast
Case STAT-TS-FC-SNAIVE-001 · status: passed
Reference
- Evidence type
- R
- Source
- R forecast package
- Citation
- forecast::naive, snaive, meanf and rwf documentation; Hyndman and Athanasopoulos, Forecasting: Principles and Practice, section 5.5
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_MODELS_01.json
Settings compared
horizon= 3method= "forecast"model= "seasonal_naive"response_column= "s4"season_length= 4
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/forecast_rows/0/forecast | tolerance | 23.19662050196041 | 23.196620501960407 | 3.19E-15 | 15 | passed |
/forecast_rows/0/lower | tolerance | 21.786684833562269 | 21.786684833562266 | 3.40E-15 | 15 | passed |
/forecast_rows/0/upper | tolerance | 24.606556170358552 | 24.606556170358548 | 3.97E-15 | 15 | passed |
/forecast_rows/1/forecast | tolerance | 19.647155752552766 | 19.647155752552766 | 4.72E-16 | 16 | passed |
/forecast_rows/1/lower | tolerance | 18.237220084154625 | 18.237220084154625 | 2.55E-16 | 16 | passed |
/forecast_rows/1/upper | tolerance | 21.057091420950908 | 21.057091420950908 | 3.10E-16 | 16 | passed |
/forecast_rows/2/forecast | tolerance | 21.883655760063455 | 21.883655760063455 | 7.97E-17 | 17 | passed |
/forecast_rows/2/lower | tolerance | 20.473720091665314 | 20.473720091665314 | 2.97E-16 | 16 | passed |
/forecast_rows/2/upper | tolerance | 23.293591428461596 | 23.293591428461596 | 1.38E-16 | 17 | passed |
/forecast_rows/3 | absent | None | passed |
Convention
- Point forecasts follow the benchmark definitions; intervals are Gaussian.
- Seasonal naive: the value one season earlier.
Reference code
The lines of the reference script that produce this case's expected values.
139 z4 <- d$s4
140 bench("STAT-TS-FC-SNAIVE-001", "Seasonal naive forecast", "seasonal_naive", "s4", list(season_length = 4L),
141 z4[T - 4 + 1:3], snaive(ts(z4, frequency = 4), h = 3, level = 95),
142 "Seasonal naive: the value one season earlier.")
Gaussian GARCH(1,1) with a constant mean
Case STAT-TS-GARCH-001 · status: passed
Reference
- Evidence type
- R
- Source
- Independent R implementation of the arch 8.0.0 GARCH(1,1) objective
- Citation
- arch GARCH.backcast documentation (Sheppard); Bollerslev (1986)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_LONG_01.json
Settings compared
columns= ["ret"]distribution= "normal"garch_p= 1garch_q= 1horizon= 1kind= "garch"mean= "constant"method= "advanced"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/parameters/0/estimate | tolerance | 0.043544357266978265 | 0.04354435498444453 | 2.28E-9 | 7 | passed |
/parameters/1/estimate | tolerance | 0.10187745710710716 | 0.10187745536155024 | 1.75E-9 | 7 | passed |
/parameters/2/estimate | tolerance | 0.16512524492104785 | 0.16512523841265347 | 6.51E-9 | 7 | passed |
/parameters/3/estimate | tolerance | 0.71856068841734833 | 0.7185606990158341 | 1.06E-8 | 7 | passed |
/persistence | tolerance | 0.88368593333839618 | 0.8836859374284876 | 4.09E-9 | 8 | passed |
/conditional_volatility/0 | tolerance | 1.0006912394431866 | 1.0006912406512287 | 1.21E-9 | 8 | passed |
/conditional_volatility/299 | tolerance | 0.69986242585321445 | 0.6998624323662838 | 6.51E-9 | 8 | passed |
/forecast_volatility/0 | tolerance | 0.9170059715406792 | 0.9170059705331532 | 1.01E-9 | 8 | passed |
Convention
- Iterative fit, tier 1e-6.
- Statistician ruling, issue #9: the arch weighted backcast is retained; this reference reproduces its objective (rescale, fixed 0.94-weighted backcast over min(75, n) residuals, sigma_1^2 = omega + (alpha + beta) b, Gaussian likelihood) independently in R.
- Backcast b = 1.017901797070679; maximized log L = -784.71559679584777.
- Until 2026-09-25 the reference was rugarch, whose variance start is the mean squared residual.
Reference code
The lines of the reference script that produce this case's expected values.
346 ga <- arch_garch11(l$ret)
347 stopifnot(abs(ga$backcast - 1.0179017970706792) < 1e-12)
348 emit("STAT-TS-GARCH-001", "timeSeriesGarchMenuItem", "Gaussian GARCH(1,1) with a constant mean", "TS_LONG_01",
349 list(method = "advanced", kind = "garch", columns = list("ret"), distribution = "normal", mean = "constant",
350 garch_p = 1L, garch_q = 1L, horizon = 1L),
351 list("/parameters/0/estimate" = fit6(ga$mu, "Constant mean."),
352 "/parameters/1/estimate" = fit6(ga$omega, "omega, in squared return units."),
353 "/parameters/2/estimate" = fit6(ga$alpha, "alpha1."),
354 "/parameters/3/estimate" = fit6(ga$beta, "beta1."),
355 "/persistence" = fit6(ga$alpha + ga$beta, "alpha + beta."),
356 "/conditional_volatility/0" = fit6(ga$volatility[1], "sqrt(omega + (alpha + beta) b): the backcast start."),
357 "/conditional_volatility/299" = fit6(ga$volatility[300], "Recursion at row 300."),
358 "/forecast_volatility/0" = fit6(ga$forecast_vol, "One-step conditional volatility.")),
359 c("Iterative fit, tier 1e-6.",
360 "Statistician ruling, issue #9: the arch weighted backcast is retained; this reference reproduces its objective (rescale, fixed 0.94-weighted backcast over min(75, n) residuals, sigma_1^2 = omega + (alpha + beta) b, Gaussian likelihood) independently in R.",
361 sprintf("Backcast b = %.17g; maximized log L = %.17g.", ga$backcast, ga$loglik),
362 "Until 2026-09-25 the reference was rugarch, whose variance start is the mean squared residual."),
363 "Independent R implementation of the arch 8.0.0 GARCH(1,1) objective",
364 "arch GARCH.backcast documentation (Sheppard); Bollerslev (1986)")
Johansen trace statistics for a cointegrated pair
Case STAT-TS-JOHANSEN-001 · status: passed
Reference
- Evidence type
- R
- Source
- R urca package
- Citation
- urca::ca.jo documentation; Johansen (1988)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_SYSTEM_01.json
Settings compared
cointegration_rank= 1columns= ["c1", "c2"]deterministic= "constant"horizon= 2kind= "var_vecm"lag_order= 2method= "advanced"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/johansen_trace/0/null_rank | exact | 0 | 0 | 0.00E+2 | passed | |
/johansen_trace/0/statistic | tolerance | 53.775946118181587 | 53.775946118222386 | 4.08E-11 | 12 | passed |
/johansen_trace/1/statistic | tolerance | 3.864595747746018 | 3.8645957477461317 | 1.14E-13 | 13 | passed |
/johansen_trace/0/reject_5pct | exact | True | True | passed |
Convention
- K = 2 level lags; unrestricted constant outside the cointegration relation (ca.jo ecdet = 'none').
Reference code
The lines of the reference script that produce this case's expected values.
296 cj <- ca.jo(data.frame(c1 = s$c1, c2 = s$c2), type = "trace", ecdet = "none", K = 2, spec = "transitory")
297 trace <- rev(cj@teststat) # ca.jo lists r <= 1 before r = 0
298 emit("STAT-TS-JOHANSEN-001", "timeSeriesVarVecmMenuItem", "Johansen trace statistics for a cointegrated pair", "TS_SYSTEM_01",
299 list(method = "advanced", kind = "var_vecm", columns = list("c1", "c2"), lag_order = 2L, cointegration_rank = 1L,
300 horizon = 2L, deterministic = "constant"),
301 list("/johansen_trace/0/null_rank" = exact(0L, "Null r = 0 first."),
302 "/johansen_trace/0/statistic" = num(trace[1], "urca::ca.jo trace statistic, r = 0."),
303 "/johansen_trace/1/statistic" = num(trace[2], "urca::ca.jo trace statistic, r <= 1."),
304 "/johansen_trace/0/reject_5pct" = exact(unname(cj@teststat[2] > cj@cval[2, "5pct"]), "The pair is cointegrated.")),
305 c("K = 2 level lags; unrestricted constant outside the cointegration relation (ca.jo ecdet = 'none')."),
306 "R urca package", "urca::ca.jo documentation; Johansen (1988)")
A random walk is a differencing candidate
Case STAT-TS-STATIONARITY-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic
- Citation
- Dickey and Fuller (1979); Kwiatkowski et al. (1992)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_STATIONARITY_01.json
Settings compared
response_column= "walk"task= "stationarity"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stationarity/assessment | exact | difference_candidate | difference_candidate | passed |
Convention
- Chapter 12: a differencing candidate is labelled only when ADF does not reject and KPSS rejects at 5 percent.
- Verdict only: the manual does not define the lag selection, so the statistics themselves are not asserted; the verdict is checked to hold at every lag choice.
- Until 2026-09-25 this case used TS_LONG_01's drifting level, whose correct verdict is inconclusive.
Reference code
The lines of the reference script that produce this case's expected values.
410 emit("STAT-TS-STATIONARITY-001", "timeSeriesStationarityMenuItem", "A random walk is a differencing candidate", "TS_STATIONARITY_01",
411 list(response_column = "walk", task = "stationarity"),
412 list("/stationarity/assessment" = exact("difference_candidate", "ADF cannot reject a unit root and KPSS rejects stationarity for a 600-step driftless random walk, at every ADF lag 0-12 and both KPSS lag rules.")),
413 c("Chapter 12: a differencing candidate is labelled only when ADF does not reject and KPSS rejects at 5 percent.",
414 "Verdict only: the manual does not define the lag selection, so the statistics themselves are not asserted; the verdict is checked to hold at every lag choice.",
415 "Until 2026-09-25 this case used TS_LONG_01's drifting level, whose correct verdict is inconclusive."),
416 "Analytic", "Dickey and Fuller (1979); Kwiatkowski et al. (1992)", oracle_class = "analytic")
White noise is stationary
Case STAT-TS-STATIONARITY-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic
- Citation
- Dickey and Fuller (1979); Kwiatkowski et al. (1992)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_STATIONARITY_01.json
Settings compared
response_column= "noise"task= "stationarity"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/stationarity/assessment | exact | stationary | stationary | passed |
Convention
- Chapter 12 combined criterion; verdict only, checked at every lag choice.
- Until 2026-09-25 this case used GARCH(1,1) returns, which KPSS legitimately rejects.
Reference code
The lines of the reference script that produce this case's expected values.
417 emit("STAT-TS-STATIONARITY-002", "timeSeriesStationarityMenuItem", "White noise is stationary", "TS_STATIONARITY_01",
418 list(response_column = "noise", task = "stationarity"),
419 list("/stationarity/assessment" = exact("stationary", "iid noise rejects a unit root and keeps level stationarity at every ADF lag 0-12 and both KPSS lag rules.")),
420 c("Chapter 12 combined criterion; verdict only, checked at every lag choice.",
421 "Until 2026-09-25 this case used GARCH(1,1) returns, which KPSS legitimately rejects."),
422 "Analytic", "Dickey and Fuller (1979); Kwiatkowski et al. (1992)", oracle_class = "analytic")
Linear trend with a two-step extrapolation
Case STAT-TS-TREND-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::nls on t = 1..n
- Citation
- R Core Team, stats package help: lm, nls, summary.lm, vcov
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_trend.R · sha256 d3ad3e09dcb6f002
- Dataset
- reference_data/datasets/TS_TREND_01.json
Settings compared
horizon= 2model= "linear"response= "y_lin"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/parameters/0/estimate | tolerance | 4.7912173913043397 | 4.791217391304356 | 1.59E-14 | 14 | passed |
/parameters/0/standard_error | tolerance | 0.25486041983066998 | 0.25486041983066965 | 3.31E-16 | 14 | passed |
/parameters/1/estimate | tolerance | 0.81022260869565255 | 0.8102226086956514 | 1.11E-15 | 14 | passed |
/parameters/1/standard_error | tolerance | 0.017836513834761154 | 0.017836513834761134 | 2.05E-17 | 14 | passed |
/mae | tolerance | 0.48140724637681231 | 0.4814072463768119 | 3.84E-16 | 15 | passed |
/mse | tolerance | 0.33537387550724745 | 0.3353738755072467 | 7.73E-16 | 14 | passed |
/rmse | tolerance | 0.57911473432062444 | 0.5791147343206238 | 6.70E-16 | 14 | passed |
/mape | tolerance | 3.6932068578753503 | 3.693206857875348 | 2.22E-15 | 15 | passed |
/fitted_count | exact | 24 | 24 | 0.00E+2 | passed | |
/series_length | exact | 24 | 24 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/extrapolation/0/0 | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/extrapolation/0/1 | tolerance | 25.046782608695654 | 25.046782608695644 | 1.05E-14 | 15 | passed |
/extrapolation/1/1 | tolerance | 25.857005217391308 | 25.85700521739129 | 1.81E-14 | 15 | passed |
Convention
- lm(y ~ t): ordinary least squares with intercept; standard errors from summary.lm (residual df n - 2).
- docs/manual/chapters/102-deterministic-trends.tex:8: linear and quadratic models use original-scale least squares.
- docs/manual/chapters/102-deterministic-trends.tex:31-32: extrapolation extends the deterministic curve without prediction intervals.
- Expected computed from the re-read TS_TREND_01 CSV with positions t = 1..n in table order.
- docs/manual/chapters/102-deterministic-trends.tex:3-6: positions t = 1..n in table order; excluded or missing responses retain their positions.
- docs/manual/chapters/102-deterministic-trends.tex:23-24: MAE, MSE, RMSE and MAPE describe in-sample original-scale errors.
Reference code
The lines of the reference script that produce this case's expected values.
24 emit <- function(id, title, config, outputs, notes, kind = "nominal", excluded = integer()) {
25 write_expected(family, id, list(
26 schema_version = "2.0.0", case_id = id, outputs = outputs,
27 expected_error = NULL, deferred_outputs = list(), generator_run = run))
28 write_case(family, id, list(
29 schema_version = "2.0.0", case_id = id, version = "1.0.0", family = family, entry_point = ep,
30 menu_items = list("trendAnalysisMenuItem"), title = title, case_kind = kind,
31 dataset = list(path = "reference_data/datasets/TS_TREND_01.json", sha256 = ""),
32 excluded_rows = as.list(as.integer(excluded)), configuration = config, "repeat" = 1L,
33 expected = list(path = paste0("reference_data/expected/", family, "/", id, ".json"), sha256 = ""),
34 oracle = list(oracle_class = "independent_implementation",
35 source = "R stats::lm and stats::nls on t = 1..n",
36 citation = "R Core Team, stats package help: lm, nls, summary.lm, vcov",
37 generator = list(path = generator, sha256 = ""), independent = TRUE,
38 convention_notes = as.list(c(notes,
39 "Expected computed from the re-read TS_TREND_01 CSV with positions t = 1..n in table order.",
40 "docs/manual/chapters/102-deterministic-trends.tex:3-6: positions t = 1..n in table order; excluded or missing responses retain their positions.",
41 "docs/manual/chapters/102-deterministic-trends.tex:23-24: MAE, MSE, RMSE and MAPE describe in-sample original-scale errors."))),
42 supported = TRUE, unsupported_reason = NULL, requirement_ids = list("REQ-STAT-TS-TREND-001"),
43 risk_ids = list("RISK-REFERENCE-001"), review_reference = NULL))
Quadratic trend
Case STAT-TS-TREND-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::nls on t = 1..n
- Citation
- R Core Team, stats package help: lm, nls, summary.lm, vcov
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_trend.R · sha256 d3ad3e09dcb6f002
- Dataset
- reference_data/datasets/TS_TREND_01.json
Settings compared
horizon= 0model= "quadratic"response= "y_quad"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/parameters/0/estimate | tolerance | 19.251281126482219 | 19.251281126482127 | 9.24E-14 | 14 | passed |
/parameters/0/standard_error | tolerance | 0.62222146424980895 | 0.6222214642498074 | 1.55E-15 | 14 | passed |
/parameters/1/estimate | tolerance | -1.4560429355427191 | -1.456042935542708 | 1.11E-14 | 14 | passed |
/parameters/1/standard_error | tolerance | 0.11467981178829359 | 0.11467981178829334 | 2.50E-16 | 14 | passed |
/parameters/2/estimate | tolerance | 0.11960757829127397 | 0.11960757829127333 | 6.39E-16 | 14 | passed |
/parameters/2/standard_error | tolerance | 0.0044533470601221406 | 0.004453347060122132 | 8.64E-18 | 14 | passed |
/mae | tolerance | 0.72725181286105234 | 0.7272518128610574 | 5.11E-15 | 14 | passed |
/mse | tolerance | 0.76099840628756288 | 0.760998406287562 | 8.90E-16 | 14 | passed |
/rmse | tolerance | 0.87235222604608675 | 0.8723522260460863 | 4.40E-16 | 15 | passed |
/mape | tolerance | 3.5980398670673472 | 3.598039867067341 | 6.18E-15 | 14 | passed |
/fitted_count | exact | 24 | 24 | 0.00E+2 | passed | |
/series_length | exact | 24 | 24 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- lm(y ~ t + I(t^2)): ordinary least squares on 1, t, t^2; standard errors with residual df n - 3.
- docs/manual/chapters/102-deterministic-trends.tex:8: linear and quadratic models use original-scale least squares.
- Expected computed from the re-read TS_TREND_01 CSV with positions t = 1..n in table order.
- docs/manual/chapters/102-deterministic-trends.tex:3-6: positions t = 1..n in table order; excluded or missing responses retain their positions.
- docs/manual/chapters/102-deterministic-trends.tex:23-24: MAE, MSE, RMSE and MAPE describe in-sample original-scale errors.
Reference code
The lines of the reference script that produce this case's expected values.
100 fit <- stats::lm(y ~ tt + I(tt^2), data = data.frame(y = d$y_quad, tt = tt))
101 cf <- coef(fit); se <- sqrt(diag(vcov(fit)))
102 emit("STAT-TS-TREND-002", "Quadratic trend", list(response = "y_quad", model = "quadratic", horizon = 0L),
103 c(param(0L, cf[[1]], se[[1]], "b0"), param(1L, cf[[2]], se[[2]], "b1"), param(2L, cf[[3]], se[[3]], "b2"),
104 accuracy(d$y_quad, fitted(fit)), counts(nrow(d), nrow(d))),
105 c("lm(y ~ t + I(t^2)): ordinary least squares on 1, t, t^2; standard errors with residual df n - 3.",
106 "docs/manual/chapters/102-deterministic-trends.tex:8: linear and quadratic models use original-scale least squares."),
107 kind = "axis_coverage")
Exponential growth, back-transformed log-linear fit
Case STAT-TS-TREND-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::nls on t = 1..n
- Citation
- R Core Team, stats package help: lm, nls, summary.lm, vcov
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_trend.R · sha256 d3ad3e09dcb6f002
- Dataset
- reference_data/datasets/TS_TREND_01.json
Settings compared
horizon= 3model= "exponential"response= "y_exp"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/parameters/0/estimate | tolerance | 2.9288938885416855 | 2.9288938885416878 | 2.25E-15 | 15 | passed |
/parameters/0/standard_error | tolerance | 0.06688188199460593 | 0.06688188199460604 | 1.11E-16 | 14 | passed |
/parameters/1/estimate | tolerance | 0.090372673520623698 | 0.09037267352062357 | 1.25E-16 | 14 | passed |
/parameters/1/standard_error | tolerance | 0.0015981311927515244 | 0.0015981311927515264 | 1.96E-18 | 14 | passed |
/mae | tolerance | 0.44386060090843205 | 0.4438606009084263 | 5.78E-15 | 13 | passed |
/mse | tolerance | 0.36563730754269957 | 0.3656373075426916 | 7.99E-15 | 13 | passed |
/rmse | tolerance | 0.60467950812202953 | 0.6046795081220229 | 6.66E-15 | 13 | passed |
/mape | tolerance | 4.3640828220035193 | 4.364082822003492 | 2.76E-14 | 14 | passed |
/fitted_count | exact | 24 | 24 | 0.00E+2 | passed | |
/series_length | exact | 24 | 24 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/extrapolation/2/1 | tolerance | 33.6054086038313 | 33.605408603831215 | 8.50E-14 | 14 | passed |
Convention
- lm(log(y) ~ t); c = exp(a) and d = b; SE(c) = exp(a) SE(a) (delta method) and SE(d) = SE(b); no bias adjustment.
- Accuracy measures use the back-transformed fitted values c exp(d t) on the original scale.
- docs/manual/chapters/102-deterministic-trends.tex:8-10: log-linear exponential growth fits log y = a + b t and displays e^a (e^b)^t, a median trend without bias adjustment.
- Expected computed from the re-read TS_TREND_01 CSV with positions t = 1..n in table order.
- docs/manual/chapters/102-deterministic-trends.tex:3-6: positions t = 1..n in table order; excluded or missing responses retain their positions.
- docs/manual/chapters/102-deterministic-trends.tex:23-24: MAE, MSE, RMSE and MAPE describe in-sample original-scale errors.
Reference code
The lines of the reference script that produce this case's expected values.
110 fit <- stats::lm(ly ~ tt, data = data.frame(ly = log(d$y_exp), tt = tt))
111 cf <- coef(fit); se <- sqrt(diag(vcov(fit)))
112 c_hat <- exp(cf[[1]]); d_hat <- cf[[2]]
113 fitted_exp <- c_hat * exp(d_hat * tt)
114 emit("STAT-TS-TREND-003", "Exponential growth, back-transformed log-linear fit",
115 list(response = "y_exp", model = "exponential", horizon = 3L),
116 c(param(0L, c_hat, c_hat * se[[1]], "c = exp(a)"), param(1L, d_hat, se[[2]], "d = b"),
117 accuracy(d$y_exp, fitted_exp), counts(nrow(d), nrow(d)),
118 list("/extrapolation/2/1" = num(c_hat * exp(d_hat * (nrow(d) + 3)), "c exp(d (n + 3)) from the log-linear fit."))),
119 c("lm(log(y) ~ t); c = exp(a) and d = b; SE(c) = exp(a) SE(a) (delta method) and SE(d) = SE(b); no bias adjustment.",
120 "Accuracy measures use the back-transformed fitted values c exp(d t) on the original scale.",
121 "docs/manual/chapters/102-deterministic-trends.tex:8-10: log-linear exponential growth fits log y = a + b t and displays e^a (e^b)^t, a median trend without bias adjustment."),
122 kind = "axis_coverage")
Exponential growth, original-scale least squares
Case STAT-TS-TREND-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::nls on t = 1..n
- Citation
- R Core Team, stats package help: lm, nls, summary.lm, vcov
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_trend.R · sha256 d3ad3e09dcb6f002
- Dataset
- reference_data/datasets/TS_TREND_01.json
Settings compared
horizon= 0model= "exponential_nls"response= "y_exp"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/parameters/0/estimate | tolerance | 3.1154563618840663 | 3.1154563619352764 | 5.12E-11 | 10 | passed |
/parameters/0/standard_error | tolerance | 0.11512841796428724 | 0.11512841899601717 | 1.03E-9 | 8 | passed |
/parameters/1/estimate | tolerance | 0.086641585981250505 | 0.08664158598124228 | 8.23E-15 | 13 | passed |
/parameters/1/standard_error | tolerance | 0.0018746634655175635 | 0.0018746635106843775 | 4.52E-11 | 7 | passed |
/mae | tolerance | 0.40536583884842026 | 0.405365838850334 | 1.91E-12 | 11 | passed |
/mse | tolerance | 0.29627688538792812 | 0.2962768853879279 | 2.18E-16 | 15 | passed |
/rmse | tolerance | 0.54431322360193324 | 0.544313223601933 | 2.24E-16 | 15 | passed |
/mape | tolerance | 4.5004262267992594 | 4.500426227010113 | 2.11E-10 | 10 | passed |
/fitted_count | exact | 24 | 24 | 0.00E+2 | passed | |
/series_length | exact | 24 | 24 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed |
Convention
- nls(y ~ c exp(d t)) Gauss-Newton from the log-linear start exp(a), b; tolerance 1e-6 (1e-5 for the standard errors) because both programs stop at an iterative optimum.
- docs/manual/chapters/102-deterministic-trends.tex:11-12: the original-scale exponential minimizes squared response residuals for y = c e^(d t).
- Expected computed from the re-read TS_TREND_01 CSV with positions t = 1..n in table order.
- docs/manual/chapters/102-deterministic-trends.tex:3-6: positions t = 1..n in table order; excluded or missing responses retain their positions.
- docs/manual/chapters/102-deterministic-trends.tex:23-24: MAE, MSE, RMSE and MAPE describe in-sample original-scale errors.
Reference code
The lines of the reference script that produce this case's expected values.
125 start_exp <- list(c = exp(cf[[1]]), d = cf[[2]])
126 fit <- stats::nls(y ~ c * exp(d * tt), data = data.frame(y = d$y_exp, tt = tt), start = start_exp,
127 control = stats::nls.control(maxiter = 1000, tol = 1e-8, minFactor = 1e-14))
128 cf4 <- coef(fit); se4 <- sqrt(diag(vcov(fit)))
129 emit("STAT-TS-TREND-004", "Exponential growth, original-scale least squares",
130 list(response = "y_exp", model = "exponential_nls", horizon = 0L),
131 c(param(0L, cf4[["c"]], se4[["c"]], "c", "1e-6", "1e-5"), param(1L, cf4[["d"]], se4[["d"]], "d", "1e-6", "1e-5"),
132 accuracy(d$y_exp, fitted(fit), "1e-6"), counts(nrow(d), nrow(d))),
133 c("nls(y ~ c exp(d t)) Gauss-Newton from the log-linear start exp(a), b; tolerance 1e-6 (1e-5 for the standard errors) because both programs stop at an iterative optimum.",
134 "docs/manual/chapters/102-deterministic-trends.tex:11-12: the original-scale exponential minimizes squared response residuals for y = c e^(d t)."),
135 kind = "axis_coverage")
S-curve three-parameter logistic trend
Case STAT-TS-TREND-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::nls on t = 1..n
- Citation
- R Core Team, stats package help: lm, nls, summary.lm, vcov
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_trend.R · sha256 d3ad3e09dcb6f002
- Dataset
- reference_data/datasets/TS_TREND_01.json
Settings compared
horizon= 1model= "scurve"response= "y_logis"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/parameters/0/estimate | tolerance | 100.38748466626321 | 100.38748466984309 | 3.58E-9 | 10 | passed |
/parameters/0/standard_error | tolerance | 0.52386368467103783 | 0.5238636834583312 | 1.21E-9 | 8 | passed |
/parameters/1/estimate | tolerance | 19.388946585598784 | 19.38894657572558 | 9.87E-9 | 9 | passed |
/parameters/1/standard_error | tolerance | 1.0736297574721549 | 1.0736296967755101 | 6.07E-8 | 7 | passed |
/parameters/2/estimate | tolerance | 0.34204345156451549 | 0.3420434515040217 | 6.05E-11 | 9 | passed |
/parameters/2/standard_error | tolerance | 0.0069087579369043811 | 0.00690875754706773 | 3.90E-10 | 7 | passed |
/mae | tolerance | 0.89248440406170038 | 0.8924844045978025 | 5.36E-10 | 9 | passed |
/mse | tolerance | 1.3058701730210744 | 1.3058701730210729 | 1.51E-15 | 14 | passed |
/rmse | tolerance | 1.1427467667952838 | 1.142746766795283 | 7.13E-16 | 15 | passed |
/mape | tolerance | 2.4560638138336426 | 2.4560638138794917 | 4.58E-11 | 10 | passed |
/fitted_count | exact | 24 | 24 | 0.00E+2 | passed | |
/series_length | exact | 24 | 24 | 0.00E+2 | passed | |
/missing_count | exact | 0 | 0 | 0.00E+2 | passed | |
/excluded_count | exact | 0 | 0 | 0.00E+2 | passed | |
/extrapolation/0/1 | tolerance | 100.0125813678995 | 100.01258137109134 | 3.19E-9 | 10 | passed |
/pearl_reed/2/estimate | tolerance | 19.388946585598784 | 19.38894657572558 | 9.87E-9 | 9 | passed |
/pearl_reed/3/estimate | tolerance | 0.71031733963890453 | 0.7103173396818743 | 4.30E-11 | 10 | passed |
Convention
- nls(y ~ K / (1 + A exp(-r t))) Gauss-Newton from the linearized start K0 = 1.05 max(y), log(K0/y - 1) ~ t; tolerance 1e-6 (1e-5 for the standard errors).
- SE(K)/K = 0.005218 from vcov(nls), below the 0.25 screen, so the one-step extrapolation is expected.
- docs/manual/chapters/102-deterministic-trends.tex:15-20: logistic S-curve y = K/(1 + A e^(-rt)); extrapolation withheld when asymptote relative SE exceeds 0.25.
- Expected computed from the re-read TS_TREND_01 CSV with positions t = 1..n in table order.
- docs/manual/chapters/102-deterministic-trends.tex:3-6: positions t = 1..n in table order; excluded or missing responses retain their positions.
- docs/manual/chapters/102-deterministic-trends.tex:23-24: MAE, MSE, RMSE and MAPE describe in-sample original-scale errors.
Reference code
The lines of the reference script that produce this case's expected values.
138 k0 <- 1.05 * max(d$y_logis)
139 z <- log(k0 / d$y_logis - 1)
140 lin <- coef(stats::lm(z ~ tt))
141 start_s <- list(K = k0, A = exp(lin[[1]]), r = -lin[[2]])
142 fit <- stats::nls(y ~ K / (1 + A * exp(-r * tt)), data = data.frame(y = d$y_logis, tt = tt), start = start_s,
143 control = stats::nls.control(maxiter = 1000, tol = 1e-8, minFactor = 1e-14))
144 cf5 <- coef(fit); se5 <- sqrt(diag(vcov(fit)))
145 relative_k <- se5[["K"]] / cf5[["K"]]
146 if (relative_k > 0.25) stop("S-curve asymptote is weakly determined; choose different data")
147 outputs5 <- c(param(0L, cf5[["K"]], se5[["K"]], "K", "1e-6", "1e-5"),
148 param(1L, cf5[["A"]], se5[["A"]], "A", "1e-6", "1e-5"),
149 param(2L, cf5[["r"]], se5[["r"]], "r", "1e-6", "1e-5"),
150 accuracy(d$y_logis, fitted(fit), "1e-6"), counts(nrow(d), nrow(d)),
151 list("/extrapolation/0/1" = fit6(cf5[["K"]] / (1 + cf5[["A"]] * exp(-cf5[["r"]] * (nrow(d) + 1))),
152 "K / (1 + A exp(-r (n + 1))); SE(K)/K below 0.25 so the extrapolation is supplied."),
153 "/pearl_reed/2/estimate" = fit6(cf5[["A"]], "Pearl-Reed beta1 = A."),
154 "/pearl_reed/3/estimate" = fit6(exp(-cf5[["r"]]), "Pearl-Reed beta2 = exp(-r).")))
155 emit("STAT-TS-TREND-005", "S-curve three-parameter logistic trend",
156 list(response = "y_logis", model = "scurve", horizon = 1L), outputs5,
157 c("nls(y ~ K / (1 + A exp(-r t))) Gauss-Newton from the linearized start K0 = 1.05 max(y), log(K0/y - 1) ~ t; tolerance 1e-6 (1e-5 for the standard errors).",
158 sprintf("SE(K)/K = %.4g from vcov(nls), below the 0.25 screen, so the one-step extrapolation is expected.", relative_k),
159 "docs/manual/chapters/102-deterministic-trends.tex:15-20: logistic S-curve y = K/(1 + A e^(-rt)); extrapolation withheld when asymptote relative SE exceeds 0.25."),
160 kind = "axis_coverage")
Linear trend with a missing response and an excluded row
Case STAT-TS-TREND-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::lm and stats::nls on t = 1..n
- Citation
- R Core Team, stats package help: lm, nls, summary.lm, vcov
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_trend.R · sha256 d3ad3e09dcb6f002
- Dataset
- reference_data/datasets/TS_TREND_01.json
Settings compared
horizon= 1model= "linear"response= "y_gap"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/parameters/0/estimate | tolerance | 4.7741227585085104 | 4.774122758508526 | 1.60E-14 | 14 | passed |
/parameters/0/standard_error | tolerance | 0.27132977007172421 | 0.27132977007172376 | 4.46E-16 | 14 | passed |
/parameters/1/estimate | tolerance | 0.80996547798153973 | 0.8099654779815396 | 1.13E-16 | 15 | passed |
/parameters/1/standard_error | tolerance | 0.018549691363207239 | 0.018549691363207207 | 3.15E-17 | 14 | passed |
/mae | tolerance | 0.49511746136188106 | 0.4951174613618793 | 1.77E-15 | 14 | passed |
/mse | tolerance | 0.34967897456778246 | 0.3496789745677814 | 1.05E-15 | 14 | passed |
/rmse | tolerance | 0.59133660005768496 | 0.5913366000576841 | 8.90E-16 | 14 | passed |
/mape | tolerance | 3.7881885459218343 | 3.7881885459218236 | 1.07E-14 | 14 | passed |
/fitted_count | exact | 22 | 22 | 0.00E+2 | passed | |
/series_length | exact | 24 | 24 | 0.00E+2 | passed | |
/missing_count | exact | 1 | 1 | 0.00E+2 | passed | |
/excluded_count | exact | 1 | 1 | 0.00E+2 | passed | |
/extrapolation/0/0 | tolerance | 25 | 25.0 | 0.00E+2 | passed | |
/extrapolation/0/1 | tolerance | 25.023259708047004 | 25.023259708047014 | 1.03E-14 | 15 | passed |
Convention
- lm(y ~ t) on the 22 fitted rows with t at their original positions (row 7 missing, row 12 excluded); the series length stays 24.
- docs/manual/chapters/102-deterministic-trends.tex:4-6: excluded or missing responses retain their positions, so removing a value does not compress elapsed index time.
- Expected computed from the re-read TS_TREND_01 CSV with positions t = 1..n in table order.
- docs/manual/chapters/102-deterministic-trends.tex:3-6: positions t = 1..n in table order; excluded or missing responses retain their positions.
- docs/manual/chapters/102-deterministic-trends.tex:23-24: MAE, MSE, RMSE and MAPE describe in-sample original-scale errors.
Reference code
The lines of the reference script that produce this case's expected values.
163 keep <- !is.na(d$y_gap)
164 keep[12] <- FALSE # 0-based row index 11 is excluded by the case
165 fit <- stats::lm(y ~ tt, data = data.frame(y = d$y_gap[keep], tt = tt[keep]))
166 cf <- coef(fit); se <- sqrt(diag(vcov(fit)))
167 emit("STAT-TS-TREND-006", "Linear trend with a missing response and an excluded row",
168 list(response = "y_gap", model = "linear", horizon = 1L),
169 c(param(0L, cf[[1]], se[[1]], "Intercept b0"), param(1L, cf[[2]], se[[2]], "Slope b1"),
170 accuracy(d$y_gap[keep], fitted(fit)), counts(sum(keep), nrow(d), 1L, 1L),
171 list("/extrapolation/0/0" = num(nrow(d) + 1, "Extrapolation starts at n + 1 counting the kept positions."),
172 "/extrapolation/0/1" = num(cf[[1]] + cf[[2]] * (nrow(d) + 1), "b0 + b1 (n + 1)."))),
173 c("lm(y ~ t) on the 22 fitted rows with t at their original positions (row 7 missing, row 12 excluded); the series length stays 24.",
174 "docs/manual/chapters/102-deterministic-trends.tex:4-6: excluded or missing responses retain their positions, so removing a value does not compress elapsed index time."),
175 kind = "axis_coverage", excluded = 11L)
Rolling-origin naive accuracy
Case STAT-TS-VALIDATE-001 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic
- Citation
- Hyndman and Athanasopoulos, Forecasting: Principles and Practice, section 5.10
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_MODELS_01.json
Settings compared
forecast= {"response_column": "rw", "model": "naive", "horizon": 3}method= "study"validation= {"initial_window": 40, "horizon": 3, "final_evaluation": 6}
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/accuracy_by_horizon/0/count | exact | 12 | 12 | 0.00E+2 | passed | |
/accuracy_by_horizon/0/metrics/mae | tolerance | 0.79483624350869952 | 0.7948362435086995 | 4.80E-18 | 17 | passed |
/accuracy_by_horizon/2/metrics/mae | tolerance | 1.5909925900072632 | 1.5909925900072632 | 2.99E-17 | 16 | passed |
/accuracy_by_horizon/1/metrics/rmse | tolerance | 1.3376726082547088 | 1.3376726082547088 | 5.18E-18 | 17 | passed |
/overall_metrics/mae | tolerance | 1.1411521969094223 | 1.1411521969094223 | 3.27E-17 | 16 | passed |
/final_evaluation_metrics/mae | tolerance | 1.9978428741517458 | 1.9978428741517433 | 2.47E-15 | 14 | passed |
/final_evaluation_metrics/rmse | tolerance | 2.0633747409116472 | 2.063374740911644 | 3.12E-15 | 14 | passed |
Convention
- Chapter 12: an expanding window from 40 initial observations, step 1, horizon 3, and an untouched final 6.
- MASE, sMAPE, bias sign and interval coverage depend on conventions the manual leaves open and are not asserted.
Reference code
The lines of the reference script that produce this case's expected values.
425 yy <- d$rw
426 origins <- 40:51 # 0-based origins; the last 6 rows are the final evaluation
427 err <- sapply(1:3, function(k) sapply(origins, function(o) yy[o + k] - yy[o]))
428 final_err <- yy[55:60] - yy[54]
429 emit("STAT-TS-VALIDATE-001", "timeSeriesValidateMenuItem", "Rolling-origin naive accuracy", "TS_MODELS_01",
430 list(method = "study", forecast = list(response_column = "rw", model = "naive", horizon = 3L),
431 validation = list(initial_window = 40L, horizon = 3L, final_evaluation = 6L)),
432 list("/accuracy_by_horizon/0/count" = exact(12L, "Origins 40 to 51 fit before the six final rows."),
433 "/accuracy_by_horizon/0/metrics/mae" = num(mean(abs(err[, 1])), "Mean absolute one-step error."),
434 "/accuracy_by_horizon/2/metrics/mae" = num(mean(abs(err[, 3])), "Mean absolute three-step error."),
435 "/accuracy_by_horizon/1/metrics/rmse" = num(sqrt(mean(err[, 2]^2)), "Root mean squared two-step error."),
436 "/overall_metrics/mae" = num(mean(abs(err)), "Every rolling error."),
437 "/final_evaluation_metrics/mae" = num(mean(abs(final_err)), "Six-step forecast from the last training row."),
438 "/final_evaluation_metrics/rmse" = num(sqrt(mean(final_err^2)), "Final evaluation RMSE.")),
439 c("Chapter 12: an expanding window from 40 initial observations, step 1, horizon 3, and an untouched final 6.",
440 "MASE, sMAPE, bias sign and interval coverage depend on conventions the manual leaves open and are not asserted."),
441 "Analytic", "Hyndman and Athanasopoulos, Forecasting: Principles and Practice, section 5.10", oracle_class = "analytic")
Level VAR(1) forecasts and impulse response
Case STAT-TS-VAR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R vars package
- Citation
- vars::VAR, predict.varest and irf documentation (Pfaff 2008)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_SYSTEM_01.json
Settings compared
cointegration_rank= 2columns= ["v1", "v2"]deterministic= "constant"horizon= 2kind= "var_vecm"lag_order= 1method= "advanced"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/model_label | exact | Level VAR (1 lag(s)) | Level VAR (1 lag(s)) | passed | ||
/forecasts/0/v1 | tolerance | 1.6400035499417269 | 1.6400035499417265 | 4.21E-16 | 15 | passed |
/forecasts/0/v2 | tolerance | 0.019540418210487021 | 0.019540418210487576 | 5.55E-16 | 13 | passed |
/forecasts/0/v1_lower | tolerance | -0.29553969794459101 | -0.2955396979445919 | 8.85E-16 | 14 | passed |
/forecasts/0/v2_upper | tolerance | 1.2515639316118783 | 1.2515639316118792 | 8.77E-16 | 15 | passed |
/forecasts/1/v1 | tolerance | 2.0089174018251104 | 2.0089174018251095 | 9.28E-16 | 15 | passed |
/forecasts/1/v2 | tolerance | -0.12344868326392272 | -0.12344868326392211 | 6.10E-16 | 14 | passed |
/forecasts/1/v1_lower | tolerance | -0.18896403853233146 | -0.18896403853233323 | 1.77E-15 | 14 | passed |
/forecasts/1/v2_upper | tolerance | 1.2529299244043031 | 1.252929924404304 | 8.52E-16 | 15 | passed |
/impulse_responses/0/shock | exact | v1 | v1 | passed | ||
/impulse_responses/0/response | exact | v1 | v1 | passed | ||
/impulse_responses/0/value | tolerance | 0.98754021153125093 | 0.9875402115312509 | 3.24E-18 | 17 | passed |
Convention
- VAR(1) with an unrestricted constant, fitted equation by equation by OLS.
- Interval and impulse scale use the residual covariance; vars divides by T - Kp - 1 as the degrees-of-freedom-adjusted estimate.
Reference code
The lines of the reference script that produce this case's expected values.
273 ir <- irf(vfit, impulse = "v1", response = "v1", n.ahead = 2, ortho = TRUE, boot = FALSE)$irf$v1
274 vo[["/impulse_responses/0/shock"]] <- exact("v1", "First impulse.")
275 vo[["/impulse_responses/0/response"]] <- exact("v1", "First response.")
276 vo[["/impulse_responses/0/value"]] <- num(ir[1, 1], "vars::irf orthogonalised response at horizon 0 (Cholesky factor).")
277 emit("STAT-TS-VAR-001", "timeSeriesVarVecmMenuItem", "Level VAR(1) forecasts and impulse response", "TS_SYSTEM_01",
278 list(method = "advanced", kind = "var_vecm", columns = list("v1", "v2"), lag_order = 1L, cointegration_rank = 2L,
279 horizon = 2L, deterministic = "constant"),
280 vo, c("VAR(1) with an unrestricted constant, fitted equation by equation by OLS.",
281 "Interval and impulse scale use the residual covariance; vars divides by T - Kp - 1 as the degrees-of-freedom-adjusted estimate."),
282 "R vars package", "vars::VAR, predict.varest and irf documentation (Pfaff 2008)")
Rank zero: a constant-only VAR in differences
Case STAT-TS-VAR-002 · status: passed
Reference
- Evidence type
- Analytical
- Source
- Analytic
- Citation
- Luetkepohl (2005), New Introduction to Multiple Time Series Analysis, section 6.3
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_SYSTEM_01.json
Settings compared
cointegration_rank= 0columns= ["v1", "v2"]deterministic= "constant"horizon= 2kind= "var_vecm"lag_order= 1method= "advanced"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/forecasts/0/v1 | tolerance | 1.2451145293752222 | 1.2451145293752222 | 4.34E-17 | 16 | passed |
/forecasts/1/v2 | tolerance | 0.5004525647785345 | 0.5004525647785345 | 3.28E-18 | 17 | passed |
Convention
- Chapter 12: the lag control counts level lags, so one level lag at rank zero fits zero lags of differences, leaving only the constant.
Reference code
The lines of the reference script that produce this case's expected values.
284 dv <- apply(cbind(s$v1, s$v2), 2, diff)
285 mu <- colMeans(dv)
286 last <- c(tail(s$v1, 1), tail(s$v2, 1))
287 emit("STAT-TS-VAR-002", "timeSeriesVarVecmMenuItem", "Rank zero: a constant-only VAR in differences", "TS_SYSTEM_01",
288 list(method = "advanced", kind = "var_vecm", columns = list("v1", "v2"), lag_order = 1L, cointegration_rank = 0L,
289 horizon = 2L, deterministic = "constant"),
290 list("/forecasts/0/v1" = num(last[1] + mu[1], "Last level plus the mean difference."),
291 "/forecasts/1/v2" = num(last[2] + 2 * mu[2], "Two steps of the mean difference.")),
292 c("Chapter 12: the lag control counts level lags, so one level lag at rank zero fits zero lags of differences, leaving only the constant."),
293 "Analytic", "Luetkepohl (2005), New Introduction to Multiple Time Series Analysis, section 6.3",
294 kind = "boundary", oracle_class = "analytic")
A delayed copy peaks at its delay
Case STAT-TS-XCORR-001 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_SHIFT.json
Settings compared
max_lag= 8series_x= "x"series_y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/lag_rows/0/lag | exact | -8 | -8 | 0.00E+2 | passed | |
/lag_rows/0/correlation | tolerance | 0.23506401150244974 | 0.23506401150244963 | 1.13E-16 | 15 | passed |
/lag_rows/0/overlap | exact | 52 | 52 | 0.00E+2 | passed | |
/lag_rows/0/inside_band | exact | False | False | passed | ||
/lag_rows/1/lag | exact | -7 | -7 | 0.00E+2 | passed | |
/lag_rows/1/correlation | tolerance | 0.326958739477476 | 0.326958739477476 | 1.41E-18 | 17 | passed |
/lag_rows/1/overlap | exact | 53 | 53 | 0.00E+2 | passed | |
/lag_rows/1/inside_band | exact | False | False | passed | ||
/lag_rows/2/lag | exact | -6 | -6 | 0.00E+2 | passed | |
/lag_rows/2/correlation | tolerance | 0.51080591021071409 | 0.5108059102107141 | 3.03E-18 | 17 | passed |
/lag_rows/2/overlap | exact | 54 | 54 | 0.00E+2 | passed | |
/lag_rows/2/inside_band | exact | False | False | passed | ||
/lag_rows/3/lag | exact | -5 | -5 | 0.00E+2 | passed | |
/lag_rows/3/correlation | tolerance | 0.4491268935547546 | 0.4491268935547547 | 1.14E-16 | 15 | passed |
/lag_rows/3/overlap | exact | 55 | 55 | 0.00E+2 | passed | |
/lag_rows/3/inside_band | exact | False | False | passed | ||
/lag_rows/4/lag | exact | -4 | -4 | 0.00E+2 | passed | |
/lag_rows/4/correlation | tolerance | 0.35694704334116983 | 0.35694704334116983 | 4.02E-18 | 16 | passed |
/lag_rows/4/overlap | exact | 56 | 56 | 0.00E+2 | passed | |
/lag_rows/4/inside_band | exact | False | False | passed | ||
/lag_rows/5/lag | exact | -3 | -3 | 0.00E+2 | passed | |
/lag_rows/5/correlation | tolerance | 0.32608855851196333 | 0.3260885585119634 | 5.89E-17 | 15 | passed |
/lag_rows/5/overlap | exact | 57 | 57 | 0.00E+2 | passed | |
/lag_rows/5/inside_band | exact | False | False | passed | ||
/lag_rows/6/lag | exact | -2 | -2 | 0.00E+2 | passed | |
/lag_rows/6/correlation | tolerance | 0.45619705304257263 | 0.45619705304257263 | 1.12E-18 | 17 | passed |
/lag_rows/6/overlap | exact | 58 | 58 | 0.00E+2 | passed | |
/lag_rows/6/inside_band | exact | False | False | passed | ||
/lag_rows/7/lag | exact | -1 | -1 | 0.00E+2 | passed | |
/lag_rows/7/correlation | tolerance | 0.54037133756861022 | 0.5403713375686102 | 1.60E-18 | 17 | passed |
/lag_rows/7/overlap | exact | 59 | 59 | 0.00E+2 | passed | |
/lag_rows/7/inside_band | exact | False | False | passed | ||
/lag_rows/8/lag | exact | 0 | 0 | 0.00E+2 | passed | |
/lag_rows/8/correlation | tolerance | 0.49938187866310685 | 0.4993818786631069 | 5.40E-17 | 15 | passed |
/lag_rows/8/overlap | exact | 60 | 60 | 0.00E+2 | passed | |
/lag_rows/8/inside_band | exact | False | False | passed | ||
/lag_rows/9/lag | exact | 1 | 1 | 0.00E+2 | passed | |
/lag_rows/9/correlation | tolerance | 0.52202708127369413 | 0.5220270812736942 | 1.08E-16 | 15 | passed |
/lag_rows/9/overlap | exact | 59 | 59 | 0.00E+2 | passed | |
/lag_rows/9/inside_band | exact | False | False | passed | ||
/lag_rows/10/lag | exact | 2 | 2 | 0.00E+2 | passed | |
/lag_rows/10/correlation | tolerance | 0.64042235973630124 | 0.6404223597363011 | 1.12E-16 | 15 | passed |
/lag_rows/10/overlap | exact | 58 | 58 | 0.00E+2 | passed | |
/lag_rows/10/inside_band | exact | False | False | passed | ||
/lag_rows/11/lag | exact | 3 | 3 | 0.00E+2 | passed | |
/lag_rows/11/correlation | tolerance | 0.97818189798416488 | 0.9781818979841651 | 2.25E-16 | 15 | passed |
/lag_rows/11/overlap | exact | 57 | 57 | 0.00E+2 | passed | |
/lag_rows/11/inside_band | exact | False | False | passed | ||
/lag_rows/12/lag | exact | 4 | 4 | 0.00E+2 | passed | |
/lag_rows/12/correlation | tolerance | 0.65898911552828399 | 0.658989115528284 | 3.70E-18 | 17 | passed |
/lag_rows/12/overlap | exact | 56 | 56 | 0.00E+2 | passed | |
/lag_rows/12/inside_band | exact | False | False | passed | ||
/lag_rows/13/lag | exact | 5 | 5 | 0.00E+2 | passed | |
/lag_rows/13/correlation | tolerance | 0.55524682082821297 | 0.5552468208282129 | 1.09E-16 | 15 | passed |
/lag_rows/13/overlap | exact | 55 | 55 | 0.00E+2 | passed | |
/lag_rows/13/inside_band | exact | False | False | passed | ||
/lag_rows/14/lag | exact | 6 | 6 | 0.00E+2 | passed | |
/lag_rows/14/correlation | tolerance | 0.49438102543153023 | 0.4943810254315303 | 5.55E-17 | 15 | passed |
/lag_rows/14/overlap | exact | 54 | 54 | 0.00E+2 | passed | |
/lag_rows/14/inside_band | exact | False | False | passed | ||
/lag_rows/15/lag | exact | 7 | 7 | 0.00E+2 | passed | |
/lag_rows/15/correlation | tolerance | 0.53717635334676905 | 0.537176353346769 | 3.23E-18 | 17 | passed |
/lag_rows/15/overlap | exact | 53 | 53 | 0.00E+2 | passed | |
/lag_rows/15/inside_band | exact | False | False | passed | ||
/lag_rows/16/lag | exact | 8 | 8 | 0.00E+2 | passed | |
/lag_rows/16/correlation | tolerance | 0.49314150643926769 | 0.4931415064392677 | 4.98E-18 | 16 | passed |
/lag_rows/16/overlap | exact | 52 | 52 | 0.00E+2 | passed | |
/lag_rows/16/inside_band | exact | False | False | passed | ||
/omitted_lag_count | exact | 0 | 0 | 0.00E+2 | passed | |
/peak_lag | exact | 3 | 3 | 0.00E+2 | passed | |
/peak_label | exact | x leads y by 3 | x leads y by 3 | passed | ||
/max_lag_used | exact | 8 | 8 | 0.00E+2 | passed | |
/band_basis | exact | nominal | nominal | passed |
Convention
- Manual line 81-83: a synthetic shifted pair y(t) = x(t - d) peaks at d with the 'X leads Y' label.
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
83 set.seed(20260930)
84 n <- 60L
85 x <- round(cumsum(rnorm(n + 3)) * 0.5 + rnorm(n + 3), 6)
86 y <- round(c(rep(0, 3), x[1:n])[1:n] + rnorm(n, 0, 0.3), 6)
87 x <- x[1:n]
88 export_dataset(data.frame(t = seq_len(n), x = x, y = y), "TS_XCORR_SHIFT",
89 "Constructed: y(t) = x(t - 3) + N(0, 0.3^2) noise, seed 20260930, rounded to 6 decimals",
90 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
91 c(t = "Int64", x = "Float64", y = "Float64"))
92 d <- read_dataset("TS_XCORR_SHIFT")
93 rows <- lag_table(d$x, d$y, 8)
94 out <- c(lag_outputs(rows), list(
95 "/peak_label" = exact("x leads y by 3", "A positive peak is labelled 'X leads Y by d' (line 32-34)."),
96 "/max_lag_used" = exact(8L, "The requested maximum lag."),
97 "/band_basis" = exact("nominal", "No prewhitening.")))
98 emit("STAT-TS-XCORR-001", "A delayed copy peaks at its delay", "TS_XCORR_SHIFT",
99 list(series_x = "x", series_y = "y", max_lag = 8L), out,
100 c("Manual line 81-83: a synthetic shifted pair y(t) = x(t - d) peaks at d with the 'X leads Y' label."))
First differences of both series
Case STAT-TS-XCORR-002 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_SHIFT.json
Settings compared
difference_order_x= 1difference_order_y= 1max_lag= 5series_x= "x"series_y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/lag_rows/0/lag | exact | -5 | -5 | 0.00E+2 | passed | |
/lag_rows/0/correlation | tolerance | 0.049571040019894715 | 0.049571040019894694 | 2.12E-17 | 15 | passed |
/lag_rows/0/overlap | exact | 54 | 54 | 0.00E+2 | passed | |
/lag_rows/0/inside_band | exact | True | True | passed | ||
/lag_rows/1/lag | exact | -4 | -4 | 0.00E+2 | passed | |
/lag_rows/1/correlation | tolerance | -0.04917862293905096 | -0.04917862293905095 | 6.72E-18 | 15 | passed |
/lag_rows/1/overlap | exact | 55 | 55 | 0.00E+2 | passed | |
/lag_rows/1/inside_band | exact | True | True | passed | ||
/lag_rows/2/lag | exact | -3 | -3 | 0.00E+2 | passed | |
/lag_rows/2/correlation | tolerance | -0.24075160154174607 | -0.24075160154174602 | 5.13E-17 | 15 | passed |
/lag_rows/2/overlap | exact | 56 | 56 | 0.00E+2 | passed | |
/lag_rows/2/inside_band | exact | False | False | passed | ||
/lag_rows/3/lag | exact | -2 | -2 | 0.00E+2 | passed | |
/lag_rows/3/correlation | tolerance | 0.057517608664571403 | 0.057517608664571375 | 2.81E-17 | 15 | passed |
/lag_rows/3/overlap | exact | 57 | 57 | 0.00E+2 | passed | |
/lag_rows/3/inside_band | exact | True | True | passed | ||
/lag_rows/4/lag | exact | -1 | -1 | 0.00E+2 | passed | |
/lag_rows/4/correlation | tolerance | 0.19155744573685679 | 0.19155744573685682 | 2.84E-17 | 15 | passed |
/lag_rows/4/overlap | exact | 58 | 58 | 0.00E+2 | passed | |
/lag_rows/4/inside_band | exact | False | False | passed | ||
/lag_rows/5/lag | exact | 0 | 0 | 0.00E+2 | passed | |
/lag_rows/5/correlation | tolerance | -0.12662860425340947 | -0.1266286042534095 | 2.36E-17 | 15 | passed |
/lag_rows/5/overlap | exact | 59 | 59 | 0.00E+2 | passed | |
/lag_rows/5/inside_band | exact | True | True | passed | ||
/lag_rows/6/lag | exact | 1 | 1 | 0.00E+2 | passed | |
/lag_rows/6/correlation | tolerance | -0.11918104264197839 | -0.11918104264197833 | 5.75E-17 | 15 | passed |
/lag_rows/6/overlap | exact | 58 | 58 | 0.00E+2 | passed | |
/lag_rows/6/inside_band | exact | True | True | passed | ||
/lag_rows/7/lag | exact | 2 | 2 | 0.00E+2 | passed | |
/lag_rows/7/correlation | tolerance | -0.33259030985867177 | -0.33259030985867183 | 5.87E-17 | 15 | passed |
/lag_rows/7/overlap | exact | 57 | 57 | 0.00E+2 | passed | |
/lag_rows/7/inside_band | exact | False | False | passed | ||
/lag_rows/8/lag | exact | 3 | 3 | 0.00E+2 | passed | |
/lag_rows/8/correlation | tolerance | 0.94623475073657182 | 0.9462347507365723 | 4.41E-16 | 15 | passed |
/lag_rows/8/overlap | exact | 56 | 56 | 0.00E+2 | passed | |
/lag_rows/8/inside_band | exact | False | False | passed | ||
/lag_rows/9/lag | exact | 4 | 4 | 0.00E+2 | passed | |
/lag_rows/9/correlation | tolerance | -0.29858296864565903 | -0.2985829686456591 | 5.59E-17 | 15 | passed |
/lag_rows/9/overlap | exact | 55 | 55 | 0.00E+2 | passed | |
/lag_rows/9/inside_band | exact | False | False | passed | ||
/lag_rows/10/lag | exact | 5 | 5 | 0.00E+2 | passed | |
/lag_rows/10/correlation | tolerance | -0.069718968928631053 | -0.06971896892863103 | 2.75E-17 | 15 | passed |
/lag_rows/10/overlap | exact | 54 | 54 | 0.00E+2 | passed | |
/lag_rows/10/inside_band | exact | True | True | passed | ||
/omitted_lag_count | exact | 0 | 0 | 0.00E+2 | passed | |
/peak_lag | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- Both series are differenced; the leading position is unavailable (line 58-60).
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
102 emit("STAT-TS-XCORR-002", "First differences of both series", "TS_XCORR_SHIFT",
103 list(series_x = "x", series_y = "y", max_lag = 5L, difference_order_x = 1L, difference_order_y = 1L),
104 lag_outputs(lag_table(difference(d$x, 1), difference(d$y, 1), 5)),
105 c("Both series are differenced; the leading position is unavailable (line 58-60)."), kind = "axis_coverage")
Prewhitening with an OLS AR(2) fit
Case STAT-TS-XCORR-003 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_SHIFT.json
Settings compared
max_lag= 5prewhiten= trueprewhiten_order= 2series_x= "x"series_y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/lag_rows/0/lag | exact | -5 | -5 | 0.00E+2 | passed | |
/lag_rows/0/correlation | tolerance | 0.16884963260677818 | 0.1688496326067783 | 1.14E-16 | 15 | passed |
/lag_rows/0/overlap | exact | 53 | 53 | 0.00E+2 | passed | |
/lag_rows/0/inside_band | exact | False | False | passed | ||
/lag_rows/1/lag | exact | -4 | -4 | 0.00E+2 | passed | |
/lag_rows/1/correlation | tolerance | -0.071440913136184378 | -0.07144091313618424 | 1.39E-16 | 14 | passed |
/lag_rows/1/overlap | exact | 54 | 54 | 0.00E+2 | passed | |
/lag_rows/1/inside_band | exact | True | True | passed | ||
/lag_rows/2/lag | exact | -3 | -3 | 0.00E+2 | passed | |
/lag_rows/2/correlation | tolerance | -0.21289627226994903 | -0.21289627226994895 | 8.04E-17 | 15 | passed |
/lag_rows/2/overlap | exact | 55 | 55 | 0.00E+2 | passed | |
/lag_rows/2/inside_band | exact | False | False | passed | ||
/lag_rows/3/lag | exact | -2 | -2 | 0.00E+2 | passed | |
/lag_rows/3/correlation | tolerance | 0.12515924225139319 | 0.1251592422513933 | 1.09E-16 | 15 | passed |
/lag_rows/3/overlap | exact | 56 | 56 | 0.00E+2 | passed | |
/lag_rows/3/inside_band | exact | True | True | passed | ||
/lag_rows/4/lag | exact | -1 | -1 | 0.00E+2 | passed | |
/lag_rows/4/correlation | tolerance | 0.24061128278847221 | 0.24061128278847232 | 1.15E-16 | 15 | passed |
/lag_rows/4/overlap | exact | 57 | 57 | 0.00E+2 | passed | |
/lag_rows/4/inside_band | exact | False | False | passed | ||
/lag_rows/5/lag | exact | 0 | 0 | 0.00E+2 | passed | |
/lag_rows/5/correlation | tolerance | -0.050071728571962994 | -0.050071728571962786 | 2.08E-16 | 14 | passed |
/lag_rows/5/overlap | exact | 58 | 58 | 0.00E+2 | passed | |
/lag_rows/5/inside_band | exact | True | True | passed | ||
/lag_rows/6/lag | exact | 1 | 1 | 0.00E+2 | passed | |
/lag_rows/6/correlation | tolerance | -0.20164258466340879 | -0.20164258466340873 | 5.96E-17 | 15 | passed |
/lag_rows/6/overlap | exact | 57 | 57 | 0.00E+2 | passed | |
/lag_rows/6/inside_band | exact | False | False | passed | ||
/lag_rows/7/lag | exact | 2 | 2 | 0.00E+2 | passed | |
/lag_rows/7/correlation | tolerance | 0.014291496392089861 | 0.014291496392089919 | 5.76E-17 | 14 | passed |
/lag_rows/7/overlap | exact | 56 | 56 | 0.00E+2 | passed | |
/lag_rows/7/inside_band | exact | True | True | passed | ||
/lag_rows/8/lag | exact | 3 | 3 | 0.00E+2 | passed | |
/lag_rows/8/correlation | tolerance | 0.95190105037794004 | 0.9519010503779404 | 3.32E-16 | 15 | passed |
/lag_rows/8/overlap | exact | 55 | 55 | 0.00E+2 | passed | |
/lag_rows/8/inside_band | exact | False | False | passed | ||
/lag_rows/9/lag | exact | 4 | 4 | 0.00E+2 | passed | |
/lag_rows/9/correlation | tolerance | -0.024753636037684483 | -0.02475363603768411 | 3.75E-16 | 13 | passed |
/lag_rows/9/overlap | exact | 54 | 54 | 0.00E+2 | passed | |
/lag_rows/9/inside_band | exact | True | True | passed | ||
/lag_rows/10/lag | exact | 5 | 5 | 0.00E+2 | passed | |
/lag_rows/10/correlation | tolerance | -0.11329104364519434 | -0.11329104364519413 | 2.12E-16 | 14 | passed |
/lag_rows/10/overlap | exact | 53 | 53 | 0.00E+2 | passed | |
/lag_rows/10/inside_band | exact | True | True | passed | ||
/omitted_lag_count | exact | 0 | 0 | 0.00E+2 | passed | |
/peak_lag | exact | 3 | 3 | 0.00E+2 | passed | |
/band_basis | exact | prewhitened | prewhitened | passed | ||
/prewhiten_order | exact | 2 | 2 | 0.00E+2 | passed |
Convention
- Each series is replaced by the residuals of lm(x_t ~ x_{t-1} + x_{t-2}) with an intercept over its gap-free block.
- The manual says 'a deterministic OLS AR(p) fit' without stating the intercept; this reference includes one.
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
107 wx <- ar_residuals(difference(d$x, 0), 2); wy <- ar_residuals(difference(d$y, 0), 2)
108 out <- lag_outputs(lag_table(wx, wy, 5))
109 out[["/band_basis"]] <- exact("prewhitened", "Bands are computed on the AR residuals (line 48-50).")
110 out[["/prewhiten_order"]] <- exact(2L, "The declared AR order.")
111 emit("STAT-TS-XCORR-003", "Prewhitening with an OLS AR(2) fit", "TS_XCORR_SHIFT",
112 list(series_x = "x", series_y = "y", max_lag = 5L, prewhiten = TRUE, prewhiten_order = 2L), out,
113 c("Each series is replaced by the residuals of lm(x_t ~ x_{t-1} + x_{t-2}) with an intercept over its gap-free block.",
114 "The manual says 'a deterministic OLS AR(p) fit' without stating the intercept; this reference includes one."),
115 kind = "axis_coverage")
Missing and excluded rows stay as unavailable positions
Case STAT-TS-XCORR-004 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_MISSING.json
Settings compared
max_lag= 6series_x= "x"series_y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/lag_rows/0/lag | exact | -6 | -6 | 0.00E+2 | passed | |
/lag_rows/0/correlation | tolerance | 0.47108160146869765 | 0.4710816014686976 | 5.28E-17 | 15 | passed |
/lag_rows/0/overlap | exact | 48 | 48 | 0.00E+2 | passed | |
/lag_rows/0/inside_band | exact | False | False | passed | ||
/lag_rows/1/lag | exact | -5 | -5 | 0.00E+2 | passed | |
/lag_rows/1/correlation | tolerance | 0.42162155605153973 | 0.4216215560515397 | 4.63E-18 | 16 | passed |
/lag_rows/1/overlap | exact | 50 | 50 | 0.00E+2 | passed | |
/lag_rows/1/inside_band | exact | False | False | passed | ||
/lag_rows/2/lag | exact | -4 | -4 | 0.00E+2 | passed | |
/lag_rows/2/correlation | tolerance | 0.31782229727212707 | 0.317822297272127 | 5.10E-17 | 15 | passed |
/lag_rows/2/overlap | exact | 49 | 49 | 0.00E+2 | passed | |
/lag_rows/2/inside_band | exact | False | False | passed | ||
/lag_rows/3/lag | exact | -3 | -3 | 0.00E+2 | passed | |
/lag_rows/3/correlation | tolerance | 0.30483157774417263 | 0.3048315777441726 | 5.29E-17 | 15 | passed |
/lag_rows/3/overlap | exact | 50 | 50 | 0.00E+2 | passed | |
/lag_rows/3/inside_band | exact | False | False | passed | ||
/lag_rows/4/lag | exact | -2 | -2 | 0.00E+2 | passed | |
/lag_rows/4/correlation | tolerance | 0.41556735003417572 | 0.41556735003417566 | 5.57E-17 | 15 | passed |
/lag_rows/4/overlap | exact | 51 | 51 | 0.00E+2 | passed | |
/lag_rows/4/inside_band | exact | False | False | passed | ||
/lag_rows/5/lag | exact | -1 | -1 | 0.00E+2 | passed | |
/lag_rows/5/correlation | tolerance | 0.53866980321876223 | 0.5386698032187622 | 3.14E-18 | 17 | passed |
/lag_rows/5/overlap | exact | 52 | 52 | 0.00E+2 | passed | |
/lag_rows/5/inside_band | exact | False | False | passed | ||
/lag_rows/6/lag | exact | 0 | 0 | 0.00E+2 | passed | |
/lag_rows/6/correlation | tolerance | 0.53107236286872272 | 0.5310723628687228 | 1.16E-16 | 15 | passed |
/lag_rows/6/overlap | exact | 55 | 55 | 0.00E+2 | passed | |
/lag_rows/6/inside_band | exact | False | False | passed | ||
/lag_rows/7/lag | exact | 1 | 1 | 0.00E+2 | passed | |
/lag_rows/7/correlation | tolerance | 0.57092254099566819 | 0.5709225409956683 | 1.14E-16 | 15 | passed |
/lag_rows/7/overlap | exact | 52 | 52 | 0.00E+2 | passed | |
/lag_rows/7/inside_band | exact | False | False | passed | ||
/lag_rows/8/lag | exact | 2 | 2 | 0.00E+2 | passed | |
/lag_rows/8/correlation | tolerance | 0.65882633146565006 | 0.6588263314656501 | 1.33E-18 | 17 | passed |
/lag_rows/8/overlap | exact | 51 | 51 | 0.00E+2 | passed | |
/lag_rows/8/inside_band | exact | False | False | passed | ||
/lag_rows/9/lag | exact | 3 | 3 | 0.00E+2 | passed | |
/lag_rows/9/correlation | tolerance | 0.97846453053954585 | 0.9784645305395455 | 3.32E-16 | 15 | passed |
/lag_rows/9/overlap | exact | 50 | 50 | 0.00E+2 | passed | |
/lag_rows/9/inside_band | exact | False | False | passed | ||
/lag_rows/10/lag | exact | 4 | 4 | 0.00E+2 | passed | |
/lag_rows/10/correlation | tolerance | 0.68038407934124723 | 0.6803840793412472 | 2.35E-18 | 17 | passed |
/lag_rows/10/overlap | exact | 49 | 49 | 0.00E+2 | passed | |
/lag_rows/10/inside_band | exact | False | False | passed | ||
/lag_rows/11/lag | exact | 5 | 5 | 0.00E+2 | passed | |
/lag_rows/11/correlation | tolerance | 0.65124008336486605 | 0.6512400833648662 | 1.12E-16 | 15 | passed |
/lag_rows/11/overlap | exact | 49 | 49 | 0.00E+2 | passed | |
/lag_rows/11/inside_band | exact | False | False | passed | ||
/lag_rows/12/lag | exact | 6 | 6 | 0.00E+2 | passed | |
/lag_rows/12/correlation | tolerance | 0.54106689032535693 | 0.5410668903253569 | 6.24E-19 | 17 | passed |
/lag_rows/12/overlap | exact | 48 | 48 | 0.00E+2 | passed | |
/lag_rows/12/inside_band | exact | False | False | passed | ||
/omitted_lag_count | exact | 0 | 0 | 0.00E+2 | passed | |
/peak_lag | exact | 3 | 3 | 0.00E+2 | passed | |
/excluded_count | exact | 2 | 2 | 0.00E+2 | passed | |
/source_count | exact | 60 | 60 | 0.00E+2 | passed |
Convention
- Rows 4 and 20 (0-based) are excluded and three values are missing; the series never closes up (line 61-65).
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
118 m <- read_dataset("TS_XCORR_SHIFT")
119 m$x[c(10, 31)] <- NA
120 m$y[45] <- NA
121 export_dataset(m, "TS_XCORR_MISSING", "TS_XCORR_SHIFT with x missing at rows 10 and 31 and y at row 45 (1-based)",
122 "R stats::rnorm documentation", "Constructed validation data; no third-party license.",
123 c(t = "Int64", x = "Float64", y = "Float64"))
124 mm <- read_dataset("TS_XCORR_MISSING")
125 excluded <- c(4L, 20L)
126 xa <- mm$x; ya <- mm$y; xa[excluded + 1L] <- NA; ya[excluded + 1L] <- NA
127 out <- c(lag_outputs(lag_table(xa, ya, 6)), list(
128 "/excluded_count" = exact(2L, "Two excluded rows."),
129 "/source_count" = exact(n, "Every source row is counted.")))
130 emit("STAT-TS-XCORR-004", "Missing and excluded rows stay as unavailable positions", "TS_XCORR_MISSING",
131 list(series_x = "x", series_y = "y", max_lag = 6L), out,
132 c("Rows 4 and 20 (0-based) are excluded and three values are missing; the series never closes up (line 61-65)."),
133 kind = "missing_excluded", excluded = excluded)
Lags with fewer than three pairs are omitted
Case STAT-TS-XCORR-005 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_SHORT.json
Settings compared
max_lag= 30series_x= "x"series_y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/lag_rows/0/lag | exact | -3 | -3 | 0.00E+2 | passed | |
/lag_rows/0/correlation | tolerance | 0.98415554466044508 | 0.9841555446604451 | 7.51E-19 | 18 | passed |
/lag_rows/0/overlap | exact | 3 | 3 | 0.00E+2 | passed | |
/lag_rows/0/inside_band | exact | False | False | passed | ||
/lag_rows/1/lag | exact | -2 | -2 | 0.00E+2 | passed | |
/lag_rows/1/correlation | tolerance | -0.0097197063478077599 | -0.00971970634780775 | 1.05E-17 | 14 | passed |
/lag_rows/1/overlap | exact | 4 | 4 | 0.00E+2 | passed | |
/lag_rows/1/inside_band | exact | True | True | passed | ||
/lag_rows/2/lag | exact | -1 | -1 | 0.00E+2 | passed | |
/lag_rows/2/correlation | tolerance | 0.99385104034495908 | 0.9938510403449591 | 2.08E-19 | 18 | passed |
/lag_rows/2/overlap | exact | 5 | 5 | 0.00E+2 | passed | |
/lag_rows/2/inside_band | exact | False | False | passed | ||
/lag_rows/3/lag | exact | 0 | 0 | 0.00E+2 | passed | |
/lag_rows/3/correlation | tolerance | 0.34543823945557295 | 0.345438239455573 | 5.40E-17 | 15 | passed |
/lag_rows/3/overlap | exact | 6 | 6 | 0.00E+2 | passed | |
/lag_rows/3/inside_band | exact | True | True | passed | ||
/lag_rows/4/lag | exact | 1 | 1 | 0.00E+2 | passed | |
/lag_rows/4/correlation | tolerance | 0.99093291715348897 | 0.990932917153489 | 2.02E-18 | 17 | passed |
/lag_rows/4/overlap | exact | 5 | 5 | 0.00E+2 | passed | |
/lag_rows/4/inside_band | exact | False | False | passed | ||
/lag_rows/5/lag | exact | 2 | 2 | 0.00E+2 | passed | |
/lag_rows/5/correlation | tolerance | -0.1921663988801095 | -0.19216639888010947 | 2.64E-17 | 15 | passed |
/lag_rows/5/overlap | exact | 4 | 4 | 0.00E+2 | passed | |
/lag_rows/5/inside_band | exact | True | True | passed | ||
/lag_rows/6/lag | exact | 3 | 3 | 0.00E+2 | passed | |
/lag_rows/6/correlation | tolerance | 0.99561764800389629 | 0.9956176480038963 | 3.93E-18 | 17 | passed |
/lag_rows/6/overlap | exact | 3 | 3 | 0.00E+2 | passed | |
/lag_rows/6/inside_band | exact | False | False | passed | ||
/omitted_lag_count | exact | 4 | 4 | 0.00E+2 | passed | |
/peak_lag | exact | 3 | 3 | 0.00E+2 | passed | |
/max_lag_used | exact | 5 | 5 | 0.00E+2 | passed |
Convention
- With n = 6 the lags |k| >= 4 have at most 2 pairs and are omitted (line 35-36); max_lag 30 is reduced to 5.
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
136 export_dataset(data.frame(x = c(1.2, 3.4, 2.2, 5.1, 4.0, 6.3), y = c(2.0, 1.1, 3.9, 2.7, 5.5, 4.2)),
137 "TS_XCORR_SHORT", "Constructed: six paired values", "Hand-constructed",
138 "Constructed validation data; no third-party license.", c(x = "Float64", y = "Float64"))
139 s <- read_dataset("TS_XCORR_SHORT")
140 out <- c(lag_outputs(lag_table(s$x, s$y, 5)),
141 list("/max_lag_used" = exact(5L, "The lag range is capped at n - 1 = 5.")))
142 emit("STAT-TS-XCORR-005", "Lags with fewer than three pairs are omitted", "TS_XCORR_SHORT",
143 list(series_x = "x", series_y = "y", max_lag = 30L), out,
144 c("With n = 6 the lags |k| >= 4 have at most 2 pairs and are omitted (line 35-36); max_lag 30 is reduced to 5."),
145 kind = "boundary")
Two rows give an insufficient-data outcome
Case STAT-TS-XCORR-006 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_TWO.json
Settings compared
max_lag= 1series_x= "x"series_y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/status | exact | insufficient_data | insufficient_data | passed | ||
/peak_lag | absent | None | passed |
Convention
- Two rows give at most two pairs at every lag.
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
146 export_dataset(data.frame(x = c(1, 2), y = c(3, 1)), "TS_XCORR_TWO", "Constructed: two paired values",
147 "Hand-constructed", "Constructed validation data; no third-party license.", c(x = "Float64", y = "Float64"))
148 emit("STAT-TS-XCORR-006", "Two rows give an insufficient-data outcome", "TS_XCORR_TWO",
149 list(series_x = "x", series_y = "y", max_lag = 1L),
150 list("/status" = exact("insufficient_data", "No lag reaches 3 pairs (line 77-78)."),
151 "/peak_lag" = list(comparison = "absent", rationale = "No lags are invented.")),
152 c("Two rows give at most two pairs at every lag."), kind = "boundary")
A 1e8 offset leaves the correlations unchanged
Case STAT-TS-XCORR-007 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_OFFSET.json
Settings compared
max_lag= 4series_x= "x"series_y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/lag_rows/0/lag | exact | -4 | -4 | 0.00E+2 | passed | |
/lag_rows/0/correlation | tolerance | 0.3569470432866888 | 0.35694704392070103 | 6.34E-10 | 8 | passed |
/lag_rows/0/overlap | exact | 56 | 56 | 0.00E+2 | passed | |
/lag_rows/0/inside_band | exact | False | False | passed | ||
/lag_rows/1/lag | exact | -3 | -3 | 0.00E+2 | passed | |
/lag_rows/1/correlation | tolerance | 0.326088558965827 | 0.32608855994659736 | 9.81E-10 | 8 | passed |
/lag_rows/1/overlap | exact | 57 | 57 | 0.00E+2 | passed | |
/lag_rows/1/inside_band | exact | False | False | passed | ||
/lag_rows/2/lag | exact | -2 | -2 | 0.00E+2 | passed | |
/lag_rows/2/correlation | tolerance | 0.45619705338554722 | 0.456197053789389 | 4.04E-10 | 9 | passed |
/lag_rows/2/overlap | exact | 58 | 58 | 0.00E+2 | passed | |
/lag_rows/2/inside_band | exact | False | False | passed | ||
/lag_rows/3/lag | exact | -1 | -1 | 0.00E+2 | passed | |
/lag_rows/3/correlation | tolerance | 0.54037133767038337 | 0.5403713379784856 | 3.08E-10 | 9 | passed |
/lag_rows/3/overlap | exact | 59 | 59 | 0.00E+2 | passed | |
/lag_rows/3/inside_band | exact | False | False | passed | ||
/lag_rows/4/lag | exact | 0 | 0 | 0.00E+2 | passed | |
/lag_rows/4/correlation | tolerance | 0.49938187896503627 | 0.4993818792834333 | 3.18E-10 | 9 | passed |
/lag_rows/4/overlap | exact | 60 | 60 | 0.00E+2 | passed | |
/lag_rows/4/inside_band | exact | False | False | passed | ||
/lag_rows/5/lag | exact | 1 | 1 | 0.00E+2 | passed | |
/lag_rows/5/correlation | tolerance | 0.5220270817161563 | 0.5220270820711249 | 3.55E-10 | 9 | passed |
/lag_rows/5/overlap | exact | 59 | 59 | 0.00E+2 | passed | |
/lag_rows/5/inside_band | exact | False | False | passed | ||
/lag_rows/6/lag | exact | 2 | 2 | 0.00E+2 | passed | |
/lag_rows/6/correlation | tolerance | 0.6404223599949348 | 0.6404223600120522 | 1.71E-11 | 10 | passed |
/lag_rows/6/overlap | exact | 58 | 58 | 0.00E+2 | passed | |
/lag_rows/6/inside_band | exact | False | False | passed | ||
/lag_rows/7/lag | exact | 3 | 3 | 0.00E+2 | passed | |
/lag_rows/7/correlation | tolerance | 0.97818189810416567 | 0.9781818982241549 | 1.20E-10 | 9 | passed |
/lag_rows/7/overlap | exact | 57 | 57 | 0.00E+2 | passed | |
/lag_rows/7/inside_band | exact | False | False | passed | ||
/lag_rows/8/lag | exact | 4 | 4 | 0.00E+2 | passed | |
/lag_rows/8/correlation | tolerance | 0.65898911512951031 | 0.6589891151151824 | 1.43E-11 | 10 | passed |
/lag_rows/8/overlap | exact | 56 | 56 | 0.00E+2 | passed | |
/lag_rows/8/inside_band | exact | False | False | passed | ||
/omitted_lag_count | exact | 0 | 0 | 0.00E+2 | passed | |
/peak_lag | exact | 3 | 3 | 0.00E+2 | passed |
Convention
- Pearson correlation is shift invariant; R centres each lag window before multiplying.
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
155 h <- read_dataset("TS_XCORR_SHIFT")
156 h$x <- h$x + 1e8
157 export_dataset(h, "TS_XCORR_OFFSET", "TS_XCORR_SHIFT with x shifted by 1e8", "R stats::rnorm documentation",
158 "Constructed validation data; no third-party license.", c(t = "Int64", x = "Float64", y = "Float64"))
159 ho <- read_dataset("TS_XCORR_OFFSET")
160 emit("STAT-TS-XCORR-007", "A 1e8 offset leaves the correlations unchanged", "TS_XCORR_OFFSET",
161 list(series_x = "x", series_y = "y", max_lag = 4L), lag_outputs(lag_table(ho$x, ho$y, 4)),
162 c("Pearson correlation is shift invariant; R centres each lag window before multiplying."), kind = "hard_numeric")
A duplicated time key is refused
Case STAT-TS-XCORR-008 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_DUPKEY.json
Settings compared
max_lag= 4series_x= "x"series_y= "y"time_column= "t"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 18-21: duplicate keys are rejected; keys are never interpolated.
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
165 dup <- read_dataset("TS_XCORR_SHIFT")
166 dup$t[12] <- dup$t[11]
167 export_dataset(dup, "TS_XCORR_DUPKEY", "TS_XCORR_SHIFT with a duplicated time key at row 12 (1-based)",
168 "Hand-constructed", "Constructed validation data; no third-party license.",
169 c(t = "Int64", x = "Float64", y = "Float64"))
170 emit("STAT-TS-XCORR-008", "A duplicated time key is refused", "TS_XCORR_DUPKEY",
171 list(series_x = "x", series_y = "y", time_column = "t", max_lag = 4L), list(),
172 c("Line 18-21: duplicate keys are rejected; keys are never interpolated."), kind = "invalid_input",
173 error = list(error_class = "ValueError", message_contains = "uplicate"))
A maximum lag above 250 is refused
Case STAT-TS-XCORR-009 · status: passed
Reference
- Evidence type
- R
- Source
- R stats::cor on explicitly aligned lag pairs
- Citation
- R stats::cor and stats::lm documentation
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/timeseries_cross_correlation.R · sha256 024b06115a56c162
- Dataset
- reference_data/datasets/TS_XCORR_SHIFT.json
Settings compared
max_lag= 251series_x= "x"series_y= "y"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 22: a fixed ceiling of 250.
- Manual chapter 60 lines 29-65 define the lag pairing, band, differencing and positions.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
174 emit("STAT-TS-XCORR-009", "A maximum lag above 250 is refused", "TS_XCORR_SHIFT",
175 list(series_x = "x", series_y = "y", max_lag = 251L), list(),
176 c("Line 22: a fixed ceiling of 250."), kind = "invalid_input",
177 error = list(error_class = "ValueError", message_contains = "250"))
Zivot-Andrews with a level and slope break
Case STAT-TS-ZA-001 · status: passed
Reference
- Evidence type
- R
- Source
- Independent R implementation of the statsmodels 0.15.0 Zivot-Andrews procedure
- Citation
- Zivot and Andrews (1992); Baum (2004)
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0, forecast 9.0.2, vars 1.6.1, urca 1.3.4
- Reference script
- generators/r/timeseries_models.R · sha256 f0a3960b73b330ae
- Dataset
- reference_data/datasets/TS_LONG_01.json
Settings compared
break_deterministic= "both"columns= ["za"]kind= "zivot_andrews"method= "advanced"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/statistic | tolerance | -8.3538253486038538 | -8.35382534860326 | 5.93E-13 | 13 | passed |
/break_label | exact | 300 | 300 | passed | ||
/selected_lags | exact | 14 | 14 | 0.00E+2 | passed |
Convention
- Statistician ruling, issue #9: Baum's approximation (lag chosen once by AIC in the no-break constant-and-trend ADF regression, maximum 19 at n = 600, trim 0.15), reproduced independently in R.
- Until 2026-09-25 the reference was urca::ur.za at lag 0, a different lag procedure.
Reference code
The lines of the reference script that produce this case's expected values.
398 zb <- za_baum(l$za)
399 stopifnot(zb$maxlag == 19L)
400 emit("STAT-TS-ZA-001", "timeSeriesZivotAndrewsMenuItem", "Zivot-Andrews with a level and slope break", "TS_LONG_01",
401 list(method = "advanced", kind = "zivot_andrews", columns = list("za"), break_deterministic = "both"),
402 list("/statistic" = num(zb$statistic, "Minimum t on the lagged level over the candidate breaks."),
403 "/break_label" = exact(as.character(zb$break_label), "The last row before the break dummies switch on (1-based)."),
404 "/selected_lags" = exact(as.integer(zb$lag), "AIC in the no-break ADF regression, maximum lag 19.")),
405 c("Statistician ruling, issue #9: Baum's approximation (lag chosen once by AIC in the no-break constant-and-trend ADF regression, maximum 19 at n = 600, trim 0.15), reproduced independently in R.",
406 "Until 2026-09-25 the reference was urca::ur.za at lag 0, a different lag procedure."),
407 "Independent R implementation of the statsmodels 0.15.0 Zivot-Andrews procedure", "Zivot and Andrews (1992); Baum (2004)")
Specification checks (not independent references)
These cases verify that the product follows its own documented rules; they are not compared with an external result and are not part of the validation matrix or its counts.
A 1e6 offset in both methods
Case STAT-MSA-DEMING-005 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R closed-form Deming and specified policy checks
- Citation
- NCSS Deming Regression chapter 303; Tabelz manual chapter 39 for policy
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING_OFFSET.json
Settings compared
x_column= "method_a"y_column= "method_b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/slope | tolerance | 1.0309691752895016 | 1.0309691752895018 | 2.27E-16 | 15 | passed |
Convention
- R centres before forming the sums.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
121 h <- read_dataset("MSA_DEMING"); h$method_a <- h$method_a + 1e6; h$method_b <- h$method_b + 1e6
122 export_dataset(h, "MSA_DEMING_OFFSET", "MSA_DEMING with both methods shifted by 1e6", "R stats::rnorm documentation",
123 "Constructed validation data; no third-party license.", c(method_a = "Float64", method_b = "Float64"))
124 ho <- read_dataset("MSA_DEMING_OFFSET")
125 emit("STAT-MSA-DEMING-005", "A 1e6 offset in both methods", "MSA_DEMING_OFFSET", list(x_column = "method_a", y_column = "method_b"),
126 list("/slope" = tol(deming(ho$method_a, ho$method_b, 1)$b, "Centered sums make the slope offset-invariant.")),
127 c("R centres before forming the sums."), kind = "hard_numeric")
Two pairs are too few
Case STAT-MSA-DEMING-006 · status: passed
Reference
- Evidence type
- property
- Source
- R closed-form Deming and specified policy checks
- Citation
- NCSS Deming Regression chapter 303; Tabelz manual chapter 39 for policy
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING_TWO.json
Settings compared
x_column= "method_a"y_column= "method_b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
| No run results loaded for this case. | ||||||
Convention
- Line 68: at least three complete pairs.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
128 export_dataset(data.frame(method_a = c(1, 2), method_b = c(1.1, 2.3)), "MSA_DEMING_TWO", "Constructed: two pairs", "Hand-constructed",
129 "Constructed validation data; no third-party license.", c(method_a = "Float64", method_b = "Float64"))
130 emit("STAT-MSA-DEMING-006", "Two pairs are too few", "MSA_DEMING_TWO", list(x_column = "method_a", y_column = "method_b"), list(),
131 c("Line 68: at least three complete pairs."), kind = "invalid_input",
132 error = list(error_class = "DemingRegressionExecutionError", message_contains = "three"))
Three pairs keep the fit and withhold the jackknife interval
Case STAT-MSA-DEMING-009 · status: passed
Reference
- Evidence type
- Analytical
- Source
- R closed-form Deming and specified policy checks
- Citation
- NCSS Deming Regression chapter 303; Tabelz manual chapter 39 for policy
- Reference software
- R version 4.6.1 (2026-06-24 ucrt) · stats 4.6.1, jsonlite 2.0.0
- Reference script
- generators/r/measurement_deming.R · sha256 4f9a1dc380b3c156
- Dataset
- reference_data/datasets/MSA_DEMING_THREE.json
Settings compared
interval_method= "jackknife_t"x_column= "method_a"y_column= "method_b"
Outputs
| Output | Rule | Reference | HypoNum | |difference| | Digits | Result |
|---|---|---|---|---|---|---|
/slope | tolerance | 0.83438497728646688 | 0.8343849772864669 | 2.10E-18 | 17 | passed |
/jackknife_slope_interval | absent | None | passed | |||
/interval_unavailable_reason | contains | ['at least 4'] | Jackknife intervals need at least 4 eligible pairs; 3 are av | passed |
Convention
- Issue #15 ruling: at least four eligible pairs for leave-one-out intervals; three-pair point fits remain.
- All reference calculations re-read the exported CSV.
Reference code
The lines of the reference script that produce this case's expected values.
171 export_dataset(data.frame(method_a = c(1, 2, 3.5), method_b = c(1.1, 2.3, 3.2)), "MSA_DEMING_THREE", "Constructed: three pairs",
172 "Hand-constructed", "Constructed validation data; no third-party license.", c(method_a = "Float64", method_b = "Float64"))
173 d3 <- read_dataset("MSA_DEMING_THREE")
174 emit("STAT-MSA-DEMING-009", "Three pairs keep the fit and withhold the jackknife interval", "MSA_DEMING_THREE",
175 list(x_column = "method_a", y_column = "method_b", interval_method = "jackknife_t"),
176 list("/slope" = tol(deming(d3$method_a, d3$method_b, 1)$b, "The point fit needs only three pairs."),
177 "/jackknife_slope_interval" = absent("Jackknife intervals need at least four pairs."),
178 "/interval_unavailable_reason" = list(comparison = "contains", values = list("at least 4"),
179 rationale = "The withheld interval states its reason.")),
180 c("Issue #15 ruling: at least four eligible pairs for leave-one-out intervals; three-pair point fits remain."),
181 kind = "boundary")