Histogram computation class. More...
#include <itpp/stat/histogram.h>
Public Member Functions | |
Histogram (Num_T from=Num_T(0), Num_T to=Num_T(99), int n_bins=100) | |
~Histogram () | |
Default destructor. | |
void | setup (Num_T from, Num_T to, int n_bins) |
Histogram setup. | |
void | update (Num_T value) |
Histogram update. | |
void | update (Vec< Num_T > values) |
Histogram update. | |
void | update (Mat< Num_T > values) |
Histogram update. | |
void | reset () |
Bins reset, so accumulation can be restarted. | |
int | get_bin (int ix) const |
Access to single bin counter. | |
ivec | get_bins () const |
Access to histogram as a vector. | |
Vec< Num_T > | get_bin_centers () const |
Access to bin center values (all bins) | |
Num_T | get_bin_center (int ix) const |
Access to bin center (single bin) | |
Vec< Num_T > | get_bin_lefts () const |
Access to left boundary of bin intervals (all bins) | |
Num_T | get_bin_left (int ix) const |
Access to left boundary of single bin. | |
Vec< Num_T > | get_bin_rights () const |
Access to right boundary of bin intervals (all bins) | |
Num_T | get_bin_right (int ix) const |
Access to right boundary of single bin. | |
vec | get_pdf () const |
Experimental Probability Density Function (PDF) computation. | |
vec | get_cdf () const |
Experimental Cumulative Density Function (CDF) computation. | |
int | bins_num () const |
Current number of bins. | |
int | trials_num () const |
Current trials counter. | |
Histogram computation class.
The Histogram class counts the number of observations of arbitrary numerical types that fall into specified bins. Centers of the leftmost and rightmost bin along with a total number of bins are passed to a histogram object as constructor parameters. Histogram counters are updated when calling update() method. It is possible to access bin counters and bin interval parameters for all bins at once or separately for each bin.
Example:
Definition at line 75 of file histogram.h.
Generated on Sat May 25 2013 16:32:34 for IT++ by Doxygen 1.8.2