Exhaustive Search Method

In the construction of technical analysis trading systems one might use a brute-force or exhaustive search for the optimized set of rules. You select a list of indicators and, for each indicator, the range of possible values.

As an example, one indicator would be the simple moving average. There are versions of that average for the open, high, low, close and volume values at each trading bar. Each of those versions must be tested with a range of periods. One might build tests for each period from 5 to 300 bars.

All indicators must be tested with each of the possible variables. That's everything from the 5-bar, simple moving average of the open to the 300-bar simple moving average of the volume. Now multiply that by the number of bars in your stock's data file.

So far you have built the tests for just one indicator. The number of test combinations quickly explodes.

You might reduce the size of the computing project by limiting the number of indicators or the range of the variables but you can't predict which terms are beneficial to a particular stock's investment system. If you don't evaluate the exponential moving average, for instance, that may be just the indicator which can turn an average system into a great performer for a particular security.

Exhaustive searches are simple to implement but at a price. A computer can be programmed to step through every combination of investment rules and variables to find the best system but the number of calculations is massive. Modern computers are fast but exponentially increasing the demands on them results in a test suite that will take an unreasonable amount of time to complete.

Evolutionary Computation and Genetic Programming

More efficient methods have been developed. To significantly reduce the time required to arrive at a set of technical trading rules you may employ one of the forms of evolutionary computation such as genetic algorithms or genetic programming.

The Genetic System Search for Technical Analysis program uses the latter technology. The algorithm randomly creates a large population of candidate systems. Then by a Darwinian process, the program searches through several generations of evolution for the most fit trading rules. The program ends when no improvements can be made to the solution.

As an additional benefit, further enhancements are possible by adding terms to the fitness formula of the genetic programming algorithm. You can tune the computer program to minimize drawdown or the volatility of trade returns. That's not possible with an exhaustive search.

The technique of evolutionary computation combined with modern computer programming results in a clever solution to an unwieldy problem.