public static double calculateRowTotal(Values2D data,int row){
  ParamChecks.nullNotPermitted(data,"data");
  double total=0.0;
  int columnCount=data.getColumnCount();
  for (int c=0; c < columnCount; c++) {
    Number n=data.getValue(row,c);
    if (n != null) {
      total+=n.doubleValue();
    }
  }
  return total;
}

public static double calculateRowTotal ( Values2D data , int row ) { ParamChecks . nullNotPermitted ( data , "data" ) ; double total = 0.0 ; int columnCount = data . getColumnCount ( ) ; for ( int c = 0 ; c < columnCount ; c ++ ) { Number n = data . getValue ( row , c ) ; if ( n != null ) { total += n . doubleValue ( ) ; } } return total ; }
returns the total of the values in one row of the supplied data table .
