Every once in a while you run accross a free trading system while surfing the web. Often I don’t spend much time with these systems since, more often than not, most turn out to be worthless. I decided to look into this system because it was a breakout method that was designed for the FOREX market. Breakout methods can have some validity and the rule base for the system was simple. In short, this system was very simple and to me, it just might be worth looking into. If this system does not do well, perhaps a few simple tweaks may make it worthwhile. If all else fails, it will be an exercise in properly modifying and testing a trading system.
The system is called Firststrike and the original PDF document describing the system can be found here. The first thing you are presented with is this wonderful looking equity curve based on trading the GBP/USD pair.
The rules of the breakout system are very straightforward and clear in the original PDF document. Here they are:
On Monday morning (0000 Central) note the opening price.
Place a buy stop 50 ticks above the opening price.
Place a Sell Short stop order 50 ticks below the opening price.
Once in a trade set your stop to 60 ticks.
Exit all open positions on Friday afternoon at 1500 Central.
That’s the basic system. What we have is a simple breakout system that enters a trade either long or short, depending upon when price reaches 50 ticks above or below the weekly opening price. Once we are in a trade, how do we manage it? A simple 60 tick stop loss is placed and we exit all open trades at the close of Friday’s session. With this system you make one trade per week and you can either get stopped out or exit on Friday. Simple!
I coded these rules in TradeStation’s EasyLanguage which is available at the bottom of this article. Now the question becomes how well does the system perform? I don’t trade FOREX so I’m going to test it on the Euro currency futures (EC) and deduct $5 for commissions and $25 for slippage per round trip. All back testing will be performed from May of 2001 – December of 2010. The dates beyond December 2010 will be used to test our modifications on “unseen” data. Finally, I applied the strategy to a 5-minute chart and generated the following results: (For the remainder of the article we will call this our “baseline” system.)
Confidence Interval Analysis
Clearly the strategy rules applied to the Euro has no resemblance to the original equity curve for the GBP/USD pair. However, we do see a positive net profit but, it’s far from an ideal equity curve. In this regards, the system appears to be worth looking at. The equity curve stays above the zero line much of the time. This trading strategy may hold a market edge.
Another way to help us determine if this system holds a market edge is to perform a confidence interval test. The purpose in doing this is to demonstrate with 95% confidence that our trading results are likely not due to luck. What we can do is compute a confidence interval around our average trade to help us estimate if our trade was a result of chance. Explaining this is beyond the score of this article, but you can read more here, System Performance and Confidence Interval.
Performing a confidence interval check around our average trade of $97.32 gives us the following information:
We can see the upper band around our average is $245.87 but the lower band is at negative $51.24. This is a problem. Based on our calculation we have estimated with 95% confidence that our trading system’s average net profit could be as low as -$53 or has high as $246. The important number is the lower band because this represents a worse case situation. In our example, we have a negative value which indicates a losing system could be possible. In short, our results could easily be based upon luck. Put another way, the baseline system does not appear to be exploiting a solid market edge.
Testing The Bull/Bear Regime Filter
Moving on, one of the first things I like to test is applying a bull/bear regime filter. This broadly divides the market into two distinct modes: bullish or bearish. Often a simple indicator such as a simple moving average applied to a daily bar chart can be very effective. But it’s not the only indicator you can use. I wrote another article called, “Testing Market Regime Indicators“, that explores several other indicators that could be used. I’m going to apply the same set of tests as used in that article to see what works on EC. Please note, I’m not testing our breakout strategy! I’m simply applying the regime filter daily chart and creating a strategy which buys during a bull market and reverses during a bear market. Based upon the strategies performance I will gauge what I think is the best regime filter.
After testing I determined a simple moving average should be fine. I then tested the lookback period to test the robustness of the lookback period and to locate an optimal region.
Adding The Bull/Bear Regime Filter
We’ll now add the bull/bear regime filter to our baseline system and see if it improves performance. With our new filter applied the strategy will only open trades which are congruent with the primary trend as defined by our regime filter. To do this we will need to add a daily bar chart to our existing chart. This is simply done by adding an additional symbol to our current chart.
Below are the code segments which shows how I create a regime filter and use it in conjunction with the buy/sell short TradeStation commands. The first part of the code sets the BullMarket and BearMarket flags to boolean true or false based upon the closing price relative to the 220-period simple moving average applied to data2. Data2 is our daily price data on the second data stream of our chart. The first data stream is our 15-minute chart.
BullMarket = Close > Average( Close data2, TrendFilter );
Bearmarket = Close < Average( Close data2, TrendFilter );
Based on the BullMarket and BearMarket flags we will take long trades or short trades when price hits our breakout level.
if ( BullMarket ) then Buy("LE") next bar at UpperBand stop;
if ( BearMarket ) then SellShort("SE") next bar at LowerBand stop;
Below are the results of the Firststrike system with our regime filter applied.
The first thing you may notice is we make a little more profit. But net profit is not the only thing to consider when testing a trading system. Look at the equity curve and compare it with our original and ask yourself which one is more tradable. Clearly it has not improved a lot, but it’s no longer below the zero line. Looking further into the numbers you can also see we reduced the number of trades while slightly increasing the profit factor and the average dollar per trade. It’s not a big difference, but it is a positive change. This tells me we removed some unproductive trades. In short, only taking trades in the direction of the primary trend improves the system.
Before we continue testing, what else can we do? Currently we are only taking trades in the direction of the primary trend. But what if we test the opposite of what we just did? That is, only take long trades when price is below the bull/bear regime filter and only take short trades when price is above it? This seems counter intuitive, but we really don’t know what the results will be until we test. Continuing with this line of thinking, we should test taking long trades during a bull and bear market, but only taking short trades during a bear market. Do you see how we can come up with many different combinations to test with this simple filter?
In upcoming issues I’m going to continue testing this trading idea in an attempt to find a tradable solution. At the time of this writing I have no idea if this trading system will be tradable or not. However, either way this is a great exercise in how to test a system.
Jeff is the founder of System Trader Success - a website and mission to empowering the retail trader with the proper knowledge and tools to become a profitable trader the world of quantitative/automated trading.