Description Usage Arguments Value
sgvSetup
is a wrapper function that sets up the SGV approximation.
Three objects are required: (1) ordering the locations, (2) identify nearest
neighbors, and (3) determine the conditioning set. This function only needs
to be run once per SGV analysis.
1 2 3 4 5 6 7 8 |
coords |
Matrix of observed locations. |
coords_pred |
Optional matrix of prediction locations. |
k |
Number of neighbors. |
seed |
Setting the seed for reproducibility of the observed location ordering |
pred.seed |
Setting the seed for reproducibility of the prediction ordering. |
order_coords |
Logical; should the coordinates be ordered. |
A list with the following components:
ord |
A vector of ordering position for the observed locations. |
ord_pred |
A vector of ordering position for the prediction
locations (if |
ord_all |
A concatenated vector of |
coords_ord |
A matrix of ordered locations (observed and prediction), included for convenience. |
nID_ord |
A matrix of (ordered) neighbor indices. |
condition_on_y_ord |
A matrix indicating whether the conditioning
set for each (ordered) location is on the latent process (y, |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.