Uppsala University Department of Statistics Autumn – 14
Supervisor: Ronnie Pingel Authors: Karl Hammarström & Fabian Söderdahl
Measuring the causal effect of air
temperature on violent crime
This thesis aimed to apply the causal framework with potential outcomes to examine the causal effect of air temperature on reported violent crimes in Swedish municipalities. The Generalized Estimating Equations method was used on yearly, monthly and also July only data for the time period 2002-‐2014. One significant causal effect was established but the majority of the results pointed to there being no causal effect between air temperature and reported violent crimes.
Keywords: Causal inference, propensity score, Inverse Probability Weighing, Generalized Estimating Equations
We would like to thank our supervisor Ronnie Pingel for his undying devotion and support in guiding us through our work on this thesis.
Table of contents
1. Introduction ... 4
2. Previous research on the link between violent crime and temperature ... 6
3. Method ... 7
3.1 Rubin causal framework and potential outcomes ... 7
3.2 Generalized Estimating Equations ... 10
3.2.1 Covariance structures for repeated measurements ... 12
3.3 GEE using a reweighted sample ... 13
3.3.1 Estimation of the propensity score ... 13
3.3.2 The Inverse Probability Weighing estimator ... 14
3.3.2 Variable selection ... 14
3.4 Spatial correlation ... 15
4. Data ... 16
5. Results ... 20
5.1 Spatial correlation ... 20
5.2 Generalized estimating equations ... 20
5.2.1 Monthly data ... 20
5.2.2 Yearly data ... 21
5.3 GEE using reweighted data ... 22
5.3.1 Monthly data ... 22
5.3.2 Yearly data ... 24
5.4 July data ... 25
5.4.1 Generalized estimating equations ... 25
5.4.1 GEE with reweighted data ... 25
6. Discussion ... 27
References ... 29
Causality is often an important goal for researchers. Causality means that the value of one variable affects the value of another variable (Imbens and Wooldridge, 2008). While proving an association is easier to do than proving a causal relationship, it often leaves a lot to be desired when drawing conclusions from a study. Showing that there, for instance, is an association between university students and higher future salary might lead us to instinctually see a causal relationship, going to university leads to higher future salary which does not have to be the case. Instead it might be that individual traits (i.e. intelligence, ambition) make it more likely for an individual to acquire a higher degree, which is also related to higher salaries.
In experiments randomization is a straightforward method for inferring causality (Rubin, 1978). In randomization treatments are randomly assigned to different groups, i.e. in the case of two treatments a control group and a treatment group. Since the treatments are randomly assigned the groups should be similar with regard to the background variables and therefore any differences in the outcome of interest between the treated group and the control group should only be due to the treatment received.
However it is not always possible to conduct these experiments in the real world. If examining smoking’s effect on lung cancer, ethics prevent researchers from randomly selecting people to smoke. In other situations it is just not physically possible to control the assigned treatment. This is the case with the subject of this thesis, the temperatures effect on violent crimes. When looking at the temperatures causal effect on crime there is obviously not any way to control what temperature will be at different locations at different times. Luckily, there are methods, given certain assumptions, for measuring the causal effect when a randomized experiment is not possible (Imbens and Wooldridge, 2008; Rubin, 1974).
Sorg and Taylor, 2011). However, the issue of the real causal effect seems to be in the background of the discussion. Applying the causal inference framework on this seems to be a natural progression for the research in this area.
The aim of this thesis is to examine if there is a causal relation between air temperatures and violent crime in Swedish municipalities. This thesis applies the causal inference framework to see if higher temperatures cause an increase in violent crime.
2. Previous research on the link between violent crime and
The association between temperature and conflict is an area that has been studied in many different scenarios. Hsiang and Burke (2014) provide a thorough summary of previous research in this area. Associations are found between temperature and group conflict (Burke et al., 2009; Dell et al., 2012) as well as temperature and violent crime (Anderson et al., 2000; Jacob et al., 2007; Mares, 2013; Rotton and Cohn, 2000).
There are differing psychological theories for the cause of the relationship between temperature and violent crimes. The general affect aggression model states that higher temperatures increases aggressive behavior by psychological changes caused by higher temperatures (Anderson et al., 2000). This theory implicates a linear relationship between temperature and violent crime. On the other side, the negative affect escape model states that violent behavior increases to a certain point in a linear fashion but then decreases as extremely high temperatures causes individuals to instead try to escape the discomfort caused by the temperatures (Rotton and Cohn, 2000). This theory suggests a curvelinear relationship but is not something that is particularly considered in this thesis, as it is uncommon that temperatures in Sweden reach such high temperatures.
This thesis applies a causal framework to estimate the relationship between temperature and violent crime. Two different methods in this framwork are utilized to see if there is a causal relation between temperature and violent crime. The first method is the Generalized Estimating Equations (GEE). GEE is a commonly used method when examining longitudinal data that is correlated over time.
The second part of the method involves reweighing the sample using the propensity score the Inverse Probability Weighing (IPW) and then applying the GEE. This section first presents the causal framework which this analysis is based upon. Secondly the GEE method is described and then the theory behind the propensity score and the IPW estimator are introduced. Lastly this section presents the issue of spatial correlation and how to test for it as that could possibly be a problem in this study.
3.1 Rubin causal framework and potential outcomes
Rubin (1974) presents the framework for potential outcomes that is widely used in causal inference. This framework is called the Rubin causal model (RCM). The aim of causal inference is to estimate the effect of a treatment on an individual. Rubin (1974) considers a causal effect as the effect of a treatment in relation to another treatment.
The fundamental aspect of the RCM is potential outcomes. Assuming a sample of
i=1, 2, …, N individuals. Each individual is associated with a value for the
potential outcomes for each individual. The observed response is then for each individual
𝑌! = 𝑇×𝑌! 1 + 1 − 𝑇 ×𝑌! 0 (1)
This equation leads to what is known as the Fundamental Problem of Causal Inference (Holland, 1986). For each individual i we can only observe one treatment T at the same time, meaning that we can only observe one of either
Yi(0) or Yi(1). This makes it impossible to estimate what the goal of causal inference is, which is the individual causal effect
𝑌! 1 − 𝑌! 0 (2)
The solution to this problem is to look at the sample as a whole instead of at each individual and compare the untreated group (control group) against the treated group (Rubin, 1974). For this to be possible the two groups need to be similar on certain background variables Xi, called covariates. In a randomized experiment where the control and treatment groups are randomly assigned, it can be assumed that the two groups are similar on the background variables (Rubin, 1978). In an observational study however, this cannot be assumed. While there are several variations when estimating the causal effect such as median or ratios, this thesis focuses on the most used variant that is the average treatment effect
𝐴𝑇𝐸 = 𝐸 𝑌 1 − 𝑌(0) (3)
The average treatment effect can be estimated in an observational study given an assumption of unconfoundedness where X is a vector of covariates
𝑌(0), 𝑌(1) ∐ 𝑇 𝑋 (4)
and an overlap assumption
The unconfoundedness assumption states that the treatment should be independent, ∐ of the outcomes conditional on a vector of covariates and the second assumption is that each individual should have a non-‐zero chance to be given one or the other treatment. Given the assumptions the average treatment effect is identified by
𝐴𝑇𝐸 = 𝐸 𝐸 𝑌 1 − 𝑌 0 𝑋 = 𝐸 𝐸 𝑌 1 𝑇 = 1, 𝑋 − 𝐸 𝑌 0 𝑇 = 0, 𝑋 = 𝐸 𝐸 𝑌 𝑇 = 1, 𝑋 − 𝐸 𝑌 𝑇 = 0, 𝑋 = 𝐸 𝑌 1 − 𝑌(0) (6)
Looking at this equation we see that identification of the average treatment effect is now possible, given the assumptions, to be estimated by comparing treated and untreated individuals conditional on the vector of covariates X. The ATE can for example be estimated by the difference on the regression of treated group and the control group.
Alternatively, it can be shown that (Imbens and Wooldridge, 2008) that by weighing the sample, an estimate of the average treatment effect is given by
𝐴𝑇𝐸 = 𝐸 !"
! ! −
!!! ! = 𝐸 𝑌 1 − 𝑌(0) (7) were p(x) is the propensity score which is described more extensively in section
3.3.1. The propensity score is often modeled using a logit model 𝑃𝑟𝑜𝑝𝑒𝑛𝑠𝑖𝑡𝑦 𝑠𝑐𝑜𝑟𝑒 = p(x) = !!!!!!!!!"!!!!!!"
From equation 7 appropriate estimators can then be developed.
In this analysis the data used is measured both over several observations and over time and this will pose a problem when estimating ATE. Consider that one might estimate the ATE for each point in time where j indicates time and 𝜏! is the ATE for each time point k
𝐸 𝑌! 1 −𝑌! 0 =𝜏! 𝐸 𝑌! 1 −𝑌! 0 =𝜏! ⋮ 𝐸 𝑌! 1 −𝑌! 0 =𝜏!
The estimated ATE:s will due to the correlation over time be dependent. To deal with this issue the model that is used must account for the correlation in the data over time. A model suitable for this is the Generalized Estimating Equations that is described in the following section.
3.2 Generalized Estimating Equations
Generalized Estimating Equations (GEE) is an extension of Generalized Linear Models (GLM) and was first introduced by Zeger et al. (1988). The GLM is suitable for independent observations and the Generalized Estimating Equations extends these models to work for time dependent data. The GEE has a population-‐average approach, meaning that the focus is to draw inferences about the population as a whole and not on individuals. This is of importance when interpretating the regression coefficients (Zeger et al., 1988).
variable Y, covariates X and the suffixes i for individuals and j for time the model looks as follows:
𝐸 𝑌!" = 𝛽!+ 𝛽!𝑋!!"+𝛽!𝑋!!"+𝛽!𝑋!!"+ ⋯ (9)
By the link function the mean of Yij is related to the covariates as seen in equation 9.
Given the effect of the covariates, the variance of each Yij are dependent on the mean response, 𝜇!", as
𝑉𝑎𝑟 𝑌!" = 𝜙𝜇!" (10)
ϕ is a time-‐invariant scale parameter, meaning it is not dependent on time. It is
required to estimate this parameter.
The GEE is dependent on both estimates of α (Equation 14) and β. Because of this, the estimation procedure is an iterative process in two steps meaning that it repeats the calculations of the two steps until the results are satisfactory. Given values of α and ϕ, the β are estimated by solving the generalized estimating equation which is the first step in the iterative process
𝑈 𝛽 = !!!! !!∗𝑉!!! 𝛼 𝑌! − 𝜇! = 0 ! !!! (11)
The other step in the iterative process is to given the values of the β estimate the
α and ϕ based on the standardized residuals
𝑒!" =(!!"!!!") !(!!")
(12) where then ϕ can be estimated by
𝜙 = !!" ! !! !!! ! !!! !! ! !!! (13)
and α when using for example the autoregressive model, AR(1), presented below as the model for the within-‐subject association can be estimated by
𝛼 = 𝜌𝛼!,!!!+ 𝑒!" (14)
3.2.1 Covariance structures for repeated measurements
When working with data that is both measured cross-‐sectionally as well as over time there are certain aspects that need to be taken into account. One issue is that observations can be correlated over time. To correct for this, the proper covariance structure needs to be estimated. We show some examples for three time points. Σ = 𝑉𝑎𝑟(𝑌!) 𝐶𝑜𝑣(𝑌!, 𝑌!) 𝐶𝑜𝑣(𝑌!, 𝑌!) 𝐶𝑜𝑣(𝑌!, 𝑌!) 𝑉𝑎𝑟(𝑌!) 𝐶𝑜𝑣(𝑌!, 𝑌!) 𝐶𝑜𝑣(𝑌!, 𝑌!) 𝐶𝑜𝑣(𝑌!, 𝑌!) 𝑉𝑎𝑟(𝑌!)
Clearly, there are several different covariance structures available depending on the data. The compound symmetry structure is the structure that is the simplest among the covariance structures. It assumes that the each covariance is constant over time
Σ = 𝜎! 1 𝜌 𝜌𝜌 1 𝜌
𝜌 𝜌 1
The most commonly used covariance structure when observations closer to each other in time are more highly correlated than observations further apart is the first order autoregressive model or AR(1) for short
The last covariance structure considered in this analysis is the Toeplitz model. While the Toeplitz model is similar to the AR(1), it does require more parameters to be estimated
Σ = 𝜎!! 𝜌1 𝜌! 𝜌! ! 1 𝜌! 𝜌! 𝜌! 1 = 𝜎!! 𝜎 !" 𝜎!" 𝜎!" 𝜎!! 𝜎!" 𝜎!" 𝜎!" 𝜎!!
The Toeplitz model and the AR(1) model are often suitable when the observations are equally spaced over time which is the case in this analysis and could speak in their favor.
3.3 GEE using a reweighted sample
The IPW estimator have been used to account for missing data in longitudinal studies (Little and Rubin, 2002). Liang and Zeger (1986) extended the GEE approach by using GEE with reweighted data. Seeing as the IPW estimator can also be used to make the reweighted sample independent of background variables, this study will also test the data by applying the GEE to the reweighted sample to see if that will give differing results from the normal use with GEE.
3.3.1 Estimation of the propensity score
The propensity score is the conditional probability that an individual is assigned treatment given a vector of observed covariates (Rosenbaum and Rubin, 1983a). The propensity allows for easily adjusting for many covariates by reducing the covariates from a multidimensional issue to be one-‐dimensional instead.
One issue with the estimation of the propensity score is that the temperature observations in consecutive months could be correlated. For the yearly and July data this does not pose a problem. Due to time constraints we do not take this into consideration but it should be noted as a possible source of weakness in the estimated propensity score.
assumption of unconfoundedness is fulfilled, meaning treatment is unconfounded given X, then it is also unconfounded given the propensity score. Given this assumption, at any value of the propensity score, unbiased estimates of the ATE are given by the difference between the treated and the control group individuals. One way to check for the suitability of the propensity score is to see if the propensity score is balanced between the treated and control group (Caliendo and Kopeinig, 2008).
3.3.2 The Inverse Probability Weighing estimator
The Inverse Probability Weighting (IPW) creates a synthetic sample where the baseline covariates are independent of treatment assignment. This is done by utilizing the propensity score (Austin, 2011). The new, weighted municipalities can be defined as
𝑌!" = 𝑌!" ! !!! + 𝑌!"!!! !(!!!!) .
The weight of a municipality is equal to the inverse probability of receiving a positive deviation in average temperature that the municipality actually received. GEE is then performed on the new synthetic sample.
𝐸 𝑌!" = 𝛽!+ 𝛽!𝑇!"
Seeing as the background variables are already accounted for, only treatment is included in the regression.
3.3.2 Variable selection
Brookhart et al. (2006) examines which variables to include in the model. They test three different variables; X1 which is only related to the treatment, X2 which
is a true confounder and is related to both the treatment and the outcome and X3
which is related only to the outcome. The results show that the true confounder X2 should always be included in the model. The variable related to the outcome,
X3, improves the model by decreasing the variance. X1, the variable related only
to the treatment should however not be included in the model. These results are also supported by earlier findings by Rubin and Thomas (1996).
Figure 1: Illustration of variable selection
In this thesis, precipitation is expected to be a true confounder affecting both temperature and violent crime. Other background variables are variables concerning socioeconomic factors and demographic factors that are believed to be related only to the response variable. Seeing as according to theory there are no other variables other than precipitation that can have an influence on both temperature and the variable violent crimes, the unconfoundedness assumption in formula 4 should hold.
3.4 Spatial correlation
The data is both monthly and yearly municipality data for the time-‐period January 2002 up until October 2014 with all the data collected from government sources. We also research the month of July on its own to test if the effect only exists for higher temperatures. Due to limitations in the accessibility of weather data our dataset is narrowed down to seventy municipalities spread evenly across the counties in Sweden.
The treatment in this paper is defined in two different ways. Firstly for the monthly and yearly analyses it is defined as
• Deviation in air temperature: This variable is a binary variable with 1 being air temperatures more than 1 degree Celsius over the historical mean temperature for each month and year respectively and 0 for observations with air temperatures below that. The observations are for every weather station located in the different municipalities, collected from The Swedish institute for meteorology and hydrology.
Secondly for the July data
• Deviation in air temperature: This variable is a binary variable with 1 being air temperatures more than 18 degree Celsius and 0 for observations with air temperature with 18 and below for each month and year respectively for every weather station located in the different municipalities, collected from The Swedish institute for meteorology and hydrology.
The effect or response in this paper is
The following variables are the covariates or background variables used. All variables are available for yearly data but only the unemployment variable is available for the monthly and July data
• Disposable income: The individual average disposable income in Swedish crowns.
• Age: The mean age for the municipalities.
• Population: The population density, recorded as individuals per square kilometer.
• Foreigners: The percentage of foreign born citizens.
• Precipitation: The mean amount of downfall measured in millimeters, also collected from SMHI.
• Unemployment: The total number of unemployed persons in the age group 16-‐64 years of age.
Variables measured in total numbers as unemployment and violent crimes were controlled for population by entering them as the total number per every 100 000 inhabitants. Table 1 displays descriptive statistics for the variables.
Table 1: Descriptive statistics
Variable Mean Standard Deviation
Crime 65.71 167.71 Unemployment 1639.69 2971.29 Precipitation 55.56 40.96 Temperature 5.41 8.29 Population density 142.62 553.90 Foreign 12.05 8.01 Income 4.79 0.57 Age 42.79 2.85
loud and the other one proofreading to catch eventual errors made by the one entering the data. A visual inspection of the dataset up on completion was also made and found errors were corrected.
Similarly to Sorg and Taylor (2011), the temperature is measured as deviations from a historical mean. By doing this we remove the effects of seasonality in the analysis. The historical mean is taken from SMHI’s calculations from the period 1960-‐1990 for each municipality.
Figure 2 shows the distribution of the variable crime. The distribution looks roughly Poisson distributed. As previously mentioned the GEE is robust assumptions of distribution and a Gaussian variance function is used in this thesis.
Figure 3: Distribution of temperature deviation
Figure 3 displays the distribution of the deviation of temperature. It is a lot pointier than a standard normal distribution but it can be assumed to be approximately normally distributed. In appendix A there are also time series plots of crime and temperature.
This section presents the results of the computations made in SAS version 9.4. The significance level used is the standard five percent level.
5.1 Spatial correlation
Since the observations in the data are geographically distributed there may be spatial correlation between nearby municipalities concerning crime. Moran’s I-‐ test for spatial correlation shown in table 2 yields a non-‐significant result. The null hypothesis for Moran’s I-‐test is that there is no spatial correlation between the observations. This means that there is no significant spatial correlation on violent crime present in the data.
Table 2: Moran’s I test for violent crime
Coefficient Observed Standard
deviation Z-‐value P-‐value
Moran's I -‐0.0207 0.0105 -‐0,649 0,52
Geary's c 1,01 0,030 0,336 0,73
5.2 Generalized estimating equations
This section presents the estimation results for the GEE model without a weighted sample with both monthly and yearly data.
5.2.1 Monthly data
The results when using the GEE with monthly data are displayed in table 3. By comparing the estimated covariance matrices with the original, the Toeplitz covariance structure was the best fit and is therefore used. The covariance matrices are however excluded here as they are large in size and due to that hard to interpret. The temperature deviation from the historical mean has a coefficient estimate of -‐0.02, which is the average treatment effect, indicating that when the temperature is equal to one degree over the historical temperature mean or colder there are on average 0.02 fewer reported violent crimes. This is not in line with the theories discussed earlier in this thesis.
significant causal effect of temperature deviation on reported violent crimes. The residual plot can be found in figure 6 in appendix A, indicating that our covariance structure is correctly specified. Even though unemployment has a significant p-‐value, it should still not be interpreted as a causal effect seeing as the assumptions required are only verified for the temperature deviation and not for the unemployment variable.
5.2.2 Yearly data
Table 4 shows the estimation using GEE on yearly data. Again the Toeplitz covariance structure was the most suitable. The average treatment effect is -‐ 0.018 but similarly to before the confidence interval, ranging from -‐0.038 to 0.002, covers zero and therefore the causal effect is not significant. The only variables that have a significant impact on the mean of violent crime are percentage of foreign born, income and age. However it is important to stress once again that even though they are significant, a causal interpretation cannot be concluded seeing as the assumptions needed are not examined. The residuals are shown in figure 7 in appendix A and show that the covariance structure used is appropriate.
Table 3: GEE with monthly data
Variable Coefficient SE 95 % CI Z P-‐value
5.3 GEE using reweighted data
This section presents the estimation results using the propensity score to reweigh the data on both monthly and yearly data.
5.3.1 Monthly data
Table 5 displays the output of the estimated propensity score using a logit model. The only background variables used are unemployment and precipitation. From the p-‐values we see that unemployment has an non significant effect while precipitation does have a significant effect, both variables are however kept in the calculations of the propensity score since unemployment is related to the outcome. The values for the dummy variables showing which municipality are not included here seeing as there are 70 dummy variables, one for each municipality.
Table 4: GEE with yearly data
Variable Coeff. SE 95 % CI Z P-‐value
Table 5: Logit with monthly data
Variable Coefficient Standard Error Wald Chi
square P-‐value Intercept -‐0,0083 0,17 0,0023 0,96 Unemployment -‐0,00003 0,000033 0,77 0,38 Precipitation 0,0031 0,00058 28,61 <0,0001
After estimating the propensity score, the weights are calculated using the inverse probability. This creates a new synthetic sample that is independent of the background variables. The boxplot of the weights are shown in figure 8 in appendix A and the weights appear to be balanced.
After the sample is weighted a GEE regression of the temperature deviation on violent crimes is performed. Here the AR(1) covariance structure was the best fit. The results are shown in table 6. This result is similar to the two previous results, i.e. we find no effect of temperature on crime. However, the point estimate of the average treatment effect of temperature on crime is 0.02 and it must be noted that using the reweighted data we don’t adjust the standard errors due to the estimation of the propensity score. That is we assume that the propensity score is true. Studies have shown (e.g. Lunceford and Davidian, 2004) that this results in conservative estimates of ATE with standard errors that are too wide. In theory this could be adjusted for by using for instance bootstrap or using a Sandwich estimator, however, this is not feasible in this study. Once again the 95 % confidence interval stretches over zero so there is no significant causal effect.
Table 6: GEE with IPW and monthly data
Variable Coeff. SE 95 % CI Z P-‐value
Intercept 4.31 0.04 4.24 4.38 119.58 <.0001
5.3.2 Yearly data
The propensity score estimate for yearly data can be seen in table 7. All variables are significant except for one variable which is unemployment. All variables are still kept to ensure that all background variables are accounted for, to increase precision. The weights are then calculated the same as earlier. The boxplot of the weights are shown in Appendix A in figure 9 and unfortunately they are not perfectly balanced but still good enough for the analysis to be performed.
Table 8 shows the final estimate of the causal relation between temperature deviation and violent crime. The covariance structure used is the Toeplitz structure. The average treatment effect is -‐0.04 with a 95 % confidence interval from -‐0.08 to -‐0.001 and therefore the causal effect is significant. On average municipalities that experience temperatures equal to 1 degree over the historical mean or below have 0.04 fewer reported crimes compared to municipalities with higher temperatures. This is not in line with the pervious result for monthly data using IPW-‐estimators. This could be because for the yearly data there are more background variables available but it could also be because there are fewer observations for yearly data.
Table 8: GEE with weighted data yearly
Variable Coefficient SE 95 % CI Z P-‐value
Intercept 6.6021 0.0562 6.4920 6.7123 117.47 <.0001
-‐0.0439 0.0173 -‐0.0779 -‐0.0099 -‐2.53 0.0113
Table 7: Logit model with yearly data
Variable Coefficient Standard Error Wald Chi
5.4 July data
This section presents estimates of GEE and propensity score with data for only July months. This is performed to see if the relationship between violent crime and temperature is stronger at time periods with higher temperatures.
5.4.1 Generalized estimating equations
Table 9 shows the results on July data using GEE. Again the Toeplitz covariance structure most resembled the original covariance structure. The average treatment effect is -‐0.07. The 95 % confidence interval is -‐0.025 to 0.11 and as previously when using the non-‐weighted sample there is no significant causal relationship found between temperature deviations and reported violent crimes. The variable unemployment has a p-‐value 0.006 meaning that it has a significant effect but seeing as the assumptions are not accounted for it cannot be interpreted as a causal relationship. Precipitation does not have a significant effect on violent crime. The residuals are in figure 10 in Appendix A and are evenly distributed around zero and therefore the covariance structure used is appropriate.
5.4.1 GEE with reweighted data
In table 10 the results of the logit estimation are shown. All variables are significant and based on the results the weights are calculated as previously.
Table 10: Logit with July data
Variable Coefficient Standard Error Wald Chi
Intercept -‐0,96 0,16 37,45 <0,0001
Unemployment -‐0,00007 0,000025 6,63 0,010
Precipitation 0,0096 0,0016 35,58 <0,0001
Table 9: GEE with July data and temperature
Variable Coeff. SE 95 % CI Z P-‐value
Intercept 4.3498 0.0549 4.2422 4.4574 79.24 <.0001
Temperature -0.0699 0.0905 -0.2472 0.1074 -0.77 0.4397
Unemployment 0.0000 0.0000 0.0000 0.0000 2.77 0.0056
The boxplot is shown in appendix A figure 11 and shows that the propensity scores are fairly evenly distributed.
Table 11 shows the regression on the reweighted sample. The estimated average treatment effect is 5,06 but similar to most of the previous results there is not a significant causal relationship between temperature and violent crimes for the July data seeing as the confidence interval stretches over zero. However, the coefficient is positive, and the p-‐value is less than 0.1. It would be interesting to carry out bootstrap to see whether we actually establish a significant effect if using correct standard errors.
Table 11: GEE with weighted July data
Variable Coefficient Standard Error Z-‐value P-‐value
Intercept 80,85 2,42 33,47 <0,0001
In this study our goal was to research the causal effect that temperature has on the total number of reported violent crimes in Sweden. When using generalized estimating equations our results show that temperature does not have a significant causal effect on the number of reported violent crimes, neither on the yearly nor monthly data material except for yearly data with a reweighted sample. Even though we included several background variables in the model for yearly data, the result was still inconclusive.
In our testing with the weighted data material temperature was insignificant on the monthly data. We got significant results for our yearly data but they showed that temperature had a negative effect on the mean of reported violent crimes. So while we found a significant causal effect, the effect was not in line with our stated theory.
The only difference in results between the two above stated methods are that the variable temperature was significant when using reweighted yearly data. This is perhaps due to an imbalance in the weight that existed for the reweighted sample with yearly data. When using data that spans over the whole year as for the monthly data and also when using the yearly data, the lower temperatures during the winter months make drawing conclusions about the general affect aggression theory not appropriate. However the routine activity theory, stating that people are more outside when temperatures are higher could possibly be connected to these results, which mostly disprove that theory.
The results for the month of July also yielded an insignificant result for the variable temperature’s effect on the mean of reported violent crimes. We were a bit surprised by this result since this goes against the general affect aggression model, which states that higher temperatures increases aggressive behavior by psychological changes.
The July results also goes against the routine activity theory which states that individuals tend to be more out and about when temperatures are higher and this leads to an increased number of violent confrontations.
A possible explanation for our lack of results is perhaps that many of the municipalities in our data material are scarcely populated. Another critique of this study is that it doesn’t take the possibly large number of unreported violent crimes in to account. While most of the results yielded a negative average treatment effect, the result for July data with reweighted sample gave a relatively higher positive average treatment effect that is consistent with the theory. This could be because the winter months are too cold for the underlying theory to be relevant. Future research could implement the causal framework in regions with more largely populated areas and where the temperatures reach higher levels. In conclusion this study does not find any compelling evidence that higher temperatures causes more violent crimes.
Anderson, C.A., Anderson, K.B., Dorr, N., DeNeve, K.M., Flanagan, M., 2000. Temperature and aggression, in: Mark P. Zanna (Ed.), Advances in Experimental Social Psychology. Academic Press, pp. 63–133.
Austin, P.C., 2011. An Introduction to Propensity Score Methods for Reducing the Effects of Confounding in Observational Studies. Multivariate Behavioral Research 46, 399–424.
Brookhart, M.A., Schneeweiss, S., Rothman, K.J., Glynn, R.J., Avorn, J., Stürmer, T., 2006. Variable Selection for Propensity Score Models. Am. J. Epidemiol. 163, 1149–1156.
Burke, M.B., Miguel, E., Satyanath, S., Dykema, J.A., Lobell, D.B., 2009. Warming increases the risk of civil war in Africa. PNAS 106, 20670–20674.
Caliendo, M., Kopeinig, S., 2008. Some Practical Guidance for the Implementation of Propensity Score Matching. Journal of Economic Surveys 22, 31–72. Cliff, A.D., Ord, J.K., 1981. Spatial processes : models and applications. Pion Ltd,
Cohen, L.E., Felson, M., 1979. Social Change and Crime Rate Trends: A Routine Activity Approach. American Sociological Review 44, 588–608.
Dell, M., Jones, B.F., Olken, B.A., 2012. Temperature Shocks and Economic Growth: Evidence from the Last Half Century. American Economic Journal: Macroeconomics 4, 66–95.
Hanley, J.A., Negassa, A., Edwardes, M.D. deB, Forrester, J.E., 2003. Statistical Analysis of Correlated Data Using Generalized Estimating Equations: An Orientation. Am. J. Epidemiol. 157, 364–375.
Holland, P.W., 1986. Statistics and Causal Inference. Journal of the American Statistical Association 81, 945–960.
Hsiang, S.M., Burke, M., 2014. Climate, conflict, and social stability: what does the evidence say? Climatic Change 123, 39–55.
Imbens, G.M., Wooldridge, J.M., 2008. Recent Developments in the Econometrics of Program Evaluation (Working Paper No. 14251). National Bureau of Economic Research.
Jacob, B., Lefgren, L., Moretti, E., 2007. The Dynamics of Criminal Behavior: Evidence from Weather Shocks. The Journal of Human Resources 42, 489–527.
Liang, K.-‐Y., Zeger, S.L., 1986. Longitudinal data analysis using generalized linear models. Biometrika 73, 13–22.
Little, R., Rubin, D., 2002. Statistical Analysis with Missing Data. Wiley. Lunceford, J.K., Davidian, M., 2004. Stratification and weighting via the
propensity score in estimation of causal treatment effects: a comparative study. Statist. Med. 23, 2937–2960.
Mares, D., 2013. Climate Change and Levels of Violence in Socially Disadvantaged Neighborhood Groups. J Urban Health 90, 768–783.
Moran, P.A.P., 1950. Notes on Continuous Stochastic Phenomena. Biometrika 37, 17–23.
Rosenbaum, P.R., Rubin, D.B., 1983a. The Central Role of the Propensity Score in Observational Studies for Causal Effects. Biometrika 70, 41–55.
Rosenbaum, P.R., Rubin, D.B., 1983b. The central role of the propensity score in observational studies for causal effects. Biometrika 70, 41–55.
Rotton, J., Cohn, E.G., 2000. Weather, disorderly conduct, and assaults: from social contact to social avoidance. Environment and Behavior 32, 651– 673.
Rubin, D.B., 1974. Estimating causal effects of treatments in randomized and nonrandomized studies. Journal of Educational Psychology 66, 688–701. Rubin, D.B., 1978. Bayesian Inference for Causal Effects: The Role of
Randomization. The Annals of Statistics 6, 34–58.
Rubin, D.B., Thomas, N., 1996. Matching Using Estimated Propensity Scores: Relating Theory to Practice. Biometrics 52, 249–264.
Sorg, E.T., Taylor, R.B., 2011. Community-‐level impacts of temperature on urban street robbery. Journal of Criminal Justice 39, 463–470.
Zeger, S.L., Liang, K.-‐Y., Albert, P.S., 1988. Models for Longitudinal Data: A Generalized Estimating Equation Approach. Biometrics 44, 1049–1060.
Figure 4: TIme serie of crime
Figure 5: Time serie of temperature
Figure 6: Residual plot monthly data
Figure 8: Boxplot for monthly data
Figure 10: Residuals for July data