Development Process — Market Research

A trading idea that is congruent with your market’s characteristics is likely to perform better. Market behaviour can be quantified in countless ways, but I typically focus on historical volatility and ability to trend well. This article will illustrate some methods to quantify these characteristics, giving you a head start in finding a trading solution. Six liquid forex markets, on the hourly timeframe, will be tested: EURUSD, GBPUSD, USDJPY, GBPJPY, EURJPY, EURGBP.

2. Market Research – Trending Tendency

Most strategies can be broadly categorized as being either trend following or countertrend. It would probably be ill-advised to develop an intraday trend strategy for the S&P500, or a countertrend strategy for the short-term interest rates. Even without quantifying the market’s behaviour, having an understanding of the market’s fundamentals will help you get a feel of it. For example, most stocks are not known to trend well because investors’ valuations of the company are highly subjective and tend to vary. The S&P500, being a market index measuring the performance of 500 companies, is even less likely to trend well. Likewise, interest rates track monetary policy and tend to have sustained trends.

I always quantify the market’s tendency to trend before developing a trading idea for it. I will highlight two methods to do so: Kaufman’s Efficiency Ratio, and reversal strategy testing.

2.1. Kaufman’s Efficiency Ratio (ER)

In his extremely comprehensive book ‘Trading Systems and Methods’, Perry Kaufman used the ER to quantify market noise. Noise is random price movement that surrounds any underlying direction. The ER is defined as the net change in price divided by the sum of the individual price changes over the same period. It is a essentially a measure of how smoothly the prices move from point to point over the calculation period. Noisy markets have a low ER and vice versa. The period used is discretionary, but should not exceed the length of the longest price run. Figure 1 demonstrates the calculation of the ER. Closing prices and a 5-bar calculation period were used.

kaufman-efficiency-ratio-formula-1422000

kaufman-efficiency-ratio-calculations-7277477

Figure 1: Computation of the Efficiency Ratio. Markets with less noise produce a higher ratio.

Repeating this computation for our 6 forex markets above, from 2003 to 2018, yields the following results:

Figure 2: Average ER values from 2003-2018. An 18-bar calculation period was used. 

The average ER values for these six markets are surprisingly similar. In fact, I redid the analysis for 28 forex markets, and EURUSD had the largest ER at 0.27, while NZDCAD had the lowest at 0.23. This small ER range may not be ideal if you are trying to rank forex markets in terms of noise. However, if you are comparing markets from completely different categories, such as interest rates vs. stock indices, you will likely see more differentiation. Markets with high ER are good choices for trend following strategies, while those with low ER are better for countertrend strategies. You can replicate the above ER analysis by downloading price history from your provider and doing the computations in Excel.

2.2. Reversal Strategy Testing

This is my preferred method of quantifying a market’s ability to trend. The concept is to test the market with a variety of simple trend following strategies. Better performance implies that the market is more conducive for trend strategies. Although more involved than the ER method, it tends to give a wider range of results and is perhaps more representative of actual trading because it reflects the interaction of your algorithm with the market. Reversal strategies will be used due to their simplicity. To make the tests on our six forex pairs more comprehensive, the tests will include:

  1. Three conceptually different reversal trend strategies, each using a distinct technical indicator to gauge trend direction.
    • Strategy 1 — Simple moving average
    • Strategy 2 — Linear regression line
    • Strategy 3 — Donchian channels
  2. Lookback periods in the 10-100 range, in steps of 10

For strategies 1 and 2, long trades are opened when the moving average/linear regression line slopes upwards, and are reversed when the slope turns down. An illustration of strategy 1 is shown in Figure 3 below.

Figure 3: A simple reversal trend strategy that uses the moving average slope

The Donchian channels used in strategy 3 are simply the zone between the highest high and lowest low over the lookback period, similar to those famously used by the Turtles almost four decades ago. The strategy goes long when price closes above the upper channel boundary, and short when when price closes below the lower boundary.

Net profit will be used for the performance metric because it is readily available in the MT4 backtest reports. Ideally a prudent metric would contain some measure of risk, but at this preliminary stage, net profit should suffice. Alternative metrics include the percentage of profitable optimizations, profit factor etc. Results are shown in Figure 4. Note that the net profit values are the average obtained across the 10 lookback periods, and across all three strategies.

Figure 4: Average net profit from 2008-2018 when backtesting with three different strategies

All six markets show a loss, which should be expected due to the simplicity of the strategies. GBPJPY seems well-suited for a trend strategy. JPY is commonly perceived as a safe haven currency, while the opposite is true for the GBP. This often causes tremendous volatility in GBPJPY when risk sentiment changes, giving it nicknames such as the ‘Dragon’ and ‘Widow Maker’. At the other end of the spectrum lies EURGBP, which often ranges due to the high correlations between EUR and GBP, although this may have changed since Brexit.

3. Market Research – Historical Volatility

Trending markets tend to be volatile as well. Volatility measurements can help corroborate the trend analysis conducted above, or help you determine whether a certain market suits your risk appetite. Wilder’s average true range (ATR) is probably the most common volatility indicator among retail traders. True range measures the high-low range for each bar, while taking possible price gaps into account. Similar to the Efficiency Ratio analysis above, historical ATR for each market can be computed if you have its price history. Using a 14-period lookback, this was done for our six markets from 2003-2018.

Figure 5: Average ATR values from 2003 to 2018

Results are similar to those obtained using the reversal strategies, except that USDJPY is less volatile than expected. These similarities lend confidence to the previous trend analysis.

Volatility can also be quantified using standard deviation, which measures the dispersion of prices from the average value. For the purposes of comparison across markets, either measure should suffice.

4. Trading Applications

Suppose you are a trend follower. The results above indicate that GBPJPY is often volatile and trends well. However, its lower Efficiency Ratio implies that trends may not be as ‘clean’ as expected; expect some whipsaws and frequent reversals.

It may be tempting to cherry-pick 1-2 of the most promising markets and solely develop strategies for them. However, markets are constantly evolving, and there is no guarantee that traditionally trending/ranging markets will remain as such. Unless you can develop a range of diversified strategies for each market, it is best to trade on a larger basket of markets. If you perform the above analysis on 20 markets, perhaps pick the best 8-10 for future development. A multi-strategy, multi-market portfolio provides the best diversification and is your best shot at obtaining a smooth overall equity curve.

5. Conclusion

This article has illustrated some methods of quantifying the volatility and trending tendency of your market. Once these are quantified, a basket of markets can be shortlisted for further strategy development. Since every method has limitations, it is advisable to use several conceptually different methods and look for areas of confluence among them.

The next few articles will address the strategy development process using Metatrader 4.

A

Additional Market Testing

A

Walk-Forward Optimization

strategyquant-4369159

Supercharge your strategy development with StrategyQuant

Access 14-day FREE trial here!

Get up to USD 300 discount!

quantanalyzer_logo-3341811

Strategies need improvement?

Use QuantAnalyzer’s powerful analysis tools

Try the FREE version here!

Get 20% Discount here!

me-3962293

Hey there, Wayne here! I’m on a mission to develop robust algorithmic trading strategies for the forex markets. Trading Tact is where I share my trading methods and insights.