jipclaassens / NZlijn

Configuration for my NZL paper
1 stars 0 forks source link

Check for spatial correlation within the residuals #2

Closed jipclaassens closed 1 month ago

jipclaassens commented 1 month ago

Test because of OLS assumption that the errors are iid is violated: assumption of uncorrelated residuals.

Spatial autocorrelation in the residuals is often interpreted to mean that (1) an important independent variable (predictor) is missing from the regression, or (2) an underlying spatial process that induces spatial autocorrelation in some of the variables is missing from the model (e.g. groundwater flow inducing spatial autocorrelation in heavy metals).

Predicted residuals

image

Lijkt duidelijk clusters te bevatten, dus we moeten hier iets mee. Wat precies?

jipclaassens commented 1 month ago

probeer standard error clustering op pc4 of pc6 om dit op te vangen.

jipclaassens commented 1 month ago

met pc6 SE clustering:

areg lnprice treated treattime did lnsize nrooms d_maintgood i.building_type b1.construction_period i.trans_year i.trans_month if ca == 1, absorb(buurt_rel) vce(cluster pc6_code)

image

Zonder die vce pc6 clustering:

image

jipclaassens commented 1 month ago

Lijkt een verbetering te zijn, waar we dus controleren voor de intragroup correlatie van de standard errors