Mathematical and Statistical Methods for Actuarial Sciences and Finance

(Nora) #1

A pattern recognition algorithm for optimal profits in


currency trading


Danilo Pelusi

Abstract.A key issue in technical analysis is to obtain good and possibly stable profits.
Various trading rules for financial markets do exist for this task. This paper describes a pattern
recognition algorithm to optimally match training and trading periods for technical analysis
rules. Among the filter techniques, we use the Dual Moving Average Crossover (DMAC) rule.
This technique is applied to hourly observations of Euro-Dollar exchange rates. The matching
method is accomplished using ten chart patterns very popular in technical analysis. Moreover,
in order for the results to have a statistical sense, we use the bootstrap technique. The results
show that the algorithm proposed is a good starting point to obtain positive and stable profits.

Key words:training sets, trading sets, technical analysis, recognition algorithm

1 Introduction


The choice of the best trading rules for optimal profits is one of the main problems in
the use of technical analysis to buy financial instruments. Park and Irwin [31] described
various types of filter rules, for instance the Dual Moving Average Crossover family,
the Momentum group of rules and the Oscillators. Foreach of these filter rules we
need to find the rule that assures the highest profit. Some good technical protocols,
to get optimal profits in the foreign exchange market, have been found by Pelusi et
al. [32].
The traders attribute to some chart patterns the property of assessing market con-
ditions (in any financial market) and anticipating turning points. This kind of analy-
sis started with the famous [23], which produced an important stream of literature.
However, the popularity of this kind of analysis has been frequently challenged by
mainstream financial economists [7, 9, 22, 28–30, 35].
Generally, the success of a rule in actual trading is independent of the type of
filter used. It depends on the choice of a so-called “training set", where the maximum
profit parameters of a rule are found, and of an independent “trading set" where you
apply the optimised filter found in the training phase. In other words, a rule which
gives good profits in one period could cause some losses in a different period. This
is due to substantial differences in the shapes of the asset price in the two. So, the

M. Corazza et al. (eds.), Mathematical and Statistical Methodsfor Actuarial Sciencesand Finance
© Springer-Verlag Italia 2010

Free download pdf