[R-sig-Geo] weighted spatial autoregression
Sam Field
fieldsh at mail.med.upenn.edu
Wed Aug 29 18:55:17 CEST 2007
Roger,
One possibility in this limited case might be to replicate the aggregate
level cases based on their respective weights (since they are integers,
i.e. within unit sample sizes), then run a spatial lag model. This
would be equivalent to recreating the individual level data from the
aggregate data (excluding measures that vary within the aggregate
units). This would obviously inflate your sample size and one would
have to correct for this somehow in the variance covariance matrix of
the parameters estimates.
You would have to do the same for your nb object as well of course. I
have looked into this by creating a list of neighbor ids from the
original nb object, but nb2listw() requires an nb object not a list so I
am stuck.
The other problem would be that you would end up with a potentially
large data set. In my case, 13,000 - maybe more then spautolm() could
handle? Maybe this whole idea if flawed.
Thanks again for your input! The results change quite a bit with the
weighted SAR models.
Sam
Roger Bivand wrote:
> On Tue, 21 Aug 2007, Sam Field wrote:
>
>
>> Thanks Roger!
>>
>> Sorry about omitting the subject line. I have been working with errorsarlm() -
>> did not know about spautolm(). Do you know if there is something analogous
>> possible in the case of the spatial lag model,
>>
>> Y = pWY + XB + e ?
>>
>
> I have not looked at it, but because it is a wierd animal, I don't think
> it will be too easy to provide a theoretical foundation for it. The
> heteroskedasticity is in the error term, but the autoregressive part
> isn't. I don't think there are any examples anywhere, either.
>
> It ought to be possible, though.
>
> Roger
>
>
>> I was going to start looking into it.
>>
>> thanks!
>>
>>
>> Sam
>>
>>
>>
>>
>> Quoting Roger Bivand <Roger.Bivand at nhh.no>:
>>
>>
>>> On Tue, 21 Aug 2007, Sam Field wrote:
>>>
>>>
>>>> List,
>>>>
>>>> I am looking for ways of estimating spatial autoregression models that
>>>>
>>> adjust
>>>
>>>> for a known source of heteroskedaticity and the Waller and Gotway (2004)
>>>>
>>> text
>>>
>>>> outline how this can be done in the case of the SAR model. If I work at
>>>>
>>> it, I
>>>
>>>> think I can implement this myself in R, but I wanted to see if anybody else
>>>>
>>> had
>>>
>>>> done it. It seems like a pretty straightforward generalization of the SAR
>>>>
>>> model
>>>
>>>> and would make a very helpful addition to the spatial regression tools in
>>>> spdep - especially given the effects of heteroskedaticity on the
>>>>
>>> consistency of
>>>
>>>> the SAR parameters!
>>>>
>>> ?spautolm
>>>
>>> The examples reproduce the results in Waller & Gotway, perhaps apart from
>>> a flattish function to optimise in the weighted CAR case. spautolm() now
>>> provides weighted or unweighted SAR, CAR, and SMA. Sparse matrix methods
>>> are available for SAR and CAR, SAR when spatial weights are symmetric or
>>> similar to symmetric (CAR weights have to be symmetric).
>>>
>>> Roger
>>>
>>>
>>>> Sam
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>> --
>>> Roger Bivand
>>> Economic Geography Section, Department of Economics, Norwegian School of
>>> Economics and Business Administration, Helleveien 30, N-5045 Bergen,
>>> Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43
>>> e-mail: Roger.Bivand at nhh.no
>>>
>>>
>>>
>>
>>
>
>
--
Samuel H. Field
Division of Internal Medicine - University of Pennsylvania
CHERP - Philadelphia VA Medical Center
3900 Woodland Ave (9 East)
Philadelphia, PA 19104
(215) 823-5800 EXT. 6155 (Office)
(215) 823-6330 (Fax)
More information about the R-sig-Geo
mailing list