A x
A x where A = sum (parameters[i]
N[i]) is a function of the spatial neighbor matrices
N[i], and
x
is an arbitrary vector (or matrix).
spatial.multiply(neighbor, x, transpose=F, parameters=NULL,
region.id=NULL)
spatial.neighbor containing the sparse matrix
representation of the spatial neighbor matrices
N[i]
(see function
spatial.neighbor).
N[i] are to be used in place of the
N[i] when
computing
A. Here
A is represented as the sum over i of
parameters[i] N[i],
parameters[i] is a scalar, and
N[i]
is the
i-th spatial neighbor matrix represented by
neighbor. If
transpose is
TRUE, then the transpose of each
N[i] is used in
place of
N[i].
row.id and
col.id of argument
neighbor are
not integer valued variables with sequential values from 1 to the
number or regions in the lattice, then argument
region.id must be
specified and is used to obtain a sequential coding of the lattice regions.
A x.
The neighbor object is a sparse matrix representation of the neighbor matrix. Because it is sparse, the matrix multiplication is carried out using sparse matrix methods.
spatial.multiply(sids.neighbor, 1:100, parameters=c(-0.3))