Skip to content

JohnCrissman/chicago-crime-tracker-map

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

git-name: chicago-crime-tracker-map

Chicago Crime Tracker

Developed by Karaoke Squad

Campus safety is a concern for all who attend universities and colleges. Students should have a right to see and understand the data that shows crimes near their campus locations. We pulled data from the “Crimes - 2001 to present” dataset on the Chicago Data Portal website, which contains all reported crimes from 2001 to present, excluding the most recent week. Our application, Chicago Crime Tracker, filters this data in a way where we can see what crimes have happened within a given area. With the application a user can enter an address and select a distance in miles to get a filtered list of crimes within the distance of the chosen Chicago address.

Setup

Dependencies

This application was developed in Java 11 and JavaFX 8, using IntelliJ IDEA with Gradle to access JavaFX.

  • Java 11.0.4
  • IntelliJ IDEA Community 2019.2
    • Running Gradle 5.6.2
  • Java packages (including several sub-packages)
    • javafx.*
    • org.json.simple.*
    • java.io.*
    • java.net.*
    • java.util.*
    • java.nio.*
    • java.text.*
    • java.time.*
  • Google Maps API (key embedded within application)

Installation & Setup

Install software

  1. Install Java 11 from Oracle. This is a free installation, but you must set up a user account with Oracle.
  2. Install IntelliJ using the JetBrains Toolbox, and be sure to set up Gradle.

Create a new project

  1. Open IntelliJ. In the File menu, select New > Project.
  2. Select Gradle in the left menu, and make sure the Project SDK is set to Java 11, and Java is checked. Click Next.
  3. For GroupID, enter cs.420.neiu. For ArtifactID, enter crime.tracker. Click Next.
  4. Name the project and put it in the desired folder. Click Create.

Set up the project

  1. Once the project has loaded, navigate to File > Settings, then Build, Execution, Deployment > Build Tools > Gradle.
    1. Check "Automatically import this project on changes in build script files."
    2. "Build and run tests using:" and "Run tests using:" should both be set to Gradle.
    3. "Use Gradle from" should be set to "'wrapper' task in Gradle build."
    4. Click OK.
  2. Navigate to File > Project Structure. Select SDKs on the left side, and make sure Java 11 is selected. Click OK.
  3. Navigate tosrc / main / java in the left side project viewer.
    1. Right click java and select "Open in explorer/finder."
    2. From the code.zip file, copy the java and resources folders to the project folders (you can write over the empty folders).
  4. Back in IntelliJ, double-click to open build.gradle.
    1. in plugins, add two lines: id 'application' id 'org.openjfx.javafxplugin' version '0.0.8'
    2. Add the following lines: allprojects { wrapper { gradleVersion = '5.6.2' } } javafx { modules = [ 'javafx.controls', 'javafx.web', 'javafx.graphics'] }
      mainClassName = 'CrimeViewerApplication' dependencies {
      testCompile group: 'junit', name: 'junit', version: '4.12' compile group: 'com.googlecode.json-simple', name: 'json-simple', version: '1.1.1' }
    3. Save the build.gradle file and wait for the project build to reload.

Run the program

  1. On the very far right, click Gradle to expand the Gradle run menu. Expand the menu to Tasks > application > run. Double-click Run to launch the application.

Contents

You can rename the current file by clicking the file name in the navigation bar or by clicking the Rename button in the file explorer.

Instructions to Use

The application window contains 3 main parts:

  • Top section: search menu
  • Middle section: view crimes as a map, list, or set of bar graphs
  • Bottom section: change between different views, or exit the application

To use:

  • Type in an address (full or partial - this works just like Google Maps to fill in incomplete addresses)
  • Select a search radius from the drop-down menu.
  • Click "Search" to run your query.

Repeat these steps as many times as desired.

Some crimes are missing latitude and longitude information -- these crimes are excluded from our application, since location information is very important to this application performing as expected! These crimes are saved in a logFile_[date information].log file at application launch, located within build/resources/main.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •