MathPHP\Statistics\Regression\Methods\LeastSquares::correlationCoefficient PHP Méthode

correlationCoefficient() public méthode

A measure of the strength and direction of the linear relationship between two variables that is defined as the (sample) covariance of the variables divided by the product of their (sample) standard deviations. n∑⟮xy⟯ − ∑⟮x⟯∑⟮y⟯ -------------------------------- √[(n∑x² − ⟮∑x⟯²)(n∑y² − ⟮∑y⟯²)]
public correlationCoefficient ( ) : number
Résultat number
    public function correlationCoefficient()
    {
        return sqrt($this->coefficientOfDetermination());
    }