FourierKernel {USP}R Documentation

Kernel matrix for Fourier basis

Description

Calculates the kernel matrix, described in (Berrett et al. 2021) for univariate continuous data when using the Fourier basis. This function is used in USPFourier.

Usage

FourierKernel(x, M)

Arguments

x

A vector in [0,1]^n for some n, containing the observations.

M

The maximum frequency of Fourier basis functions to compute.

Value

The kernel matrix K, to be used in independence testing.

References

Berrett TB, Kontoyiannis I, Samworth RJ (2021). “Optimal rates for independence testing via U-statistic permutation tests.” Annals of Statistics, to appear.

Examples

n=10; x=runif(n)
FourierKernel(x,5)

[Package USP version 0.1.2 Index]