filter_gaussian computes the Gaussian density filter.

filter_gaussian(dist, sigma = 1, ...)

Arguments

dist

The distance matrix.

sigma

A scalar controling the sensitivity of the gaussian kernel.

...

Further arguments.

Value

A matrix object of filter values.

Details

The Gaussian density filter is defined as \(f(x_i;\sigma) = C\sum_{j=1}^n exp(-\frac{\|x_i-x_j\|^2}{2\sigma^2})\), where \(C\) is the normalizing constant and \(\sigma\) is the scalar controling the sensitivity of the gaussian kernel.

Examples

tp_data = chicken_generator(1)
tp_dist = dist(tp_data[,-1])
filter_gaussian(dist=tp_dist, sigma=1)