41 #ifndef BPP_NUMERIC_ADAPTIVEKERNELDENSITYESTIMATION_H
42 #define BPP_NUMERIC_ADAPTIVEKERNELDENSITYESTIMATION_H
70 std::vector<double>
c2_;
86 x_(x),
n_(x.getNumberOfColumns()),
r_(x.getNumberOfRows()),
88 c1_(0),
c2_(x.getNumberOfColumns()),
h_(0),
89 lambda_(x.getNumberOfColumns()),
pilot_(x.getNumberOfColumns())
100 double kDensity(
const std::vector<double>& x);
Density estimation using the adaptive kernel method.
RowMatrix< double > invSqrtCovar_
void sampleMean_(const Matrix< double > &x, std::vector< double > &mean)
RowMatrix< double > covar_
AdaptiveKernelDensityEstimation(const Matrix< double > &x, double gamma=0.5)
Build a new AdaptiveKernelDensityEstimation object.
std::vector< double > lambda_
double kernel_(const Matrix< double > &x)
The kernel function.
std::vector< double > pilot_
double kDensity(const std::vector< double > &x)
std::vector< double > xMean_
virtual ~AdaptiveKernelDensityEstimation()
std::vector< double > c2_
The matrix template interface.