sphkde.pg {pgKDEsphere}R Documentation

sphkde.pg

Description

Function sphkde.pg computes the kernel density estimator for (hyper)spherical data with a parametric guide, which corresponds to the von Mises-Fisher model.

Usage

sphkde.pg(datax, kappa = NULL, eval.points = NULL, guide = TRUE)

Arguments

datax

Matrix containing the data in cartesian coordinates, where the number of rows is the number of observations and the number of columns is the dimension of the Euclidean space where the sphere is embebed.

kappa

Smoothing parameter. It refers to the concentration when employing a von Mises-Fisher kernel.

eval.points

Matrix containing the evaluation points for the estimation of the density.

guide

Logical; if TRUE, the estimator with a von Mises-Fisher as guide is computed. If FALSE, the classical kernel density estimator without guide is computed (equivalent to uniform guide).

Details

See Alonso-Pena et al. (2023) for details.

Value

An object with class "sphkde" whose underlying structure is a list containing the following components:

estim

The estimated values of the density.

kappa

The smoothing parameter used.

data

The n coordinates of the points where the regression is estimated.

eval.points

The points where the estimated density was evaluated.

data

Original dataset.

References

Alonso-Pena, M., Claeskens, G. and Gijbels, I. (2023) Nonparametric estimation of densities on the hypersphere using a parametric guide. Under review.

Examples

library(movMF)
n<-200
mu<-matrix(c(0,0,1,0,0,-1),ncol=3,byrow=TRUE)
k<-c(7,2)
probs<-c(0.85,0.15)
datax<-rmovMF(n,k*mu,alpha=probs)
est<-sphkde.pg(datax,guide=TRUE)
sphkde.plot(est,type="sph")

[Package pgKDEsphere version 1.0.1 Index]