gk: Two dimensional Gaussian kernel

View source: R/util.R

gkR Documentation

Two dimensional Gaussian kernel

Description

gk calculates the Gaussian similarity as the parallel distances between the elements of two vectors

Usage

gk(x1, x2, sigma = 1)

Arguments

x1

the numbers in x1 that should be compared to those in x2

x2

the numbers in x2 that should be compared to those in x1

sigma

parameter controlling the spread of the gaussian curve. The higher, the more tolerant we are are of differences. Defaults to 1.

Details

The Gaussian similarity is calculated as d(x_1, x_2) = e ^{ - \frac{\sqrt{(x_1 - x_2) ^ 2}}{\sigma^2}}


rijpma/capelinker documentation built on Nov. 7, 2024, 3:06 a.m.