Estimate Spatial Autoregressive model using weighted least squares

Viewed 14

I have a regression estimated via OLS and WLS and would like to test for spatial effects (estimate SAR) in both models, but I didn't find how to use WLS in SAR model. The package spatialreg offers the option to include weights just for the Spatial Error Model (function errorsarlm). By reading the manual I thought the function spautolm with the argument SAR should do it, but the results seem to be exactly the same of SEM.

Replication:

 library(spatialreg)
 data(oldcol, package="spdep")
 listw <- spdep::nb2listw(COL.nb, style="W")
 COL.OLD$POP <- rnorm(49, 1000, 400)

 model1 <- errorsarlm(CRIME ~ INC + HOVAL, data=COL.OLD,
                 weights=POP,listw=listw)
 model2 <- spautolm(CRIME ~ INC + HOVAL, data=COL.OLD,family = "SAR",
               weights=POP,listw=listw)
 summary(model1)
 summary(model2)

How can I estimate the SAR model?

I'm using R, but any other software would be fine as well.

0 Answers
Related