Removes the row that contains -1 in a specified column, indicating that the
charge described in that observation has either been deemed unfounded or has been
up-coded. For example, a victim of an aggravated assault dies, and the charge is changed
to homicide.
cs_filter_count(.data, var)
| .data | A tibble or data frame |
|---|---|
| var | the name of the column |
A subset object with rows containing -1 removed
# load example data testData <- january2018 # subset data to remove negative counts testData <- cs_filter_count(testData, var = count)