Saturday, October 27, 2018

The Fisher Transform - Multi-Timeframe Entry and Exits


If you are on the blog page in a web browser from a computer, please subscribe to this using the "Follow by Email" link to the left.  If you're on a mobile device you should see something in the frame that allows you to subscribe.  Having your email helps me to notify you when Google mucks up email distribution.

~~~~~~~~~~

The Fisher Transform

Yesterday I published results related to the impact of position sizing on your portfolio.  If you've not read this I urge you to do so; the link is here:

https://fwdtest.blogspot.com/2018/10/more-preliminary-results-fisher.html

Two days ago I published buy/sell information related to the Fisher Transform, and that link is here:

https://fwdtest.blogspot.com/2018/10/preliminary-results-fisher-transform.html

Both of these entries should be useful if you want to see how strategy development occurs in the Duncan mindset.

Today I'm going to expand on the buy/sell information that I posed earlier; here I want to qualify criteria across multiple time frames and see if the original data that I presented holds.  This is called a "sliding window" test, and it basically puts the criteria of one window against other windows, helping us to ensure that differences are highlighted.  I received an email asking about this so I thought it would be helpful for everybody to see the results.

Here is the generalized set up:
  • Sample Duration:  10 years
  • Moving Window Approach:  2002-2012, 2004-2014, 2006-2016, 2008-2018, all windows ending on 9/30 of their respective year
  • Sample Stocks:  The stocks of the NASDAQ-100.
  • Starting equity:  $100,000.00, no margin.
  • Position Size:  1% of equity, commissions & slippage not considered
  • Fisher Transform Window Size:  10 days for Daily, 5 weeks for Weekly.  I have discussed elsewhere that John Ehlers picked the 10-day window length and I've confirmed that this is the best length given multiple window tests.
  • Position entry requirement:  The close > 50d MA > 150d MA > 200d MA.  
  • Enter / exit on the next day open after the signal bar
  • If entering a position, hold it at least 1 bar to avoid whipsaws.
The test conditions are relatively straight forward:
  • Consider two time frames:  weekly, daily.
  • Enter / exit if the weekly and daily are in a particular combination of uptrend and/or downtrend
  • Enter / exit if the previous week or previous day were opposite than the current week or day, and the current week or day is in a particular known combination of uptrend or downtrend.
  • Ignore weekly conditions for the sell and just test for daily conditions to exit
When you do these various combinations you end up with 24 unique tests per window (weekly can be uptrend/downtrend, daily can be uptrend/downtrend for a total of 16 unique combinations, and if we ignore the weekly data and just re-evaluate the daily, that is another 8), 

2002 - 2012 Optimized Entry/Exit Results

Here are the top 4 results from 2002 to 2012.  The period contains a significant drawdown event in 2008-2009:

Click on the image above to enlarge.

The list is sorted from highest equity descending.  There is about a 3:1 reward/risk component, which I consider acceptable.  

The top performer contains the following rules:
  1. Enter when the WEEKLY Fisher Transform transitions from a downtrend to an uptrend AND the DAILY is already in an uptrend.  Put another way, the weekly is confirming the daily trend.
  2. Enter when the DAILY Fisher Transform transitions from a downtrend to an uptrend AND the WEEKLY is already in an uptrend.  Put another way, if the weekly is already in an uptrend and the daily has whipsawed in and out and comes back in, enter when the DAILY goes to the uptrend.
  3. Enter when the WEEKLY Fisher Transform transitions from an uptrend to a downtrend (0) and the daily is already in a downtrend.  This means that the daily has fallen and is being confirmed now by the weekly.  This is a "buy the dip" condition that we are familiar with.
  4. Enter when the DAILY Fisher Transform transitions from an uptrend to a downtrend (0) and the weekly is already in a downtrend.  This should rarely happen, since the daily should lead the weekly down.
  5. Exit criteria varies.  
    1. Two of the top 4 performers suggest that you exit when the weekly transitions to an uptrend (1) from and downtrend AND the daily was already in a downtrend (0).  
    2. The third top performer suggests that you exit when the WEEKLY transitions from an uptrend to a downtrend (0) AND the daily is an an uptrend.  
    3. The 4th top performer suggests ignoring the weekly signal (-1) and exit if the daily transitions to a downtrend (0).
All of these are plausible, so should be part of our tool kit.

2004 - 2014 Optimized Entry/Exit Results

Moving onto 2004-2014 yields the following results:

Click on the image above to enlarge.

Take a look at the right side of the figure -- it varies somewhat from 2002-2012 but if you look closer, the ordering is different but the conditions are the same.  The TOP performer maps to the second-best performer for the 2002-2012 period, but in general, the entry and exit conditions are consistent between the two window periods.


2006 - 2016 Optimized Entry/Exit Results


Click on the image above to enlarge.

Again, look at the right side of the 2006-2016 figure.  The top performer is the 0-0-1-0 sequence, which was the top performer in the 2004-2014 test window and the 2nd best performer in the 2002-2012 window.  The other three sets are the same as the previous windows too, they are just in a difference order.

Finally, to relate this to the blog entry of two days ago and using the SP 500 (recall that these tests have been with the NASDAQ-100):

2008 - 2018 Optimized Entry/Exit Results



Click on the image above to enlarge.

The top performer is the same as the 2006-2016 and 2004-2014 top performer.  All the others are present too-- just reordered.

Furthermore, this set of data matches the tests presented two days ago for the SP500.

~~~~~~~~~~

Conclusions

There are incredibly consistent results across the period 2002 - 2018.  I note the following:
  1. Although the magnitude of the portfolios varied in each 10-year moving window, the number of trades remained fairly consistent.
  2. Entering and exiting trades as listed above gives us a defined range that we should experience performance, independent of changing market conditions.  
  3. From a rational point of view, each of the different entry/exit conditions are "plausible" in that if we were simply doing ad-hoc trading we would most likely duplicate one of the entry and one of the exit conditions.  All I have done here is quantified and explicitly identified each of the conditions so that we can track them.

~~~~~~~~~~


I tackled position sizing yesterday and we established that between 5-20 positions would be ideal from a Total Return / Maximum Drawdown perspective.  I arbitrarily selected 11 positions as the go-forward portfolio size.

Additional work that follows is now to consider the use of stop losses and profit targets, and do so across a large range of trades.

~~~~~~~~~

That's all for now.  If you have questions -- ask.

~~~~~~~~~

As with all my ramblings, you are responsible for your own actions and I am not.  Nothing I've written here is advice to buy or sell any security, so don't do it unless you absolutely take ownership for your actions.

Regards,

Paul

No comments:

Post a Comment