Australian (ASX) Stock Market Forum

Books on systems testing and design

There is always huge scope
In gaining useful perspectives

esp from those who are rigorous and innovative in quantitative testing..

The themes in Wyckoff don't necessarily mean they can not be quantified or tested.. it is a matter of working out how and realizing that it will always be limited and more suggestive than definitive...

eg here are some bits and pieces I had come across from this Author..

Using a profit target will:
1. Double the probability of being at or above that target at the end of a fixed period of time.
2. Have no impact on your expected gain or loss.
3. Reduce your variance and standard deviation
4. Result in larger losses than gains

This result derives from the fact that the normal distribution is symmetric and self-similar. Thus it obeys a property called the Reflection Principle. Each price path has an equal and opposite mirror image. Each price point reached has a distribution of points past it and an equal and opposite distribution of points which were 'reflected back'. Elementery proofs for the analogous case of stops, using nothing more than high school algebra, are given in my book Optimal Portfolio Modeling.

It should be emphasized that this is the theoretical model. To the extent that one can find empirical evidence that the market does not conform to this, there may be something tradeable. But just because you can manipulate your distribution to double the probability of a winning trade does not mean that the average winnings will be any better My Motto: You need an edge ”” never let your money leave home without it.

You need an edge ”” never let your money leave home without it.

The ultimate question. Is our fate (and trading success) predetermined or do we have some control over it?

Perhaps a better way to express the problem is through the paradigm of statistical thinking. In statistics the central concept is randomness. Randomness is actually a very deep philosophical issue. It is not the same for all people. Rather randomness depends greatly upon what you know, and different people know different things.

Suppose a company has a great quarter. During the quarter many employees will have a pretty good idea that the quarter is going well. Those at the top such as the CEO and CFO will have a very clear picture. After the end of the quarter the outside auditors may get a good idea as well. Then some time later the earnings report is released to the public and the stock moves unexpectedly. To the outside investor the event seemed random and unpredictable. But clearly someone knew.

The central point is that from the perspective of those who knew of the coming announcement in advance the event was not completely random. From the perspective of those who knew nothing the event was unexpected and seemingly random. Randomness and non-randomness can coexist in different people with different information. So then the best definition of randomness must ultimately be egocentric. What is random to me is that which I do not know and cannot predict.

This concept can be quantified very nicely by various statistical ideas.
A little counting can greatly reduce the randomness in our trading.


Randomness is actually a very deep philosophical issue. It is not the same for all people. Rather randomness depends greatly upon what you know, and different people know different things.

A little counting can greatly reduce the randomness in our trading.


Encoding prices as Binary Codes, from Philip J. McDonnell

Claude Shannon's work on information theory demonstrated conclusively that all information could be efficiently represented in binary code. This breakthrough enabled tremendous advances in digital communications. In addition nearly every computer since that time has used some form of binary storage for both numbers and character oriented information.

With recent discussion of information theory it is appropriate to note that price patterns can be conveniently encoded as binary patterns as well. For example if a day was up that would be a 1 (one) bit and if it was down it would be a 0 (zero). Binary representation only has two digits 1 and 0.


To use this to construct character codes for price patterns we could take the last 3 days of up down net change and assign 1 if up and 0 if down. The pattern + - + would take on the code 101. Here is a table of the first 8 binary numbers:

decimal binary
0 000
1 001
2 010
3 011
4 100
5 101
6 110
7 111

So if we are studying what happens the day after a number 5 pattern we put all those results into bin number five. Thus from the bin 5 results we can calculate the average, standard deviation and probability of being up after that pattern is seen. The same principal applies to the other bins.

Another different use for such bins is to calculate the entropy of all the bins for a recent period. In an earlier study I found that increased entropic diversity tended to be followed by better markets than other periods. One simple measure of this would be to take the last 8 non-overlapping periods of 3 days and set up the bins as described above. We now look at how many fell into each of the 8 bins. The maximum diversity is achieved when each bin contains exactly 1 observation. The minimum is when all observations fall into only one bin. So our resulting statistic is a number from 1 through 8 which can be checked for its relationship to subsequent market performance.

A slight refinement of this would be to do a more sophisticated entropy calculation using a summation of the logs of estimated probabilities per Shannon's original formula.


With recent discussion of information theory it is appropriate to note that price patterns can be conveniently encoded as binary patterns as well.


All of these points are principles of the Wyckoff Mehod

The last is Wyckoff P&F methodology for goodness sake :)

So I am interested .....
( The above are not quotes from the book . But I think it is his only book to date)


He makes a distinction between counting and TA

Perhaps most importantly, counting looks to repeatable observations and analyses. What one observer sees and analyzes looks the same to another counter. Observations are objectively repeatable. By contrast, TA allows chart interpretations. A pattern which one trained analyst sees on a chart may not be interpreted the same way by another. TA allows subjective non-repeatable interpretation whereas counting does not.

Counting requires some sort of significance testing. To my knowledge there is no TA testing software which includes any sort of significance testing. In fact the only time a standard deviation is normally used in TA is in the calculation of John's own Bollinger Bands.

Your knowledge through tradeguider should allow you to see Wyckoff is about counting not TA in this sense

A SOS a Test etc even a "binary pattern" on a P&F chart
are all
repeatable observations and analyses

price volume and time can be given quantifiable definitions
But relative to the prior data

This is exactly what tradeguider tries to do for You
and Wyckoff teaches You to do

P&F patterns are Quantities
No ambiguity at all..

motorway



motorway
 
Thanks for your posts motorway.
I had a look at your link to the book and its looks good.

I already have 2 books on my shelf that havent been read yet, but i will put this one next on the list.
 
Some last interesting snippets from Philip J. McDonnell .

Are moving averages on time series data totally useless or just almost useless ( and what of other such indicators ) ?

Is market behavior best analysed as waves of buying and selling that gather and lose followings ?

Is the key really to be had by noting Where the ""volume comes in"
and what the subsequent response is in the context of prior price movement ?


These three points correspond to...

motorway

The Slutsky-Yule Theorem is quite old and says that taking a moving average of a time series induces periodic motion even though none existed in the data itself. This topic arises periodically. One need not feel to bad after falling into this trap.

There is the famous story of Holbrook Working, a big name economist and arguably the best statistician in the government's employ. His paper, published in the 1960s compendium Random Character of Stock Market Prices seemed to show positive serial correlation in monthly prices. Thus it was a counterpoint to the argument for the random walk. The trend following crowd was born and looked to papers by Working, Alexander and Levy as proof that trend following was the Holy Grail.

Eventually the Working paper was debunked because he had used monthly average prices as his data set. This technique created the Slutzky-Yule effect and artificially induced the apparent serial correlation. When the defect was corrected the correlations were negative. The Alexander and Levy papers were also discredited but for different technical flaws.

Apparently some trend following hedge funds and best selling investment authors still have not received the word.




The Traveler's Dilemma and Prisoner's Dilemma are two examples of cooperative-competitive games. They contain aspects of reward for cooperative behavior and rewards for competitive behavior. In the Traveler's Dilemma game picking a higher number is cooperative play. The player is maximizing the reward to the two-player community. Picking the low Nash Equilibrium is competitive play. The player is maximizing the minimum reward. Naturally as the reward for competitive play increases the number of actual players using competitive strategies increases as well.

There is a strong parallel to the market. If we all buy stocks with all of our money they will go up. The community of investors will all gain. But human nature being what it is we will always be at least somewhat fearful that someone else will sell first and we will be the last to get out. Thus based on a news event or even non-news some will choose the competitive choice to get out early. They seek to avoid the maximum risk of a putative future decline by getting out before the other guy. However the long-term drift strongly indicates that such anti-cooperative behavior is self-defeating and leads to opportunity loss.


Sometimes we do not have the luxury of a perfectly sorted list of items. Occasionally the list may have increasing values up to a certain point and then declining values thereafter. Such an arrangement is known as an unimodal distribution ”” it has only one peak somewhere in the middle. For example a list of the probability values of the normal distribution would have one peak in the middle and a decline thereafter. In optimization problems such a pattern arises quite naturally, with the values to be optimized rising up to a certain point, after which they will fall. That point is the optimum (maximum).

To search a unimodal list the search of choice is called a Fibonacci Search which relies on the spacing between the Fibonacci numbers to calculate its next step size. As such it is more adaptable than the binary search. Under certain circumstances it can be shown that the Fibonacci search is an optimal search algorithm for such problems.

The financial ecosystem requires much upkeep; a massive numbers of people and huge capital investment are required to keep the markets functioning all cost money. The source of revenue to fund these operations comes from three main sources, commissions, market spreads and professional advice and the key driver of all of these revenue sources is volume. The relationship between volume and commissions and market making profits are obvious. Order flow is everything to a commission broker or market maker. However those who sell advice also thrive on volume which is a proxy for interest in the market. When the public is interested in the market more money flows in and a certain portion of that money needs advice. The entire ecosystem of the financial industry thrives on volume, when volume is maximized the health of the financial system is maximized.

In this context it may be that the objective of the markets is not to maximize the price discovery process but rather to maximize the volume of trading, after all the health of the markets is integrally bound to the health of the financial system itself. If volume optimization is the real goal of the market is it not likely that the market uses an efficient search technique to discover the optimum. In this context the Fibonacci search is the best known algorithm for such a search in a unimodal volume environment.

One hastens to note that this is quite different from the mystical application of Fibonacci numbers which some traders try to apply in the price domain.
 
One last time again ...

Pundits have often referred to market gyrations as a price discovery process. The mental image being one of seeking an optimal price via some inscrutable search algorithm. Economists also subscribe to this meme with their ever present assumption of price equilibrium. Implicit in this kind of thinking is that markets will settle down to some sort of stable price in the absence of news shocks. The flaw in both lines of thinking is that speculative markets are never stable - they always fluctuate. What the markets are trying to discover is not price at all but rather volume. In effect the markets are searching for that price level which will maximize volume. It is volume and order flow which nourishes the fixed overhead of the industry which feeds on the the markets. The price is irrelevant to the industry as long as the volume is maximized. Fundamentally this is the reason that markets will always fluctuate. When the market moves up it stimulates sellers to sell who were waiting for their price. At the same time buyers who are trend followers or break out players will buy. The price can move up until volume fades. Then it moves down seeking a new volume peak. The down move brings out new buyers waiting for their price. Sliding prices also stimulate new sellers who are momentum players or simply cutting losses via stops. It is the movement of markets which stimulates volume and the ecology of the market will always seek to maximize volume.

Wyckoff Lives :)

In Wyckoff Terms

The market is there for the benefit of the CM ( Composite Man also called the CO Composite Operator )

And His campaigns are what make it fluctuate


You say all this is unethical, if not unscrupulous. You say it is a
cruel and crooked game. Very well. Electricity can be very cruel,
but you can take advantage of it; you can make it work for your
benefit. Just so with the stock market and the Composite Man. Play
the game as he plays the rules.

Richard D wyckoff; Stock Market Science 1931
 
Kauri wrote

Leon Wilson (from Tassie) recently wrote his second book in which he walks through all the stages of building and testing a mechanical system using MS/Bullcharts and TS. Ends up with a decent system too....

I have read that book. It was actually his third and was called "Breakthrough Trading". A very interesting and enlightening read it was too.

Cheers

Richard.
 
From the Bob Pardo Capital Limited website.
All PCL client funds are exclusively managed by a sophisticated proprietary trading system. This system, XT99, is an advanced algorithmic trading program, signaling all buys and sells across a multitude of international markets and asset classes and without human emotion or judgment.
This is what designing, testing and implementing a trading system is all about. Removing the human emotive factor to produce a positive average return. This is all secret traders business but I can't imagine how any set of instructions could be so fantastic as to warrant such hush hush. What exactly is an advanced algorithm? Are they a combination of (as yet unheard of ) indicators that, when aligned, produce these buy/sell signals.

Also on the website is ...
Trading systems cover numerous strategies, including moving-average crossovers, volatility breakouts, channels, day patterns, chart patterns, etc.
So it isn't anything magical or something no one knows.


I'm sorry but it seems there is a lot of hype surrounding algorithmic trading and there is literally hundreds of thousands of dud systems already created.

Is this another money spinning business within the securities trading industry? Having traders chasing their tails.
 
Does anyone have evidence that mechanical trading/algo trading systems indeed generate profits except by random luck to a few people?
I notice that the best CTA/Hedge fund consistency can make 25-30% over a decade. Is this type of gain even possible to the individual with $100,000 trading account and if so, would it ever be more profitable to trade than a $70,000/year job?
 
Yes.

There is a system which has been running live for 8 yrs on the net.
Still is.
It started with $30k with the capacity for margin and had a peak equity of $450 odd K
It currently has around $350K balance.

I cannot post the link here due to ASF policy.
However if you wish to PM me I will supply the link (unless ASF mods tell me thats not allowed either).
If so then it will remain faceless---but yes I do know of at least one.
 
would it ever be more profitable to trade than a $70,000/year job?

$100k initially in my view NO.
Potentially yes.
But would need for most systems ideal conditions which suit the system for a long period of time.
Then the power of compounding and leverage can kick in.
 
I notice that the best CTA/Hedge fund consistency can make 25-30% over a decade. Is this type of gain even possible to the individual with $100,000 trading account and if so, would it ever be more profitable to trade than a $70,000/year job?

Its not comparable in a lot of ways. A hedge fund and CTA will trade with their money in a very different fashion to the way someone with a robust system would. And don't forget that they also have a larger drag due to admin & commission cost.
 
Thanks all for your kind feedback. I will not take up the offer to view the direct results of the trading system but thank for the offer.

I have only been trading for 1.5 years and I was discouraged and wondering if anyone can achieve profit. I need to find this out for myself in order to truly believe it. I have been experimenting with day trading systems and am not ready to give up yet and move to position trading.
 
Can anyone recommend a book for trading system design ( as opposed to testing ). I just ordered the Bandy book QTS but I think its about testing. I also have gone thru the Pardo book but again this is about testing.

I'm looking for a book that teaches best practices, principles of the actual design steps and process ( e.g. I am familiar with Object Oriented design and design patterns so this is an analogy of what I am looking for.
 
Tushar Chande - Beyond Technical Analysis: How to develop and implement a winning trading system

I also like Charlie Wright - Trading for a Living although it's a lot about testing

Hard to find now, but the Omega Research 'System Trading and Development Club' STAD volumes 1 - 13 very good on system ideas. I pull them out quite often and tweak their ideas and retest.
 
Ooops Charlie Wrights book is Trading as a Business. A free download.

High Probability Trading by Marcel Link is the book I'm currently reading, pretty good.
 
Top