Skip to contents

Wraps the static historical arrests CSV published by the Chicago Police Department at https://www.chicagopolice.org/statistics-data/public-arrest-data/ covering adult and juvenile arrests from 01 JAN 2014 through 31 DEC 2017, with all personally identifying information removed. Ten upper-case-coded columns matching the CPD data dictionary:

Usage

morie_datasets_cpd_public_arrests(
  url = NULL,
  offline = TRUE,
  max_features = NULL
)

Arguments

url

Optional direct-CSV URL. If NULL and offline = FALSE, the loader errors with a "lookup pending" message pointing at the chicagopolice.org landing page.

offline

Logical; if TRUE (default), read the bundled synthetic 5-row fixture (inst/extdata/cpd_public_release_arrests_sample.csv).

max_features

Integer or NULL; cap on returned rows.

Value

A data.frame with the 10-col CPD schema.

Details

ARR_DISTRICT

Chicago PD district (geographic boundary).

ARR_BEAT

Chicago PD beat (geographic boundary).

ARR_YEAR

Calendar year of the arrest.

ARR_MONTH

Calendar month of the arrest.

RACE_CODE_CD

Perceived race code.

FBI_CODE

IUCR/FBI crime category code.

STATUTE

ILCS / MCC statute charged.

STAT_DESCR

Plain-text statute title.

CHARGE_CLASS_CD

ILCS/MCC charge class code.

CHARGE_TYPE_CD

"M" = misdemeanour, "F" = felony.

Unlike the SODA2 feeds, CPD publishes this as a single direct CSV download with no documented API; the file URL is not stable across CPD's quarterly republications. morie therefore ships an offline- first loader; pass a url for live mode (visit the landing page to find the current direct-CSV URL).

References

Chicago Police Department, "Public Arrest Data"; landing page at chicagopolice.org/statistics-data/public- arrest-data/.

Examples

df <- morie_datasets_cpd_public_arrests(offline = TRUE)
df$STAT_DESCR
#> [1] "SYNTH MFG/DEL CONTROLLED SUBSTANCE"      
#> [2] "SYNTH FUGITIVE FROM JUSTICE OUT OF STATE"
#> [3] "SYNTH RETAIL THEFT UNDER $300"           
#> [4] "SYNTH BATTERY PHYSICAL CONTACT"          
#> [5] "SYNTH POSSESSION OF CONTROLLED SUBSTANCE"