Search code examples
genetic-algorithmevolutionary-algorithm

Genetic Algorithm Results Presentation


I have data of an experiment that I ran using the genetic algorithm and am trying to present it in a paper. What is a good/ classic way of representing the results of the genetic algorithm. I was thinking of doing a scatterplot representing the maximum fit individuals by their generations. Is this a good representation of the results?


Solution

  • When you gauge the performance of a Genetic Algorithm (or any other stochastic algorithm), you run it multiple times and then aggregate the results to eliminate the effect of some runs being "lucky" or "unlucky". Then it's about presenting such aggregated results.

    For a single run (among many of those), you are typically concerned with the best individual in the fitness only (unless you are analyzing the population dynamics which I think you don't), because that's the output of the algorithm at any given time during its runtime.

    When you have such best individuals for each run, you present the results. Typical visual representation of a GA is an "evolution plot" or "progress plot" (I personally use the first term and other researchers use it too) and it looks something like this (from my master thesis):

    evolution plot example

    I know, it's a little bit messy. However, the solid lines are the medians of the aggregated runs. That means that at X evaluations, for each algorithm the solid line is at the median fitness of all the best individuals from each of the run of the particular algorithm (mean is also used sometimes, but it is not resistant to outliers). The error bars stretch from 1st to 3rd quartile, in my case (standard deviation is also used sometimes, but then the error bars are symmetrical about the solid line and do not show the distribution as much as the quantiles).

    If you are not interested in the progress of the evolution but rather in the final results, you can use e.g. boxplot to properly show the distribution of final values of the algorithms. It looks something like this (again, from my master thesis, corresponds to the evolution plot above):

    final values box plot example

    This one was created in MATLAB. There is an online tool for creating boxplots: http://boxplot.bio.ed.ac.uk

    If you have only a single algorithm to present, you can also combine the evolution plot with boxplot - an evolution plot made of boxplots! You just put a boxplot every N-th evaluation (N depends on the figure size to be readable). The quartile error bars and median solid line is a sort-of a boxplot, in a (distorted) way.

    The last option is to present the results textually (or in a table) supported by some statistical tests. For comparison of two algorithms (the final values), you can use e.g. the Mann-Whitney U-test. Comparing more than two algorithms becomes tricky and you need to find a friendly statistician to help you out :).