Program: 39233
Project: 39233
Buggy source:
/** 
 * @param panel
 * @param gen
 * @param objective
 * @param scores
 * @param focus
 */
public static void plotBestsWorsts(DrawingPanel panel,int gen,int objective,ArrayList<ArrayList<Double>> scores,int focus){
  int offset=Plot.OFFSET;
  int browseDim=Plot.BROWSE_DIM;
  int ovalDim=Plot.OVAL_DIM;
  Graphics g=panel.getGraphics();
  g.setColor(Color.black);
  g.drawLine(offset,offset,offset,browseDim - offset);
  g.drawLine(offset,browseDim - offset,browseDim - offset,browseDim - offset);
  double max=maxes.get(objective);
  double min=mins.get(objective);
  double maxRange=Math.max(max,max - min);
  double lowerMin=Math.min(0,min);
  for (int i=0; i < bestScores[objective].length; i++) {
    g.setColor(Color.blue);
    g.fillRect(offset + Plot.scale(i,bestScores[objective].length * 1.0,0),offset + Plot.invert(bestScores[objective][i],maxRange,lowerMin),1,1);
    g.setColor(Color.magenta);
    g.fillRect(offset + Plot.scale(i,worstScores[objective].length * 1.0,0),offset + Plot.invert(worstScores[objective][i],maxRange,lowerMin),1,1);
  }
  g.setColor(Color.black);
  g.drawString("String_Node_Str" + max,offset / 2,offset / 2);
  g.drawString("String_Node_Str" + lowerMin,offset / 2,browseDim - (offset / 2));
  g.setColor(Color.green);
  g.fillRect(offset + Plot.scale(gen,bestScores[objective].length * 1.0,0),offset + Plot.invert(scores.get(focus).get(objective),maxRange,lowerMin),ovalDim,ovalDim);
  g.setColor(Color.cyan);
  for (int i=0; i < scores.size(); i++) {
    if (i != focus) {
      g.drawOval(offset + Plot.scale(gen,bestScores[objective].length * 1.0,0),offset + Plot.invert(scores.get(i).get(objective),maxRange,lowerMin),ovalDim,ovalDim);
    }
  }
  if (tugGoals != null) {
    for (int i=0; i < tugGoals[objective].length; i++) {
      g.setColor(Color.green);
      g.fillRect(offset + Plot.scale(i,bestScores[objective].length * 1.0,0),offset + Plot.invert(tugGoals[objective][i],maxRange,lowerMin),1,1);
    }
  }
}

Fixed version (ground truth):
/** 
 * @param panel
 * @param gen
 * @param objective
 * @param scores
 * @param focus
 */
public static void plotBestsWorsts(DrawingPanel panel,int gen,int objective,ArrayList<ArrayList<Double>> scores,int focus){
  int offset=Plot.OFFSET;
  int browseDim=Plot.BROWSE_DIM;
  int ovalDim=Plot.OVAL_DIM;
  Graphics g=panel.getGraphics();
  g.setColor(Color.black);
  g.drawLine(offset,offset,offset,browseDim - offset);
  g.drawLine(offset,browseDim - offset,browseDim - offset,browseDim - offset);
  double max=maxes.get(objective);
  double min=mins.get(objective);
  double maxRange=Math.max(max,max - min);
  double lowerMin=Math.min(0,min);
  for (int i=0; i < bestScores[objective].length; i++) {
    g.setColor(Color.blue);
    g.fillRect(offset + GraphicsUtil.scale(i,bestScores[objective].length * 1.0,0),offset + GraphicsUtil.invert(bestScores[objective][i],maxRange,lowerMin),1,1);
    g.setColor(Color.magenta);
    g.fillRect(offset + GraphicsUtil.scale(i,worstScores[objective].length * 1.0,0),offset + GraphicsUtil.invert(worstScores[objective][i],maxRange,lowerMin),1,1);
  }
  g.setColor(Color.black);
  g.drawString("String_Node_Str" + max,offset / 2,offset / 2);
  g.drawString("String_Node_Str" + lowerMin,offset / 2,browseDim - (offset / 2));
  g.setColor(Color.green);
  g.fillRect(offset + GraphicsUtil.scale(gen,bestScores[objective].length * 1.0,0),offset + GraphicsUtil.invert(scores.get(focus).get(objective),maxRange,lowerMin),ovalDim,ovalDim);
  g.setColor(Color.cyan);
  for (int i=0; i < scores.size(); i++) {
    if (i != focus) {
      g.drawOval(offset + GraphicsUtil.scale(gen,bestScores[objective].length * 1.0,0),offset + GraphicsUtil.invert(scores.get(i).get(objective),maxRange,lowerMin),ovalDim,ovalDim);
    }
  }
  if (tugGoals != null) {
    for (int i=0; i < tugGoals[objective].length; i++) {
      g.setColor(Color.green);
      g.fillRect(offset + GraphicsUtil.scale(i,bestScores[objective].length * 1.0,0),offset + GraphicsUtil.invert(tugGoals[objective][i],maxRange,lowerMin),1,1);
    }
  }
}