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

Public Types

typedef Numeric point_type
 

Public Member Functions

 LOrPE1D (const LOrPE1DSymbetaKernel &i_kernel, const Numeric *i_coords, const unsigned long i_nCoords)
 
 LOrPE1D (const LOrPE1DSymbetaKernel &i_kernel, const std::vector< Numeric > &i_coords)
 
void setNormFactor (const double d)
 
void setSample (const Numeric *i_coords, const unsigned long i_nCoords)
 
void setSample (const std::vector< Numeric > &i_coords)
 
void setWeights (const double *weights, unsigned long nWeights)
 
bool normalizingLOrPEEstimate () const
 
const LOrPE1DSymbetaKernelkernel () const
 
double normFactor () const
 
const std::vector< Numeric > & coords () const
 
unsigned long nCoords () const
 
Numeric minCoordinate () const
 
Numeric maxCoordinate () const
 
double totalSampleWeight () const
 
double effectiveSampleSize () const
 
double pointCoordinate (const unsigned long i) const
 
double pointWeight (const unsigned long i) const
 
double bandwidthCurve (const double) const
 
double cvLocalizingWeight (const double) const
 
double density (const double x, const double bw) const
 
template<typename Fcn >
LOrPE1DFunctorHelper< Numeric, Fcn > densityFunctor (Fcn bandwidthFunctor) const
 
template<class Fcn >
double densityIntegral (unsigned nIntegIntervals, unsigned nIntegPoints, Fcn bandwidthFunctor) const
 
template<class Fcn >
double integratedSquaredError (const AbsDistribution1D &distro, const unsigned nIntegIntervals, const unsigned nIntegPoints, Fcn bandwidthFunctor) const
 
template<class Fcn >
double normalizeDensityEstimate (unsigned nIntegIntervals, unsigned nIntegPoints, Fcn bandwidthFunctor)
 
bool operator== (const LOrPE1D &r) const
 
bool operator!= (const LOrPE1D &r) const
 

Static Public Member Functions

static bool cvCapable ()
 

Member Function Documentation

◆ bandwidthCurve()

template<class Numeric >
double npstat::LOrPE1D< Numeric >::bandwidthCurve ( const double  ) const
inline

Method included for compatibility with LOrPE1DCV class

◆ cvCapable()

template<class Numeric >
static bool npstat::LOrPE1D< Numeric >::cvCapable ( )
inlinestatic

Is this class capable of cross-validation?

◆ densityFunctor()

template<class Numeric >
template<typename Fcn >
LOrPE1DFunctorHelper<Numeric,Fcn> npstat::LOrPE1D< Numeric >::densityFunctor ( Fcn  bandwidthFunctor) const
inline

The lifetime of the lightweight functor returned by this method must not exceed the lifetime of this object.

Fcn can either be a functor which calculates the bandwidth as a function of x or just a double (for the constant bandwidth).

◆ normalizeDensityEstimate()

template<class Numeric >
template<class Fcn >
double npstat::LOrPE1D< Numeric >::normalizeDensityEstimate ( unsigned  nIntegIntervals,
unsigned  nIntegPoints,
Fcn  bandwidthFunctor 
)

Set the normalization factor so that the density estimate integrates to 1. The function returns the value of the density integral before normalization.

◆ normalizingLOrPEEstimate()

template<class Numeric >
bool npstat::LOrPE1D< Numeric >::normalizingLOrPEEstimate ( ) const
inline

Is the density estimate auto-normalizing?

◆ setWeights()

template<class Numeric >
void npstat::LOrPE1D< Numeric >::setWeights ( const double *  weights,
unsigned long  nWeights 
)
inline

This method with throw std::runtime_error if Numeric is not an std::pair. Note that this method resets the normalization factor.


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