I have made some simple and small changes to the GUI which I feel are well worth
keeping. It allows new chart types to be made easily by simply extending
ChartableStatistics. A new chart can be declared in the parameter file by
simply adding a new statistics child. Now one can have many different charts
displayed in multiple tabs by just adding new statistics children.
I hope that you will consider reviewing and adding these changes to ECJ13. They
offer much greater display functionality and better program structure. If you
are interested, I am willing to add more comments/documentation to the chart
display portion of ECJ13, even a small tutorial.
Attached is the source code for ECJ13 with the changes I have made to the
display files. A more detailed description of the changes I have made are given
below. Note: I also changed the ec.app.gui.coevolve2.params which demonstrates
Georgia Institute of Technology
[log in to unmask]
[log in to unmask]
Summary: Chart types are made by extending ChartableStatistics. An actual
chart must be made by extending the ChartType, where it will then specify what
information the chart type is going to display.
Adjustments to the Display GUI in ECJ13:
In order to improve the capabilities and the flexibility of the display
portion of the gui, the following modifications where made:
This class is now abstract and holds an abstract method makeChart() which will
make and return a chart. It is no longer a class designed specifically for
XYSeries charts so information about such has been removed. Now by extending
ChartableStatistics you can easily add new chart types such as the Bar Chart and
XY Series Chart, which are done in the classes below.
-ec.display.chart.BarChartStatistics and ec.display.XYSeriesStatistics
These classes extend ChartableStatistics. They declare how the chart is made
in the makeChart() method. More classes like these can easily be made to
accommodate different types of charts.
-ec.display.chart.SimpleBarChartStatistics and ec.SimpleXYSeriesStatistics
These are the statistics classes that tell specifically how to construct the
bar charts by giving them the information that is needed. For example, the
SimpleXYSeriesStatistics will construct a line graph of the fitness as it
changes through each generation (this is exactly what the old
SimpleChartableStatistics did, they are equivalent). The
SimpleBarChartStatistics will construct a bar chart that displays the genome
values of the best individual in each subpop.
JFreeChart chart is defined by calling an abstract method, makeChart(), in
ChartableStatistics. The abstract method is defined in each class that extends