de.lmu.ifi.dbs.elki.math.statistics
Class KernelDensityEstimator

java.lang.Object
  extended by de.lmu.ifi.dbs.elki.math.statistics.KernelDensityEstimator

public class KernelDensityEstimator
extends Object

Estimate density given an array of points. Estimates a density using a kernel density estimator. Multiple common Kernel functions are supported.


Field Summary
private  double[] dens
          Result storage: density
private  double[] var
          Result storage: variance / quality
 
Constructor Summary
KernelDensityEstimator(double[] data, double min, double max, KernelDensityFunction kernel, int windows)
          Initialize and execute kernel density estimation.
KernelDensityEstimator(double[] data, KernelDensityFunction kernel)
          Process an array of data
 
Method Summary
 double[] getDensity()
          Retrieve density array (NO copy)
 double[] getVariance()
          Retrieve variance/quality array (NO copy)
private  void process(double[] data, double min, double max, KernelDensityFunction kernel, int windows)
          Process a new array
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

dens

private double[] dens
Result storage: density


var

private double[] var
Result storage: variance / quality

Constructor Detail

KernelDensityEstimator

public KernelDensityEstimator(double[] data,
                              double min,
                              double max,
                              KernelDensityFunction kernel,
                              int windows)
Initialize and execute kernel density estimation.

Parameters:
data - data to use
min - minimum value
max - maximum value
kernel - Kernel function to use
windows - window size

KernelDensityEstimator

public KernelDensityEstimator(double[] data,
                              KernelDensityFunction kernel)
Process an array of data

Parameters:
data - data to process
kernel - Kernel function to use.
Method Detail

process

private void process(double[] data,
                     double min,
                     double max,
                     KernelDensityFunction kernel,
                     int windows)
Process a new array

Parameters:
data - data to use
min - minimum value
max - maximum value
kernel - Kernel function to use
windows - window size

getDensity

public double[] getDensity()
Retrieve density array (NO copy)

Returns:
density array

getVariance

public double[] getVariance()
Retrieve variance/quality array (NO copy)

Returns:
variance array

Release 0.4.0 (2011-09-20_1324)