Analysis report

Cigarette Pricing

Data from R package Ecdat (CRAN), published under https://diafunc.com/licences/view-only.

Target
Number of packs per capita
Analyzed
2026-10-24 18:39 UTC

Summary

The model for Number of packs per capita relies most on Avgprs, with Consumer price index as a secondary input, and tracks patterns in the data. The actual improvement over a straight line through the data is too small to distinguish row by row, with the model coming out ahead on about as many rows as it falls behind.

The model is far less accurate when Avgprs, Taxs, or Tax are in the third quarter, Taxs in the second or highest quarter, and Pop in the lowest or second quarter, and in those segments predicts worse than always guessing the average would. Overlap in what several inputs capture limits what can be learned from the model. Validate on a fresh sample before relying on the model for decisions.

Formula

Number of packs per capita = Year × 6.1 × Consumer price index / AvgprsNumber of packs per capita=Year×6.1×Consumer price indexAvgprs
Number of packs per capita = Year × 6.1 × Consumer price index / Avgprs
1 term · single non-separable expression

Held-out diagnostics

TargetQualityErrorR²MAEGeneralizationRows
Number of packs per capita39.57 %58.28 %0.417212.52generalizing106
  • Number of packs per capita · Quality 95 % CI 22.82 % – 51.43 %
  • Number of packs per capita · Error 95 % CI 46.85 % – 74.44 %
  • Number of packs per capita · R² 95 % CI 0.2556 – 0.5315
  • Number of packs per capita · MAE 95 % CI 10.48 – 14.87

Concerns

CRITICAL model

3 pairs of inputs carry nearly the same information

3 pairs of the model's inputs move together so closely that the weight the model gives either one of a pair could as well belong to the other; 1 of them is almost identical. The closest are Consumer price index and Year (Spearman's rho = 1 (Pearson r = 0.996)), Avgprs and Consumer price index (Spearman's rho = 0.86 (Pearson r = 0.856)) and Avgprs and Year (Spearman's rho = 0.86 (Pearson r = 0.846)). Consider dropping one input of each pair or combining the two.

Complete list (3)
InputsAssociationReading
cpi · yearSpearman's rho = 1 (Pearson r = 0.996)Almost identical
avgprs · cpiSpearman's rho = 0.86 (Pearson r = 0.856)Highly correlated
avgprs · yearSpearman's rho = 0.86 (Pearson r = 0.846)Highly correlated

CRITICAL implications

Weaker quality on 19 slices of the data

On 19 of the 28 slices compared the model is weaker than on all held-out rows (R² 0.417). The largest gaps: Avgprs in the third quarter (152 to 174) (worse than always guessing the segment's average, on 28 rows) and Taxs in the third quarter (43 to 53.1) (worse than always guessing the segment's average, on 32 rows). Predictions for these rows deserve caution; the Quality by Input Range chapter lists every slice.

Complete list (19)
SegmentRowsR²Against all rowsVerdict
Avgprs in the third quarter (152 to 174)28worse than guessing the segment's averageR² 0.417 on all rowsMuch weaker
Taxs in the third quarter (43 to 53.1)32worse than guessing the segment's averageR² 0.417 on all rowsMuch weaker
Tax in the third quarter (39 to 46.0)28worse than guessing the segment's averageR² 0.417 on all rowsMuch weaker
Pop in the second quarter (1,580,664 to 3,560,884)29worse than guessing the segment's averageR² 0.417 on all rowsMuch weaker
Taxs in the highest quarter (54.3 to 93.5)26worse than guessing the segment's averageR² 0.417 on all rowsMuch weaker
Taxs in the second quarter (36.7 to 42.8)220.0429-0.374Much weaker
Avgprs in the highest quarter (176 to 237)250.124-0.294Much weaker
Pop in the lowest quarter (496,000 to 1,519,933)230.186-0.232Weaker
Tax in the second quarter (32 to 37.7)250.199-0.219Weaker
Income in the lowest quarter (6,940,614 to 24,173,868)250.207-0.21Weaker
Consumer price index in the highest quarter (1.45 to 1.52)290.211-0.206Weaker
Year in the highest quarter (1,993 to 1,995)290.211-0.206Weaker
Avgprs in the lowest quarter (95.5 to 120)240.237-0.18Weaker
Taxs in the lowest quarter (21.1 to 34.9)260.265-0.152Weaker
Tax in the lowest quarter (18 to 31.0)250.288-0.129Weaker
Consumer price index in the third quarter (1.31 to 1.40)290.31-0.107Weaker
Year in the third quarter (1,990 to 1,992)290.31-0.107Weaker
Consumer price index in the second quarter (1.14 to 1.24)310.313-0.104Weaker
Year in the second quarter (1,987 to 1,989)310.313-0.104Weaker

WARNING model

The model barely beats a straight line through the data on `Number of packs per capita`

The model explains 42% of the variation on the held-out rows, where a straight line through the data explains 40%, a margin of 1.6 points. The formula adds little over the reference predictor; whether it is worth its complexity depends on the use. Row by row the two are about level.

Analysis

The report opens with the Headline and the Concerns, followed by the Discovered Relations when the analysis has targets and by Questions & Answers when questions were asked. Three sections carry the detail: Model presents one model per target, Implications states where the models hold and what to weigh before relying on them, and Data describes the table as supplied, column by column, for reference.

Generated 2026-10-24 18:39 UTC, analysis f3416400-48b7-11f1-8087-d378640fe787, 1 target, time budget 1 h 0 min, compute budget 500 credits, 528 rows. The Provenance & Audit chapter holds the full record.

Validity

Validity: valid. Nothing in the data or the formula speaks against relying on this result.

How to read this

Whether this result is one to rely on. Quality says how closely the formula follows the data; validity says whether that closeness means anything. A formula that only restates its target, or that reads a column which already holds the answer, can reach a very high quality and still tell you nothing new.

What it found

Number of packs per capita rises with Consumer price index and Year and falls with Avgprs.

  1. Avgprs carries most of the model. Avgprs accounts for 78% of what the formula explains and Consumer price index for 22%. Year is in the formula too, with no measurable share.
  2. Number of packs per capita rises with Consumer price index. For each additional 0.01 units of Consumer price index, the model's output for Number of packs per capita is higher by 0.806. This holds with the other inputs at typical values.
  3. State is not in the formula. It has the strongest association with Number of packs per capita in the table (0.89).
  4. The formula is only slightly ahead of a straight line. The formula explains 42% of Number of packs per capita; a straight line explains 40%, so treat them as level. That was measured on 106 rows it never saw. The formula typically misses Number of packs per capita by 12.5.

Summary

What to do next: Intervals are wider than their level requires, largest gap 12.3 percentage points.

5 chapters, each headed by what it found.

Avgprs carries most of the formula

What the formula relies on. Shares of the formula: Avgprs 78%, Consumer price index 22%.

InputShare of importancePermutation importanceSensitivityResidual correlationOccurrences
Avgprs78.1 %1.64560.61940.051971
Consumer price index21.9 %0.461574.240.15961
Year-0.00380.050340.16921

The formula is not additively decomposable: the prediction comes from a single non-separable expression. The curve below shows the whole-formula response.

Additive
No
Terms in the formula
1
Notation
Year × 6.1 × Consumer price index / Avgprs
Target
Number of packs per capita

It holds on new rows: R² 0.42 held out, 0.39 on the training rows

How well it holds. The formula explains 42% of Number of packs per capita; a straight line explains 40%, so treat them as level.

R² of 0.417: weak. The model captures only a small part of the variance; either the relevant inputs are missing, or the target depends on interactions the formula did not recover. Mean absolute error is 12.5 on the target's scale.

Error
58.28 % (95 % CI 46.85 % – 74.44 %)
MAE
12.52 (95 % CI 10.48 – 14.87)
N
106
Training rows
422
Quality
39.57 % (95 % CI 22.82 % – 51.43 %)
R²
0.4172 (95 % CI 0.2556 – 0.5315)
Target
Number of packs per capita

The model beats the strongest simple yardstick, a straight line through the data, by 1.6 points of variance explained on the held-out rows. Row by row the margin is negligible: the model reads as roughly level with the yardstick. Of the 106 held-out rows where the two differ, the model is closer on 46% (95% interval 37% to 56%). The interval of the margin includes zero: on this many held-out rows the lead is not settled.

Best yardstick's score
0.401 (95 % CI 0.2631 – 0.5152)
Best baseline R²
0.401
Effect size d
-0.09074 (95 % CI -0.279 – 0.1064)
Effect size d magnitude
negligible
Margin over the best yardstick
0.01614 (95 % CI -0.07172 – 0.07971)
Margin's interval stays above zero
No
Model MAE
12.52 (95 % CI 10.48 – 14.87)
Model
0.4172 (95 % CI 0.2556 – 0.5315)
Model R²
0.4172 (95 % CI 0.2556 – 0.5315)
Held-out rows
106
Held-out rows without an answer
0
Target
Number of packs per capita
Rows where the model is closer
46.23 % (95 % CI 37.03 % – 55.68 %)
Rows compared
106
Rows level
0
Regression yardstick trained with gaps filled (too few complete rows)
No
Training rows of the regression yardstick
422

The model explains held-out rows about as well as training rows (held-out R² 0.417, gap between training and held-out R² -0.0255): it generalizes. The structure the formula encodes carries from the training rows to the held-out rows.

Generalization gap
-0.02547
N test
106
Target
Number of packs per capita
Test error
12.52 (95 % CI 10.48 – 14.87)
Test R²
0.4172 (95 % CI 0.2556 – 0.5315)
Train error
0.6151
Train R²
0.3917
Verdict
Generalizing

Weaker on 19 slices of the data, most in the third quarter of Avgprs

Where it is weak. The largest miss on a held-out row is 61.6 (recorded 198, predicted 136).

Segment avgprs in the third quarter (152 to 174) is much weaker than the aggregate (28 held-out rows): segment R² -0.0992 against aggregate R² 0.417 (gap -0.516). A drop this large means the model describes this slice of the data poorly; an input interaction or a missing column may be specific to this subset.

SegmentRowsR²Gap to all rowsVerdict
Avgprs = q328-0.0992-0.5164Much weaker than on all rows
Taxs = q332-0.0906-0.5078Much weaker than on all rows
Tax = q328-0.0624-0.4796Much weaker than on all rows
Pop = q229-0.0106-0.4277Much weaker than on all rows
Taxs = q426-0.0031-0.4203Much weaker than on all rows
Taxs = q2220.0429-0.3743Much weaker than on all rows
Avgprs = q4250.1236-0.2936Much weaker than on all rows
Pop = q1230.1855-0.2317Weaker than on all rows
Tax = q2250.1986-0.2185Weaker than on all rows
Income = q1250.2068-0.2104Weaker than on all rows

The first 10 rows of 24. The other 14 are in the notebook.

Aggregate R²
0.4172
Measure
r2
Target
Number of packs per capita

The worst held-out row was missed by 61.6 (target's scale). The 10 rows with the largest absolute residuals out of 106 held-out rows are shown. Each card breaks the failure down into per-term contributions and input values, so the failure mode is inspectable. A large residual with one concentrated term contribution means one term got this row wrong; a large residual with balanced contributions means a structural mismatch.

ActualPredictedResidualAvgprsConsumer price indexYear
197.99136.43+61.5795.51.0761985
185.20126.66+58.54108.71.1361987
64.42106.38-41.97169.41.4821994
57.4498.74-41.30152.41.241989
88.74126.77-38.02102.81.0761985
129.7392.62+37.11162.41.241989
71.58106.89-35.31148.41.3071990
175.95141.35+34.6097.411.1361987
124.1090.80+33.30187.81.4031992
57.8787.32-29.45206.41.4821994
Additive
No
N extrapolated
0
Held-out rows
106
Held-out rows for the interval
106
Residual P5
-28.9
Residual P95
27.52
Residual std
17.26

0 of 106 held-out rows (0%) lie further from the training rows than 99 in 100 rows like them would, measured on the 3 inputs the model reads (avgprs, cpi, year). That is a small minority; the held-out figures describe the model on rows like the ones it was trained on.

TargetInputs measuredLineHeld-out rowsBeyond the lineShare
Number of packs per capitaAvgprs, Consumer price index, Year3.36810600 %
Score bins · 24 of 30 rows shown
CountFromTo
500.135
10.1350.269
30.2690.404
50.4040.539
80.5390.674
50.6740.808
40.8080.943
20.9431.078
61.0781.213
21.2131.347

The first 10 rows of 24. The other 14 are in the notebook.

Not ready to use yet: 2 critical concerns

What to watch. First: 3 pairs of inputs carry nearly the same information.

SeveritySectionConcernDetail
CriticalModel3 pairs of inputs carry nearly the same information3 pairs of the model's inputs move together so closely that the weight the model gives either one of a pair could as well belong to the other; 1 of them is almost identical. The closest are Consumer price index and Year (Spearman's rho = 1 (Pearson r = 0.996)), Avgprs and Consumer price index (Spearman's rho = 0.86 (Pearson r = 0.856)) and Avgprs and Year (Spearman's rho = 0.86 (Pearson r = 0.846)). Consider dropping one input of each pair or combining the two.
CriticalImplicationsWeaker quality on 19 slices of the dataOn 19 of the 28 slices compared the model is weaker than on all held-out rows (R² 0.417). The largest gaps: Avgprs in the third quarter (152 to 174) (worse than always guessing the segment's average, on 28 rows) and Taxs in the third quarter (43 to 53.1) (worse than always guessing the segment's average, on 32 rows). Predictions for these rows deserve caution; the Quality by Input Range chapter lists every slice.
WarningModelThe model barely beats a straight line through the data on Number of packs per capitaThe model explains 42% of the variation on the held-out rows, where a straight line through the data explains 40%, a margin of 1.6 points. The formula adds little over the reference predictor; whether it is worth its complexity depends on the use. Row by row the two are about level.

The analysis ran with the configuration below. The checks and the verdict of this chapter are read against it.

  • Targets: 1 target: packpc
  • Rows: 528 rows
  • Per-Segment Predictions: not produced, because no segment column was chosen
  • Fairness: compared across 1 categorical column (state); which of them are protected attributes is not decided here
  • Out-of-Distribution: held-out rows are scored against the training rows; predictions made outside this report are not scored
  • Provenance & Audit: recorded in the chapter of that name

Across 5 checks (3 pass, 2 warn, 0 fail, 2 critical concerns), at least one check fails or a critical concern is open: Not ready. The failing checks need addressing first; they typically indicate data leakage, severe miscalibration, or a model that loses to its baseline.

NameStatusDetail
GeneralizationPassheld-out quality holds up against training quality
Prediction Interval CoverageWarnintervals are wider than their level requires, largest gap 12.3 percentage points
Baseline Lift for Number of packs per capitaWarnbarely beats the best baseline, R² lift 0.0161
Model ConstraintsPassevery held-out prediction is finite and within the training range
Out-of-DistributionPass0% of held-out rows are out of distribution
N critical concerns
2
N fail
0
N pass
3
N warn
2
Overall verdict
Not ready

More rows in the third quarter of Avgprs would help most

What to collect next. There the model does worse than the average of the slice, on 28 held-out rows.

  • Collect more rows where Avgprs is in the third quarter (152 to 174), Taxs is in the third quarter (43 to 53.1), Tax is in the third quarter (39 to 46.0), Pop is in the second quarter (1,580,664 to 3,560,884), or Taxs is in the highest quarter (54.3 to 93.5). Reason: the model is far less accurate than overall on these segments, predicting them worse than always guessing their average would.
  • Collect more rows where Taxs is in the second quarter (36.7 to 42.8) or Avgprs is in the highest quarter (176 to 237). Reason: the model is much less accurate on these segments, explaining only 4.3% of the variation for Taxs in the second quarter (36.7 to 42.8) and 12% for Avgprs in the highest quarter (176 to 237).
  • Collect more rows where Pop is in the lowest quarter (496,000 to 1,519,933). Reason: the model explains just 19% of the variation in this segment, well below its overall quality.
  • Inspect and clarify the relationships among Avgprs, Taxs, and Tax columns. Reason: 3 pairs of inputs carry nearly the same information, which can make the model harder to interpret and limits what can be learned from the coefficients.
  • Add columns or factors that could improve the model's quality for Number of packs per capita. Reason: the model barely beats a straight line through the data, adding just 1.6 points of variance explained, and a stronger formula may need additional features.

Evidence

Every chapter of the analysis in full: the figures the story rests on, and everything else the analysis measured.

Headline

Diafunc modeled Number of packs per capita from 8 columns, of which the model uses 3. The model explains less than half of its target, 42% of Number of packs per capita, and relies most on Avgprs.

  • One target was modeled; 106 rows were held out for checking.
  • A straight line through the data already explained 40%; the model added 1.6 points, a slight and not consistent margin.
  • 3 pairs of inputs carry nearly the same information, a critical concern.
Best R²
0.4172
Best quality
39.57 %
Best target
packpc
Targets
1

Concerns

SeveritySectionConcernDetail
CriticalModel3 pairs of inputs carry nearly the same information3 pairs of the model's inputs move together so closely that the weight the model gives either one of a pair could as well belong to the other; 1 of them is almost identical. The closest are Consumer price index and Year (Spearman's rho = 1 (Pearson r = 0.996)), Avgprs and Consumer price index (Spearman's rho = 0.86 (Pearson r = 0.856)) and Avgprs and Year (Spearman's rho = 0.86 (Pearson r = 0.846)). Consider dropping one input of each pair or combining the two.
CriticalImplicationsWeaker quality on 19 slices of the dataOn 19 of the 28 slices compared the model is weaker than on all held-out rows (R² 0.417). The largest gaps: Avgprs in the third quarter (152 to 174) (worse than always guessing the segment's average, on 28 rows) and Taxs in the third quarter (43 to 53.1) (worse than always guessing the segment's average, on 32 rows). Predictions for these rows deserve caution; the Quality by Input Range chapter lists every slice.
WarningModelThe model barely beats a straight line through the data on Number of packs per capitaThe model explains 42% of the variation on the held-out rows, where a straight line through the data explains 40%, a margin of 1.6 points. The formula adds little over the reference predictor; whether it is worth its complexity depends on the use. Row by row the two are about level.

How to read this

Data-quality, model-quality, and deployment-risk issues detected during the analysis appear below, ordered by severity. Critical concerns are listed first; Warning and Info entries follow.

Discovered Relations

Quality and error measured on the 106 held-out rows
TargetFormulaQualityComplexityError
Number of packs per capitaNumber of packs per capita = Year × 6.1 × Consumer price index / Avgprs39.57 %7.9 %58.28 %

How to read this

One model per target, each a formula with its quality, complexity and error. Higher quality at lower complexity describes the data most clearly. The findings below read the models together; the per-target chapters in the Model section carry each formula, its predictions and its diagnostics.

Model

Most of the model's signal comes from Avgprs, and the formula is year times 6.1 times cpi divided by avgprs. The model explains a share of variation of 0.417 on held-out rows, with a mean absolute error of 12.5. Three pairs of inputs report nearly the same information and both that and the model's limited quality are flagged in Concerns.

Most notable in the Model section:

  • Avgprs carries most of the model (78% of its reliance on inputs)

How to read this

The Model section presents one model per target: its formula, its predictions on held-out rows, the inputs it relies on, the baselines it is measured against, and diagnostics of how it behaves. With more than one target, the Composite Model, Multi-Output and Leaderboard chapters read the models as a set.

Number of packs per capita

The Model section builds one model for Number of packs per capita: a formula that expresses it through the other columns. Diafunc searches the space of mathematical expressions for the formula that balances accuracy against simplicity, so the result is not a black box but an expression that can be read, evaluated and questioned. The chapters that follow show the formula, score it on rows it never saw during training, and take it apart term by term.

Number of packs per capita Model

The model’s output strongly falls as Avgprs rises and also rises with Consumer price index. The formula also includes Year, and these three inputs explain the model’s predictions of Number of packs per capita.

Number of packs per capita = Year × 6.1 × Consumer price index / Avgprsf:Avgprs,Consumer price index,Year↦Number of packs per capitaAvgprs,Consumer price index,Year,Number of packs per capita∈RNumber of packs per capita=Year×6.1×Consumer price indexAvgprs
Number of packs per capita = Year × 6.1 × Consumer price index / Avgprs
Quality 39.57 % · Error 58.28 % on 106 held-out rows · Complexity 7.9 %
Held out R²
0.4172 (95 % CI 0.2556 – 0.5315)
Training rows
422
Held-out rows
106
Inputs the formula reads
3
Terms in the formula
1

How to read this

The three gauges score the model on the held-out rows: rows that were set aside before the search and that the model never saw. They are the figures to quote for how the model does on new data.

MetricMeaning
QualityHow well the model predicts on the held-out rows, marked down for the size of its formula: 100% is an exact prediction, 0% is no better than always predicting the average. It is not R², and sits at or just below it
ErrorHow far the predictions lie from the held-out values, as a share of the miss of always predicting the average: 0% is an exact prediction, 100% is no better than the average
ComplexityThe size of the formula as a share of the complexity the search was allowed: a low figure is a short formula

The figures under During the search are the same measures on the training rows. They are what the search ranked its candidates by, so they describe the search and tend to flatter the model it chose. The Generalization chapter sets the training rows beside the held-out rows, and the Baselines chapter sets the model beside its baselines. The time and credit gauges account for the computation that produced the model, not for the model itself.

Prediction

The model predicts Number of packs per capita for any row that supplies the other columns. This chapter applies it to the held-out rows, the rows set aside before training, so that the predictions can be compared with values the model never saw. The rows themselves and the function that predicts them are kept as reference under Foundation, with the processed data.

Prediction Chart

R² of 0.417: weak. The model captures only a small part of the variance; either the relevant inputs are missing, or the target depends on interactions the formula did not recover. Mean absolute error is 12.5 on the target's scale.

Error
58.28 % (95 % CI 46.85 % – 74.44 %)
MAE
12.52 (95 % CI 10.48 – 14.87)
N
106
Training rows
422
Quality
39.57 % (95 % CI 22.82 % – 51.43 %)
R²
0.4172 (95 % CI 0.2556 – 0.5315)
Target
Number of packs per capita

How to read this

Actual Number of packs per capita on the horizontal axis against the model's predicted value on the vertical axis, for the held-out rows the model never saw during training. Points on the diagonal are perfect predictions; systematic vertical offsets reveal bias, vertical spread reveals noise, and points far from the diagonal are rows the model handles poorly. With 10,000 held-out rows or more, the rows are counted instead of drawn one point each: each cell is a range of the actual and a range of the predicted value, its colour the number of rows that fall in both, and the cells whose two ranges match hold the rows the model predicts well.

Residual Distribution
Bias
-1.916 (95 % CI -5.103 – 1.407)
N
106
P50
-1.541 (95 % CI -4.418 – 0.6167)
P90
13.97 (95 % CI 10.04 – 26.53)
P95
27.52 (95 % CI 13.17 – 37.11)
P99
57.47 (95 % CI 27.42 – 61.57)
Std
17.26 (95 % CI 13.75 – 20.45)

How to read this

How the held-out residuals (actual Number of packs per capita minus predicted) are distributed. Bias is their mean: a value away from zero means the model is systematically high or low rather than merely imprecise. The standard deviation and the percentiles describe the spread, and the tail percentiles say how large the worst misses get. Every figure carries a bootstrap 95% confidence interval; with a small held-out set those intervals are wide, and that width is itself the finding.

Which inputs matter most
InputShare of importancePermutation importanceSensitivityResidual correlationOccurrences
Avgprs78.1 %1.64560.61940.051971
Consumer price index21.9 %0.461574.240.15961
Year-0.00380.050340.16921

How to read this

The chart ranks the inputs of the Number of packs per capita model by permutation importance: how much the model's error rises when that input's values are shuffled across rows so that it carries no information. A longer bar means the model relies on the input more. The order says which columns the model reads most, and those are the columns where measurement quality and data collection matter most. A short bar marks an input the model barely uses, which is a fact about this model and not a verdict on the column. Importance describes the model's reliance and nothing more: an input can rank high because it stands in for something the data does not contain. Where the search measured it, an input also carries the direction in which the model's output moves as the input rises, counted on the rows the search trained on, and the change of the output when the input alone goes from its first to its third quartile; both describe the formula inside the observed range and say nothing about causes.

Baselines

The model beats the strongest simple yardstick, a straight line through the data, by 1.6 points of variance explained on the held-out rows. Row by row the margin is negligible: the model reads as roughly level with the yardstick. Of the 106 held-out rows where the two differ, the model is closer on 46% (95% interval 37% to 56%). The interval of the margin includes zero: on this many held-out rows the lead is not settled.

Best yardstick's score
0.401 (95 % CI 0.2631 – 0.5152)
Best baseline R²
0.401
Effect size d
-0.09074 (95 % CI -0.279 – 0.1064)
Effect size d magnitude
negligible
Margin over the best yardstick
0.01614 (95 % CI -0.07172 – 0.07971)
Margin's interval stays above zero
No
Model MAE
12.52 (95 % CI 10.48 – 14.87)
Model
0.4172 (95 % CI 0.2556 – 0.5315)
Model R²
0.4172 (95 % CI 0.2556 – 0.5315)
Held-out rows
106
Held-out rows without an answer
0
Target
Number of packs per capita
Rows where the model is closer
46.23 % (95 % CI 37.03 % – 55.68 %)
Rows compared
106
Rows level
0
Regression yardstick trained with gaps filled (too few complete rows)
No
Training rows of the regression yardstick
422

How to read this

The table scores the model for Number of packs per capita against simple yardsticks on the same held-out rows. A yardstick is a predictor simple enough to need no explanation: a constant (the average, the middle value, the most common class or level, the average count), a plain regression on the numeric inputs (a straight line, a logistic regression, a Poisson regression), and for a series over time a forecast from its own past (the last value, the value one season back, the recent trend extended). Which of them appear depends on what kind of column Number of packs per capita is. They are yardsticks only: the analysis has one model, and it is the last row. A regression yardstick answers every row the model answers: where one of its numeric inputs is empty, it reads the average of that input over the training rows. Nothing is filled in for the model. A yardstick whose row is empty could not be scored, and the summary then says what the margin is measured against.

Read the columns from top to bottom. Each kind of target is scored by the measure it is judged on: R² and MAE for a continuous value, with MASE added for a series (below 1 means a typical miss is smaller than the series' usual step from one row to the next); accuracy and balanced accuracy for a yes/no value, with the Brier score where a probability is predicted; accuracy and macro F1 for a class; weighted kappa and the distance in levels for an ordered level; Poisson deviance and RMSE for a count. When the model clears every yardstick by a wide margin, its structure earns its place. When it is level with the regression yardstick, a plain regression describes the data as well. When it is level with the constant, the inputs carry no usable signal for Number of packs per capita.

The margin over the best yardstick comes with an interval. When that interval includes zero, the lead is not settled on this many held-out rows. The share of rows on which the model is closer than the best yardstick is counted only on the rows where the two differ; for a yes/no value or a class these are the rows where the two disagree.

Generalization

The model explains held-out rows about as well as training rows (held-out R² 0.417, gap between training and held-out R² -0.0255): it generalizes. The structure the formula encodes carries from the training rows to the held-out rows.

Generalization gap
-0.02547
N test
106
Target
Number of packs per capita
Test error
12.52 (95 % CI 10.48 – 14.87)
Test R²
0.4172 (95 % CI 0.2556 – 0.5315)
Train error
0.6151
Train R²
0.3917
Verdict
Generalizing

How to read this

The chart sets the score of the Number of packs per capita model on the rows it trained on beside its score on the held-out rows it never saw, and the gap between the two bars is the finding. The score is the one that suits the target: R² for a quantity, balanced accuracy for a yes/no target, weighted kappa for ordered levels. The held-out figure carries a bootstrap 95% confidence interval, which says how far it could move with a different held-out draw; the training bar has none, because it is measured on the rows that shaped the model.

The verdict reads from the two figures. Generalizing: the held-out score is strong, or training and held-out agree closely; the structure the formula encodes carries to new rows. Overfit: training is far ahead of held-out and the held-out score is not strong on its own; the formula has absorbed noise from the training rows, and the training figure overstates what to expect on new data. Underfit or noisy: held-out is far ahead of training; this is not strength, it usually means an outlier or a flat region in the training rows that the held-out rows happen to avoid. Insufficient: fewer than 30 held-out rows and no strong held-out score, too little evidence for a negative verdict. A model that predicts the same value for every held-out row gets no verdict: there is nothing that could carry over. In every case the width of the held-out interval says how much weight the gap can bear.

How each term responds to its inputs

The formula is not additively decomposable: the prediction comes from a single non-separable expression. The curve below shows the whole-formula response.

Additive
No
Terms in the formula
1
Notation
Year × 6.1 × Consumer price index / Avgprs
Target
Number of packs per capita

How to read this

The formula for Number of packs per capita is split into its additive terms, and each term is traced as one of its inputs moves across the training range while the other inputs stay at their medians. Each curve is therefore a profile of the term at the typical row, not an average over the data: it shows what the term contributes at every value of that input when everything else is ordinary.

A term that depends on several inputs gets one curve per input; a constant term gets none. Terms the formula subtracts are drawn with their sign, so a curve below zero pulls the prediction down. At any fixed row, the terms add up to the model's prediction. Where the search measured it, a term also carries its share of the variation of the model's output on the rows the search trained on; that is a share of what the formula returns, not of Number of packs per capita itself. The notebook lets the reader trim each range to the central 95% of the input. When the formula has no additive structure, the chapter traces the whole formula as a single term along each of its inputs, and the Sensitivity chapter is the better read for how the inputs combine.

How the formula behaves outside the data

The model diverges beyond the observed range of year, cpi: predictions there are not supported by the formula's shape. It has a pole at avgprs = 0. Extrapolate with caution.

Bounded at infinity
No
Inputs the formula reads
3
N singularities
1
Risky inputs
year, cpi, avgprs
Target
Number of packs per capita
Limits at neg infinity
InputKind
YearNegative infinity
Consumer price indexNegative infinity
AvgprsFinite
Limits at pos infinity
InputKind
YearPositive infinity
Consumer price indexPositive infinity
AvgprsFinite
Singularities
AtInputKind
0AvgprsPole

How to read this

The formula for Number of packs per capita is read as a mathematical object, without data, to state how it behaves beyond the range it was trained on. A black box cannot answer that question; a formula can. For each input the chapter reports the limit as the input grows without bound in either direction (whether the formula diverges, settles to a finite value or oscillates, with the sign tracked exactly, so that a term like minus two times the cube of the input is reported as diverging downward on the right and upward on the left), whether the formula stays finite in every direction, and any singularity with its solved location: a division whose denominator reaches zero, a logarithm or square root whose argument leaves its domain, or a periodic pole.

The inputs along which the formula diverges or meets a singularity are listed as the risky ones; along them the formula's shape gives no support for extrapolation. A formula that stays finite everywhere with no singularity carries no structural hazard when extrapolated; the data still ends where it ends, and a prediction outside the training range remains unsupported by evidence. The plain-language summary at the end states the same facts in one paragraph.

Contributions per term
Additive
No
N rows
5

The notebook draws this chapter's figure from each held-out row; the row-by-row detail is there.

How to read this

For up to five representative held-out rows, the chapter draws one bar chart showing how each additive term of the formula builds that row's prediction of Number of packs per capita. The five rows are the worst prediction (largest absolute residual), the best (smallest), the median miss, the row with the smallest prediction and the row with the largest. When two roles fall on the same row, which is common with few held-out rows, the earlier role keeps it and fewer than five charts appear.

In each chart the bars stack the terms' contributions at the row's input values, terms the formula subtracts sit below zero, and the bars sum to the prediction. The dashed line marks the actual value; the distance between it and the top of the stack is the residual. The bars are evaluated at the same precision as the predictions, so they agree with the Prediction Chart. When the formula has no additive structure, each chart holds one bar for the whole formula, and the Sensitivity chapter is the better read for how individual inputs move it.

What each term is worth

Full-formula R² is 0.417. The formula is non-decomposable, so ablation collapses to a single bar; the chapter "How each term responds to its inputs" is the better surface in this case.

Additive
No
Baseline R²
0.4172
Held-out rows
106

The notebook draws this chapter's figure from each held-out row; the row-by-row detail is there.

How to read this

For each additive term of the formula for Number of packs per capita, the chart shows how much the held-out R² drops when that term is replaced by its mean contribution, so that it no longer varies from row to row. The bars are sorted from the largest drop down, and the dashed line marks the R² of the full model.

A large drop means the term carries real predictive work; the complexity it adds is paid for. A small drop means the term adds little beyond its average value: it may refine a stronger term, or its curve in the chapter "How each term responds to its inputs" may be nearly flat. A negative drop means the held-out R² rises without the term, which is a sign that the term tracks noise in the training rows. Each figure describes what a term contributes inside the model as discovered; the chart diagnoses the model, it is not a guide to removing terms. When the formula has no additive structure, the chart shows one bar for the whole formula.

What-If
The prediction at the typical row: every input at its median or most common value
ItemValue
Avgprs150.5
Consumer price index1.307
Year1990
Prediction105.4
Additive
No
Held-out rows for the interval
106
Terms in the formula
1
Residual P5
-28.9
Residual P95
27.52
Residual std
17.26

How to read this

The chapter shows the model's prediction for Number of packs per capita at one input combination, with the contribution of each term stacked beneath it. The inputs start at their training medians, so the first view is the prediction for a typical row, and each input can move within the range the training rows cover; the notebook lets the reader change the inputs and watch the prediction and the stack update.

In the stack, a long bar marks the term that dominates at this input combination, often the one whose removal costs most in the chapter "What each term is worth". A short bar marks a term that makes a small adjustment here; the chapter "How each term responds to its inputs" shows whether it stays small everywhere or grows toward the edges of the range. A negative bar marks a term that pulls the prediction down at this point, either because the formula subtracts it or because it evaluates below zero.

The inputs stay inside the training range for a reason: the formula computes a value anywhere, but outside that range no training row supports it. When the formula has no additive structure, the stack holds a single bar for the whole formula and the inputs move the prediction directly.

Sensitivity

The prediction responds to 3 inputs. The formula is non-additive: the change in the prediction per unit of each input (∂ŷ/∂xᵢ) is computed with the others held at the training median. Flat curves mean a constant linear response, bent curves a non-linear response that depends on the position in the range, and zero crossings a response that reverses sign between regions.

Additive
No
Terms in the formula
1

How to read this

For each input, the chart traces the rate at which the predicted Number of packs per capita changes as that input moves across its training range, with the other inputs held at their medians. The rate is the local slope of the prediction with respect to the input, measured by a small finite difference at each point. A table summarizes each input with the mean, minimum and maximum of the absolute slope, which ranks the inputs by how strongly the prediction responds to them.

A flat curve means the model is close to linear in that input: the prediction responds at the same rate everywhere in the observed range, which is easy to state and says nothing about values beyond that range. A curve that grows or shrinks marks diminishing or accelerating returns, and whether that is plausible is a question for the domain. A curve that crosses zero means the prediction rises with the input in one part of the range and falls in another, which is either a real optimum or a sign that the formula bends around a few rows. A curve with a large magnitude marks an input to which the prediction is highly responsive; the chapter "What each term is worth" says whether the term behind it also carries predictive work.

In the table, the mean absolute slope ranks the inputs by typical responsiveness. A minimum close to the maximum means the responsiveness is nearly constant; a wide gap means it varies strongly across the range. The chapter reads the whole formula, so it applies whether or not the formula splits into terms.

How two inputs act together

The formula is non-decomposable: every pair of inputs potentially interacts. The heatmaps show the full-formula response across each pair's plane.

The prediction across Avgprs (columns) and Consumer price index (rows), the other inputs at their typical values
Consumer price index \ Avgprs84.97113.3141.7170198.3226.7
1.076153.7115.392.2176.8465.8657.62
1.157165.412499.1982.6570.8461.98
1.239177132.7106.288.4775.8366.35
1.32188.6141.5113.294.2880.8170.71
1.402200.3150.2120.1100.185.875.07
1.483211.9158.9127.1105.990.7879.43
The prediction across Avgprs (columns) and Year (rows), the other inputs at their typical values
Year \ Avgprs84.97113.3141.7170198.3226.7
1985186.3139.7111.793.179.7969.82
1987186.4139.8111.893.1979.8769.89
1989186.6140111.993.2879.9569.96
1990186.714011293.3379.9969.99
1992186.9140.2112.193.4280.0770.06
1994187.1140.3112.293.5280.1570.13
The prediction across Consumer price index (columns) and Year (rows), the other inputs at their typical values
Year \ Consumer price index1.0761.1571.2391.321.4021.483
198586.5593.199.65106.2112.8119.3
198786.6493.299.75106.3112.9119.4
198986.7293.2999.85106.4113119.6
199086.7793.3499.9106.5113119.6
199286.8593.43100106.6113.2119.7
199486.9493.52100.1106.7113.3119.9
Additive
No
Terms in the formula
1

How to read this

When a single term of the formula combines two or more inputs, the prediction's response to one of them depends on the value of the other. This chapter draws one surface for each such pair: the predicted Number of packs per capita across the plane of the two inputs, with every other input held at its training median. Pairs that never share a term have no interaction by construction, and the curves in the chapter "How each term responds to its inputs" already say everything about them. Where the search tested a pair, the summary says on how many pairs of rows the two inputs acted together in the model's output; that is a statement about the formula, not a finding that the data hold no other interaction.

Parallel stripes mean the two inputs act almost independently, so the surface is close to a sum of two one-input curves. Curved contours mean a real interaction, where the slope along one input changes with the other; the location of the peak or trough matters. A saddle, rising along one axis and falling along the other, marks a trade-off between the two. A sharp edge or cliff means the formula encodes a change of regime, and the curve for the same input in the chapter "How each term responds to its inputs" shows whether the bend appears there too.

The grid is deliberately coarse, and the color scale runs from low to high predictions. When the formula has no additive structure, the single whole-formula term holds every input, so every pair appears; the number of surfaces is capped for models with many inputs.

Worst Predictions

The worst held-out row was missed by 61.6 (target's scale). The 10 rows with the largest absolute residuals out of 106 held-out rows are shown. Each card breaks the failure down into per-term contributions and input values, so the failure mode is inspectable. A large residual with one concentrated term contribution means one term got this row wrong; a large residual with balanced contributions means a structural mismatch.

ActualPredictedResidualAvgprsConsumer price indexYear
197.99136.43+61.5795.51.0761985
185.20126.66+58.54108.71.1361987
64.42106.38-41.97169.41.4821994
57.4498.74-41.30152.41.241989
88.74126.77-38.02102.81.0761985
129.7392.62+37.11162.41.241989
71.58106.89-35.31148.41.3071990
175.95141.35+34.6097.411.1361987
124.1090.80+33.30187.81.4031992
57.8787.32-29.45206.41.4821994
Additive
No
N extrapolated
0
Held-out rows
106
Held-out rows for the interval
106
Residual P5
-28.9
Residual P95
27.52
Residual std
17.26

How to read this

The held-out rows on which the model misses Number of packs per capita by the most, sorted by absolute residual with the largest first and capped at ten. Each card shows the row's actual value, the prediction, the residual, the contribution of every additive term at that row and the row's input values. R² and MAE say how good the model is on average; these cards say where it fails and let each failure be read input by input and term by term.

A large residual with one dominant term means that term produced the wrong value at this row; the row's value for that input, read against its curve in the chapter "How each term responds to its inputs", shows whether it fell in a region the formula models poorly. A large residual with balanced contributions means every term was a little off and the sum still missed, which points to a shape the formula cannot represent in that region. Residuals that change sign from card to card mean the misses are not a consistent bias but scattered errors on particular rows. When the formula has no additive structure, each card shows a single whole-formula contribution.

Prediction Interval Coverage

Across 106 held-out rows, the 95% prediction interval actually covers 92.5% of the rows. The normal band is wider than needed for this residual distribution (worst gap 12.3 percentage points), often because a few large residuals inflate σ above what the bulk requires. Real uncertainty for typical rows is tighter than the interval suggests.

Nominal levelHalf-widthEmpirical coverage
50 %11.6462.26 %
80 %22.1283.96 %
90 %28.489.62 %
95 %33.8492.45 %
Largest miss (percentage points)
12.26
Held-out rows
106
Residual P2.5
-36.33
Residual P97.5
35.54
Verdict
Underconfident

How to read this

Each held-out prediction of Number of packs per capita carries a prediction interval, and this chapter checks whether that interval covers the actual value as often as it claims. The interval reported with each prediction is built from the held-out residuals themselves: its bounds are the 2.5th and 97.5th percentiles of the residuals added to the prediction, so it is asymmetric when the residuals are skewed and assumes no particular error distribution.

The coverage table checks a second, simpler band: the symmetric interval that a normal error distribution with the residuals' standard deviation would give. At four nominal levels (50%, 80%, 90% and 95%) it lists the half-width of that normal band and the share of held-out rows whose actual value falls inside it. Empirical coverage close to nominal means the residuals are close enough to normal that the two bands agree and the interval can be taken at face value. Empirical coverage below nominal means the normal band is too narrow, the residuals have heavier tails than a normal distribution, and the percentile-based interval is the one to trust. Empirical coverage above nominal means the normal band is wider than the data needs, usually because a few large residuals inflate the standard deviation. Every figure comes from the same held-out residuals the intervals are built from.

Regression Diagnostics

106 held-out residuals, with a spread up to 61.6 in absolute terms. Mean residual is -1.92, close to zero. The model is approximately unbiased on these held-out rows (a small held-out set makes this less reliable; the Prediction Chart chapter states R² and the mean absolute error with their 95% confidence intervals). The charts below check whether the errors look like noise: a pattern in residuals-vs-fitted or a curving Q-Q means a structural miss. The held-out rows are a random draw, so their order carries no time and the autocorrelation of the residuals is not assessed.

Abs residual vs predicted r
0.2128
Bias
-1.916
Bias over residual sd
-0.111
Held-out rows
106
Order
shuffled
Residual sd
17.26
Share within normal band
0.9245

The notebook draws this chapter's figure from each held-out row; the row-by-row detail is there.

How to read this

Four residual diagnostics for Number of packs per capita, all computed from the held-out residuals. Each asks in its own way whether the model's errors look like noise, which is what remains when a model has captured all the structure the data holds.

Residuals against predicted values: Each held-out row is plotted with the model's prediction on the horizontal axis and its residual on the vertical axis, around a zero line. A symmetric cloud around zero means errors of similar size across the predicted range and no systematic bias. A funnel or fan means the size of the errors depends on the predicted value: the model is more uncertain in some regions than in others, and its prediction interval is not equally trustworthy everywhere. A curved pattern, a smile or a frown, means the model misses a structural component; the chapters "How each term responds to its inputs" and "How two inputs act together" show the shapes the formula does capture.

Normal Q-Q plot: The sorted residuals are plotted against the quantiles of a normal distribution, with the diagonal marking a perfectly normal set of residuals. Points that hug the line mean approximately normal residuals, so the normal band in the Prediction Interval Coverage chapter will hold. An S-shape means heavier or lighter tails than normal; heavier tails (below the line at the left, above it at the right) mean the model occasionally produces large errors. A banana or arc means skewed residuals: the model is systematically high or low in part of the range.

Histogram: The residuals binned into equal-width intervals. A bell centered on zero means symmetric errors with no bias. An off-center bell means the model is biased, with a mean error away from zero. A long tail or two peaks mean outliers or two regimes inside the prediction range.

Autocorrelation: For each lag, the correlation of the residual sequence with itself shifted by that many rows, with the band that pure noise would stay inside at plus or minus 1.96 divided by the square root of the row count. Bars inside the band mean uncorrelated residuals with no order-dependent structure left. A bar at lag 1 outside the band means the residuals of neighbouring dates correlate: structure in time that the model has not captured. A wave across the lags means periodic structure remains, and the Time Series chapter in the Data section is where to look for its period.

Autocorrelation carries meaning only when the row order itself does. When the data has a date column, the held-out rows are the most recent ones in date order, and the autocorrelation is assessed. Without a date column the held-out rows are a random draw: the row after a held-out row is an arbitrary other row, so the autocorrelation is not assessed and the summary above says so.

Search Progress

The search ran for 122 generations, ending at quality 0.551 (gain +0.0533 from generation 2). The curve shows a substantial climb; if the last generations are still rising, a longer time limit is likely to produce a better model.

First generation
2
First quality
49.79 %
Last generation
123
Last quality
55.13 %
Max quality
55.13 %
N points
122
N total generations
122

How to read this

The line traces the best quality the search for the Number of packs per capita model had reached at each generation, from the first generation to the last. Quality is the technology's combined score on the training rows, the figure the Model Metrics chapter defines. A curve that flattens well before the last generation means the search converged: the budget was more than enough, and the model is the one the search settled on. A curve still rising at the last generation means the budget ended before the search settled, and the model is the best the search reached within it. The chart describes the search, not the data: it says whether the search had time to settle, not whether more rows would help.

Model Constraints

Across 106 held-out predictions, the formula is mathematically well-behaved: every output is finite, stays inside the training-target ±2σ band, and no prediction runs away beyond the bounded-prediction limit. It is safe to consume downstream at face value.

NameStatusDetail
Output coherentPassno non-finite predictions across 106 rows
Within domainPassno rows outside the training target's ±2σ range across 106 rows
Bounded predictionsPassno runaway predictions beyond ±10σ across 106 rows
Held-out rows
106
N non finite
0
N outside domain
0
N runaway
0
Verdict
Clean

How to read this

Sanity checks on the Number of packs per capita formula, run against the held-out rows. Three checks: every prediction is a finite number (output coherent), predictions stay within the range of the training target widened by two standard deviations on each side (within domain), and no single prediction runs away more than ten standard deviations from the training mean (bounded predictions).

These are pass or fail guards, not quality measures: a formula can clear all three and still predict poorly. A failure is the stronger signal. It means the formula misbehaves numerically somewhere in the data it was shown, and any downstream use of it should wait until that is understood.

Modeling

Measured during the search, on the rows the model was trained on

Error
61.51 %
N train
422
Quality
32.63 %

How to read this

The function below trains the model for Number of packs per capita on the processed data. Its output is the model that every other chapter of this section scores and dissects.

Findings

2 findings from the model diagnostics (1 Critical, 1 Warning) are listed in the Concerns chapter at the top of the analysis.

Data

Variables in the data move closely together, especially state and population as well as consumer price index and year. State accounts for most of the observed variation in number of packs per capita. All rows are complete and the data contains no suspected leakage or duplicate rows.

Most notable in the Data section:

  • State accounts for 76% of the spread in Packpc: KY averages 117 above UT (95% interval 110 to 124)
  • Pop and State go together (association 0.998)
  • Consumer price index and Year move together (correlation 0.996)

How to read this

The Data section describes the table as supplied, before any modeling: the Column Profiles overview of every column and its role, one chapter per column with its distribution and correlations, a closer look at columns with notable characteristics, Duplicate Rows, Leakage Suspicion, a map for paired coordinate columns, and the General chapter with descriptive statistics, correlations, missing values, outlier ranges, clusters and segments across all columns.

Column Profiles

Profiled 9 columns across 528 rows (8 numeric, 1 non-numeric): every column is at least 75% populated. Distributional statistics on numeric columns can be read at face value. 2 columns are strongly skewed: the mean of such a column is pulled toward its long tail, so the median is the better guide to a typical value.

Columns
NameRoleTypeNMissingMeanStdMinP25MedianP75MaxSkewnessCV
Number of packs per capitaTargetnumber5280106.523.149.391.4105.9119.6198.00.63810.2172
AvgprsInputnumber5280150.333.185.0121.4150.5173.7240.80.19380.2204
Consumer price indexInputnumber52801.2960.1521.0761.1361.3071.4451.524-0.028860.1175
IncomeInputinteger528099,245,556117,020,4676,769,88325,100,46161,692,010118,084,118771,470,1442.7251.179
PopInputinteger52805,159,7385,448,905453,4011,579,2483,628,2546,012,16331,493,5242.4181.056
StateInputtext5280
TaxInputnumber528040.3512.3618.0032.0039.0046.3199.000.89670.3062
TaxsInputnumber528046.1814.8820.8136.0043.0053.16112.630.96730.3222
YearInputinteger5280199031985198719901993199500.001591
N columns
9
N high missing
0
N rows
528
N strongly skewed
2
Table branch
main
Table ID
5c628d86-9010-4408-b16c-47a784dfbe4c

How to read this

One row per column of the analyzed table: its role in the analysis (the target being predicted, an input it is predicted from, or the segment column), its type, value count and missing count, and for numeric columns the mean, standard deviation, minimum, quartiles, maximum and interquartile range. A column with 25% or more missing values is flagged; its mean and quartiles describe only the rows that have a value.

Two further figures describe the shape of a numeric column. The skewness says whether the values lean to one side: close to zero the column is symmetric, from 0.5 it is moderately skewed and from 1 strongly skewed, with the longer tail on the high side when the figure is positive and on the low side when it is negative. In a strongly skewed column the mean is pulled toward the tail, and the median is the better guide to a typical value. The coefficient of variation is the standard deviation divided by the mean: it compares how widely columns spread regardless of their units, and is given only for a column whose mean is positive.

These are the columns as supplied, before any modeling: the reference against which every later chapter reads.

Avgprs

Avgprs: 85.0 to 241, median 151; moves with Cpi most (r 0.856).

How to read this

A column chapter profiles one column: its distribution in figures and charts, and how it relates to the other columns. It opens with one line on what the column holds. The Description chapter carries its figures, with every other column summarized for each of its values where it has few, and its association with every other column where it is numeric. The Visualization chapter carries its charts. A table with a date column adds an Over Time and a Time Series chapter; a target with classes adds a Class Balance chapter.

Description
Avgprs
StatisticValue
Typenumber
Values present528
Distinct values526
Continuousyes
Decimal places13
Minimum84.97
Maximum240.8
Mean150.3
Median150.5
Mode126.586250305176

The first 10 rows of 17. The other 7 are in the notebook.

How to read this

The figures below summarize Avgprs in numbers: where its values center (mean, median, mode), how far they spread (range, variance, standard deviation, interquartile range) and how they are distributed across percentiles. They are the reference for every chart in the Visualization chapter and for the correlation measures further down.

The figures for Avgprs are grouped: the column itself first, then where its values center, how far they spread, the shape of their distribution and its percentiles. Each statistic is explained in the Description chapter under General in the Data section.

Correlation
Correlations
ColumnPair ofAssociationPearson's r95% CI (Pearson)Spearman's ρKendall's τq-valueRows
Consumer price indextwo numbers0.85980.85580.8312 to 0.87710.85980.6932< 0.001528
Yeartwo numbers0.85980.84630.8202 to 0.86890.85980.6932< 0.001528
Taxstwo numbers0.8510.8510.8256 to 0.87290.83220.6507< 0.001528
Taxtwo numbers0.81030.81030.7788 to 0.83770.78430.6019< 0.001528
Number of packs per capitatwo numbers0.6261-0.5854-0.6389 to -0.5264-0.6261-0.4469< 0.001528
Statea number and a category0.4208< 0.001528
Incometwo numbers0.27580.27580.1951 to 0.35280.22210.1527< 0.001528
Poptwo numbers0.14720.14720.06263 to 0.22960.082540.05725< 0.001528

How to read this

Each row pairs Avgprs with one other column, numeric or categorical, and reports how strongly the two go together on an association from 0 to 1, and whether an association this strong could be chance. For another numeric column the row adds the direction: Pearson's coefficient measures a straight-line relationship, and Spearman's rho and Kendall's tau measure a monotonic relationship on ranks, which makes them resistant to outliers and lets them see a curved but consistently rising or falling pattern. For a categorical column the association is the correlation ratio η, which has no direction. A strong association is not an explanation: two columns can go together when a third one moves both.

The table lists every other numeric or categorical column against Avgprs, with the pair's kind and association, three correlation coefficients and a confidence interval where the other column is numeric, the q-value and the rows the pair was measured on.

MeasureMeaning
KindWhat the other column holds: a number (numeric) or categories (numeric_categorical). A categorical column is one that is not numeric and holds between 2 and 50 distinct values
AssociationThe strength of the pair from 0 to 1. With a numeric column: the stronger of Pearson's coefficient and Spearman's ρ, without its sign. With a categorical column: the correlation ratio η, the square root of the share of Avgprs's spread that lies between the categories
CovarianceNumeric partner only. The direction of the relationship (positive or negative) in the units of the two columns. It is not standardized, so its size says little about strength without the columns' own spread
Pearson's Correlation CoefficientNumeric partner only. The strength and direction of a linear relationship, from -1 (a perfect falling line) through 0 (no linear relationship) to 1 (a perfect rising line)
Spearman's ρNumeric partner only. The strength and direction of a monotonic relationship, computed on ranks rather than values, from -1 to 1. It follows a curved pattern as long as it rises or falls consistently, and outliers move it little
Kendall's τNumeric partner only. The strength and direction of association from the agreement and disagreement of rank order across pairs of rows, from -1 to 1. It is the steadier of the two rank measures when the rows are few
q-valueHow likely a pair this strong is among unrelated columns, adjusted for the number of pairs involving Avgprs (Benjamini-Hochberg). Among all pairs reported with q below 0.05, about 5% or fewer are expected to be false discoveries
95% CI (Pearson)Numeric partner only. The lower and upper bounds of the 95% confidence interval on the Pearson coefficient, from the Fisher z-transform. An interval that contains 0 leaves the direction of the relationship open
RowsThe rows in which both columns hold a value. The q-value and the interval of a pair rest on this count
Visualization

The rows of Avgprs are not charted in their order: consecutive rows are no more alike than rows picked at random (a correlation of 0.05 between each value and the next), so the order carries no pattern to show.

How to read this

The charts in this chapter were chosen from the type of Avgprs and of the columns it is compared with: a numeric column gets a histogram, a box plot and, when its row order carries a pattern, a value sequence, a categorical column gets a frequency chart, and its relation to each target of the analysis, and to the segment column when there is one, gets the chart that suits the pair, with the target on the vertical axis where it is a number. A column is not charted against every other column; which columns move together is shown under Strongest Correlations. The charts complement the figures in the Description chapter; the shape of a distribution and the position of its outliers are easier to see than to read.

Consumer price index

Cpi: 1.08 to 1.52, median 1.31, 11 distinct values; moves with Year most (r 0.996).

Description
Consumer price index
StatisticValue
Typenumber
Values present528
Distinct values11
Continuousyes
Decimal places14
Minimum1.076
Maximum1.524
Mean1.296
Median1.307
Mode1.07599997520447

The first 10 rows of 17. The other 7 are in the notebook.

By Value

Cpi accounts for 15% of the spread in Packpc: 1.07599997520447 averages 27.0 above 1.48199999332428 (95% interval 18.4 to 35.7). An association, not a cause.

Groups
TargetValueRowsAverage or share95% interval
Number of packs per capita1.0759999752044748122115.9 to 128.2
Number of packs per capita1.0959999561309848118.8112.7 to 124.9
Number of packs per capita1.136000037193348116.3110.4 to 122.2
Number of packs per capita1.1830000877380448113.5107.2 to 119.7
Number of packs per capita1.2400000095367448109.1102.9 to 115.4
Number of packs per capita1.3069999217987148104.297.92 to 110.4
Number of packs per capita1.3619999885559148100.995.01 to 106.9
Number of packs per capita1.402999997138984898.5392.53 to 104.5
Number of packs per capita1.52399992942814896.3389.42 to 103.2
Number of packs per capita1.445000052452094896.2790.25 to 102.3

The first 10 rows of 11. The other 1 is in the notebook.

Mean per value of Consumer price index
Consumer price indexRowsPopIncomeYearNumber of packs per capitaTaxAvgprsTaxs
1.07599997520447484,911,27172,084,490198512231.68103.634.79
1.09599995613098484,956,79276,192,3471986118.832.78110.936.2
1.1360000371933485,001,68881,325,3331987116.333.611937.48
1.18300008773804485,047,56387,701,6351988113.535.19130.439.84
1.24000000953674485,094,85494,437,3581989109.135.81142.541.08
1.30699992179871485,149,891100,665,9581990104.237.59153.843.39
1.36199998855591485,205,399104,360,9161991100.940.89169.347.35
1.40299999713898485,264,761110,774,809199298.5343.9118551.85
1.44500005245209485,321,828115,340,392199396.2747.07178.654.82
1.48199999332428485,376,615121,144,894199495.0351.64176.359.32

The first 10 rows of 11. The other 1 is in the notebook.

How to read this

The rows are grouped by the value of Consumer price index, and every other column is summarized within each group with the same descriptive statistics. A statistic that shifts from group to group marks a column that moves with Consumer price index; one that stays level marks a column that does not. Groups with few rows produce unstable figures, so the row count of each group is the first thing to read. Where the groups differ in a target by more than chance would give, the chapter states by how much; it states that the two go together, not that one brings the other about.

Correlation
Correlations
ColumnPair ofAssociationPearson's r95% CI (Pearson)Spearman's ρKendall's τq-valueRows
Yeartwo numbers10.99640.9957 to 0.996911< 0.001528
Avgprstwo numbers0.85980.85580.8312 to 0.87710.85980.6932< 0.001528
Taxstwo numbers0.59720.59720.5394 to 0.64950.59720.4399< 0.001528
Taxtwo numbers0.57440.57440.5143 to 0.62890.57070.4195< 0.001528
Number of packs per capitatwo numbers0.4511-0.4036-0.4726 to -0.3296-0.4511-0.3247< 0.001528
Incometwo numbers0.1740.15110.06665 to 0.23340.1740.1258< 0.001528
Poptwo numbers0.040410.03033-0.05515 to 0.11540.040410.032080.5564528
Statea number and a category01528
Visualization

The rows of Cpi are not charted in their order: consecutive rows are no more alike than rows picked at random (a correlation of 0.00 between each value and the next), so the order carries no pattern to show.

Income

Income: 6,769,883 to 771,470,144, median 61,692,010, skewed to high values; moves with Pop most (r 0.977).

Description
Income
StatisticValue
Typeinteger
Values present528
Distinct values528
Continuousyes
Decimal places0
Minimum6,769,883
Maximum771,470,144
Mean99,245,556
Median61,692,010
Mode6769883

The first 10 rows of 17. The other 7 are in the notebook.

Correlation
Correlations
ColumnPair ofAssociationPearson's r95% CI (Pearson)Spearman's ρKendall's τq-valueRows
Poptwo numbers0.97940.9770.9727 to 0.98050.97940.8828< 0.001528
Statea number and a category0.9742< 0.001528
Taxstwo numbers0.29580.29580.2159 to 0.37170.19310.1376< 0.001528
Avgprstwo numbers0.27580.27580.1951 to 0.35280.22210.1527< 0.001528
Taxtwo numbers0.26810.26810.187 to 0.34550.16740.1151< 0.001528
Number of packs per capitatwo numbers0.2554-0.2554-0.3334 to -0.1738-0.1185-0.09114< 0.001528
Consumer price indextwo numbers0.1740.15110.06665 to 0.23340.1740.1258< 0.001528
Yeartwo numbers0.1740.15140.06697 to 0.23380.1740.1258< 0.001528
Visualization

The rows of Income are not charted in their order: consecutive rows are no more alike than rows picked at random (a correlation of 0.00 between each value and the next), so the order carries no pattern to show.

Number of packs per capita

Packpc: 49.3 to 198, median 106; moves opposite to Taxs most (r -0.588).

Description
Number of packs per capita
StatisticValue
Typenumber
Values present528
Distinct values528
Continuousyes
Decimal places13
Minimum49.27
Maximum198
Mean106.5
Median105.9
Mode49.2721977233887

The first 10 rows of 17. The other 7 are in the notebook.

Correlation
Correlations
ColumnPair ofAssociationPearson's r95% CI (Pearson)Spearman's ρKendall's τq-valueRows
Statea number and a category0.8862< 0.001528
Avgprstwo numbers0.6261-0.5854-0.6389 to -0.5264-0.6261-0.4469< 0.001528
Taxstwo numbers0.6227-0.5876-0.6408 to -0.5288-0.6227-0.4495< 0.001528
Taxtwo numbers0.596-0.5677-0.6229 to -0.507-0.596-0.4342< 0.001528
Consumer price indextwo numbers0.4511-0.4036-0.4726 to -0.3296-0.4511-0.3247< 0.001528
Yeartwo numbers0.4511-0.4004-0.4697 to -0.3262-0.4511-0.3247< 0.001528
Incometwo numbers0.2554-0.2554-0.3334 to -0.1738-0.1185-0.09114< 0.001528
Poptwo numbers0.1813-0.1813-0.2626 to -0.09751-0.03312-0.02946< 0.001528
Visualization

The rows of Packpc are not charted in their order: consecutive rows are no more alike than rows picked at random (a correlation of 0.01 between each value and the next), so the order carries no pattern to show.

Pop

Pop: 453,401 to 31,493,524, median 3,628,254, skewed to high values; moves with Income most (r 0.977).

Description
Pop
StatisticValue
Typeinteger
Values present528
Distinct values518
Continuousyes
Decimal places0
Minimum453,401
Maximum31,493,524
Mean5,159,738
Median3,628,254
Mode696000

The first 10 rows of 17. The other 7 are in the notebook.

Correlation
Correlations
ColumnPair ofAssociationPearson's r95% CI (Pearson)Spearman's ρKendall's τq-valueRows
Statea number and a category0.9981< 0.001528
Incometwo numbers0.97940.9770.9727 to 0.98050.97940.8828< 0.001528
Taxstwo numbers0.18650.18650.1028 to 0.26750.074880.05799< 0.001528
Number of packs per capitatwo numbers0.1813-0.1813-0.2626 to -0.09751-0.03312-0.02946< 0.001528
Taxtwo numbers0.15410.15410.06963 to 0.23630.041910.032< 0.001528
Avgprstwo numbers0.14720.14720.06263 to 0.22960.082540.05725< 0.001528
Consumer price indextwo numbers0.040410.03033-0.05515 to 0.11540.040410.032080.4868528
Yeartwo numbers0.040410.03042-0.05506 to 0.11550.040410.032080.4868528
Visualization

The rows of Pop are not charted in their order: consecutive rows are no more alike than rows picked at random (a correlation of -0.00 between each value and the next), so the order carries no pattern to show.

State

State: 48 distinct values, most often DE.

Description
State
StatisticValue
Typetext
Values present528
Distinct values48
Continuousno
ModeDE
Rows per value
VariableValueRowsShare
StateAL112.083 %
StateAR112.083 %
StateAZ112.083 %
StateCA112.083 %
StateCO112.083 %
StateCT112.083 %
StateDE112.083 %
StateFL112.083 %
StateGA112.083 %
StateIA112.083 %

The first 10 rows of 48. The other 38 are in the notebook.

By Value

State accounts for 76% of the spread in Packpc: KY averages 117 above UT (95% interval 110 to 124). An association, not a cause.

Groups
TargetValueRowsAverage or share95% interval
Number of packs per capitaKY11173.9168.3 to 179.5
Number of packs per capitaNH11166.3153.7 to 178.9
Number of packs per capitaNC11134.9125 to 144.7
Number of packs per capitaIN11131.6127.8 to 135.4
Number of packs per capitaDE11128.4121.9 to 135
Number of packs per capitaVT11125.5120.1 to 130.9
Number of packs per capitaMO11124.1120.8 to 127.4
Number of packs per capitaTN11123.5119.6 to 127.4
Number of packs per capitaAR11119.1113.4 to 124.9
Number of packs per capitaSC11119.1113.8 to 124.4

The first 10 rows of 24. The other 14 are in the notebook.

Mean per value of State
StateRowsPopIncomeYearNumber of packs per capitaTaxAvgprsConsumer price indexTaxs
AL114,091,14764,137,2271990109.935.05139.81.29636.27
AR112,386,78035,031,5071990119.142.11148.91.29647.29
AZ113,713,24064,086,970199087.7836.96150.31.29644.12
CA1129,474,096623,427,174199076.743.59169.21.29653.85
CO113,393,75367,137,756199093.0337.64138.41.29637.64
CT113,262,42384,549,187199093.2354.841771.29666.59
DE11668,62514,187,4191990128.436.83141.31.29636.83
FL1112,876,312249,924,9611990106.146.5162.91.29655.3
GA116,545,529116,220,7351990113.930.55134.21.29631.76
IA112,799,79348,131,054199099.3149.19156.81.29655.69

The first 10 rows of 48. The other 38 are in the notebook.

Tax

Tax: 18 to 99, median 39; moves with Taxs most (r 0.971).

Description
Tax
StatisticValue
Typenumber
Values present528
Distinct values141
Continuousyes
Decimal places13
Minimum18
Maximum99
Mean40.35
Median39
Mode34.0

The first 10 rows of 17. The other 7 are in the notebook.

Correlation
Correlations
ColumnPair ofAssociationPearson's r95% CI (Pearson)Spearman's ρKendall's τq-valueRows
Taxstwo numbers0.97130.97130.966 to 0.97580.95140.8289< 0.001528
Avgprstwo numbers0.81030.81030.7788 to 0.83770.78430.6019< 0.001528
Statea number and a category0.7083< 0.001528
Number of packs per capitatwo numbers0.596-0.5677-0.6229 to -0.507-0.596-0.4342< 0.001528
Yeartwo numbers0.57850.57850.5188 to 0.63260.57070.4195< 0.001528
Consumer price indextwo numbers0.57440.57440.5143 to 0.62890.57070.4195< 0.001528
Incometwo numbers0.26810.26810.187 to 0.34550.16740.1151< 0.001528
Poptwo numbers0.15410.15410.06963 to 0.23630.041910.032< 0.001528
Visualization

The rows of Tax are not charted in their order: consecutive rows are no more alike than rows picked at random (a correlation of 0.07 between each value and the next), so the order carries no pattern to show.

Taxs

Taxs: 20.8 to 113, median 43, skewed to high values; moves with Tax most (r 0.971).

Description
Taxs
StatisticValue
Typenumber
Values present528
Distinct values466
Continuousyes
Decimal places13
Minimum20.81
Maximum112.6
Mean46.18
Median43
Mode43.0

The first 10 rows of 17. The other 7 are in the notebook.

Correlation
Correlations
ColumnPair ofAssociationPearson's r95% CI (Pearson)Spearman's ρKendall's τq-valueRows
Taxtwo numbers0.97130.97130.966 to 0.97580.95140.8289< 0.001528
Avgprstwo numbers0.8510.8510.8256 to 0.87290.83220.6507< 0.001528
Statea number and a category0.6948< 0.001528
Number of packs per capitatwo numbers0.6227-0.5876-0.6408 to -0.5288-0.6227-0.4495< 0.001528
Yeartwo numbers0.59990.59990.5423 to 0.65180.59720.4399< 0.001528
Consumer price indextwo numbers0.59720.59720.5394 to 0.64950.59720.4399< 0.001528
Incometwo numbers0.29580.29580.2159 to 0.37170.19310.1376< 0.001528
Poptwo numbers0.18650.18650.1028 to 0.26750.074880.05799< 0.001528
Visualization

The rows of Taxs are not charted in their order: consecutive rows are no more alike than rows picked at random (a correlation of 0.07 between each value and the next), so the order carries no pattern to show.

Year

Year: 1,985 to 1,995, median 1,990, 11 distinct values; moves with Cpi most (r 0.996).

Description
Year
StatisticValue
Typeinteger
Values present528
Distinct values11
Continuousyes
Decimal places0
Minimum1985
Maximum1995
Mean1990
Median1990
Mode1985

The first 10 rows of 17. The other 7 are in the notebook.

By Value

Year accounts for 15% of the spread in Packpc: 1985 averages 27.0 above 1994 (95% interval 18.4 to 35.7). An association, not a cause.

Groups
TargetValueRowsAverage or share95% interval
Number of packs per capita198548122115.9 to 128.2
Number of packs per capita198648118.8112.7 to 124.9
Number of packs per capita198748116.3110.4 to 122.2
Number of packs per capita198848113.5107.2 to 119.7
Number of packs per capita198948109.1102.9 to 115.4
Number of packs per capita199048104.297.92 to 110.4
Number of packs per capita199148100.995.01 to 106.9
Number of packs per capita19924898.5392.53 to 104.5
Number of packs per capita19954896.3389.42 to 103.2
Number of packs per capita19934896.2790.25 to 102.3

The first 10 rows of 11. The other 1 is in the notebook.

Mean per value of Year
YearRowsPopIncomeNumber of packs per capitaTaxAvgprsConsumer price indexTaxs
1985484,911,27172,084,49012231.68103.61.07634.79
1986484,956,79276,192,347118.832.78110.91.09636.2
1987485,001,68881,325,333116.333.61191.13637.48
1988485,047,56387,701,635113.535.19130.41.18339.84
1989485,094,85494,437,358109.135.81142.51.2441.08
1990485,149,891100,665,958104.237.59153.81.30743.39
1991485,205,399104,360,916100.940.89169.31.36247.35
1992485,264,761110,774,80998.5343.911851.40351.85
1993485,321,828115,340,39296.2747.07178.61.44554.82
1994485,376,615121,144,89495.0351.64176.31.48259.32

The first 10 rows of 11. The other 1 is in the notebook.

Correlation
Correlations
ColumnPair ofAssociationPearson's r95% CI (Pearson)Spearman's ρKendall's τq-valueRows
Consumer price indextwo numbers10.99640.9957 to 0.996911< 0.001528
Avgprstwo numbers0.85980.84630.8202 to 0.86890.85980.6932< 0.001528
Taxstwo numbers0.59990.59990.5423 to 0.65180.59720.4399< 0.001528
Taxtwo numbers0.57850.57850.5188 to 0.63260.57070.4195< 0.001528
Number of packs per capitatwo numbers0.4511-0.4004-0.4697 to -0.3262-0.4511-0.3247< 0.001528
Incometwo numbers0.1740.15140.06697 to 0.23380.1740.1258< 0.001528
Poptwo numbers0.040410.03042-0.05506 to 0.11550.040410.032080.5548528
Statea number and a category01528
Visualization

The rows of Year are not charted in their order: consecutive rows are no more alike than rows picked at random (a correlation of 0.01 between each value and the next), so the order carries no pattern to show.

Duplicate Rows

Across 528 rows the table has no exact duplicates: every row's value vector is unique across all columns, so the row count reflects distinct rows.

Largest group size
0
N exact duplicates
0
N exact groups
0
N rows
528
N unique
528
Pct exact duplicates
0
Verdict
Clean

How to read this

This chapter counts rows that repeat another row exactly, value for value: how many rows take part in a duplicate group, how many groups exist, and how large the largest group is.

Duplicate rows inflate the apparent row count and can place identical rows on both sides of the training and held-out split, which flatters every quality figure in this report. Only exact repeats are detected here; rows that differ by a rounding digit or a whitespace variant count as distinct.

Leakage Suspicion

Nothing to check. No column that awaits an answer tracks a target at 0.95 or more, so no column on its own gives a target away.

Categorical verdict
Clean
Critical threshold
0.999
N categorical critical
0
N categorical suspects
0
N confirmed
0
N critical
0
N suspects
0
Threshold
0.95
Verdict
Clean

How to read this

For every column that is not a target, this chapter reads how closely the column tracks each target, on an association from 0 to 1, and lists any pair at 0.95 or more. For two numeric columns the association is the stronger of Pearson's r and Spearman's rho; when the column or the target is categorical it is the correlation ratio η, or Cramér's V when both are. At 0.999 or more the column reproduces the target: that is what a copy or a rescaled copy of it looks like.

A listed column poses one question: is its value known before the target's value exists? If it is, the column is a strong input and the quality stated in this report is real. If it was computed from the target or recorded after it, a formula that reads it looks right on these rows and will not hold on new data. The coefficients read the same in both cases; the answer needs someone who knows where the column came from.

The owner of the analysis can give that answer. A column confirmed as known before the target is listed as confirmed and is no longer a suspect. A column that turns out to be a leak is left out of the model's inputs, and the analysis run again.

General

Clustering found no clear groups. The best grouping of the 528 complete rows over 7 numeric columns is into 2 groups, with a silhouette of 0.394 (on a scale where 1 is fully separate groups and 0 is none), below the 0.50 that clear structure shows, so no Clusters chapter is written.

Groupings tried
GroupsSilhouetteInertiaKept
20.39352128.6yes
30.38941583.4
40.37451307.2
50.37191025.9
60.3788920.4
Inertia
2128.6
K
2
N columns used
7
N rows
528
N rows complete
528
Silhouette
0.3935
Verdict
Weak

How to read this

The General chapter covers what holds across all columns together: descriptive statistics, correlations, missing values and outlier ranges under Description, the Clusters found among the rows, and, when a segment column was chosen, the Segments.

Description
Columns
VariableTypeValues presentDistinct valuesContinuousDecimal places
Popinteger528518yes0
Incomeinteger528528yes0
Yearinteger52811yes0
Number of packs per capitanumber528528yes13
Taxnumber528141yes13
Avgprsnumber528526yes13
Statetext52848no
Consumer price indexnumber52811yes14
Taxsnumber528466yes13
Center
VariableMeanMedianMode
Pop5,159,7383,628,254696000
Income99,245,55661,692,0106769883
Year199019901985
Number of packs per capita106.5105.949.2721977233887
Tax40.353934.0
Avgprs150.3150.5126.586250305176
StateDE
Consumer price index1.2961.3071.07599997520447
Taxs46.184343.0
Spread
VariableMinimumMaximumStandard deviationVarianceInterquartile rangeSum
Pop453,40131,493,5245,448,9052.969e+134,432,9152,724,341,877
Income6,769,883771,470,144117,020,4671.369e+1692,983,65852,401,653,491
Year198519953.16510.0261,050,720
Number of packs per capita49.2719823.12534.728.1956208.2
Tax189912.36152.714.3121303.8
Avgprs84.97240.833.121096.752.3679333.5
State
Consumer price index1.0761.5240.15230.023190.309684.2
Taxs20.81112.614.88221.417.1624383.7
Shape
VariableSkewnessKurtosisTotal sum of squares
Pop2.4187.1051.565e+16
Income2.7259.3417.217e+18
Year0-1.225280
Number of packs per capita0.63811.541281,803
Tax0.89671.24480460.1
Avgprs0.1938-0.7467577,974
State
Consumer price index-0.02886-1.42212.22
Taxs0.96730.9345116,695
Rows per value
VariableValueRowsShare
StateAL112.083 %
StateAR112.083 %
StateAZ112.083 %
StateCA112.083 %
StateCO112.083 %
StateCT112.083 %
StateDE112.083 %
StateFL112.083 %
StateGA112.083 %
StateIA112.083 %

The first 10 rows of 48. The other 38 are in the notebook.

How to read this

This chapter summarizes every column at once: the descriptive statistics table below, then Correlation, Missing Values and Outliers. For a numeric column the table reports its center (mean, median, mode), its spread (standard deviation, variance, interquartile range, percentiles) and its shape (skewness, kurtosis); for a categorical column it reports the count and share of each category.

Each row of the tables describes one column. The statistics are grouped: the column itself, where its values center, how far they spread, what shape their distribution takes, and its percentiles. They read as follows.

StatisticExplanation
VariableName of the column the statistics in the row describe
TypeType assigned during data processing (bool, integer, number, decimal, text or date)
Values presentNumber of rows in which the column holds a value
Distinct valuesNumber of different values the column holds
ContinuousWhether the column can take any value in a range, as opposed to a discrete column limited to a fixed set of values
Decimal placesLength of the fractional part of the values
MeanArithmetic average: the sum of all values divided by the number of values
MedianThe middle value: half of the values lie at or below it and half at or above it. It is also the 50 % percentile
ModeThe value that appears most often
MinimumSmallest numeric value in the column

The first 10 rows of 20. The other 10 are in the notebook.

Missing Values

No column has a missing value: all 528 rows are complete.

N columns with missing
0
N complete rows
528
N rows
528
Pct complete rows
100

How to read this

The table lists, for each column, the count of present values (Values) beside the row count of the processed table (Rows), the number of missing values and their share. The larger the share, the less any statistic or model built on the column can be trusted.

  • Below 5% missing: safe to use as it is.
  • 5% to 25% missing: usable; filling the gaps or excluding those rows is worth considering.
  • 25% or more missing: the column is flagged and receives its own chapter in the Data section. Verify why so much is missing before trusting any result that depends on it.

A model is computed only on rows that hold a value in every column it reads, so gaps spread over several columns cost more rows than any one column's share suggests. The last column, Complete rows without, shows for each input with gaps how many rows would be complete if that column were left out; it is blank for a column without gaps, for a target, and for a column no model reads. A column that is the only gap in many rows is the one whose removal keeps the most data.

Outliers

5 of 8 numeric columns have values beyond the Tukey fences (1.5 times the interquartile range outside the quartiles). income has the largest share: 8.1% of its values. Whether such values are rare but real rows or recording errors decides whether they are kept.

Outliers
ColumnValuesLower fenceUpper fenceBelowAboveShare
Avgprs528none belownone above000 %
Consumer price index528none belownone above000 %
Income528none below257,559,6040438.14 %
Number of packs per capita528none below161.870163.03 %
Pop528none below12,661,5360397.39 %
Tax528none below67.780183.41 %
Taxs528none below78.900173.22 %
Year528none belownone above000 %
N columns
8
N columns assessed
8
N columns with outliers
5
Worst column
income
Worst pct
8.14

How to read this

The table counts the outliers of every numeric column by the Tukey rule. Q1 and Q3 are the values below which 25% and 75% of a column's values fall, and the interquartile range is Q3 minus Q1. The lower fence lies 1.5 times the interquartile range below Q1, the upper fence the same distance above Q3; a value beyond a fence is an outlier. For each column the table gives both fences, how many values lie below and above them, their share of the column's values, and the single value that lies furthest beyond its fence. These are the same fences the box plots draw their whiskers to.

A column is not assessed when it has fewer than four values, or when the middle half of its values sits on a single number: the interquartile range is then zero and the rule would call every other value an outlier.

Extreme values can be real (rare but legitimate rows) or errors (measurement mistakes, data-entry slips). Which case applies decides whether to keep, clip or drop them before trusting a model that uses the column. A strongly skewed column has many values beyond one fence without any of them being wrong.

Correlation

36 column pairs analyzed across 528 rows (28 of two numbers, 8 of a number and a category, 0 of two categories); 32 (89%) are unlikely to be chance, after allowing for how many pairs were tested. Any other pair may still show a large association, but one that cannot be told apart from chance on the rows the pair was measured on. Every pair is stated as an association from 0 to 1, whatever its kind, so pairs of different kinds can be ranked against each other. An association states that two columns go together, not that one brings the other about.

N categorical pairs
0
N mixed pairs
8
N numeric pairs
28
N pairs
36
N samples
528
N significant
32
Pairs · 24 of 36 rows shown
Association95 % CIColumnEta squaredGroupsKendallKindNOther columnPearsonQ valueSpearman
10.9957, 0.9969Consumer price index1numeric528Year0.9964< 0.0011
0.9981Pop0.996348numeric_categorical528State< 0.001
0.97940.9727, 0.9805Income0.8828numeric528Pop0.977< 0.0010.9794
0.9742Income0.949148numeric_categorical528State< 0.001
0.97130.966, 0.9758Tax0.8289numeric528Taxs0.9713< 0.0010.9514
0.8862Number of packs per capita0.785448numeric_categorical528State< 0.001
0.85980.8312, 0.8771Avgprs0.6932numeric528Consumer price index0.8558< 0.0010.8598
0.85980.8202, 0.8689Avgprs0.6932numeric528Year0.8463< 0.0010.8598
0.8510.8256, 0.8729Avgprs0.6507numeric528Taxs0.851< 0.0010.8322
0.81030.7788, 0.8377Avgprs0.6019numeric528Tax0.8103< 0.0010.7843

The first 10 rows of 24. The other 14 are in the notebook.

How to read this

This chapter measures how pairs of columns go together: the Correlation Measures table below, the Strongest Correlations, the Correlation Heatmap and, when the analysis has targets, the Potential Data Leaks. Numeric columns and categorical columns are both paired, a categorical column being one that is not numeric and holds between 2 and 50 distinct values. Every pair is stated as an association from 0 (unrelated) to 1 (one column gives the other away), so pairs of different kinds can be compared. An association states that two columns go together, not that one brings the other about.

The table lists every pair of columns once, with its kind, its association, the figures of its kind, its q-value and the number of rows the pair was measured on. A pair is measured on the rows where both columns hold a value.

MeasureExplanation
KindWhat the two columns hold: two numbers (numeric), a number and a category (numeric_categorical), or two categories (categorical)
AssociationStrength of the pair from 0 to 1, whatever its kind. Two numbers: the stronger of Pearson's coefficient and Spearman's ρ, without its sign. A number and a category: the correlation ratio η. Two categories: Cramér's V
CovarianceTwo numbers only. Direction of the relationship (positive or negative) in the units of the two columns. It is not standardized, so its size says little about strength without further context
Pearson's Correlation CoefficientTwo numbers only. Strength and direction of a linear relationship, from -1 (perfect negative) through 0 (no linear relationship) to 1 (perfect positive)
Spearman's ρTwo numbers only. Strength and direction of a monotonic relationship, computed on ranks rather than values. It captures relationships that consistently rise or fall even when they are not linear, and it is less affected by extreme values
Kendall's τTwo numbers only. Strength and direction of a monotonic relationship based on the concordance of ranks between the two columns. More conservative than Spearman's ρ, and steadier on small tables
Correlation ratio ηA number and a category. The square root of the share of the number's spread that lies between the categories, from 0 (every category has the same average) to 1 (the category fixes the number). For a category of two values it equals the absolute Pearson coefficient with the category coded 0 and 1. Its square, η², is that share: an η of 0.6 means the categories account for 36% of the spread
Cramér's VTwo categories. How far the table of counts of the two columns departs from what unrelated columns would give, from 0 (unrelated) to 1 (each value of one column goes with one value of the other), corrected so that columns with many rare values do not read as related
q-valueHow likely a pair this strong is among unrelated columns, adjusted for the number of pairs listed (Benjamini-Hochberg false-discovery rate). Among all pairs reported with q below 0.05, about 5% or fewer are expected to be false discoveries. The right measure for ranking many pairs
95% CI (Pearson)Two numbers only. Lower and upper bounds of the 95% confidence interval on the Pearson coefficient, via the Fisher z-transform, on the rows the pair was measured on. A narrow interval means the coefficient is well estimated; a wide interval that straddles zero means the relationship is uncertain

The first 10 rows of 12. The other 2 are in the notebook.

Strongest Correlations

The 20 pairs of columns with the smallest q-values: the associations that remain significant after the Benjamini-Hochberg adjustment for the number of pairs tested. Among all pairs reported with q below 0.05, about 5% or fewer are expected to be false discoveries; a pair above 0.05 may be coincidence even when its association looks strong.

A pair with an association above 0.9 often signals a duplicate or derived column. Moderately strong pairs with a low q-value are the relationships most worth investigating.

Each listed pair is drawn below, the picture behind the figure. Two numbers are drawn as a scatter, one point per row, the quickest way to see whether a strong value rests on a trend or on a few rows far from the rest. A number and a category are drawn as the number's box plot per category. Two categories are drawn as a heat map of how many rows hold each combination of values.

Potential Data Leaks

The table lists the association between every column and each target, whatever the two hold, with its q-value. An association close to 1 with a target, together with a q-value near zero, is one of two things: a strong input, or a data leak, a column derived from the target after the fact, such as a tax amount computed from the price being predicted. A leaked column trains a model that looks perfect and fails on new data, because the leak is not available at prediction time.

The Leakage Suspicion chapter in the Data section lists the pairs at 0.95 or more and marks those at 0.999 or more, where a column reproduces the target. For two numbers the association is whichever of Pearson's r and Spearman's rho is the stronger, because a column derived from the target often follows a curve rather than a line: the log of a price tracks the price perfectly, and Pearson alone reads that as weaker than it is. For a number and a category it is the correlation ratio η, and for two categories Cramér's V. Whether a listed column is a strong input or a leak depends on whether it is known before the target exists, which the owner of the analysis can confirm.

Implications

Weaker quality in 19 slices is flagged in Concerns, and accuracy drops sharply for rows where Avgprs, Taxs or Tax fall in the third quarter. The model covers nearly all rows, with 99% in scope, and the output is measured as correlative rather than predictive of causation.

Most notable in the Implications section:

  • The model is far less accurate on rows with Avgprs in the third quarter (152 to 174) (worse than always predicting the average of those rows)
  • The model is far less accurate on rows with Taxs in the third quarter (43 to 53.1) (worse than always predicting the average of those rows)
  • The model is far less accurate on rows with Tax in the third quarter (39 to 46.0) (worse than always predicting the average of those rows)

How to read this

The Implications section states how to act on the models: the Stakeholder Summary and the Recommended Next Data, where the models hold and where they weaken (Quality by Input Range, Rows unlike the ones the model learned from, Per-Segment Predictions, Fairness), what to weigh before relying on them (Causal Honesty, Deployment Readiness), and the Provenance & Audit trail a reviewer needs to retrace the analysis.

Stakeholder Summary

The model for Number of packs per capita relies most on Avgprs, with Consumer price index as a secondary input, and tracks patterns in the data. The actual improvement over a straight line through the data is too small to distinguish row by row, with the model coming out ahead on about as many rows as it falls behind.

The model is far less accurate when Avgprs, Taxs, or Tax are in the third quarter, Taxs in the second or highest quarter, and Pop in the lowest or second quarter, and in those segments predicts worse than always guessing the average would. Overlap in what several inputs capture limits what can be learned from the model. Validate on a fresh sample before relying on the model for decisions.

Recommended Next Data

  • Collect more rows where Avgprs is in the third quarter (152 to 174), Taxs is in the third quarter (43 to 53.1), Tax is in the third quarter (39 to 46.0), Pop is in the second quarter (1,580,664 to 3,560,884), or Taxs is in the highest quarter (54.3 to 93.5). Reason: the model is far less accurate than overall on these segments, predicting them worse than always guessing their average would.
  • Collect more rows where Taxs is in the second quarter (36.7 to 42.8) or Avgprs is in the highest quarter (176 to 237). Reason: the model is much less accurate on these segments, explaining only 4.3% of the variation for Taxs in the second quarter (36.7 to 42.8) and 12% for Avgprs in the highest quarter (176 to 237).
  • Collect more rows where Pop is in the lowest quarter (496,000 to 1,519,933). Reason: the model explains just 19% of the variation in this segment, well below its overall quality.
  • Inspect and clarify the relationships among Avgprs, Taxs, and Tax columns. Reason: 3 pairs of inputs carry nearly the same information, which can make the model harder to interpret and limits what can be learned from the coefficients.
  • Add columns or factors that could improve the model's quality for Number of packs per capita. Reason: the model barely beats a straight line through the data, adding just 1.6 points of variance explained, and a stronger formula may need additional features.

Quality by Input Range

Quality by Input Range splits the held-out rows by every usable input and compares the model's quality on each segment with its quality on all held-out rows. For a number the quality is R², the share of variation explained; for a yes-or-no target it is accuracy, the share of rows classified correctly, the measure the Classification Performance chapter reports. A numeric input is split into quartiles; a categorical input with at most ten values is split by value. A segment with fewer than three held-out rows is left out, because its gap would be noise.

The chart is sorted from the worst gap to the best. Each bar is the segment's figure minus the figure on all held-out rows.

  • Negative bars: the model is weaker on these rows than on all held-out rows. A segment 0.25 or more below the overall value (25 points of accuracy) reads much weaker; a segment 0.10 to 0.25 below reads weaker. These are the segments to treat with caution.
  • Positive bars: the model is stronger on these rows than overall. A strong segment can mask weakness elsewhere, so the negative segments come first.
Number of packs per capita by Input Range

Segment avgprs in the third quarter (152 to 174) is much weaker than the aggregate (28 held-out rows): segment R² -0.0992 against aggregate R² 0.417 (gap -0.516). A drop this large means the model describes this slice of the data poorly; an input interaction or a missing column may be specific to this subset.

SegmentRowsR²Gap to all rowsVerdict
Avgprs = q328-0.0992-0.5164Much weaker than on all rows
Taxs = q332-0.0906-0.5078Much weaker than on all rows
Tax = q328-0.0624-0.4796Much weaker than on all rows
Pop = q229-0.0106-0.4277Much weaker than on all rows
Taxs = q426-0.0031-0.4203Much weaker than on all rows
Taxs = q2220.0429-0.3743Much weaker than on all rows
Avgprs = q4250.1236-0.2936Much weaker than on all rows
Pop = q1230.1855-0.2317Weaker than on all rows
Tax = q2250.1986-0.2185Weaker than on all rows
Income = q1250.2068-0.2104Weaker than on all rows

The first 10 rows of 24. The other 14 are in the notebook.

Aggregate R²
0.4172
Measure
r2
Target
Number of packs per capita

Rows unlike the ones the model learned from

0 of 106 held-out rows (0%) lie further from the training rows than 99 in 100 rows like them would, measured on the 3 inputs the model reads (avgprs, cpi, year). That is a small minority; the held-out figures describe the model on rows like the ones it was trained on.

TargetInputs measuredLineHeld-out rowsBeyond the lineShare
Number of packs per capitaAvgprs, Consumer price index, Year3.36810600 %
Score bins · 24 of 30 rows shown
CountFromTo
500.135
10.1350.269
30.2690.404
50.4040.539
80.5390.674
50.6740.808
40.8080.943
20.9431.078
61.0781.213
21.2131.347

The first 10 rows of 24. The other 14 are in the notebook.

How to read this

Out-of-distribution detection finds held-out rows that lie far from the training rows of a model. It looks only at the numeric inputs the model reads. Each of them is standardized against the mean and standard deviation of the training rows, and the standardized values are combined into one distance per row. The line a row is read against depends on the number of inputs: it is the distance that 99 in 100 rows like the training rows stay below. A row beyond the line is flagged as out of distribution, and the held-out figures are unlikely to apply to it. When the held-out rows resemble the training rows, about one row in a hundred is flagged.

The chart shows one bar per held-out row in row order; the flagged rows are the bars at or above the line. With more than one target, the chart shows the model with the largest flagged share, and the figures name it.

The check treats inputs independently, so it will not notice a rare combination of values that are each ordinary on their own, such as a large height with a small weight. It is a first screen. A decision that depends on catching unusual inputs needs a dedicated check.

Fairness

This chapter checks the held-out predictions for uneven treatment of groups. For every categorical column with two to ten distinct values, other than the target, it reports per group the row count, mean actual value, mean prediction and mean residual, with R² and MAE for a number or accuracy, the share of rows classified correctly, for a yes-or-no target, and two measures across the groups.

  • Prediction parity ratio: the smallest group mean prediction divided by the largest, in absolute value. A ratio of 1.0 is perfect parity. Below 0.80, the four-fifths rule, some group receives systematically different predictions.
  • Largest mean residual: the largest absolute mean residual of any group. Above 30% of the overall residual standard deviation, at least one group is systematically over- or under-predicted.

The verdict combines the two: balanced when neither measure trips, parity gap or residual bias when one does, parity gap and residual bias when both do, and insufficient data when fewer than two groups have enough held-out rows.

Diafunc does not decide which columns are protected attributes; it reports every plausible one. A flagged column matters where it is a protected attribute in the decision the model supports, and can be set aside where it is not.

Number of packs per capita Fairness

Fairness was not assessed on this run, because no categorical column had two or more groups with at least 3 held-out rows each.

Causal Honesty

Diafunc found a formula that captures the structure in the training data. That structure is correlative: it states what predicts what in this data. It does not establish that any input causes the target.

A correlative model is the right tool for predicting the target on new rows like these, for exploring which inputs carry information about the target, and for an early-stage diagnostic or screening tool.

A correlative model is not the right tool for claiming that intervening on an input will change the target, for attributing a target's values to specific causes for accountability, or for choosing between policies that act on the inputs.

The Quality by Input Range, Fairness and Concerns chapters show the most common confounding patterns in the data.

The model is correlative: it captures which columns predict the target in the training data, not whether changing one would change the other. Predictions are reliable for inputs that look like the training distribution; they are not evidence that intervening on an input will change the target. The 4 upgrade pathways below show what evidence would support a causal claim.

Upgrade pathways
NameSummary
Controlled experimentRandomize the input to be acted on, then analyze again. Randomization breaks confounding, so any change in the target is attributable to the input.
Natural experimentFind a setting where the input varied for reasons unrelated to the target, an instrumental variable. Variation of that kind supports causal inference.
Causal graphWrite out what plausibly causes what, then check whether the model's terms are consistent with the conditional independences the graph implies.
Control for confoundersIf a third variable plausibly moves both the input and the target, stratify by it or condition on it before training again. Gaps in the Quality by Input Range chapter are a clue.

Deployment Readiness

The analysis ran with the configuration below. The checks and the verdict of this chapter are read against it.

  • Targets: 1 target: packpc
  • Rows: 528 rows
  • Per-Segment Predictions: not produced, because no segment column was chosen
  • Fairness: compared across 1 categorical column (state); which of them are protected attributes is not decided here
  • Out-of-Distribution: held-out rows are scored against the training rows; predictions made outside this report are not scored
  • Provenance & Audit: recorded in the chapter of that name

Across 5 checks (3 pass, 2 warn, 0 fail, 2 critical concerns), at least one check fails or a critical concern is open: Not ready. The failing checks need addressing first; they typically indicate data leakage, severe miscalibration, or a model that loses to its baseline.

NameStatusDetail
GeneralizationPassheld-out quality holds up against training quality
Prediction Interval CoverageWarnintervals are wider than their level requires, largest gap 12.3 percentage points
Baseline Lift for Number of packs per capitaWarnbarely beats the best baseline, R² lift 0.0161
Model ConstraintsPassevery held-out prediction is finite and within the training range
Out-of-DistributionPass0% of held-out rows are out of distribution
N critical concerns
2
N fail
0
N pass
3
N warn
2
Overall verdict
Not ready

Provenance & Audit

This record captures the inputs and configuration that produced the report, so the analysis can be reproduced or the result defended in an audit.

ItemValue
Analysis IDf3416400-48b7-11f1-8087-d378640fe787
Run time2026-10-24 18:41 UTC
Total rows528
Modeled targetsNumber of packs per capita
Segment columnnot available
Time limit1 h 0 min
Time taken48 s
Credit budget500 credits
Models kept fromrun 890adb30-ae9b-11f1-9bda-6d5d1e225b8a, whose search found them; this report was built again around them

Findings

1 finding from the implications diagnostics (1 Critical) is listed in the Concerns chapter at the top of the analysis.

Loading Diafunc…