Preparation

Let's get prepared for obtaining spatial statistical information about a dataset using ArcGIS, as follows:

  1. In ArcMap, open the C:\GeospatialTraining\SpatialStats\DenverCrime.mxd file. You should see a point feature class called Crime, as shown in the following screenshot:

Point locations for all crimes for the city of Denver 2013

  1. The Crime feature class contains point locations for all crimes for the city of Denver in 2013. The first thing we need to do is isolate a type of crime for our analysis. Open the attribute table for the crime feature class.
  1. Use the Select by Attributes... tool to select all records where the OFFENSE_CATEGORY_ID ='burglary' method, as shown in the following screenshot. This will select 25,743 burglaries from the dataset. These are burglaries within the city limits of Denver in 2013:
  1. Close the attribute table. In the Table Of Contents pane, right-click on the Crime layer and select Properties.... Go to the Source tab and note that the value of Geographic Coordinate System is GCS_WGS_1984. Data is often stored in this WGS84 Web Mercator coordinate system for display purposes on the Web.

The WGS84 Web Mercator coordinate system, which is so popular today for online mapping applications, is not suitable for use with the spatial statistics tools. These tools require accurate distance measurements that aren't possible with WGS84 Web Mercator. So, it's important to project your datasets to a coordinate system that supports accurate distance measurements. The Web Mercator coordinate system supports accurate directions, but this analysis requires accurate distance measurements.

Take a look at the following screenshot:

  1. Close this dialog by clicking on the Cancel button. Now, right-click on the Layers data frame and select Properties... and then Coordinate System. The current coordinate system of the data frame should be set to NAD_1983_UTM_Zone_13N, which is acceptable for our analysis.
  1. With the records from the crime layer still selected, right-click on the layer and navigate to Data | Export Data.... The next dialog is very important. Click on the data frame as the coordinate system, as shown in the following screenshot. Name the layer Burglary and export it to the crime geodatabase in C:\GeospatialTraining\SpatialStats\Data\crime.gdb  and then click on the OK button.
  1. The new burglary layer will be added to the Layers data frame. Rename the layer to Denver Burglary:
  1. You can now remove the Crime layer.
  2. Save your map document file.