mungeCARdata4stan: Prepare necessary components of the IAR model for use in...

View source: R/mungeCARdata4stan.R

mungeCARdata4stanR Documentation

Prepare necessary components of the IAR model for use in stan.

Description

The underlying 'stan' code can work without explicitly calling or building the adjacency matrix, but to do so requires some processing, which is done here.

Usage

mungeCARdata4stan(adjBUGS, numBUGS)

Arguments

adjBUGS

A vector of neighbor indices.

numBUGS

A vector containing the number of neighbors for each point.

Value

Returns a list where J is the number predictors, J_edges is the number of edges in connected graph representing the spatial data, and node1, node2 are required to fit the model without explicitly specifying an adjacency matrix. This function is essentially unchanged from Mitzi Morris's code \insertCiteMorris:2017,Morris:2019ssnet.

References

\insertRef

Morris:2017ssnet

\insertRef

Morris:2019ssnet


jmleach-bst/ssnet documentation built on March 4, 2024, 5:04 p.m.