Skip to content
Prev 19838 / 29559 Next

Spatial Regression Eigenwert-Matrix

On Fri, 22 Nov 2013, Jacqueline Schweizer wrote:

            
You did not provide the output of sessionInfo(), but I assume that you are 
using 32-bit Windows. On 64-bit Linux, the error message is:
Error: cannot allocate vector of size 36.5 Gb

You also omitted to report the output of traceback() run after the error 
occurred, so it isn't obvious where this happens

The underlying question is why you want to try to do something that is 
hard (handling large dense matrices), when easier alternatives are 
provided in the same model-fitting function you are using. If you look at 
the help page for lagsarlm(), you'll see that for your intrinsically 
asymmetric weights (k-nearest neighbours are almost always asymmetric), 
your choices for an exact fit are method="eigen" and method="LU", and 
"eigen" presumes moderate n (say < 5000 in most cases).

"LU" provides the same numerical result as "eigen", but is not limited to 
moderate n, because it uses a sparse representation of W; for large n it 
will take some time. Analytical standard errors are not available for 
"LU", with values based on the numerical Hessian returned - you may wish 
to pass the traces of the power series of W to lagsarlm() to improve the 
numerical Hessian values. See Lesage & Pace (2009) and Bivand, Hauke & 
Kossowski (2013) for details.

There are further possibilities for approximations, also described in 
?do_ldet.

Note that the output coefficients of lagsarlm() cannot be interpreted, so 
you will also need to use impacts() to get to something you can use.

Hope this helps,

Roger