The dataset viewer is not available because its heuristics could not detect any supported data files. You can try uploading some data files, or configuring the data files location manually.
Cook County State's Attorney Felony Case Database
Cook County (Chicago) State’s Attorney’s Office prosecutor records covering felony review, charges, dispositions, sentencing and diversion. A disposition is how a charge was resolved; diversion records describe referrals to diversion programs. The office closed this series on December 30, 2024. Intake starts with cases received in 2011; disposition and sentencing records also include older cases resolved during 2011–2024. Tables have different units, including defendants presented for review, charge versions and sentence components, so do not add their row counts as unique cases or people.
Start querying
Preview up to five felony-review intake records received in 2024, showing the received date, offense category and recorded review result. A review record is not a unique defendant or case count.
Choose R or Python. Install the datapond package once: use install.packages("datapond") in R, or run python -m pip install datapond in a terminal.
R
library(datapond)
con <- dp_connect("cook-sao")
tryCatch({
DBI::dbExecute(con, "SET threads=1")
DBI::dbExecute(con, "SET memory_limit='128MiB'")
DBI::dbExecute(con, "SET max_temp_directory_size='0B'")
print(DBI::dbGetQuery(con, "SELECT received_date,offense_category,felony_review_result FROM intake WHERE received_date>=DATE '2024-01-01' LIMIT 5"))
}, finally = dp_disconnect(con))
Python
import datapond
con = datapond.connect('cook-sao')
try:
con.execute("SET threads=1")
con.execute("SET memory_limit='128MiB'")
con.execute("SET max_temp_directory_size='0B'")
print(con.execute("""SELECT received_date,offense_category,felony_review_result FROM intake WHERE received_date>=DATE '2024-01-01' LIMIT 5""").fetchall())
finally:
con.close()
Queries run on your computer and read the byte ranges they need. A small result can still require a large scan. These examples limit DuckDB to one thread and a 128 MiB buffer pool with disk spill disabled; that is not a limit on the entire R or Python process. Larger analyses may need more memory or a local download with enough disk space.
Tables and case stages
3,171,690 rows across five tables, ordered below from intake through later case stages. The row units differ and should not be added as unique cases or people.
| Table | Description | Row Count | Column Count |
|---|---|---|---|
intake |
One row per potential defendant brought to the State's Attorney for felony review, 2011-2024: received date, offense category, felony-review result, arrest and incident dates, demographics, arresting agency | 528,111 | 17 |
initiation |
One row per charge on a case at initiation (after felony review approval), 2011-2024: charge statute/class, initiation event and date, arraignment date, initial and current bond type/amount, demographics | 1,228,260 | 38 |
dispositions |
One row per charge disposition, 2011-2024: charged offense as disposed, disposition and reason, judge, court, plus the case-level intake fields | 1,080,014 | 33 |
sentencing |
One row per sentence component imposed on a disposed charge, 2011-2024: sentence type, commitment type/term/unit, sentence judge and court, whether it is the current sentence, case length | 305,884 | 41 |
diversion |
One row per diversion-program referral, 2011-2024: program, referral date, primary charge, result, closed date | 29,421 | 13 |
Use case_id for case context and case_participant_id for the defendant within a case. Charge-level linkage requires case_participant_id, charge_id and charge_version_id together; co-defendants can share charge_id, and charge versions can repeat. A version increments when a charge is amended.
See the data dictionary for column definitions.
Interpreting case stages and dates
The series closed on December 30, 2024, with cases received through November 2024 present. Later cases may not yet have a disposition. Disposition and sentencing tables also include older cases resolved in 2011–2024; those cases may have no intake row.
A sentence component is one part of a sentence, such as prison or probation. A charge may have several current components. primary_charge_flag selects the primary charge and current_sentence_flag selects sentences that stand; neither makes the component rows unique people.
received_date is the time axis used in the office’s reports. Arrest and incident dates can be years earlier. Out-of-range dates are set to NULL, but in-range placeholders can survive; bound date arithmetic to 2000 onward and consult the repository caveats.
More example queries
Count felony-review records by received year and recorded result. The counts describe intake records, not unique people. This direct DuckDB connection is an alternative to the package examples above.
INSTALL httpfs; LOAD httpfs;
ATTACH 'https://huggingface.co/datasets/Nason/cook-sao-database/resolve/main/cook-sao.duckdb' AS cook_sao (READ_ONLY);
SELECT EXTRACT(YEAR FROM received_date) AS year, felony_review_result, COUNT(*) AS n
FROM cook_sao.intake GROUP BY 1, 2 ORDER BY 1, 3 DESC;
Sources and maintenance
Sources and build documentation
Source: Cook County State's Attorney's Office (county open-data portal). License: Public domain.
The office published these five case-level datasets through the county portal. Each becomes one database table, with types taken from the portal’s own column metadata.
Build pipeline, the State’s Attorney’s Office (SAO) data glossary and caveats: https://github.com/ian-nason/cook-sao-database Source: Cook County open-data portal, https://datacatalog.cookcountyil.gov (public domain).
R with DBI and duckdb
Install the dependencies once with install.packages(c("DBI", "duckdb")).
library(DBI)
con <- dbConnect(duckdb::duckdb())
dbExecute(con, "INSTALL httpfs")
dbExecute(con, "LOAD httpfs")
dbExecute(con, "ATTACH 'https://huggingface.co/datasets/Nason/cook-sao-database/resolve/main/cook-sao.duckdb' AS cook_sao (READ_ONLY)")
dbGetQuery(con, "SELECT received_date, felony_review_result FROM cook_sao.intake LIMIT 5")
dbDisconnect(con, shutdown = TRUE)
DuckDB uses HTTP range requests; queries run on your machine and may need substantial memory or download data. A LIMIT does not guarantee a small scan.
Or with the datapond packages: pip install datapond / pak::pak("datapond-db/datapond-r").
Build pipeline, the SAO data glossary and caveats: https://github.com/ian-nason/cook-sao-database Source: Cook County open-data portal, https://datacatalog.cookcountyil.gov (public domain).
- Downloads last month
- 444