I am modeling the diffusion of a technology product across space and time. I am hoping to model the interdependence and influence between geographies directly, and use the model to forecast future performance in specific geographies. I am a bit confused by the different terminologies (e.g. spatiotemporal model vs. spatial panel data, etc.), but the model I want to fit is
$$ Y_t = \lambda W Y_t + \phi Y_{t-1} + \theta W Y_{t-1} + X_t \beta + \epsilon_t $$
Where:
- $W$ is the spatial weights matrix
- $\lambda$ is contemporaneous spatial dependence
- $\phi$ is temporal dependence / inertia
- $\theta$ is temporally lagged spatial dependence
- and $X_t$ and $\beta$ are the usual explanatory variables and their coefficients
The kicker is that I want to use custom weight matrices $W$ - i.e. be able to specify it directly as opposed to have it fall out of the coordinates of point-referenced data.
Many packages in R
come very close to what I need, including spTimer
, spBayes
, stem
and splm
, but nothing quite exactly.
I was wondering if anyone knew of a package in R
that can be used to fit these models. Would be highly appreciated.