Description Usage Arguments Value Examples
View source: R/mra-wendland-2d-pred.R
Code to construct the mutli-resolution sparse basis function representation for fitting spatial processes
1 | mra_wendland_2d_pred(locs, locs_pred, MRA, use_spam = TRUE)
|
locs |
The location variables in 2 dimensions over which to construct the basis function representation in the fitting stage. |
locs_pred |
The location variables in 2 dimensions over which to construct the basis function representation in the prediction stage. |
MRA |
The multi-resolution basis expansion at the observed locations. This object is the output of |
use_spam |
is a boolean flag to determine whether the output is a list of spam matrix objects ( |
A list of objects including the MRA knots locations locs_grid
,
the Wendland basis representation matrix W_pred
at the prediction locations, and the basis radius radius
1 2 3 4 5 6 7 8 9 10 | set.seed(111)
locs <- matrix(runif(20), 10, 2)
locs_pred <- matrix(runif(20), 10, 2)
MRA <- mra_wendland_2d(locs, M = 2, n_coarse_grid = 4)
MRA_pred <- mra_wendland_2d_pred(locs, locs_pred, MRA)
## plot the MRA prediction grid at different resolutions
layout(matrix(1:2, 1, 2))
plot(MRA_pred$locs_grid[[1]])
plot(MRA_pred$locs_grid[[2]])
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.