Various statistical functions. More...
Functions | |
| template<typename IteratorType > | |
| static DoubleReal | sum (IteratorType begin, IteratorType end) |
| Calculates the sum of a range of values. | |
| template<typename IteratorType > | |
| static DoubleReal | mean (IteratorType begin, IteratorType end) |
| Calculates the mean of a range of values. | |
| template<typename IteratorType > | |
| static DoubleReal | median (IteratorType begin, IteratorType end, bool sorted=FALSE) |
| Calculates the median of a range of values. | |
| template<typename IteratorType > | |
| static DoubleReal | quantile (IteratorType begin, IteratorType end, UInt quantile, bool sorted=FALSE) |
| Calculates the quantile of a range of values. | |
| template<typename IteratorType1 , typename IteratorType2 > | |
| static DoubleReal | meanSquareError (IteratorType1 begin_a, IteratorType1 end_a, IteratorType2 begin_b, IteratorType2 end_b) |
| Calculates the mean square error for the values in [begin_a, end_a) and [begin_b, end_b). | |
| template<typename IteratorType1 , typename IteratorType2 > | |
| static DoubleReal | classificationRate (IteratorType1 begin_a, IteratorType1 end_a, IteratorType2 begin_b, IteratorType2 end_b) |
| Calculates the classification rate for the values in [begin_a, end_a) and [begin_b, end_b). | |
| template<typename IteratorType1 , typename IteratorType2 > | |
| static DoubleReal | matthewsCorrelationCoefficient (IteratorType1 begin_a, IteratorType1 end_a, IteratorType2 begin_b, IteratorType2 end_b) |
| Calculates the Matthews correlation coefficient for the values in [begin_a, end_a) and [begin_b, end_b). | |
| template<typename IteratorType1 , typename IteratorType2 > | |
| static DoubleReal | pearsonCorrelationCoefficient (IteratorType1 begin_a, IteratorType1 end_a, IteratorType2 begin_b, IteratorType2 end_b) |
| Calculates the Pearson correlation coefficient for the values in [begin_a, end_a) and [begin_b, end_b). | |
| template<typename IteratorType1 , typename IteratorType2 > | |
| static DoubleReal | rankCorrelationCoefficient (IteratorType1 begin_a, IteratorType1 end_a, IteratorType2 begin_b, IteratorType2 end_b) |
| calculates the rank correlation coefficient for the values in [begin_a, end_a) and [begin_b, end_b) | |
Various statistical functions.
These functions are defined in OpenMS/MATH/STATISTICS/StatisticFunctions.h .
| static DoubleReal OpenMS::Math::classificationRate | ( | IteratorType1 | begin_a, | |
| IteratorType1 | end_a, | |||
| IteratorType2 | begin_b, | |||
| IteratorType2 | end_b | |||
| ) | [static] |
Calculates the classification rate for the values in [begin_a, end_a) and [begin_b, end_b).
Calculates the classification rate for the data given by the two iterator ranges.
| Exception::InvalidRange | is thrown if the iterator ranges are not of the same length or empty. |
| static DoubleReal OpenMS::Math::matthewsCorrelationCoefficient | ( | IteratorType1 | begin_a, | |
| IteratorType1 | end_a, | |||
| IteratorType2 | begin_b, | |||
| IteratorType2 | end_b | |||
| ) | [static] |
Calculates the Matthews correlation coefficient for the values in [begin_a, end_a) and [begin_b, end_b).
Calculates the Matthews correlation coefficient for the data given by the two iterator ranges. The values in [begin_a, end_a) have to be the predicted labels and the values in [begin_b, end_b) have to be the real labels.
| Exception::InvalidRange | is thrown if the iterator ranges are not of the same length or empty. |
| static DoubleReal OpenMS::Math::mean | ( | IteratorType | begin, | |
| IteratorType | end | |||
| ) | [static] |
Calculates the mean of a range of values.
| Exception::InvalidRange | is thrown if the range is empty |
References OpenMS::Math::sum().
Referenced by PeakTypeEstimator::estimateType(), and BasicStatistics< Real >::normalDensity_sqrt2pi().
| static DoubleReal OpenMS::Math::meanSquareError | ( | IteratorType1 | begin_a, | |
| IteratorType1 | end_a, | |||
| IteratorType2 | begin_b, | |||
| IteratorType2 | end_b | |||
| ) | [static] |
Calculates the mean square error for the values in [begin_a, end_a) and [begin_b, end_b).
Calculates the mean square error for the data given by the two iterator ranges.
| Exception::InvalidRange | is thrown if the iterator ranges are not of the same length or empty. |
| static DoubleReal OpenMS::Math::median | ( | IteratorType | begin, | |
| IteratorType | end, | |||
| bool | sorted = FALSE | |||
| ) | [static] |
Calculates the median of a range of values.
| begin | Start of range | |
| end | End of range (past-the-end iterator) | |
| sorted | Is the range already sorted? If not, it will be sorted. |
| Exception::InvalidRange | is thrown if the range is empty |
| static DoubleReal OpenMS::Math::pearsonCorrelationCoefficient | ( | IteratorType1 | begin_a, | |
| IteratorType1 | end_a, | |||
| IteratorType2 | begin_b, | |||
| IteratorType2 | end_b | |||
| ) | [static] |
Calculates the Pearson correlation coefficient for the values in [begin_a, end_a) and [begin_b, end_b).
Calculates the linear correlation coefficient for the data given by the two iterator ranges.
If one of the ranges contains only the same values 'nan' is returned.
| Exception::InvalidRange | is thrown if the iterator ranges are not of the same length or empty. |
Referenced by FeatureFinderAlgorithmPicked< PeakType, FeatureType >::checkFeatureQuality_(), FeatureFinderAlgorithmPicked< PeakType, FeatureType >::cropFeature_(), ModelFitter< PeakType, FeatureType >::evaluate_(), MaxLikeliFitter1D::fitOffset_(), and FeatureFinderAlgorithmPicked< PeakType, FeatureType >::isotopeScore_().
| static DoubleReal OpenMS::Math::quantile | ( | IteratorType | begin, | |
| IteratorType | end, | |||
| UInt | quantile, | |||
| bool | sorted = FALSE | |||
| ) | [static] |
Calculates the quantile of a range of values.
| begin | Start of range | |
| end | End of range (past-the-end iterator) | |
| sorted | Is the range already sorted? If not, it will be sorted. |
| Exception::InvalidRange | is thrown if the range is empty or a quantile over 100 is given |
| static DoubleReal OpenMS::Math::rankCorrelationCoefficient | ( | IteratorType1 | begin_a, | |
| IteratorType1 | end_a, | |||
| IteratorType2 | begin_b, | |||
| IteratorType2 | end_b | |||
| ) | [static] |
calculates the rank correlation coefficient for the values in [begin_a, end_a) and [begin_b, end_b)
Calculates the rank correlation coefficient for the data given by the two iterator ranges.
If one of the ranges contains only the same values 'nan' is returned.
| Exception::InvalidRange | is thrown if the iterator ranges are not of the same length or empty. |
References OpenMS::Math::computeRank().
Referenced by ModelFitter< PeakType, FeatureType >::evaluate_().
| static DoubleReal OpenMS::Math::sum | ( | IteratorType | begin, | |
| IteratorType | end | |||
| ) | [static] |
Calculates the sum of a range of values.
Referenced by ComplementFilter::apply(), OpenSwath::dotProd(), Normalizer::filterSpectrum(), FeatureFinderAlgorithmPickedHelperStructs::MassTrace< PeakType >::getAvgMZ(), FeatureFinderAlgorithmPickedHelperStructs::MassTraces< PeakType >::getPeakCount(), OpenSwath::manhattanDist(), OpenMS::Math::mean(), and BasicStatistics< Real >::normalApproximationHelper_().
| OpenMS / TOPP release 1.10.0 | Documentation generated on Thu Mar 7 2013 09:42:48 using doxygen 1.7.1 |