fitSIRFk: Estimation of covariance parameters

Description Usage Arguments Details Value Author(s) See Also

View source: R/covariance.R

Description

Fit a generalized covariance model to simulation data

Usage

1
2
3
fitSIRFk(qldata, set.var = TRUE, var.type = "wcholMean",
  var.opts = list(var.sim = 1e-06), intrinsic = FALSE, ...,
  controls = list(), cl = NULL, verbose = FALSE)

Arguments

qldata

object of class QLdata, a data frame from setQLdata

set.var

logical vector of length one or equal to the number of covariance models; for values TRUE (default), set simulation variances as local nugget variances for the corresponding covariance model/statistic

var.type

name of variance matrix approximation type (see covarTx)

var.opts

list of arguments passed to setCovModel (only if 'var.type'="kriging" and ignored otherwise)

intrinsic

logical vector, FALSE (default), of length one or equal to the number of Cholesky decompositions of variance matrices; as default use an internal nugget variance estimate (see details) for kriging the variance matrix of the involved statistics

...

arguments passed to setCovModel

controls

list of control parameters passed to nloptr for local minimization

cl

cluster object, NULL (default), of class "MPIcluster", "SOCKcluster", "cluster"

verbose

if TRUE, print intermediate results

Details

The function estimates the parameters of a covariance model using the REML method for kriging the sample means of the statistics and kriging the variance matrix of statistics unless 'var.type' equals "const". By default it uses the covariance model derived from a (self-similar) intrinsic random function, that is, the 'sirfk' function of order k (see, e.g. [1]) with k=1,2, for all statistics (including a default quadratic drift term k=2). The user can also define different covariance models for each statistic separately (see below). Other covariance models can be used by their name 'model' which is passed to the function setCovModel. Kriging the variance matrix always uses the 'sirfk' covariance model.

Argument 'var.opts' only sets the options for the covariance models for kriging the variance matrix if this is the users prefered type of approximation. Other optional arguments, e.g., 'var.sim' for the statistics, 'var.opts$var.sim' for kriging the variance matrix, specify the local or global nugget values for each sample point depending on whether or not 'set.var' (used for kriging the statistics) equals TRUE. Both are passed to setCovModel and must be data frames of lengths (number of columns) corresponding to the number of covariance models of statistics and, respectively, to the number of Cholesky decomposed terms in case of kriging the variance matrix. If 'set.var' equals TRUE (default), then local nugget variances are estimated by the variance of the sample average of the statistics. Otherwise the values given in 'var.sim' are used as fixed 'nugget' variances and replicated to match the number of sample points if required.

The same principle applies in case of kriging the variance matrix. If 'intrinsic' equals TRUE, then local nugget variances for each of the variance-covariances of the of the statistics are estimated by a bootstrapping procedure. Otherwise the values given by 'var.opts$var.sim' (of length one or equal to the number of corresponding sample points) are used directly as local estimates (which then must correspond to the other Cholesky decomposed terms). A global nugget value can be also estimated during the REML estimation which is the default option for both cases unless this parameter is excluded from the covariance parameter estimation (see setCovModel). The default optimization algorithm for estimating the covariance parameters is the random starting point method mlsl followed by a final local search by the same local algorithm. Note that in this case the estimated parameters may vary when starting the REML procedure several times since starting points are chosen as random. All options for the optimization can be modified by the argument 'controls'.

Note that the returned object can also be constructed manually and passed as an input argument to QLmodel in case the user prefers to set up each covariance model separately. In this case, first use setCovModel to construct the covariance model, then estimate the parameters by fitCov and pass a list of fitted covariance models to function QLmodel.

Please see function QLmodel for an example.

Value

A list of fitted covariance models for kriging the sample means of statistics named 'covT' and optionally the variance matrix of statistics, 'covL'. The object also stores the reml optimization parameters 'controls'.

Author(s)

M. Baaske

See Also

setCovModel, fitCov, QLmodel


mbaaske/qle documentation built on May 27, 2019, midnight