View source: R/basic_functions.R
run_npvecchia | R Documentation |
This wraps all of the smaller functions into one simple function to compute the MAP estimate of the upper Cholesky of the precision matrix.
run_npvecchia( datum, locs, corr_order = T, tapering_range = 0.4, threshh = 0.001, max_m = 50, init_theta = c(1, -1, 0) )
datum |
an N * n matrix of the data (N replications of n locations/variables) |
locs |
an n*d matrix of data locations(to match input argument of fields::rdist) |
corr_order |
logical flag (defaults to TRUE). If true, uses correlation ordering. Otherwise, it uses maximin ordering based on locations. |
tapering_range |
Percentage of the maximum distance for Exponential tapering, which defaults to 0.4 * the maximum distance. |
threshh |
threshold for number of neighbors (for thetas_to_priors); defaults to 1e-3 |
max_m |
number of neighbors to compute initially; a maximum number of neighbors possible for the methodology |
init_theta |
the initialization of the optimization to find the optimal theta |
A list of two elements: 1) u – a sparse triangular matrix that is the Cholesky of the precision matrix Ω such that
Ω = U U'
and 2) the order of the data that was used to calculate it (i.e. the reordered data is approximately normal with mean 0 and precision Ω)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.