predictions: Compute Gaussian process predictions using Vecchia's...

Description Usage Arguments Details

View source: R/predictions.R

Description

With the prediction locations ordered after the observation locations, an approximation for the inverse Cholesky of the covariance matrix is computed, and standard formulas are applied to obtain the conditional expectation.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
predictions(
  fit = NULL,
  locs_pred,
  X_pred,
  y_obs = fit$y,
  locs_obs = fit$locs,
  X_obs = fit$X,
  beta = fit$betahat,
  covparms = fit$covparms,
  covfun_name = fit$covfun_name,
  m = 60,
  reorder = TRUE,
  st_scale = NULL
)

Arguments

fit

GpGp_fit object, the result of fit_model

locs_pred

prediction locations

X_pred

Design matrix for predictions

y_obs

Observations associated with locs_obs

locs_obs

observation locations

X_obs

Design matrix for observations

beta

Linear mean parameters

covparms

Covariance parameters

covfun_name

Name of covariance function

m

Number of nearest neighbors to use

reorder

TRUE/FALSE for whether reordering should be done. This should generally be kept at TRUE, unless testing out the effect of reordering.

st_scale

amount by which to scale the spatial and temporal dimensions for the purpose of selecting neighbors. We recommend setting this manually when using a spatial-temporal covariance function. When lonlat = TRUE, spatial scale is in radians (earth radius = 1).

Details

We can specify either a GpGp_fit object (the result of fit_model), OR manually enter the covariance function and parameters, the observations, observation locations, and design matrix. We must specify the prediction locations and the prediction design matrix.


GpGp documentation built on June 10, 2021, 1:07 a.m.