Overview

From the Unified Crime Reporting Statistics and under the collaboration of the U.S. Department of Justice and the Federal Bureau of Investigation information crime statistics are available for public review. The following data set has information on the crime rates and totals for states across the United States for a wide range of years. The crime reports are divided into two main categories: property and violent crime. Property crime refers to burglary, larceny, and motor related crime while violent crime refers to assault, murder, rape, and robbery. These reports go from 1960 to 2012.

http://www.ucrdatatool.gov/Search/Crime/Local/JurisbyJurisStepTwo.cfm

Downloads

Download all of the following files.

Usage

Begin by adding the above JAR file to your classpath. This library has 3 functions you can use.
import corgis.state_crime.StateCrimeLibrary;
import corgis.state_crime.domain.*;
import java.util.ArrayList;

public class ExampleClass {
    public static void main(String[] args) {
        // Get access to the library
        StateCrimeLibrary stateCrimeLibrary = new StateCrimeLibrary();
        // Access data inside the library
        ArrayList<Report> list_of_report = stateCrimeLibrary.getAllCrimes(false);ArrayList<Report> list_of_report = stateCrimeLibrary.getCrimeByState("Alabama", false);ArrayList<Report> list_of_report = stateCrimeLibrary.getCrimeByYear(1984, false);
    }
}
Additionally, some of the functions can optionally return Big Data using the last argument (setting it to true). If you use this Big Data, it may be much slower. Wait until you are sure your code is correct before using these examples.
import corgis.state_crime.StateCrimeLibrary;
import corgis.state_crime.domain.*;
import java.util.ArrayList;

public class ExampleClass {
    public static void main(String[] args) {
        // Get access to the library
        StateCrimeLibrary stateCrimeLibrary = new StateCrimeLibrary();
        // Access data inside the library
        ArrayList<Report> list_of_report = stateCrimeLibrary.getAllCrimes(true);ArrayList<Report> list_of_report = stateCrimeLibrary.getCrimeByState("Alabama", true);ArrayList<Report> list_of_report = stateCrimeLibrary.getCrimeByYear(1984, true);
    }
}

Documentation

We provide full JavaDoc for this library. Alternatively, you may refer to the below:

 stateCrimeLibrary.getAllCrimes(test)

Gets a list of all the crime reports in the database.

 stateCrimeLibrary.getCrimeByState(department, test)

Given the name of a state, returns all the crime reports for that state in the database.

 stateCrimeLibrary.getCrimeByYear(year, test)

Given a year, returns all the crime reports for that year in the database.