public static double ssError(double[] predictedValues,double[] targetAttribute){
  double ret=0;
  for (int i=0; i < predictedValues.length; i++) {
    ret+=Math.pow(targetAttribute[i] - predictedValues[i],2);
  }
  return ret;
}

public static double ssError ( double [ ] predictedValues , double [ ] targetAttribute ) { double ret = 0 ; for ( int i = 0 ; i < predictedValues . length ; i ++ ) { ret += Math . pow ( targetAttribute [ i ] - predictedValues [ i ] , 2 ) ; } return ret ; }
how much of the variance is not explained by the regression
