Learn R Programming

geoR (version 1.0-0)

krige.conv: Spatial Prediction -- Conventional Kriging

Description

This function performs spatial prediction for fixed covariance parameters using global neighborhood. Available options implement the following kriging types: SK (simple kriging), OK (ordinary kriging), KTE (external trend kriging) and UK (universal kriging).

Usage

krige.conv(geodata, coords = geodata$coords, data = geodata$data, 
           locations,
           krige = krige.control(type.krige, beta = NULL,
                     trend.d, trend.l, cov.model, cov.pars,
                     kappa = 0.5, nugget = 0, micro.scale = 0,
                     dist.epsilon = 1e-10, aniso.pars = NULL, 
                     lambda = 1, signal = FALSE,
                     n.samples.backtransform = 500, n.sim = 0),
           messages.screen = TRUE)

Arguments

geodata
a list containing elements coords and data as described next. Typically an object of the class "geodata" - a geoR data-set. If not provided the arguments
coords
an $n \times 2$ containing in each row have the 2-D coordinates of the $n$ data locations. By default it takes the component coords of the argument geodata, if provided.
data
a vector with n data values. By default it takes the component data of the argument geodata, if provided.
locations
an $N \times 2$ matrix or data-frame with the 2-D coordinates of the $N$ prediction locations.
krige
defines the model components and the type of kriging. See section DETAILS below. ATTENTION: the argument cov.pars is obligatory whilst all the others have default options.
messages.screen
logical. Indicates whether or not status messages are printed on the screen (or other output device) while the function is running.

Value

  • An object of the class kriging which is a list with the following components:
  • predicta vector with predicted values.
  • krige.vara vector with predicted variances.
  • beta.estestimates of the $\beta$, parameter implicit in kriging procedure. Not valid if type.krige = "SK".
  • simulationsan $ni \times n.sim$ matrix where $ni$ is the number of prediction locations. Each column corresponds to a conditional simulation of the predictive distribution. Only returned if n.sim > 0.
  • messagemessages about the type of prediction performed.
  • callthe function call.

Details

One of the following different types of kriging: SK, OK, UK or KTE is performed, according to the input options. Defaults correspond to ordinary kriging. Arguments for krige = krige.control(...) :

[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]

References

Further information about geoR can be found at: http://www.maths.lancs.ac.uk/~ribeiro/geoR.html.

See Also

image.kriging for graphical output of the results, krige.bayes for Bayesian prediction and ksline for a different implementation of kriging allowing for moving neighborhood.

Examples

Run this code
if(is.R()) data(s100) 
loci <- expand.grid(seq(0,1,l=31), seq(0,1,l=31))
kc <- krige.conv(s100, loc=loci,
                 krige=krige.control(cov.pars=c(1, .25)))
par(mfrow=c(1,2))
image.kriging(kc, loc=loci, main="kriging estimates")
image.kriging(kc, loc=loci, val=sqrt(kc$krige.var),
              main="kriging std. errors")

Run the code above in your browser using DataLab