result.append("& " + getColName(j) + " & ");
result.append("& " + cells[0][j] + " & ");
  public String toStringMatrix() {    StringBuffer    result;    String[][]      cells;    int             i;    int             j;    int             n;    int             size;    result  = new StringBuffer();    cells   = toArray();    result.append(  "\\begin{table}[thb]\n\\caption{\\label{labelname}"                  + "Table Caption}\n");    if (!getShowStdDev())      result.append("\\footnotesize\n");    else      result.append("\\scriptsize\n");    // output the column alignment characters    // one for the dataset name and one for the comparison column    if (!getShowStdDev()) {      result.append(  "{\\centering \\begin{tabular}{"                    + "l"                     // dataset                    + ""                      // separator                    + "r"                     // mean                    );    } else {      // dataset, mean, std dev      result.append(  "{\\centering \\begin{tabular}{"                     + "l"                     // dataset                    + ""                      // separator                    + "r"                     // mean                    + "@{\\hspace{0cm}}"      // separator                    + "c"                     // +/-                    + "@{\\hspace{0cm}}"      // separator                    + "r"                     // stddev                    );    }    for (j = 1; j < getColCount(); j++) {      if (getColHidden(j))        continue;      if (!getShowStdDev())        result.append(  "r"                   // mean                      + "@{\\hspace{0.1cm}}"  // separator                      + "c"                   // significance                      );      else         result.append(  "r"                   // mean                      + "@{\\hspace{0cm}}"    // separator                      + "c"                   // +/-                      + "@{\\hspace{0cm}}"    // separator                      + "r"                   // stddev                      + "@{\\hspace{0.1cm}}"  // separator                      + "c"                   // significance                      );    }    result.append("}\n\\\\\n\\hline\n");    if (!getShowStdDev())      result.append("Dataset & " + getColName(0));    else      result.append("Dataset & \\multicolumn{3}{c}{" + getColName(0) + "}");    // now do the column names (numbers)    for (j = 1; j < getColCount(); j++) {      if (getColHidden(j))        continue;      if (!getShowStdDev())        result.append("& " + getColName(j) + " & ");      else        result.append("& \\multicolumn{4}{c}{" + getColName(j) + "} ");    }    result.append("\\\\\n\\hline\n");    // change "_" to "-" in names    for (i = 1; i < cells.length; i++)      cells[i][0] = cells[i][0].replace('_', '-');    // pad numbers    for (n = 1; n < cells[0].length; n++) {      size = getColSize(cells, n);      for (i = 1; i < cells.length; i++)        cells[i][n] = padString(cells[i][n], size, true);    }    // output data (w/o wins/ties/losses)    for (i = 1; i < cells.length - 1; i++) {      for (n = 0; n < cells[0].length; n++) {        if (n == 0) {          result.append(padString(cells[i][n], getRowNameWidth()));        }        else {          if (getShowStdDev()) {            if (isMean(n - 1)) {              if (!cells[i][n].trim().equals(""))                result.append(" & $\\pm$ & ");              else                result.append(" &       & ");            }            else              result.append(" & ");          }          else {            result.append(" & ");          }          result.append(cells[i][n]);        }      }            result.append("\\\\\n");    }    result.append("\\hline\n\\multicolumn{" + cells[0].length + "}{c}{$\\circ$, $\\bullet$"		  +" statistically significant improvement or degradation}"		  +"\\\\\n\\end{tabular} ");    if (!getShowStdDev())           result.append("\\footnotesize ");    else      result.append("\\scriptsize ");        result.append("\\par}\n\\end{table}"		  +"\n");         return result.toString();  }