Date: September 20, 2005 14:00GMT
Expert: Erik Long, President of Tetrahex and Principal of Ceres Capital LLC
- We will discuss this useful indicator
- How it can be applied to all trading markets.
Who is Erik Long?
Erik Long has been active in the study of evolutionary feedback systems since his university days at UCLA and CSU from 1987-1992. After obtaining a Bachelors in Bio-Anthropology and Economics, Erik went on to study evolution of markets with the accomplished academic and entrepreneur Dr. Gerald Fecht and notable mathematician Dr. Viktor Fontaine. Erik founded Tetrahex in 1996 as a forum to discuss evolution, entropy, and later fractals in financial markets. In the process Tetrahex later formed into a corporation, offering it's services to private industry. In 1998 Erik studied for his Post Graduate Diploma in Economics at the University of London. Since that time Erik has developed proprietary trading systems for Altea Trading from 2000-2002. Erik has also consulted in non-linear methodologies for Nexbridge Inc., 2000-2002. Erik is one of the founding members of the System Select Group at Peregrine Financial Group, 2002-2004. Mr. Long became a founding principal of Ceres Capital LLC in 2004. Erik Long has been published in Futures magazine and Stocks & Commodities magazine. Mr. Long has been a sponsored member of the New York Academy of Sciences since 1997 and listed in Who'sWho in America since 2003. Erik is available for presentations on a case by case basis.
There has been much talk lately about Chaos theory, fractals and financial markets. Although large amounts of information are available about the theory of these subjects, there is little in terms of practical application. Previous research has determined that most chaotic systems produce some form of graphic representation. A common example is the turbulent flow in a stream producing swirls, eddies and vortices. Unfortunately it has also been discovered that standard Euclidean geometry does not accurately represent chaotic events, so a new type of geometry is needed.
Benoit Mandelbrot recognized the problem and decided to formulate a new type of geometry that could solve the problem of describing chaos. In his pursuit, he realized that many of the problems being researched had a common graphic representation, the squiggly line. So he asked himself the question, “What is the dimension of a squiggly line?” His answer was the creation of a new type of geometry known as fractal geometry.
The problem can be represented in figure 1.
Click to enlarge:
A straight line has a dimension of one. A plane surface has a dimension of two. A squiggly line has a dimension of between 1 and 2, depending on how much squiggle is in the line. The dimension of the squiggly line is actually a fraction of a dimension between 1 and 2. This fractional measurement is commonly known as the fractal dimension of the line. More importantly, others discovered that systems with the same fractal dimension had other properties in common. This of course led to the importance of the fractal dimension as a tool in chaos work.
This is all very interesting, but as traders we are mainly concerned with the application of the fractal dimension to price motion. Fractal dimensions can be used to analyze the price action of any stock or commodity. Depending on the application, fractal dimensions can measure how trendy or congested price action is. In order to do this we must have a tool based on the fractal dimension. To develop this tool, we will look at a problem that interested Mandelbrot. The question is, “How long is a coastline?” The surprise answer is an infinite answer. In other words it can be measured over and over again with different scales of measurement.
To present this more clearly, please look at fig. 2
Click to enlarge:
Which depicts an island and two ways to measure the coastline. In this diagram, the coastline is measured with two different rulers. You can clearly see that the longer ruler will not measure the coastline as accurately as the smaller ruler. Because of this, the larger ruler will indicate a shorter length around the coast than the smaller ruler. Progressively shorter rulers will produce progressively greater distance. Theoretically this can be carried on indefinitely.
In an effort to find a relationship that he could quantify, Mandelbrot plotted the data on log-log charts. The outcome was a relationship between the length of the ruler and the length of the coastline that had a constant slope on the log-log chart. This relationship held up for any coastline. Because of his discovery, Mandelbrot was able to determine that the slope of the log-log chart was one minus the fractal dimension.
Please see figure 3 for a graphic example.
Click to enlarge:
Why is all of this important you may ask?
The answer is that price movement creates a graphical representation that is similar to coastlines. Based on this similarity, it only makes sense to measure price movement with the same approach as the coastlines. Simply put, price movement is a bunch of squiggly lines. A very squiggly line is symptomatic of congested price movement. A less squiggly line is characteristic of more “efficient” price movement. If I measure price from A to B and the price is a straight line, the price efficiency is 100%. Prices rarely do this however, and are usually some degree or fraction of a dimension between a 2d plane and a 1d line,
figure 4. Click to enlarge:
If we wish to measure price efficiency, all that we need to do is divide the length of the straight line by the length of the squiggly line. If we add a plus sign when it is moving up and a negative sign when it is moving down, we have polarized fractal efficiency (PFE).
Please refer to figure 5 to see how this is measured on a stock or commodity chart. We can measure directly from C1 to C2 to get distance B, or measure along each closed bar to get distance A. If we take distance B and divide it by distance A, the efficiency would be 36%. The fractal efficiency equation expresses this efficiency using logarithms. In terms of the coastline example, the measure along each closed bar represents the short ruler. The C1 to C2 distance represents the long ruler.
The mathematical equation for computing PFE is derived in figure 6. Each close to close line is treated as the hypotenuse of a triangle, the length of which is computed as the square root of the squares of the sides. Length A is the close to close length added together. Distance B is the hypotenuse of the triangle between the first and last close.
Applying the PFE is simply a matter deciding what lookback length to use in the chart and then working the calculation for PFE. Traders may also use filter techniques to remove noise caused by trends switching directions. As an example, Tetrahex has used wavelets, adaptive moving averages and non-linear regression with various degrees of success. The filtered PFE is easily plotted under a price chart in most common charting packages such as MetaStock or TradeStation. Dr. Al Larson, the inventor of PFE has found that a five-period exponential moving average is also useful for filtering market noise. Figure 7 illustrates his use of the PFE on the OEX index with a 10-day PFE. According to Dr. Larson, this is a reasonable compromise between computational delay, which is half the span, and usability of the indicator information.
Please note that Dr. Larson has discovered that all stock indices have approximately a 43% maximum efficiency going up or down. Other stock or commodities markets have various maximums, but a maximum is always observed. Bear in mind that the maximum is a commonly observed event, but is not a hard/fast rule. Variations are always possible. You will also see in Figure 7 that the PFE generally has a smooth transition from trending up to down or vice versa. It is possible however, for the PFE to bounce or hover around the zero line in the indicator. This zero level signifies a balance between the forces of supply and demand. Whenever the PFE maintains this zero state, the market is in a congestion zone.
Dr. Larson has made two other observations about the PFE. When the efficiency passes the 66% level in the OEX market, it tends to move sharply to 80%. In many cases the time from the sharp rise to the next top or bottom is a constant time period. This implies that maximum price velocity can only last for X amount of time.
The other behavior is a hook toward maximum efficiency right before the end of an efficient period. See point B in figure 7. This hook usually appears too late to be tradable, but may be used as a confirming indicator with other indicators. When using PFE to trade it is also advisable to place a stop at the point just beyond the hook and watch the PFE. If the PFE begins to trend and then starts to lose traction around the zero level, you may want to exit the trade. On the other hand, if it continues through the zero line, stay with the trade until it reaches efficiency on the other side. Stay in the trade until efficiency starts to reverse again.
Please bear in mind that PFE is not a leading indicator like the Fractal Dimension Index discussed in previous Q&A sessions. PFE is a measure of past price activity. It is recommended that this indicator be used with other indicators and/or with trailing stops. I have found personally that trailing stops and an adaptive moving average work well with this indicator in the forex markets. I encourage experimentation with PFE. You will find that it is easy to use and offers valuable information about any tradable market.
For your convenience I have included MetaStock code for creating the PFE indicator.
Erik Long and Tetrahex would like to give special thanks to Dr. Al Larson and Stocks & Commodities magazine for references in this Q&A presentation.
MetaStock code for creating the PFE indicator:
Polarized Fractal Efficiency
Mov(If(C,>,Ref(C,-9),Sqr(Pwr(Roc(C,9,$),2) + Pwr(10,2)) /
Sqr(Pwr(Roc(C,9,$),2) + Pwr(10,2)) /
Click image to enlarge: