DGtal 1.3.0
|
#include <iostream>
#include <vector>
#include "DGtal/math/Statistic.h"
#include "DGtal/math/Histogram.h"
Go to the source code of this file.
Functions | |
double | getRandomNumber (double first, double last) |
bool | testHistogramUniform () |
bool | testHistogramGaussian () |
bool | testHistogramGaussian2 () |
int | main (int, char **) |
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Functions for testing class Histogram.
This file is part of the DGtal library.
Definition in file testHistogram.cpp.
double getRandomNumber | ( | double | first, |
double | last | ||
) |
Example of a test. To be completed.
Definition at line 48 of file testHistogram.cpp.
Referenced by testHistogramGaussian(), testHistogramGaussian2(), and testHistogramUniform().
int main | ( | int | , |
char ** | |||
) |
Definition at line 116 of file testHistogram.cpp.
References DGtal::Trace::beginBlock(), DGtal::Trace::emphase(), DGtal::Trace::endBlock(), testHistogramGaussian(), testHistogramGaussian2(), testHistogramUniform(), and DGtal::trace.
bool testHistogramGaussian | ( | ) |
Definition at line 73 of file testHistogram.cpp.
References DGtal::Statistic< TQuantity >::addValue(), DGtal::Histogram< TQuantity, TBinner >::addValues(), DGtal::Statistic< TQuantity >::begin(), DGtal::Histogram< TQuantity, TBinner >::cdf(), DGtal::Statistic< TQuantity >::end(), getRandomNumber(), DGtal::Histogram< TQuantity, TBinner >::init(), DGtal::Histogram< TQuantity, TBinner >::pdf(), DGtal::Histogram< TQuantity, TBinner >::size(), DGtal::Histogram< TQuantity, TBinner >::terminate(), and DGtal::Statistic< TQuantity >::terminate().
Referenced by main().
bool testHistogramGaussian2 | ( | ) |
Definition at line 92 of file testHistogram.cpp.
References DGtal::Statistic< TQuantity >::addValue(), DGtal::Histogram< TQuantity, TBinner >::addValues(), DGtal::Statistic< TQuantity >::begin(), DGtal::Histogram< TQuantity, TBinner >::cdf(), DGtal::Statistic< TQuantity >::end(), getRandomNumber(), DGtal::Histogram< TQuantity, TBinner >::init(), DGtal::Histogram< TQuantity, TBinner >::pdf(), DGtal::Histogram< TQuantity, TBinner >::size(), DGtal::Histogram< TQuantity, TBinner >::terminate(), and DGtal::Statistic< TQuantity >::terminate().
Referenced by main().
bool testHistogramUniform | ( | ) |
Definition at line 54 of file testHistogram.cpp.
References DGtal::Statistic< TQuantity >::addValue(), DGtal::Histogram< TQuantity, TBinner >::addValues(), DGtal::Statistic< TQuantity >::begin(), DGtal::Histogram< TQuantity, TBinner >::cdf(), DGtal::Statistic< TQuantity >::end(), getRandomNumber(), DGtal::Histogram< TQuantity, TBinner >::init(), DGtal::Histogram< TQuantity, TBinner >::pdf(), DGtal::Histogram< TQuantity, TBinner >::size(), DGtal::Histogram< TQuantity, TBinner >::terminate(), and DGtal::Statistic< TQuantity >::terminate().
Referenced by main().