# Validation report

The build writes no file unless every check below passes; this report lists them and the reconciliations behind the card's numbers. Rerun it with `py src/ops/catalog.py build nyc-subway-crime-and-ridership` in SparkyData's repository.

## Checks run before anything is written

- Every row of the article's published data file is reproduced from the monthly and fiscal files (counts exactly, rides to the article's rounding).
- The six major felonies add up to six_major, and the felony-assault codes to felony_assault, in every month.
- The complaint extracts agree with one another cell for cell (by offence, by code, by day, by place).
- The daily, hourly, station, victim and report-delay files add up to the monthly table in every month or year (the victim file by law category and offence, the report-delay file by offence group); the record file does too once its 109 late reports are left out.
- The record file is the NYPD extract record for record: the multiset of every source field the file keeps, taken together, is unchanged, and a cell is empty only where the source is blank or (null).
- Daily paid rides add up to the monthly paid rides of every counted month.
- The classroom file holds the monthly table's complaints month by month, with the record file's blanks; the pooled station table sums the annual one, each rate lies in its range and each shrunk rate between the raw rate and the pooled one; station entries by day and by hour add up to the monthly table's exactly (all come from the MTA's hourly tables), and the station-monthly table agrees with them within 0.1% to February 2026, its last whole month; the hours from 1:00 to 3:59 hold almost no entries in every month of the 2020-21 overnight closure, summer and winter time alike; the network's complexes are the station list's.
- Each notebook runs on the built files and asserts the results it tells a reader to expect; the card's first example prints what the card says it prints.
- Every figure the card, the questions and the cautions quote is recomputed from the files, and every phrase events.csv quotes is found in its saved document.
- Every column with empty cells has a reason (missing_values.csv). Before each upload the release is built a second time and must match byte for byte.

## Station entries against paid rides, by year

The MTA's station entries, added up, divided by the paid rides used (modelled to February 2020, the MTA's daily figures after):

| Year | Lowest month | Highest month | Months |
| --- | ---: | ---: | ---: |
| 2017 | 0.9578 | 1.0476 | 11 |
| 2018 | 0.9407 | 1.0420 | 12 |
| 2019 | 0.9882 | 1.0322 | 12 |
| 2020 | 0.9776 | 1.0248 | 12 |
| 2021 | 0.9993 | 1.0048 | 12 |
| 2022 | 0.9990 | 1.0079 | 12 |
| 2023 | 1.0042 | 1.0112 | 12 |
| 2024 | 1.0033 | 1.0167 | 12 |
| 2025 | 1.0107 | 1.0203 | 12 |
| 2026 | 1.0131 | 1.0151 | 2 |

## The headline comparison on three denominators

Felony assaults in January to May, per million rides or entries:

| Year | Denominator | Complaints | Rides or entries | Rate | Against 2019 |
| --- | --- | ---: | ---: | ---: | ---: |
| 2019 | paid_rides | 157 | 702,461,957 | 0.2235 | 1.000 |
| 2019 | station_entries | 157 | 699,851,766 | 0.2243 | 1.000 |
| 2019 | estimated_entries | 157 | 730,969,778 | 0.2148 | 1.000 |
| 2025 | paid_rides | 267 | 523,745,387 | 0.5098 | 2.281 |
| 2025 | station_entries | 267 | 530,223,998 | 0.5036 | 2.245 |
| 2025 | estimated_entries | 267 | 580,922,734 | 0.4596 | 2.140 |
| 2026 | paid_rides | 272 | 537,074,361 | 0.5064 | 2.266 |
| 2026 | station_entries | 272 | 542,317,329 | 0.5016 | 2.236 |
| 2026 | estimated_entries | 272 | 599,623,313 | 0.4536 | 2.112 |

Months in the monthly table: 150; complaints: 187,630.
