matern_nonstat_var: Isotropic Matern covariance function, nonstationary variances

Description Usage Arguments Value Functions Parameterization

View source: R/RcppExports.R

Description

From a matrix of locations and covariance parameters of the form (variance, range, smoothness, nugget, <nonstat variance parameters>), return the square matrix of all pairwise covariances.

Usage

1
2
3
matern_nonstat_var(covparms, Z)

d_matern_nonstat_var(covparms, Z)

Arguments

covparms

A vector with covariance parameters in the form (variance, range, smoothness, nugget, <nonstat variance parameters>). The number of nonstationary variance parameters should equal p.

Z

A matrix with n rows and 2 columns for spatial locations + p columns describing spatial basis functions. Each row of locs gives a point in R^2 (two dimensions only!) + the value of p spatial basis functions.

Value

A matrix with n rows and n columns, with the i,j entry containing the covariance between observations at locs[i,] and locs[j,].

Functions

Parameterization

This covariance function multiplies the isotropic Matern covariance by a nonstationary variance function. The form of the covariance is

C(x,y) = exp( φ(x) + φ(y) ) M(x,y)

where M(x,y) is the isotropic Matern covariance, and

φ(x) = c_1 φ_1(x) + ... + c_p φ_p(x)

where φ_1,...,φ_p are the spatial basis functions contained in the last p columns of Z, and c_1,...,c_p are the nonstationary variance parameters.


GpGp documentation built on June 10, 2021, 1:07 a.m.