Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

Dying in Detention: Deaths in U.S. Immigration and Customs Enforcement Custody

Data analysis from the Human Rights Watch report "Dying in Detention"

Code by Brian Root. Report authored by Human Rights Watch.


Introduction

This repository contains the analytical code and underlying data used for all quantitative findings in the Human Rights Watch report on deaths in U.S. Immigration and Customs Enforcement (ICE) detention. The report examines mortality rates across presidential administrations from 2016 through 2026, facility-level overcrowding in the two weeks before each death, and comparisons with published findings from Basu et al. (JAMA, April 2026).

The analysis script is written in R. All data inputs needed to reproduce the core findings are included in the data/ folder. The population data underlying this analysis was built from multiple ICE FOIA releases and biweekly facility detention sheets; the processing pipeline that produced those files is described below but is not included in this repository due to its size and complexity.


Repository Contents

├── src/
│   └── HRW_Dying_in_Detention.R      # Main analysis script
├── data/
│   ├── ICE_deaths.csv                # Death-level data (source: ICE FOIA / HRW tracking)
│   ├── complete_daily_system.csv     # Daily system-wide detention population (Oct 2015–Apr 2026)
│   ├── complete_daily_facility.csv   # Daily facility-level detention population (Oct 2015–Apr 2026)
│   ├── facility_list_with_capacity.csv  # Facility metadata including contractual capacity
│   └── compare_JAMA/
│       ├── all_272_deaths_detailed.csv  # Death records from Basu et al. (JAMA 2026)
│       └── average_daily_population.csv # ADP data used in JAMA analysis
├── output/                           # Directory for script outputs (created on run)
└── doc/
    └── data_processing_methodology.md  # Description of the upstream population pipeline

Data

Deaths Data (data/ICE_deaths.csv)

The primary deaths dataset was compiled by HRW from ICE's publicly released death notifications, FOIA requests, and media reporting. Each row represents one death in ICE custody. Key fields include:

Field Description
name Name of the person who died
date_death Date of death (day-month-year format)
announcement_date Date ICE publicly announced the death
detention_facility_code ICE facility code (links to facility metadata)
facility_name Name of the detention facility
age Age at time of death
exclude If 1, excluded from overcrowding analysis (see notes in script)

Three deaths are excluded from the facility overcrowding analysis: two at the Dallas Hold Room (where facility-level population data is not meaningful) and one with no facility code.

Population Data (data/complete_daily_system.csv, data/complete_daily_facility.csv)

These files record the number of people detained in ICE custody each day, at both the system-wide and facility level. They were produced by stitching together three tiers of source data:

  • Tier 1 (archived): Individual-level FOIA records covering October 2012–September 2022 (FOIA 2023-ICFO-42034), plus TRAC FOIA records extending back to October 2003 (FOIA 24-41855). For this analysis, data from October 2015 onward is used.
  • Tier 2 (disaggregated release): Individual-level FOIA records from the most recent disaggregated ICE release (March 2026), covering October 2022 through early March 2026.
  • Tier 3 (biweekly): ICE's publicly posted biweekly detention management facility sheets, covering the gap between the FOIA release cutoff and the most recent available data (through approximately April 2026).

For dates after the last observed population day, the script carries forward the last known count to provide a denominator for any deaths that fall after the population data cutoff. This is flagged transparently in the script.

The source column in both files records which tier provided each row: "archived", "release", or "biweekly".

Facility Metadata (data/facility_list_with_capacity.csv)

Facility-level metadata including standardized facility names, ICE Area of Responsibility (AOR), facility type, guaranteed minimum contractual bed counts (where available), and contractual capacity from TRAC Reports. Capacity data was sourced from TRAC Reports (Table 3, Report 762) and joined to facility records by fuzzy name matching.

JAMA Comparison Data (data/compare_JAMA/)

These files were published as part of Basu et al., "Mortality in U.S. Immigration and Customs Enforcement Detention, 2004–2025," JAMA (April 2026), and are included here to allow replication of the comparison between HRW's findings and theirs. The all_272_deaths_detailed.csv file contains death records used in that analysis; average_daily_population.csv contains the ADP figures used in their rate calculations. HRW replicated the JAMA mortality rate calculations in R using chi-squared–based Poisson confidence intervals matching their Python implementation.


Analysis Script (src/HRW_Dying_in_Detention.R)

What It Produces

Running the script generates the following outputs in output/ (mirroring the structure described in the script's output paths):

Output File Description
deaths_monthly.csv Monthly death counts with mean age
deaths_annualized_rate_with_ci.csv Loess-smoothed annualized death rate per 10,000 ADP with 95% CI
trump2_monthly_mortality_rate.csv Raw monthly mortality rate, January 2025 onward
admin_summary_death_rates.csv Annualized death rates by presidential administration
deaths_age_histogram_trump2.csv Age distribution of deaths since January 20, 2025
facility_death_table.csv Facility-level deaths and detainee-days
death_2week_facility_capacity_analysis.csv 2-week pre-death population analysis (Trump 2 deaths)
death_overcrowding_datawrapper1.csv Diverging bar chart data: people above/below baseline
death_overcrowding_datawrapper2.csv Detailed table with baselines and % of average
death_overcrowding_scatter.csv Scatter plot data: date of death vs. % of baseline
admin_capacity_table.csv Overcrowding summary by administration
pre_post_oct3_comparison.csv Before/after October 3, 2025 contract cancellation

The script also prints diagnostic text to the console with suggested paragraph text for key findings, including population growth comparisons, rate ratios vs. historical baselines, and days-between-deaths by period.

Key Methodological Decisions

Mortality rate calculation. Rates are expressed per 10,000 average daily population (ADP), annualized. ADP for each period is computed from the daily population series. For partial months, the rate is annualized using actual days observed rather than multiplying by 12. Confidence intervals use the chi-squared–based exact Poisson method, matching Basu et al.'s Python implementation.

Loess smoothing. A loess model with span = 0.75 is fit to the monthly annualized rate series. The partial final month is down-weighted proportionally to its days observed relative to a full month (30.44 days).

2-week pre-death overcrowding. For each Trump 2 death at a facility with population data, the script computes the average daily population at that facility during the 14 days before the death date. This is expressed as a percentage of that facility's historical average (using all available days in the series where n_detained > 0, from October 2015 onward). The baseline is the full historical average since October 2015, not a fixed pre-Trump 2 window. Facilities that first appear in the population data during the Trump 2 period (no pre-inauguration history) are noted as having non-meaningful baselines.

Administrative periods. Administration assignments use exact inauguration dates: Obama through January 19, 2017; Trump 1 from January 20, 2017 through January 19, 2021; Biden from January 20, 2021 through January 19, 2025; Trump 2 from January 20, 2025 onward.

Death vs. non-death facility comparison. For the facility-level overcrowding comparison, the script computes the Trump 2 average population as a percentage of historical baseline for all active facilities (not just those with deaths), then uses a Wilcoxon rank-sum test to compare the distribution between facilities that had at least one Trump 2 death and those that did not, restricted to facilities with a baseline ADP of 100 or more.


Population Processing Pipeline (Not Included)

The complete_daily_system.csv and complete_daily_facility.csv files included in this repository were produced by a multi-stage processing pipeline operating on raw ICE FOIA data. That pipeline is not included in this repository because it involves large proprietary FOIA-sourced datasets (individual-level detention records for millions of people) that cannot be publicly released.

The pipeline is documented in doc/data_processing_methodology.md. In summary, it involves:

  1. FOIA release processing (disaggregated arrest, detention, removal, encounter, and detainer records from three FOIA releases: July 2025, October 2025, and March 2026)
  2. Archived historical processing (individual-level FOIA records from 2023-ICFO-42034, covering FY2012–FY2023)
  3. TRAC historical extension (FOIA 24-41855 records extending coverage back to FY2004)
  4. Biweekly facility sheet processing (ICE detention management sheets covering the gap after the most recent FOIA release)
  5. Complete series construction (stitching all four sources into a single daily time series)

A false-transfer collapsing fix was applied during detention processing to correct an artifact in the raw data where transfers between booking systems within the same facility were recorded as two separate stints, inflating facility-level populations. The corrected detention records are saved as detentions.rds; the uncorrected raw records are preserved as detentions_raw.rds.


Packages Required

install.packages("pacman")
pacman::p_load(
  data.table, lubridate, arrow, readxl, readr, rcartocolor, extrafont,
  scales, tidycensus, tidyverse, fuzzyjoin, zoo, stringdist,
  quantmod, tidytext, RecordLinkage, janitor
)

R version 4.5.2 was used for this analysis. The CGPfunctions and qs packages are not required and are not compatible with this R version.


Replicating the JAMA Comparison

Basu et al. (JAMA, April 2026) reported mortality rates using Python. HRW replicated their calculations in R using:

  • Their published death records (data/compare_JAMA/all_272_deaths_detailed.csv)
  • Their ADP data (data/compare_JAMA/average_daily_population.csv)
  • Chi-squared–based Poisson confidence intervals (matching poisson.test() from their Python scipy.stats implementation)
  • Fiscal year boundaries matching their study period (October 1 through September 30, with FY2026 ending January 19, 2026, as in their paper)

A FY2016 discrepancy between the two analyses (HRW: 10 deaths; JAMA: 11 deaths) was traced to a chunk execution order issue in the Quarto document and resolved. The replication script is embedded in the main analysis file.


Contact

Please contact Brian Root at rootb@hrw.org or dilresearch@hrw.org with questions about the data or methodology.

Human Rights Watch Technology, Rights, and Investigations Division

About

Data and analysis for the HRW/PHR report on deaths in U.S. ICE immigration detention

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages