npstat is hosted by Hepforge, IPPP Durham
NPStat  5.10.0
npstat::BandwidthGCVPseudoLogli1D< Numeric, Num2 > Class Template Reference

#include <BandwidthGCVPseudoLogli1D.hh>

Inheritance diagram for npstat::BandwidthGCVPseudoLogli1D< Numeric, Num2 >:
npstat::AbsBandwidthGCV1D< Numeric, Num2 >

Public Member Functions

 BandwidthGCVPseudoLogli1D (double regularizationPower=0.5)
 
unsigned long getNonZeroCount () const
 
unsigned long getRenormCount () const
 
virtual double operator() (const HistoND< Numeric > &histo, const Num2 *densityEstimate, const Num2 *leaveOneOutEstimate, unsigned lenEstimate, const AbsPolyFilter1D &filterUsed) const
 
virtual double operator() (const HistoND< Numeric > &histo, double effectiveSampleSize, const Num2 *densityEstimate, const Num2 *leaveOneOutEstimate, unsigned lenEstimate, const AbsPolyFilter1D &filterUsed) const
 

Additional Inherited Members

- Public Types inherited from npstat::AbsBandwidthGCV1D< Numeric, Num2 >
typedef Numeric bin_type
 
typedef Num2 density_type
 

Detailed Description

template<typename Numeric, typename Num2>
class npstat::BandwidthGCVPseudoLogli1D< Numeric, Num2 >

Class for calculating KDE or LOrPE cross-validation pseudo log-likelihood, for 1-dimensional density estimates. This class is intended for use inside degree and/or bandwidth scans.

Constructor & Destructor Documentation

◆ BandwidthGCVPseudoLogli1D()

template<typename Numeric , typename Num2 >
npstat::BandwidthGCVPseudoLogli1D< Numeric, Num2 >::BandwidthGCVPseudoLogli1D ( double  regularizationPower = 0.5)
inlineexplicit

Parameter "regularizationPower" is used to limit the contributions into the overall pseudo log likelihood from points for which the "leaving one out" density is very low. For those points, instead of "leaving one out" density, we will use the density generated by that point itself divided by pow(N, regularizationPower). This method limits the effect of tails on bandwidth determination.

Member Function Documentation

◆ operator()() [1/2]

template<typename Numeric , typename Num2 >
virtual double npstat::BandwidthGCVPseudoLogli1D< Numeric, Num2 >::operator() ( const HistoND< Numeric > &  histo,
const Num2 *  densityEstimate,
const Num2 *  leaveOneOutEstimate,
unsigned  lenEstimate,
const AbsPolyFilter1D filterUsed 
) const
virtual

It should be assumed that the "nFillsInRange" method of the argument histogram returns the actual number of fills (that is, the histogram represents an actual collection of points, has possible bin values of 0, 1, 2, ..., and it is not scaled).

Implements npstat::AbsBandwidthGCV1D< Numeric, Num2 >.

◆ operator()() [2/2]

template<typename Numeric , typename Num2 >
virtual double npstat::BandwidthGCVPseudoLogli1D< Numeric, Num2 >::operator() ( const HistoND< Numeric > &  histo,
double  effectiveSampleSize,
const Num2 *  densityEstimate,
const Num2 *  leaveOneOutEstimate,
unsigned  lenEstimate,
const AbsPolyFilter1D filterUsed 
) const
virtual

Cross-validation for samples of univariate weighted points

Implements npstat::AbsBandwidthGCV1D< Numeric, Num2 >.


The documentation for this class was generated from the following file: