model.auto {RGeostats}R Documentation

Automatic Model Fitting

Description

Automatic Model Fitting

Usage

model.auto(vario, struct = melem.name(c(1,4,5,2,3)), constraints=NA,
      auth.aniso = TRUE, auth.rotation = TRUE, 
      auth.locksame = FALSE, auth.lock2d = FALSE, flag.goulard=TRUE,
      flag.noreduce = FALSE, flag.norm.sill=FALSE,flag.keep.intstr=FALSE,
      flag.intrinsic = FALSE,
      param = NA, lower = NA, upper = NA, equal = NA, properties=NA,
      draw = TRUE, wmode=2, maxiter = 1000, verbose=0, tolstop = 1.e-6, 
      epsdelta = 1.e-5, tolsigma = 5, delta=1, ...)

Arguments

vario

The vario-class containing the set of experimental variograms

struct

List of basic structures to be used. It can be given as a vector of character strings or as a vector of indexes. In the latter case, the basic structures will be the result of melem.name(struct).

constraints

Value giving the constraints on the cumulative sills of the model. In the multi-variate case, this value will be applied to all variables. This value must be positive (or undefined). Otherwise, no constraints is applied on the Sill estimation. This is incompatible with the 'flag.norm.sill' flag.

auth.aniso

When TRUE, the anisotropy will be checked

auth.rotation

When TRUE, the fit will look for rotation search in anisotropy. However note that an initial rotation is always defined (based on the calculation directions of the experimental variogram). Therefore when this switch is OFF, the initial rotation is maintained.

auth.locksame

When TRUE and if an anisotropy is allowed (auth.aniso), all the basic structures should share the same rotation.

auth.lock2d

When TRUE, the anisotropy rotation will only consider a rotation around the Z-axis. The Dip and Plunge angles are kept equal to zero.

flag.goulard

When TRUE, the Goulard algorithm is used for the determination of the Sills (quicker). Otherwise Sills are infered using the standard Foxleg algorithm.

flag.noreduce

When TRUE, the useless basic structures must not be discarded.

flag.norm.sill

When TRUE, the automatic fit must fulfill the constraint that the sum of the sills must always be equal to 1. This flag is incompatible with the definition of 'constraints'.

flag.keep.intstr

When TRUE, the fitting procedure must always maintain at least one intrinsic basic structure. If no intrinsic basic structure is provided in the initial template, the automatic fitting procedure fails.

flag.intrinsic

In the case of an Automatic Model Fitting in the multivariate case, when TRUE, the resulting Model is Intrinsic (all simple and croos-variograms are proportional)

param

List of initial values for the parameters to be fitted. For details see model.decode.

lower

List of lower bounds for the parameters to be fitted For details see model.decode.

upper

List of upper bounds for the parameters to be fitted For details see model.decode.

equal

List of constant values assigned to the parameters to be fitted For details see model.decode.

properties

This argument defines the transformation to be applied to the model. For more details, see properties.define.

draw

When TRUE, both the experimental variograms and the Model are represented graphically. Otherwise, no graphic is produced.

wmode

Type of the weighting function used in the fitting procedure. This function is defined in the case of several directional experimental variograms, calculated in a multivariate case:

  • 0: The weight is constant

  • 1: The weight is proportional to the number of pairs

  • 2: The weight is proportional to the number of pairs and inverse proportional to the distance

  • 3: The weight is inverse proportional to the number of lags for each direction

maxiter

Maximum number of iterations

verbose

Verbose option

  • 1 Indications are given regarding the convergence of the algorithm used for automatic model fitting.

  • 0 No message is printed except the warning when convergence is not reached

  • -1 Silent mode

tolstop

Tolerance for the distance between the experiment and the model. This quantity is transformed internally proportionally to the variance of the data.

epsdelta

Tolerance for the direction increment used in the gradient search

tolsigma

Percentage of the variance below which a basic structure will be discarded

delta

Delta value

...

Arguments passed to vario.plot and model.plot.

Value

The model-class with fitted parameters

When needed, you can access to each matrix of sills by using the keypair mechanism using the keyword "Fitted_Sill_'i'" where 'i' stands for the rank of the each basic structure (starting from 1).

You can also access to the eigen decomposition of the matrix of Sills of rank 'i' where 'i' stands for the rank of each basic structure (starting from 1), using:

Note

Function originally funded by Geovariances and ANR CRISCO2.

Author(s)

Nicolas Desassis and Didier Renard (Geosciences/Mines-ParisTech)

References

Desassis, N., and Renard, D. (2013) Automatic Variogram Modeling by Iterative Least Squares: Univariate and Multivariate Cases. Mathematical Geosciences 45 (4) pp 453-470.

Examples

data(Exdemo_autofit3.vario)
plot(Exdemo_autofit3.vario,
	title="Experimental Variogram in 2-D space to be Fitted")
model <- model.auto(Exdemo_autofit3.vario,maxiter=100,
        title="Experimental variogram in 2-D space")
rm(model,pos=1)

[Package RGeostats version 14.0.10 Index]