cov.RQ: Rational quadratic covariance function

Description Usage Examples

View source: R/covariance-functions.R

Description

Rational quadratic covariance function

Usage

1
cov.RQ(X, X2, beta, D = NA, ...)

Examples

1
2
3
4
5
6
7
locations = matrix(rnorm(10), ncol=2)
beta      = rnorm(3) # Logarithms of variance, length scale & alpha

K = cov.RQ(locations, beta=beta)
stopifnot(all(Matrix::diag(K)==exp(beta[1]))) # Diagonal is exp(beta[1])
stopifnot(all(svd(K)$d>0)) # K is positive definite
stopifnot(all(K[upper.tri(K)]<K[1,1])) # Largest element is on diagonal

JimSkinner/spca documentation built on Aug. 19, 2018, 7 a.m.