Abstract

Replication of Steven Levitt, AER, 1997, "Using Electoral Cycles in Police Hiring to Estimate the Effect of Police on Crime"

Author: Justin McCrary

Copyright (c) 2001 Justin McCrary

Keywords: police, crime, elections

References: Justin McCrary, "Do Electoral Cycles in Police Hiring Really Help Us Estimate the Effect of Police on Crime?" Center for Labor Economics working paper #35, September 2001; Steven Levitt, "Using Electoral Cycles in Police Hiring to Estimate the Effect of Police on Crime," American Economic Review, June 1997.

Description: The files posted are intended to allow researchers to replicate the findings of Justin McCrary, "Do Electoral Cycles in Police Hiring Really Help Us Estimate the Effect of Police on Crime?" Center for Labor Economics working paper #35, September 2001.

This paper is a replication of Steven Levitt's paper, "Using Electoral Cycles in Police Hiring to Estimate the Effect of Police on Crime," American Economic Review, June 1997.

Levitt's paper is available from http://www.jstor.org, or in hard copy. Researchers may also be interested in Levitt's working paper which preceded his AER publication "Using Electoral Cycles in Police Hiring to Estimate the Effect of Police on Crime," NBER Working Paper # 4991, January 1995.

In the files provided on this server (see below), the subdirectory 'originallevittfiles' contains a sequence of files kindly provided by Levitt. See 'readme_mccrary.txt' and 'readme_levitt.txt' in that subdirectory.

The subdirectory 'data' contains all the data used in the author's replication. It is a merged data set containing both Levitt's original data set (see 'originallevittfiles/crime.dta') and the author's data on mayoral election dates. See 'readme.txt' within that subdirectory for more information.

The subdirectory 'programs' contains all the programs used in the author's replication. Note that it will be necessary to change the path in a number of places within the code. See 'readme.txt' within that subdirectory for more information.

The essence of the comment is that 'holdstd', the weight Levitt employs for roughly the bottom 2/3 of his code 'secstage.sas', is the standard deviation of the residuals. In the top 1/3 of his code, he weights by holdwght=1/(holdstd*holdstd), which is the correct (i.e. heteroskedasticity-correction) weight. It looks like he just accidentally wrote holdstd in place of holdwght at some point, and then just copied his code further without noticing the mistake.

Platforms: Unix SAS 6.12 for Solaris 7.

Support: Please contact the author with questions or suggestions at jmccrary@econ.berkeley.edu

By clicking on the links below, you agree that you have read our disclaimer, understand it, and will abide by its terms and conditions.

Archive files: mccrary.zip, mccrary.tar.gz
The programs, sample data, and output are contained in the files described in the manifest below. If you click on the zip archive link above (mccrary.zip), you can download and archive that requires PCWare's unzip software to expand the archive. If you click on the tar archive link above (mccrary.tar.gz), you can download a unix gzipped tar archive that requires unix gunzip and tar software to extract the tarfiles. If you click on the link to the manifest below, you can pick and choose individual files to download.

Manifest:

Subdirectory:  data
-rw-r--r--   464598 Sep  4 20:20 crime2.dta
-rw-r--r--   434176 Sep  4 20:20 crime2.ssd01
-rw-r--r--   996864 Sep  4 20:20 crime2.xls
-rw-r--r--     1530 Sep  5 16:58 readme.txt

Subdirectory:  programs
-rw-r--r--   174991 Sep  4 19:16 checkcov.raw
-rw-r--r--     6231 Sep 11 14:15 checkcov.sas
-rw-r--r--    26876 Sep 11 14:10 master.log.1.gz
-rw-r--r--    15043 Sep 11 13:25 master.log.2.gz
-rw-r--r--   600518 Sep 11 14:10 master.lst.1.gz
-rw-r--r--   215728 Sep 11 13:25 master.lst.2.gz
-rw-r--r--    11672 Sep 11 14:15 master.sas
-rw-r--r--      818 Sep 11 13:54 readme.txt
-rw-r--r--     5319 Sep  6 14:11 step1.sas
-rw-r--r--     2546 Sep  6 14:12 step2.sas
-rw-r--r--      979 Sep 11 13:38 stockandyogo.prg
-rw-r--r--    81673 Sep 11 14:10 stockandyogo.raw.lev
-rw-r--r--    81658 Sep 11 14:10 stockandyogo.raw.mcc
-rw-r--r--     2485 Sep 11 13:37 stockandyogo.sas
-rw-r--r--   174991 Sep  4 19:16 table1.raw
-rw-r--r--     6198 Sep  7 21:26 table1.sas
-rw-r--r--      808 Sep  7 18:54 table2.sas

Subdirectory: originallevittfiles
-rw-r--r--    27336 Aug 31 16:10 convert.do
-rw-r--r--   200645 Aug 31 16:10 crime.dta
-rw-r--r--     4450 Aug 31 16:10 crime.txt
-rw-r--r--     7973 Aug 31 16:13 firststa.do
-rw-r--r--    93330 Aug 31 16:13 firststa.log
-rw-r--r--     2219 Aug 31 16:13 readme_levitt.txt
-rw-r--r--     1401 Sep  5 16:47 readme_mccrary.txt
-rw-r--r--   204867 Aug 31 16:11 secstage.lst.gz
-rw-r--r--    43897 Aug 31 16:11 secstage.sas
-rw-r--r--     6384 Aug 31 16:13 summstat.do
-rw-r--r--    68381 Aug 31 16:13 summstat.log


Replication developed by J. McCrary. Tested on a Sun Ultra running Solaris 7.

Archived by Grace Katagiri, 10 September 2001

Last modified: 9/11/2001