Learn R Programming

hmer (version 1.6.2)

exp_sq: Exponential squared correlation function

Description

For points x, xp and a correlation length theta, gives the exponent of the squared distance between x and xp, weighted by theta squared.

Usage

exp_sq(x, xp, hp)

Value

The exponential-squared correlation between x and xp.

Arguments

x

A data.frame of rows corresponding to position vectors

xp

A data.frame of rows corresponding to position vectors

hp

The hyperparameter theta (correlation length)

References

Rasmussen & Williams (2005) <ISBN: 9780262182539>

Examples

Run this code
exp_sq(data.frame(a=1), data.frame(a=2), list(theta = 0.1))
#> 3.720076e-44
exp_sq(data.frame(a=1,b=2,c=-1),data.frame(a=1.5,b=2.9,c=-0.7), list(theta = 0.2))
#> 3.266131e-13

Run the code above in your browser using DataLab