October 5, 2011

Recently, I posted the following AAPL chart in the LinkedIn Automated Trading forum.

The chart speaks for itself. It has very impressive numbers. My response was to see if the script used could be improved upon and mostly would it apply to other stocks. The main purpose was to find ways to increase the number of trades over the trading interval as this seemed to be the conclusion of my most recent article (On Seeking Alpha Part III).

Well, in the set of charts listed below, I have tried to push the envelope a little bit further (all from dataset 1, the need to compare again...). I think it would have been very difficult to trade all these charts by hand. They do stress the point on trade automation.

( click to enlarge))

Each of the 10 stocks started with 100k (as per the old WL4 simulator), which means that with 1M, one could have traded the whole group. The purpose here is to show that trading over a share accumulation program can have desirable side effects; and also to show that the above AAPL chart was no fluke, a one of a kind sort of thing.

## Trading Procedures

The trading procedures were performed according to mathematical functions. They just did what they were programmed to do from the start. The functions had no notion of what was coming and could not even try to predict where future prices would go. However, to work, these functions did need a trend definition since technically speaking the buying would be done on the way up using part of the accumulating profits when and if available. In some cases, you could have liquidated positions if you wanted to, with a profit, even after a 50% price drop, as shown in a few of the charts. One even has a 78% drop in price from its recent high and is still highly profitable (see TZOO).

All the charts were tested on the WL4 simulator using the same program version where an uptrend is defined as 3 up days in a row (not the greatest trend definition). It was sufficient to go up by one penny to have an up day. I think that close to half of the entries were the result of a random function, could be more or less (still, a lot were random). I did not keep track of trade origination. All 10 charts were run once, there was no need to run them again, due to the great number of random trades; the final answer would have been different but within expected statistical variance.

Some statistics for the 10 charts: there were 188,969 executed trades on the buy side of which 78,466 positions were closed (about 41%). This averaged out to 18,897 trades per stock, with on average 7,847 closed positions. This left 110,503 positions still opened representing the accumulation side of the equations. The closed trades are highly correlated to profits (r^{2 }= 0.81) which corroborates the notion that the closed trades are feeding the accumulative stance of the program.

## The Backtest

In the 10 charts presented, the back-tests were performed almost blind. I did not see the data except for the last 11 months (about 220 days) of the 1,500 days back-test; and even there, it was after the test. The simulator and the data itself were on the Wealth-Lab site. All I supplied was the script and the symbol to be tested. I could have tested 10 more ticker symbols which, I think, would have given about the same results. But I thought that my point was made: that is that the number of trades does count after all. And since my trading methodology is scalable, I could push performance even higher.

By increasing function parameters to the governing quadratic equations, I could increase trading volume and the number of trades which is, I think, the main reason for the above average performance. You can find the equations in my papers. All the ingredients are there to do the same and/or better.

I cannot be certain how the trading procedures behaved prior to those 11 months except in a statistical sense: they must have done this and that. I knew what the equations would have done depending on price movements, but I have no idea as to the price movement itself prior to those 11 months. Not seeing the data might be considered a different type of script testing. One thing is sure, it is hard to optimize what you don't see.

## The Trading Methods

The trading methods in that script were totally path dependent, which path you could not see except again for the last 11 months. But it did not matter: I played mathematical equations that would gradually expand day by day to finally span the whole 1,500 trading days. I was playing quadratic equations, power functions that were related but independent of price. I was in a way playing inventory management with a bent on acquisitions. (see my Alpha Power papers).

The reason to increase the trading volume is explained in my most recent article (On Seeking Alpha Part III). It is not only having an edge that matters, it turns out that being able to apply it more often really matters too.

The above charts show so much promise that I can not investigate further. So now, the questions left open, for me at least, are: 1- what is really happening prior to the last 11 months, 2- what is the impact of each of the trading procedures used, 3- how can I control the whole set of equations better?

Created on ... October 5, 2011, © Guy R. Fleury. All rights reserved.