Skip to content

Coregionalization

Linear model of coregionalization: nugget and each structure's sills are symmetric positive semi-definite nvar × nvar matrices, else InvalidInput is raised. rotation and ratios are as in Variogram.

nugget property

nugget

nvar x nvar nugget matrix.

structures property

structures

(model, range, sills) per structure, sills its nvar x nvar matrix.

cross_covariance method descriptor

cross_covariance(i, j, a, b)

Cross-covariance C_ij between paired rows of a and b.

fit staticmethod

fit(
    experimentals,
    model=Ellipsis,
    *,
    weighting="count",
    nugget=True,
    ranges=None,
    directions=None,
    rotation=None,
    ratios=None,
    intrinsic=False,
)

Linear model of coregionalization fitted to the direct and cross experimental variograms of several variables together.

The structures, their shapes and ranges, are shared by all variables; the nugget and each structure's sill matrix are kept positive semi-definite. Each pair's residuals are divided by the square root of the product of the two variables' largest direct γ, so variables in different units count alike. For given ranges the matrices are updated in turn by weighted least squares, negative eigenvalues clipped; the ranges start from Variogram.fit on the pooled scaled direct variograms and are refined, deterministically. With directions, the shared anisotropy is fitted too, starting from Variogram.fit_directional on the scaled direct variograms.

Parameters:

Name Type Description Default
experimentals VariogramSet or sequence of sequence of ExperimentalVariogram or None

A VariogramSet, whose directions are used, or an nvar x nvar matrix: entry [i][j] for i <= j is the direct (i == j, required) or cross variogram of variables i and j; the lower triangle is ignored, and a missing cross pair (None) is left to the positive semi-definite constraint. With directions, each entry is a sequence of one per direction.

required
model

As in Variogram.fit; count/gamma weighs a cross pair by the model's sqrt(γii γjj).

Ellipsis
weighting

As in Variogram.fit; count/gamma weighs a cross pair by the model's sqrt(γii γjj).

Ellipsis
ranges

As in Variogram.fit; count/gamma weighs a cross pair by the model's sqrt(γii γjj).

Ellipsis
nugget bool

False fixes the nugget matrix at zero.

True
directions sequence of (float, float)

Azimuth and dip in degrees of each experimental variogram.

None
rotation sequence of (None, float or (float, float))

Azimuth, dip and rake, and the range ratios, free, fixed or bounded as in Variogram.fit_directional; need directions. Ranges are then major-axis ranges.

None
ratios sequence of (None, float or (float, float))

Azimuth, dip and rake, and the range ratios, free, fixed or bounded as in Variogram.fit_directional; need directions. Ranges are then major-axis ranges.

None
intrinsic bool

Fit an intrinsic model instead (see Coregionalization.intrinsic): one shape, fitted to the direct variograms each divided by its largest γ and pooled, scaled to a unit sill; then each pair's entry of the covariance matrix by weighted least squares on its variograms, the matrix projected on the positive semi-definite cone. A missing cross pair is taken as uncorrelated. With one variable this is Variogram.fit.

False

Returns:

Type Description
Coregionalization

from_json staticmethod

from_json(text)

Reads to_json output; raises InvalidInput on another class's JSON or a newer format.

intrinsic staticmethod

intrinsic(variogram, covariance)

Intrinsic coregionalization: every direct and cross variogram is one shape scaled by an entry of covariance.

γ_ij(h) = covariance[i][j] · γ(h) / sill: all variables share the structures, ranges, nugget proportion and anisotropy of variogram, and the correlation between two variables is the same at every lag. The result is an ordinary Coregionalization for cokriging and cosimulation.

Parameters:

Name Type Description Default
variogram Variogram

The shape; only its proportions matter. Needs a finite positive sill.

required
covariance (array_like, shape(nvar, nvar))

Symmetric positive semi-definite sill matrix, else InvalidInput.

required

Returns:

Type Description
Coregionalization

to_json method descriptor

to_json()

JSON of the parameters and, once fitted, the fitted state.

used in