KernelSE {BKTR}R Documentation

R6 class for Square Exponential Kernels

Description

R6 class for Square Exponential Kernels

Super class

BKTR::Kernel -> KernelSE

Public fields

lengthscale

The lengthscale parameter instance of the kernel

has_dist_matrix

Identify if the kernel has a distance matrix or not

name

The kernel's name

Methods

Public methods

Inherited methods

Method new()

Create a new KernelSE object.

Usage
KernelSE$new(
  lengthscale = KernelParameter$new(2),
  kernel_variance = 1,
  jitter_value = NULL
)
Arguments
lengthscale

KernelParameter: The lengthscale parameter instance of the kernel

kernel_variance

Numeric: The variance of the kernel

jitter_value

Numeric: The jitter value to add to the kernel matrix

Returns

A new KernelSE object.


Method core_kernel_fn()

Method to compute the core kernel's covariance matrix

Usage
KernelSE$core_kernel_fn()
Returns

The core kernel's covariance matrix


Method clone()

The objects of this class are cloneable with this method.

Usage
KernelSE$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.

Examples


# Create a new SE kernel
k_se <- KernelSE$new()
# Set the kernel's positions
positions_df <- data.frame(x=c(-4, 0, 3), y=c(-2, 0, 2))
k_se$set_positions(positions_df)
# Generate the kernel's covariance matrix
k_se$kernel_gen()


[Package BKTR version 0.1.1 Index]