EUR/USD optimization: the old optimum looks good enough

User Rating: / 1
PoorBest 
Written by Forex Automaton   
Monday, 06 July 2009 14:02

This study completes the third round of optimizations done with individual (isolated) time series for the major forex exchange rates. What could be a better trading system parameter optimum for EUR/USD turned out to be a disappointment. While investigating the reason, I discovered a new high risk, high return area in the parameter space but ignored it.

1. The basics

The basic framework remains the same: a run of the program included simulations of trading histories of 22736 independent "virtual traders" (forex robots), each of them being an incarnation of the same algorithm, differing by the setting of the adjustable knobs. As in all other published studies so far, the trading is performed on one-decision-a-day time scale, with 1:100 leverage, risking no more than 10% of the trading capital at any point in time. This report uses the EUR/USD day scale data covering the time interval from August 20, 2002 to March 23, 2009, with the actual trading starting in March 2006 (when the initial "training" of the system was completed). The key concepts of conditional projection distributions and profile histograms have been explained before. The trading system control parameters remain as previously defined.

The current mode of the market analysis, when the various exchange rates are being treated by the algorithm in isolation from one another, is not the way the production trading system will operate. However, understanding the markets in isolation and optimizing the system in this simpler problem setting is seen as the first step towards optimization of the more complex algorithm where the amount of information at every point in time will be radically increased by combining multiple exchange rates and the cross-market, as well as intra-market patterns will be taken advantage of.

Repetition of the optimizatin analysis on the independent markets is a great validity test for the entire idea: ideally, if the problem is treated correctly, the algorithmic optimization must deal with bare essentials of the market predictability, with all the transient and non-essential specifics and particulars of the individual exchange rates being left behind and "abstracted" away. Are we indeed dealing with such essentials? If the "best" solutions for the different markets and the very landscape of the optimization problem look different market to market, then the answer is no. The good news is that we see a lot of similarity between such landscapes, and the best way to verify that is to compare the various "Optimizing the forex trading system..." reports in the Forex trading system: are we there yet? section. The more justifiable cut-and-paste you see among such reports, the better. The Forex Automaton genre is different from journalism: re-used content is a signature of failure there and a signature of succes here!

2. Stop-loss optimization

What is the best stop-loss parameter to use in EUR/USD? The answer depends on the time scale of trading, since so does the distribution of returns. The distribution of returns gets broader with time scale; in the random walk problem, your expected root-mean-square departure from the origin grows with time as a square root of time. My stop-loss parameter is not expressed in pips or dollars. Instead, it is a fraction of the root-mean-square of the series of linear returns (price differences) in the nearest subset of the price series. By expressing it in the units of the market volatility, I can have apple-to-apple comparisons between different markets and different time frames.

Effect of stop-loss on the trading returns. Comparing trade entry ranges. EUR/USD.

Fig.2.1. A profile histogram showing dependence of the annualized return (measured directly by comparing equity at the beginning and end points of trading) on the stop-loss placement. Different symbols represent different trade entry parameter ranges. The unit of return is 100% (100%=1).

The more conservative values of the trade-entry parameter are seen to increase the magnitude of the average return for such a marginal distribution, in particular, for the lower stop-loss settings. EUR/USD is unique among the exchange rates analyzed so far, in that not only the magnitude changes, but the very curve changes shape as the entry threshold is varied. More specifically, EUR/USD is the case where a strategy with a very conservative entry requirement and a very tight stop-loss can be profitable on the basis of the forecast signal being researched. Either the shifting of the maximum or its growth with the increase in the entry parameter (non-monotonic, taking place in the lower range of the trade-entry parameter) or both have been seen in all forex markets looked at in enough detail so far. Apparently those more conservative values increase the relative weight of the situations where tighter stop-loss makes sense -- a welcome development, consistent with presence of intelligence in the forecast signal to which the entry threshold is applied.

Fig.2.1 shows that the importance of the trade entry parameter grows as the stop-loss gets tighter (up to a certain point, until everything seems to become a losing strategy with a very tight stop loss). Somewhat counter-intuitively, it is the traders using tight stop-loss who need to be particularly conservative about when to enter a trade. The tight stop-loss is not a replacement for being critical and selective!

3. Trade entry and exit thresholds

Dependence of the annualized return on the trade entry parameter. EUR/USD

Fig.3.1. A profile histogram showing dependence of the actual annualized return on the trade entry threshold parameter. Traders are grouped according to the trade entry threshold parameter, as in the previous figures. The unit of return is 100% (100%=1).

The entry and exit threshold parameters have been explained elsewhere. In Figures 3.1 and 3.2 I present data for the trade entry and trade exit parameters, respectively, grouped and color-coded according to the value of the trade entry parameter. Compared to the previous EUR/USD optimization study, the range of entry parameter has been extended from 0.009 to 0.016. The dynamics of the annualized return in Fig.3.1 is understandable: lack of selectiveness in the trade ideas (the lower settings of the entry threshold parameter) leads to decreased returns. The extreme conservatism, on the other hand, leads to the situation when trades are made so seldom that it is hard to expect returns. Thus, a maximum is to be expected; it seems that it is located in the range of the ENTRY values in the 0.009-0.010 range, already covered in the previous EUR/USD report quoted above. We begin to see the right-side tail of falling returns with more conservative ENTRY values.

Dependence of the annualized return on the trade exit parameter. EUR/USD

Fig.3.2. Profile histograms showing dependence of the actual annualized return on the trade exit threshold parameter. The unit of return is 100% (100%=1).

Speaking of the exit parameter, its influence on the annualized return, seen in Fig.3.2, is very similar to what has been seen for USD/JPY.

In several cases analyzed before, a shift of the entry parameter range toward higher (more conservative) values resulted in an improved optimum. Thus the action on the agenda is to see if this works for EUR/USD.

4. Optimizing the forecasting parameter

We optimize the forecasting quality parameter, the least trivial of all, by playing with the combined (simultaneous) cut on the parameters inspected so far. The parameter is euphemistically called Fred to avoid disclosing its nature.

Optimizing the forecasting control parameter. All entry ranges. EUR/USD. Optimizing the forecasting control parameter. New maximum of return. EUR/USD.

Fig.4.1 Profile histograms showing the dependence of the annualized return on the forecasting control parameter Fred. Top: data are selected and color-coded according to the entry parameter range. Bottom: the "new" optimum. The unit of return is 100% (100%=1).

The bottom panel of Fig.4.1 shows the "new" maximum of the return (and an optimum candidate), with the entry parameter values extended into the newly-explored "conservative" area. I attempt to capitalize on the newly gained understanding of the stop-loss effect (Fig. 2.1) by lowering the stop-loss range somewhat, compared to the optimum found in the previous report. The overall shape in Fig.4.1, with what looks like a broad maximum in the right half of the range, looks familiar, since we found the maximum in the same ballpark for USD/CAD, EUR/USD, AUD/USD, USD/CHF, GBP/USD, and recently, USD/JPY. Since part of the rationale for these studies is to see how consistent the performance-driven selection results for the different currency combinations are, the existence of shared optima among such different currency pairs is a good news.

The new sweet spot remains within the same 71-86 Fred range as the "old" one.

5. The winners

With this input, the preferred ranges of the trading system parameters (both old and new) are given in the Table. Still to be discussed is the risk associated with making a wrong choice of a robot, and how much value is added to the system by the selection of the forecasting parameter, the most problematic of all.

Table 5.1. Preferred values for the EUR/USD forex trading system parameters and the corresponding performance figures. "Yellow" is the new optimum.

Optimum candidate

Green

new: Yellow
Number of traders 126 126
Forecasting parameter, Fred 71, 74, 77, 80, 83, 86 71, 74, 77, 80, 83, 86
Stop-loss placement parameter, s 1.6 1.6
Enter-the-trade threshold parameter, ten 0.007, 0.008, 0.009 0.009, 0.010, 0.011
Exit-the-trade threshold parameter, tex 0.001 through 0.013 0.001 through 0.013
Annualized return mean, 1=100% 0.50 0.40
Annualized return RMS 0.13 0.13
Log annualized monthly return mean 0.35 0.26
Log annualized monthly return RMS mean 1.7
1.6
Log annualized monthly return min mean -2.5 -3.2
Log annualized monthly return max mean 7.1
6.7

Regarding the figures of merit shown in the table, a walk-through is now in order.

  • Annualized return mean and RMS -- these two refer to the group mean and RMS of the group of traders, selected by cutting on the adjustable parameters that control the trading system. The cuts are deliberately loose enough so that the question of overlap between cuts, optimized for the various markets, remains meaningful. As a consequence, we are left not with one, but with dozens of winning traders, thus one can also discuss them as a statistical distribution.

  • Log annualized monthly return RMS mean -- contrary to the above, here the RMS is the characteristic of each individual trader's month-by-month performance, while "mean" characterizes the group of winning traders.

  • Log annualized monthly return mean -- the return is calculated for each winning trader separately and then averaged over traders.

  • Log annualized monthly return min mean -- the minimum is calculated for each trader in the group separately and then averaged over traders.

  • Log annualized monthly return max mean -- the maximum is calculated for each trader in the group separately and then averaged over traders.

The Yellow optimum in the table looks superior to the Green one in almost all respects.

Annualized return distribution, Green forecasting parameter selection on and off Annualized return distribution, Yellow forecasting parameter selection on and off

Fig.5.1. Distributions of the annualized return in the course of the trading system parameter optimization. Black histograms: all parameters except for Fred are as in the respective Table for the "Green" or "Yellow", no selection on Fred. Green and yellow: same as the black in the respective panel, with an extra condition on Fred. Normalization is arbitrary. The unit of return is 100%.

Fig.5.1 presents the summary of progress accomplished so far, using the annualized return statistic. Entries in the histogram are the forex robots (algorithmic traders) and the statistic refers to their trading performance. In the course of the optimization, the initial sample of 22736 forex robots is reduced to two (somewhat overlapping) sets of winners by trading system parameter cuts. The new "yellow" optimum can be compared with the "old" optimum denoted as Green in the Table and shown in green color in Fig.5.1.

From the analysis of various foreign exchange rates so far, it's evident that forecasting is the most tricky aspect of the trading system to optimize. We may end up with a single, compromise approach for all exchange rate or be forced to class exchange rates according to the similarity of the Fred optimization solutions. In either case, we must be prepared to face the worst-case scenario when we will have to admit that the Fred selection adds no value to the algorithm. That's why I am showing the black histograms in Fig.5.1. The black-color data represent the options on the table in the absence of any Fred selection, and show the effect of the money management style selection alone. The Fred selection shifts the return distribution in the positive direction considerably.

Speaking of risk (within the risk vs return framework), there are two kinds of risk to discuss here: the risk of ending up with a "bad" robot which only seemed to be part of the "good" distribution, and the inherent risk of a given robot's strategy. The latter form of risk is the one commonly talked about. Its measure is the Log annualized monthly return RMS mean in Table 5.1, as well as the Log annualized monthly return min mean, Log annualized monthly return max mean, and the spread between the latter two.

While the mean of the distributions in Fig.5.1 is the measure of return, its RMS is the measure of risk associated with choosing a particular robot, or a particular version of the trading system, and its importance is hard to overestimate. One has to minimize the probability of ending up with a "lemon", a robot which belongs to the parent distribution and lands in the negative area of returns. For Gaussian distributions, a good measure of the probability that this happens is the ratio of mean to the RMS (or Sigma). The higher it is, the lower is the chance of a bad choice. This is, essentially, the rationale behind the Sharpe ratio (when different trading strategies, rather than different periods, are used to obtain the return estimate for a set of similar trading strategies). As seen from Table 5.1, the "green" (old) optimum results in better returns while offering comparable risks to the new "yellow" candidate.

This comes as a surprise since on the basis of Fig.3.1, one would expect the opposite outcome. Why didn't it work?

Mean log annualized return vs trading system entry parameter RMS of log annualized return vs trading system entry parameter

Fig.5.2. Dependence of the mean (top panel) and RMS (bottom panel) of the time series of logarithmic monthly returns on the entry threshold parameter of the trading system. Attention: the top plot shows the annualized value while the bottom shows RMS of monthly values.

As it turns out, Fig.3.1, while representing a dependence of the annualized return on the entry parameter on average, does not reflect the specifics of the Fred and stop-loss subspace in the vicinity of the maximum returns. And the specifics, shown in Fig.5.2, top panel, are such that a shift of the entry threshold range to the right of 0.008 does not lead to improvements. Moreover there is another local maximum at or near ENTRY=0.004. However, as the bottom panel indicates, moving down in the entry threshold severely increases the risk (measured as the RMS fluctuation of logarithmic return month-to-month). Thus the new local maximum is unlikely to be a better optimum.

Bookmark with:

Deli.cio.us    Digg    reddit    Facebook    StumbleUpon    Newsvine
Last Updated ( Monday, 04 January 2010 12:31 )