kriging {RGeostats}R Documentation

Performs Kriging

Description

Kriging procedure

Usage

kriging(dbin, dbout,
model = model.input(), neigh = neigh.input(),
uc = c("1"), mean = NA, flag.linked = FALSE, calcul = "point",
ndisc = NA, mat.CL = NA, nostat = NA, cov.extract = NA, drift.extract = NA,
flag.est = TRUE, flag.std = TRUE, flag.varz=FALSE,
rank.colcok = NA, flag.grad = FALSE, var.save=NA,
ball.radius = 1,radix = "Kriging",modify.target = db.locmod())

Arguments

dbin

The db-class structure containing the data file

dbout

The db-class structure containing the target file

model

The model-class structure containing the Model information For more information check check.model.

neigh

The neigh-class structure containing the Neighborhood information

uc

The drift description. Use command uc.names for details.

mean

Array containing the mean of each variable, used in the case of Simple (Co-)Kriging

flag.linked

When TRUE, the variables are sharing the same mean (or more generally the same drift). Otherwise, the variables have separate means (drifts).

calcul

Kriging option:

  • "point" : for ponctual estimation

  • "block" : for block average estimation

  • "drift" : for local mean or large scale drift estimation

ndisc

Array giving the number of discretisation points in each direction of the space. If the dimension of the argument 'ndisc' does not match the space dimension, this vector is set to 1 in each direction, leading to a point estimation.

mat.CL

Array giving the expression of the output variables (nvarout) as a function of the input variables (nvarin). The number of input variables must correspond to the number of variables for which the argument 'model' is defined. The dimension of 'mat.CL' is nvarout (nrow) x nvarin (ncol).

nostat

List of non-stationary parameters. For details see model.param.define.

cov.extract

List of the ranks of the basic covariance structures to be extracted. Setting it to 0 filters out all the basic covariance structures.

drift.extract

List of the ranks of the drift basic components to be extracted. Setting if to 0 filters out all the drift basic components.

flag.est

When TRUE, the estimation is required (at each target)

flag.std

When TRUE, the standard deviation of the estimation error is required (at each target)

flag.varz

When TRUE, the variance of the estimator is required (at each target)

rank.colcok

Array of ranks for the colocated variables, in the case of a colocation option. For more information, check check.colcok.

flag.grad

When TRUE and if gradient components are defined in the input db-class, then kriging is performed using the Gradient constraints

var.save

Array of the ranks of the variables for which the results are stored. If left undefined, the results of all variables are stored.

ball.radius

Radius of the ball used for Gradient integration

radix

Radix of the name given to the variables storing the results in the target Db.

modify.target

Decides whether or not the newly created variables will have their locator defined or not. For more information, see db.locmod.

Details

The keypair mechanism may be invoked using the sentence: set.keypair("SaveKrigingWeights",1)

This allows recovering all the Kriging Weights using: get.keypair("KrigingWeights")

The result if a matrix with 5 columns. The columns contain:

All the ranks are expressed starting from 0. Only the relevant weights are saved. The number of rows is variables: it is approximately equal to the number of target samples x the number of samples per neighborhood x the number of variables (squared).

Attention: This keypair stack is managed as a cumulative pile. Therefore it must be freed by the user between two runs.

The samples in 'dbin' may be considered with an attached support (not always ponctual). This is defined using the 'dblk' locator(s). The user may require this support to be taken into account. The number of discretization steps 'disc'(same for all space dimensions) is specified via: set.keypair("Data_Discretization",ndisc) If this parameter is not specified, a message is issued warning the user that the support is disregarded and data samples are considered as points.

Value

The target Db where the following variables have been added:

These variables are multiplied for each one of the data variables.


[Package RGeostats version 14.0.10 Index]