Skip to content

nrgreenup/boston-crime

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Boston Crime

Description: This project contains analyses of Boston crime rates R and the ArcGIS suite (namely, ArcMap). These analyses were a part of a semester term project completed for a graduate-level geographic information systems course. R is used for cleaning crime data, producing 2- and 3-dimensional scatterplots, and fitting simple and multiple linear regression models. ArcMap is used for joining crime and demographic data with shapefiles - which contain spatial information about census tracts in Boston - and creating choropleth maps of crime rates, median income, and racial composition at the census tract level.

Analytical Report

The information in the README.md file below contains instructions and helpful information for replicating all analyses. For a step-by-step report that walks through the analytical process, please visit my website.

Necessary Software

You will need the following software and R packages installed to run code files and reproduce analyses.

Necessary software: R , ArcGIS

Necessary R packages: broom , dplyr , ggplot2 , httpuv , plotly , readxl , scales

File Descriptions

Files names begin with a prefix according to their function:

  analysis- : R analysis file
  clean-    : R data cleaning file
  data-     : Data used for analyses
  map-      : PNG or MXD file of map created using ArcMap 
  plot-     : Plots created using R packages `ggplot2` or `plotly`
  table-    : Table containing linear regression parameters

Installation and File Execution

To begin, download all files into a single folder. When using R, set this folder as the working directory using setwd. When using ArcMap, establish a folder connection to this folder.

R script files are executable once a working directory to the folder containing data files is set. Running these scripts will reproduce all data cleaning procedures, plots, and regression analyses.

To examine and alter the map documents using ArcMap , open the relevant MXD file. When using ArcMap, ensure that all of the files contained in the /shapefiles/ subdirectory have been downloaded into the folder that you establish a folder connection to. For further details, review the README file included in the /shapefiles/ subdirectory.

Data Sources

US Census Bureau American Factfinder

US Census Bureau TIGER/Line Shapefiles

City of Boston Crime Data

License

See LICENSE.md for licensing details for this project.

About

Analyses of Boston crime rates using R and ArcGIS.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages