Genetic Programming

Venice supports using evolutionary computation to create new buy/sell rules based on historical data. The default way it works is that Venice initially creates a set of random buy/sell rule equations. A pair of buy/sell rule equations is refered to as an individual. It will then use algebraic simplification to reduce the size of the individual's equations and also to remove any unecessary computation. It will then check the individual's equations using a few simple rules, e.g. is the equation big enough to be meaningful? Is the equation not too large? If the individual's equations look like they could be meaningful, it will paper trade with them, in the same method as the Paper Trade Module. If the individual makes a loss or beaks even, then it will be immediately rejected.

Once Venice has created a set of these random individuals, it will then move onto the second generation. For this generation it will pick two random individuals (with a strong bias to the better performing individuals) and combine them, using a combination of cross-over and mutation, to create a new individual. This process is refered to as breeding. It will again apply algebraic simplification to the resultant individual's equations. It will then paper trade this new individual. If the new individual has a greater return than any of the previous individuals, it will be recorded. Venice will then repeat this process, creating several new individuals. The number of individuals created is refered to as the popluation. The number of the highest returning individuals created which are bred in the next generation, is refered to as the breeding population.

Once a given number of individuals have been created, Venice will then move onto the third generation. Here, it is the same as the second generation, except that instead of breeding from the random individuals that were initially created, it will breed from individuals created that were bred from the random individuals. Each generation then breeds from the individuals bred from the last generation.

While equations created from Genetic Programming can give fantastic returns on historical data, they unfortunately do not transfer directly to different date and symbol ranges, than the ones that they were created with. However, it is an experimental technique to see whether they can actually come up with any principles that can be generally applied.

The Range Page

This is the same as the range page in the Paper Trade Module.

The Portfolio Page

This is the same as the portfolio page in the Paper Trade Module.

The Trade Value Page

This is the same as the trade value page in the Paper Trade Module.

The GP Parameters Page

The genetic programming (GP) parameters page defines the Genetic Programme settings. You can set the number of Generations to run, the Population size, the Breeding Population size, the Display Population size and the Window Size. The display population is the number of highest returning individuals that are displayed when that generation has completed. The Window Size is the maximum number of quote days that an individual will be able to base its buy/sell evaluation on.

Some example values:

The Initial Population Page

In the initial population page you can set many buy/sell rules as you wish. For each of them you need to specify the percentage that it will be used to generate the first population of GP algorithm. You can set Percentage of Random Population, it is used to know the probability to generate a random individual, during the first step of GP algorithm; you can set Percentage of Initial Population, it is used to know the probability to generate an individual got from user defined ones, during the first step of GP algorithm; you can set Number of Mutations, it is the number of mutations that will be applied to the user defined individuals. You can click two buttons: the former can be clicked to calculate the values so that their sum is 100%, the latter can be clicked to set all the tabbed pane values to the default. Normal behaviour should be: put values as you like, then click on the former button to transform the inserted values to percentages.

The GP algorithm will generate the first population in this way: it will choose between a random individual and an individual got from user defined ones, this is done in accordance with the two values Percentage of Random Population and Percentage of Initial Population; then if a user defined is choosen, it will be applied on it a number of mutations equal to Number of Mutations; then if the individual is not fine for breeding, other mutations will be done until it is.

The GP Language Page

The Genetic Programme (GP) Language page defines the Gondola settings. Currently you can set the probabilities for each word of Gondola. So the random GP algorithm will choose the words in accordance with user defined probabilities. If you set any of these values to zero, the GP algorithm will work without considering this word as a Gondola language's word.

To make the selection easy, there are some selectable tabbed panes. Each of them has two buttons: the former can be clicked to calculate the values so that their sum is 100%, the latter can be clicked to set all the tabbed pane values to the default. Normal behaviour should be: put values as you like, then click on the former button to transform the inserted values to percentages.