a simple histogram that uses an instance of THistogramFeeder as input converter More...
#include <mia/core/histogram.hh>
Public Types | |
typedef std::vector< size_t >::const_iterator | const_iterator |
STL iterator. More... | |
typedef std::pair< typename Feeder::value_type, typename Feeder::value_type > | range_type |
typedef std::pair< typename Feeder::value_type, size_t > | value_type |
A type for the value-index pair. More... | |
Public Member Functions | |
const value_type | at (size_t idx) const |
double | average () const |
const_iterator | begin () const |
double | deviation () const |
const_iterator | end () const |
double | excess_kurtosis () const |
range_type | get_reduced_range (double remove) const |
Feeder::value_type | MAD () const |
Feeder::value_type | median () const |
size_t | operator[] (size_t idx) const |
void | push (typename Feeder::value_type x) |
void | push (typename Feeder::value_type x, size_t count) |
template<typename Iterator > | |
void | push_range (Iterator begin, Iterator end) |
size_t | size () const |
double | skewness () const |
THistogram (const Feeder &f) | |
THistogram (const THistogram< Feeder > &org, double perc) | |
a simple histogram that uses an instance of THistogramFeeder as input converter
This class implements a simple histogram that uses the nearest neighbor approach implemeneted in THistogramFeeder to fill the histogram and provides some funcionallity to work with the histogram.
the | input feeder |
Definition at line 132 of file histogram.hh.
typedef std::vector<size_t>::const_iterator THistogram< Feeder >::const_iterator |
STL iterator.
Definition at line 136 of file histogram.hh.
typedef std::pair<typename Feeder::value_type, typename Feeder::value_type> THistogram< Feeder >::range_type |
Definition at line 141 of file histogram.hh.
typedef std::pair<typename Feeder::value_type, size_t> THistogram< Feeder >::value_type |
A type for the value-index pair.
Definition at line 139 of file histogram.hh.
THistogram< Feeder >::THistogram | ( | const Feeder & | f | ) |
Constructor to create the histogram with the given input feeder.
Definition at line 288 of file histogram.hh.
THistogram< Feeder >::THistogram | ( | const THistogram< Feeder > & | org, |
double | perc | ||
) |
Constructor to create a histogram by copying another histogram and cutting of part ot the upper tail.
org | original histogram to copy from |
perc | percentage of the bins to cut off |
Definition at line 296 of file histogram.hh.
const THistogram< Feeder >::value_type THistogram< Feeder >::at | ( | size_t | idx | ) | const |
Return the count and input range value corresponding to the bin at idx
idx |
Definition at line 391 of file histogram.hh.
Referenced by THistogram< Feeder >::average(), THistogram< Feeder >::deviation(), THistogram< Feeder >::excess_kurtosis(), and THistogram< Feeder >::skewness().
double THistogram< Feeder >::average | ( | ) | const |
Definition at line 400 of file histogram.hh.
References THistogram< Feeder >::at(), and THistogram< Feeder >::size().
Referenced by THistogram< Feeder >::excess_kurtosis(), and THistogram< Feeder >::skewness().
THistogram< Feeder >::const_iterator THistogram< Feeder >::begin | ( | ) | const |
Definition at line 343 of file histogram.hh.
double THistogram< Feeder >::deviation | ( | ) | const |
Definition at line 457 of file histogram.hh.
References THistogram< Feeder >::at(), and THistogram< Feeder >::size().
THistogram< Feeder >::const_iterator THistogram< Feeder >::end | ( | ) | const |
Definition at line 349 of file histogram.hh.
double THistogram< Feeder >::excess_kurtosis | ( | ) | const |
Definition at line 413 of file histogram.hh.
References THistogram< Feeder >::at(), THistogram< Feeder >::average(), and THistogram< Feeder >::size().
THistogram< Feeder >::range_type THistogram< Feeder >::get_reduced_range | ( | double | remove | ) | const |
return the histogram range that cuts off the remove percent of pixels from the lower ane upper end of the histogram
remove | the amout of pixels to remove from the upper and lower end of the historam [0,40] |
Definition at line 473 of file histogram.hh.
References cvdebug(), and NS_MIA_END.
Referenced by CSplineParzenMI::fill().
Feeder::value_type THistogram< Feeder >::MAD | ( | ) | const |
Definition at line 374 of file histogram.hh.
References THistogram< Feeder >::median(), THistogram< Feeder >::push(), and THistogram< Feeder >::size().
Feeder::value_type THistogram< Feeder >::median | ( | ) | const |
Definition at line 362 of file histogram.hh.
Referenced by THistogram< Feeder >::MAD().
size_t THistogram< Feeder >::operator[] | ( | size_t | idx | ) | const |
Definition at line 355 of file histogram.hh.
void THistogram< Feeder >::push | ( | typename Feeder::value_type | x | ) |
Add a value x to the histogram
x |
Definition at line 319 of file histogram.hh.
Referenced by CSplineParzenMI::fill(), THistogram< Feeder >::MAD(), and THistogram< Feeder >::push_range().
void THistogram< Feeder >::push | ( | typename Feeder::value_type | x, |
size_t | count | ||
) |
Add a value x to the histogram count times
x | |
count |
Definition at line 336 of file histogram.hh.
void THistogram< Feeder >::push_range | ( | Iterator | begin, |
Iterator | end | ||
) |
Add a range of data to the histogram
Iterator | forward iterator |
begin | start of input range |
end | end of input range (STL convention) |
Definition at line 327 of file histogram.hh.
References THistogram< Feeder >::push().
Referenced by CSplineParzenMI::fill().
size_t THistogram< Feeder >::size | ( | ) | const |
Definition at line 313 of file histogram.hh.
Referenced by THistogram< Feeder >::average(), THistogram< Feeder >::deviation(), THistogram< Feeder >::excess_kurtosis(), THistogram< Feeder >::MAD(), and THistogram< Feeder >::skewness().
double THistogram< Feeder >::skewness | ( | ) | const |
Definition at line 436 of file histogram.hh.
References THistogram< Feeder >::at(), THistogram< Feeder >::average(), and THistogram< Feeder >::size().