yat
0.14.5pre
|
Class for calculating Pearson correlation. More...
#include <yat/statistics/PearsonCorrelation.h>
Public Member Functions | |
PearsonCorrelation (void) | |
The default constructor. | |
virtual | ~PearsonCorrelation (void) |
The destructor. | |
void | add (double value, bool target, double weight=1.0) |
double | score (void) const |
correlation More... | |
double | p_value_one_sided (void) const |
double | p_left (void) const |
double | p_right (void) const |
double | p_value (void) const |
Class for calculating Pearson correlation.
void theplu::yat::statistics::PearsonCorrelation::add | ( | double | value, |
bool | target, | ||
double | weight = 1.0 |
||
) |
Adding a data value to PearsonCorrelation.
double theplu::yat::statistics::PearsonCorrelation::p_left | ( | void | ) | const |
Similar to p_right, but returns probability to get observed correlation or less.
double theplu::yat::statistics::PearsonCorrelation::p_right | ( | void | ) | const |
The p-value is the probability of getting a correlation as large (or larger) as the observed value by random chance, when the true correlation is zero (and the data is Gaussian).
P-value is calculated using function pearson_p_value(double, unsigned int) where degrees of freedom is calculated using n(void) in AveragerPairWeighted.
double theplu::yat::statistics::PearsonCorrelation::p_value | ( | void | ) | const |
Claculates the probability to get correlation greater than |r| or less than -|r|.
double theplu::yat::statistics::PearsonCorrelation::p_value_one_sided | ( | void | ) | const |
double theplu::yat::statistics::PearsonCorrelation::score | ( | void | ) | const |
correlation
Correlation is calculated as implemented in AveragerPairWeighted