List of utility methods to do Double Array Average
double sum = 0; for (int i = 0; i < a.length; i++) { sum += a[i]; return sum / a.length;