krige.conv
should be preferred, unless
moving neighborhood is to be used.ksline(geodata, coords = geodata$coords, data = geodata$data,
locations, borders = NULL,
cov.model = "matern",
cov.pars=stop("cov. parameters (sigmasq and phi) needed"),
kappa = 0.5, nugget = 0, micro.scale = 0,
lambda = 1, m0 = "ok", nwin = "full",
n.samples.backtransform = 500, trend = 1, d = 2,
ktedata = NULL, ktelocations = NULL, aniso.pars = NULL,
signal = FALSE, dist.epsilon = 1e-10,
messages.screen = TRUE)
coords
and
data
as described next. Typically an object of the class
"geodata"
- a geoR data-set. If not provided the arguments
coords
of the argument geodata
, if
provided.data
of the argument geodata
, if provided.cov.spatial
.
Defaults are equivalent to the exponential model."matern"
,
"powered.exponential"
,
"cauchy"
and
"gneiting.matern"
."ok"
indicates that ordinary
kriging will be performed. Other options are "kt"
for kriging
with a trend model (universal kriging) and "kte"
for kriging
with external trend (covariates). "full"
global neighborhood is used
i.e., all data values are used in the
prediction of every prediction location.
An integer number defines the moving neighborhood algorithm.
The number provided is used aslambda
), back-transformations
are usually performed by sampling from the predictive distribution and
then back-transform0 = "kt"
(universal kriging).
Possible values are $1$ or $2$, corresponding to a first or second degree
polynomial trend on the coordinates, respectively.m0 = "kte"
. A vector or matrix
with the values of the
external trend (covariates) at the data locations.m0 = "kte"
. A vector or
matrix with the values of the
external trend (covariates) at the prediction locations.aniso.pars = FALSE
no correction is made, otherwise
a two elements vector with values for the anisotropy parameters
must be provided. Anisotropy correction consists of a
transTRUE
the signal is predicted, otherwise the
variable is predicted. If no transformation is performed the
expectations are the same in both cases and the difference is only for
values of the kriging variance, if the valclass
kriging
which is a list
with the following components:m0 = "kt"
(universal kriging).m0 = "kte"
(external trend kriging).m0 = "ok", "kte"
or "kt"
.krige.conv
for a more efficient implementation of
conventional kriging methods,
krige.bayes
for Bayesian prediction.if(is.R()) data(s100)
loci <- expand.grid(seq(0,1,l=31), seq(0,1,l=31))
kc <- ksline(s100, loc=loci, 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