function __construct($yValues, $xValues = array(), $const = True)
 {
     if (parent::__construct($yValues, $xValues) !== False) {
         $this->_linear_regression($yValues, $xValues, $const);
     }
 }
 function __construct($order, $yValues, $xValues = array(), $const = True)
 {
     if (parent::__construct($yValues, $xValues) !== False) {
         if ($order < $this->_valueCount) {
             $this->_bestFitType .= '_' . $order;
             $this->_order = $order;
             $this->_polynomial_regression($order, $yValues, $xValues, $const);
             if ($this->getGoodnessOfFit() < 0.0 || $this->getGoodnessOfFit() > 1.0) {
                 $this->_error = True;
             }
         } else {
             $this->_error = True;
         }
     }
 }