public JComponent renderChart(List data) {
ArrayList dset = new ArrayList();
ArrayList xlabels = new ArrayList();
Iterator itr = data.iterator();
while (itr.hasNext()) {
DataSet item = (DataSet)itr.next();
SamplingStatCalculator ss = item.getStatistics(this.getURL());
if (ss != null) {
// we add the entry
dset.add(ss);
if ( getXLabel().equals(X_DATA_FILENAME_LABEL) ) {
xlabels.add(item.getDataSourceName());
} else {
xlabels.add(item.getMonthDayYearDate());
}
}
}
double[][] dbset = convertToDouble(dset);
return renderGraphics(dbset, (String[])xlabels.toArray(new String[xlabels.size()]));